diff options
author | Araq <rumpf_a@web.de> | 2012-09-22 10:04:31 +0200 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2012-09-22 10:04:31 +0200 |
commit | 3ef146b0eacb8781dd0e352925001de342d6cc9d (patch) | |
tree | c7f24c6cb75c872aff2bd0694d9d0eec3b3b88b1 | |
parent | 4577751bad1a2421921eb8c9bf40a4961daceb78 (diff) | |
download | Nim-3ef146b0eacb8781dd0e352925001de342d6cc9d.tar.gz |
'mixin' and 'interface' are now keywords
-rwxr-xr-x | compiler/lexer.nim | 13 | ||||
-rwxr-xr-x | compiler/wordrecg.nim | 9 | ||||
-rwxr-xr-x | doc/keywords.txt | 4 | ||||
-rwxr-xr-x | web/news.txt | 2 |
4 files changed, 16 insertions, 12 deletions
diff --git a/compiler/lexer.nim b/compiler/lexer.nim index 488c30f92..faa9fc672 100755 --- a/compiler/lexer.nim +++ b/compiler/lexer.nim @@ -38,10 +38,12 @@ type tkConst, tkContinue, tkConverter, tkDiscard, tkDistinct, tkDiv, tkDo, tkElif, tkElse, tkEnd, tkEnum, tkExcept, tkExport, tkFinally, tkFor, tkFrom, - tkGeneric, tkIf, tkImport, tkIn, tkInclude, tkIs, tkIsnot, tkIterator, + tkGeneric, tkIf, tkImport, tkIn, tkInclude, tkInterface, + tkIs, tkIsnot, tkIterator, tkLambda, tkLet, - tkMacro, tkMethod, tkMod, tkNil, tkNot, tkNotin, tkObject, tkOf, tkOr, - tkOut, tkProc, tkPtr, tkRaise, tkRef, tkReturn, tkShl, tkShr, tkStatic, + tkMacro, tkMethod, tkMixin, tkMod, tkNil, tkNot, tkNotin, + tkObject, tkOf, tkOr, tkOut, + tkProc, tkPtr, tkRaise, tkRef, tkReturn, tkShl, tkShr, tkStatic, tkTemplate, tkTry, tkTuple, tkType, tkVar, tkWhen, tkWhile, tkWith, tkWithout, tkXor, tkYield, # end of keywords @@ -72,9 +74,10 @@ const "const", "continue", "converter", "discard", "distinct", "div", "do", "elif", "else", "end", "enum", "except", "export", "finally", "for", "from", "generic", "if", - "import", "in", "include", "is", "isnot", "iterator", + "import", "in", "include", "interface", "is", "isnot", "iterator", "lambda", "let", - "macro", "method", "mod", "nil", "not", "notin", "object", "of", "or", + "macro", "method", "mixin", "mod", + "nil", "not", "notin", "object", "of", "or", "out", "proc", "ptr", "raise", "ref", "return", "shl", "shr", "static", "template", "try", "tuple", "type", "var", "when", "while", "with", "without", "xor", diff --git a/compiler/wordrecg.nim b/compiler/wordrecg.nim index 8397ce5d2..963b493db 100755 --- a/compiler/wordrecg.nim +++ b/compiler/wordrecg.nim @@ -27,8 +27,8 @@ type wContinue, wConverter, wDiscard, wDistinct, wDiv, wDo, wElif, wElse, wEnd, wEnum, wExcept, wExport, wFinally, wFor, wFrom, wGeneric, wIf, wImport, wIn, - wInclude, wIs, wIsnot, wIterator, wLambda, wLet, - wMacro, wMethod, wMod, wNil, + wInclude, wInterface, wIs, wIsnot, wIterator, wLambda, wLet, + wMacro, wMethod, wMixin, wMod, wNil, wNot, wNotin, wObject, wOf, wOr, wOut, wProc, wPtr, wRaise, wRef, wReturn, wShl, wShr, wStatic, wTemplate, wTry, wTuple, wType, wVar, wWhen, wWhile, wWith, wWithout, wXor, wYield, @@ -104,9 +104,10 @@ const "discard", "distinct", "div", "do", "elif", "else", "end", "enum", "except", "export", "finally", "for", "from", "generic", "if", - "import", "in", "include", "is", "isnot", "iterator", + "import", "in", "include", "interface", "is", "isnot", "iterator", "lambda", "let", - "macro", "method", "mod", "nil", "not", "notin", "object", "of", "or", + "macro", "method", "mixin", "mod", "nil", "not", "notin", + "object", "of", "or", "out", "proc", "ptr", "raise", "ref", "return", "shl", "shr", "static", "template", "try", "tuple", "type", "var", "when", "while", "with", "without", "xor", diff --git a/doc/keywords.txt b/doc/keywords.txt index 9638dc12a..03e9cc6fd 100755 --- a/doc/keywords.txt +++ b/doc/keywords.txt @@ -5,9 +5,9 @@ discard distinct div do elif else end enum except export finally for from generic -if import in include is isnot iterator +if import in include interface is isnot iterator lambda let -macro method mod +macro method mixin mod nil not notin object of or out proc ptr diff --git a/web/news.txt b/web/news.txt index ae6df0b29..f6a7dd112 100755 --- a/web/news.txt +++ b/web/news.txt @@ -74,7 +74,7 @@ Changes affecting backwards compatibility The ``system``, ``os``, ``osproc`` and ``memfiles`` modules use the wide string versions of the WinAPI. Use the ``-d:useWinAnsi`` switch to revert back to the old behaviour which uses the Ansi string versions. -- ``static`` and ``do`` are now keywords. +- ``static``, ``do``, ``interface`` and ``mixin`` are now keywords. - Templates now participate in overloading resolution which can break code that uses templates in subtle ways. Use the new ``immediate`` pragma for templates to get a template of old behaviour. |