Reserve is keyword.
This commit is contained in:
parent
5c31ec7f78
commit
43363e0660
@ -7,6 +7,11 @@ Version 1.4.0
|
|||||||
This version adds support for integer _ranges_ via the `..` and `..=` operators.
|
This version adds support for integer _ranges_ via the `..` and `..=` operators.
|
||||||
Many standard API's are extended with range parameters where appropriate.
|
Many standard API's are extended with range parameters where appropriate.
|
||||||
|
|
||||||
|
Script-breaking changes
|
||||||
|
-----------------------
|
||||||
|
|
||||||
|
* `is` is (pun intended) now a reserved keyword to prepare for possible future type checking expressions (e.g. `x is "string"`).
|
||||||
|
|
||||||
New features
|
New features
|
||||||
------------
|
------------
|
||||||
|
|
||||||
@ -100,8 +105,8 @@ Bug fixes
|
|||||||
Version 1.2.0
|
Version 1.2.0
|
||||||
=============
|
=============
|
||||||
|
|
||||||
Bug fixes with breaking script changes
|
Bug fixes (potentially script-breaking)
|
||||||
-------------------------------------
|
--------------------------------------
|
||||||
|
|
||||||
* As originally intended, function calls with a bang (`!`) now operates directly on the caller's scope, allowing variables inside the scope to be mutated.
|
* As originally intended, function calls with a bang (`!`) now operates directly on the caller's scope, allowing variables inside the scope to be mutated.
|
||||||
* As originally intended, `Engine::XXX_with_scope` API's now properly propagate constants within the provided scope also to _functions_ in the script.
|
* As originally intended, `Engine::XXX_with_scope` API's now properly propagate constants within the provided scope also to _functions_ in the script.
|
||||||
|
@ -786,11 +786,16 @@ impl Token {
|
|||||||
#[cfg(feature = "no_module")]
|
#[cfg(feature = "no_module")]
|
||||||
"import" | "export" | "as" => Reserved(syntax.into()),
|
"import" | "export" | "as" => Reserved(syntax.into()),
|
||||||
|
|
||||||
"===" | "!==" | "->" | "<-" | ":=" | "~" | "::<" | "(*" | "*)" | "#" | "#!"
|
// List of reserved operators
|
||||||
| "public" | "protected" | "super" | "new" | "use" | "module" | "package" | "var"
|
"===" | "!==" | "->" | "<-" | ":=" | "~" | "::<" | "(*" | "*)" | "#" | "#!" => {
|
||||||
| "static" | "shared" | "with" | "goto" | "exit" | "match" | "case" | "default"
|
Reserved(syntax.into())
|
||||||
| "void" | "null" | "nil" | "spawn" | "thread" | "go" | "sync" | "async" | "await"
|
}
|
||||||
| "yield" => Reserved(syntax.into()),
|
|
||||||
|
// List of reserved keywords
|
||||||
|
"public" | "protected" | "super" | "new" | "use" | "module" | "package" | "var"
|
||||||
|
| "static" | "shared" | "with" | "is" | "goto" | "exit" | "match" | "case"
|
||||||
|
| "default" | "void" | "null" | "nil" | "spawn" | "thread" | "go" | "sync"
|
||||||
|
| "async" | "await" | "yield" => Reserved(syntax.into()),
|
||||||
|
|
||||||
KEYWORD_PRINT | KEYWORD_DEBUG | KEYWORD_TYPE_OF | KEYWORD_EVAL | KEYWORD_FN_PTR
|
KEYWORD_PRINT | KEYWORD_DEBUG | KEYWORD_TYPE_OF | KEYWORD_EVAL | KEYWORD_FN_PTR
|
||||||
| KEYWORD_FN_PTR_CALL | KEYWORD_FN_PTR_CURRY | KEYWORD_THIS | KEYWORD_IS_DEF_VAR => {
|
| KEYWORD_FN_PTR_CALL | KEYWORD_FN_PTR_CURRY | KEYWORD_THIS | KEYWORD_IS_DEF_VAR => {
|
||||||
|
Loading…
Reference in New Issue
Block a user