lexer: Implement workspace <number> "<name>"
This commit is contained in:
parent
0ed2d62263
commit
0e8b87e9da
|
@ -257,6 +257,16 @@ workspace:
|
|||
workspace_set_name(&(workspaces[ws_num - 1]), $<string>8);
|
||||
}
|
||||
}
|
||||
| TOKWORKSPACE WHITESPACE NUMBER workspace_name
|
||||
{
|
||||
int ws_num = $<number>3;
|
||||
if (ws_num < 1 || ws_num > 10) {
|
||||
LOG("Invalid workspace assignment, workspace number %d out of range\n", ws_num);
|
||||
} else {
|
||||
if ($<string>4 != NULL)
|
||||
workspace_set_name(&(workspaces[ws_num - 1]), $<string>4);
|
||||
}
|
||||
}
|
||||
;
|
||||
|
||||
workspace_name:
|
||||
|
|
Loading…
Reference in New Issue