Merge branch 'devel' into bigbreak
Conflicts: web/news.txt
This commit is contained in:
commit
201d3c9ed0
7 changed files with 35 additions and 27 deletions
|
|
@ -153,7 +153,7 @@ proc importModuleAs(n: PNode, realModule: PSym): PSym =
|
||||||
localError(n.info, errGenerated, "module alias must be an identifier")
|
localError(n.info, errGenerated, "module alias must be an identifier")
|
||||||
elif n.sons[1].ident.id != realModule.name.id:
|
elif n.sons[1].ident.id != realModule.name.id:
|
||||||
# some misguided guy will write 'import abc.foo as foo' ...
|
# some misguided guy will write 'import abc.foo as foo' ...
|
||||||
result = createModuleAlias(realModule, n.sons[1].ident, n.sons[1].info)
|
result = createModuleAlias(realModule, n.sons[1].ident, realModule.info)
|
||||||
|
|
||||||
proc myImportModule(c: PContext, n: PNode): PSym =
|
proc myImportModule(c: PContext, n: PNode): PSym =
|
||||||
var f = checkModuleName(n)
|
var f = checkModuleName(n)
|
||||||
|
|
@ -173,7 +173,7 @@ proc evalImport(c: PContext, n: PNode): PNode =
|
||||||
# ``addDecl`` needs to be done before ``importAllSymbols``!
|
# ``addDecl`` needs to be done before ``importAllSymbols``!
|
||||||
addDecl(c, m) # add symbol to symbol table of module
|
addDecl(c, m) # add symbol to symbol table of module
|
||||||
importAllSymbolsExcept(c, m, emptySet)
|
importAllSymbolsExcept(c, m, emptySet)
|
||||||
importForwarded(c, m.ast, emptySet)
|
#importForwarded(c, m.ast, emptySet)
|
||||||
|
|
||||||
proc evalFrom(c: PContext, n: PNode): PNode =
|
proc evalFrom(c: PContext, n: PNode): PNode =
|
||||||
result = n
|
result = n
|
||||||
|
|
@ -198,4 +198,4 @@ proc evalImportExcept*(c: PContext, n: PNode): PNode =
|
||||||
let ident = lookups.considerQuotedIdent(n.sons[i])
|
let ident = lookups.considerQuotedIdent(n.sons[i])
|
||||||
exceptSet.incl(ident.id)
|
exceptSet.incl(ident.id)
|
||||||
importAllSymbolsExcept(c, m, exceptSet)
|
importAllSymbolsExcept(c, m, exceptSet)
|
||||||
importForwarded(c, m.ast, exceptSet)
|
#importForwarded(c, m.ast, exceptSet)
|
||||||
|
|
|
||||||
|
|
@ -1949,11 +1949,13 @@ proc semExport(c: PContext, n: PNode): PNode =
|
||||||
while s != nil:
|
while s != nil:
|
||||||
if s.kind in ExportableSymKinds+{skModule}:
|
if s.kind in ExportableSymKinds+{skModule}:
|
||||||
x.add(newSymNode(s, a.info))
|
x.add(newSymNode(s, a.info))
|
||||||
|
strTableAdd(c.module.tab, s)
|
||||||
s = nextOverloadIter(o, c, a)
|
s = nextOverloadIter(o, c, a)
|
||||||
if c.module.ast.isNil:
|
when false:
|
||||||
c.module.ast = newNodeI(nkStmtList, n.info)
|
if c.module.ast.isNil:
|
||||||
assert c.module.ast.kind == nkStmtList
|
c.module.ast = newNodeI(nkStmtList, n.info)
|
||||||
c.module.ast.add x
|
assert c.module.ast.kind == nkStmtList
|
||||||
|
c.module.ast.add x
|
||||||
result = n
|
result = n
|
||||||
|
|
||||||
proc setGenericParams(c: PContext, n: PNode) =
|
proc setGenericParams(c: PContext, n: PNode) =
|
||||||
|
|
|
||||||
|
|
@ -2125,8 +2125,7 @@ elif hostOS != "standalone":
|
||||||
inc(i)
|
inc(i)
|
||||||
{.pop.}
|
{.pop.}
|
||||||
|
|
||||||
proc echo*[T](x: varargs[T, `$`]) {.magic: "Echo", tags: [WriteIOEffect], gcsafe,
|
proc echo*[T](x: varargs[T, `$`]) {.magic: "Echo", tags: [WriteIOEffect], gcsafe.}
|
||||||
locks: 0.}
|
|
||||||
## Writes and flushes the parameters to the standard output.
|
## Writes and flushes the parameters to the standard output.
|
||||||
##
|
##
|
||||||
## Special built-in that takes a variable number of arguments. Each argument
|
## Special built-in that takes a variable number of arguments. Each argument
|
||||||
|
|
@ -2142,7 +2141,7 @@ proc echo*[T](x: varargs[T, `$`]) {.magic: "Echo", tags: [WriteIOEffect], gcsafe
|
||||||
## instead.
|
## instead.
|
||||||
|
|
||||||
proc debugEcho*[T](x: varargs[T, `$`]) {.magic: "Echo", noSideEffect,
|
proc debugEcho*[T](x: varargs[T, `$`]) {.magic: "Echo", noSideEffect,
|
||||||
tags: [], raises: [], locks: 0.}
|
tags: [], raises: [].}
|
||||||
## Same as `echo <#echo>`_, but as a special semantic rule, ``debugEcho``
|
## Same as `echo <#echo>`_, but as a special semantic rule, ``debugEcho``
|
||||||
## pretends to be free of side effects, so that it can be used for debugging
|
## pretends to be free of side effects, so that it can be used for debugging
|
||||||
## routines marked as `noSideEffect <manual.html#nosideeffect-pragma>`_.
|
## routines marked as `noSideEffect <manual.html#nosideeffect-pragma>`_.
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,9 @@ discard """
|
||||||
|
|
||||||
import mexporta
|
import mexporta
|
||||||
|
|
||||||
|
# bug #1029:
|
||||||
|
from rawsockets import accept
|
||||||
|
|
||||||
# B.TMyObject has been imported implicitly here:
|
# B.TMyObject has been imported implicitly here:
|
||||||
var x: TMyObject
|
var x: TMyObject
|
||||||
echo($x, q(0), q"0")
|
echo($x, q(0), q"0")
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,9 @@
|
||||||
discard """
|
discard """
|
||||||
file: "tselfimport.nim"
|
file: "tselfimport.nim"
|
||||||
line: 6
|
line: 7
|
||||||
errormsg: "A module cannot import itself"
|
errormsg: "A module cannot import itself"
|
||||||
"""
|
"""
|
||||||
|
import strutils as su # guard against regression
|
||||||
import tselfimport #ERROR
|
import tselfimport #ERROR
|
||||||
echo("Hello World")
|
echo("Hello World")
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -192,8 +192,14 @@
|
||||||
${If} $0 == "success"
|
${If} $0 == "success"
|
||||||
ZipDLL::extractall "$TEMP\?zipName" "$INSTDIR\?dir"
|
ZipDLL::extractall "$TEMP\?zipName" "$INSTDIR\?dir"
|
||||||
Delete "$TEMP\?zipName"
|
Delete "$TEMP\?zipName"
|
||||||
|
${ElseIf} $0 == "cancel"
|
||||||
|
MessageBox MB_ICONQUESTION|MB_YESNO|MB_TOPMOST \
|
||||||
|
"Download of component '?sectionName' cancelled. Continue installation process??" \
|
||||||
|
IDYES ignore
|
||||||
|
abort
|
||||||
${Else}
|
${Else}
|
||||||
MessageBox MB_ICONSTOP|MB_ABORTRETRYIGNORE "Error: $0" IDRETRY retry IDIGNORE ignore
|
MessageBox MB_ICONSTOP|MB_ABORTRETRYIGNORE|MB_TOPMOST "Error: $0" \
|
||||||
|
IDRETRY retry IDIGNORE ignore
|
||||||
abort
|
abort
|
||||||
${EndIf}
|
${EndIf}
|
||||||
|
|
||||||
|
|
@ -252,4 +258,4 @@
|
||||||
Function .onInit
|
Function .onInit
|
||||||
${GetRoot} "$EXEDIR" $R0
|
${GetRoot} "$EXEDIR" $R0
|
||||||
strCpy $INSTDIR "$R0\?{c.name}"
|
strCpy $INSTDIR "$R0\?{c.name}"
|
||||||
FunctionEnd
|
FunctionEnd
|
||||||
|
|
|
||||||
25
web/news.txt
25
web/news.txt
|
|
@ -13,16 +13,6 @@ News
|
||||||
prevent name conflicts with the new type ``FileHandle``.
|
prevent name conflicts with the new type ``FileHandle``.
|
||||||
- Comments are now not part of the AST, as such you cannot use them in place
|
- Comments are now not part of the AST, as such you cannot use them in place
|
||||||
of ``discard``.
|
of ``discard``.
|
||||||
- The ``irc`` module has been moved into its own
|
|
||||||
`repository <https://github.com/nimrod-code/irc>`_
|
|
||||||
and is now a Nimble package.
|
|
||||||
- Many wrappers have been moved into their own repositories and are now
|
|
||||||
Nimble packages including ``lua``, ``opengl``, ``x11``, ``nim-zmq``,
|
|
||||||
``gtk2``, ``mongo``, ``cairo``, ``tcl``, ``python`` and
|
|
||||||
`more <https://github.com/Araq/Nimrod/issues/623>`_. They can be
|
|
||||||
found under the `nim-code <https://github.com/nimrod-code>`_ organisation.
|
|
||||||
- Removed the deprecated ``web`` module, the ``httpclient`` module should
|
|
||||||
be used instead.
|
|
||||||
- Large parts of the stdlib got rid of the T/P type prefixes. Instead most
|
- Large parts of the stdlib got rid of the T/P type prefixes. Instead most
|
||||||
types now simply start with an uppercased letter. The
|
types now simply start with an uppercased letter. The
|
||||||
so called "partial case sensitivity" is now active allowing for code
|
so called "partial case sensitivity" is now active allowing for code
|
||||||
|
|
@ -63,7 +53,7 @@ News
|
||||||
2014-10-19 Nimrod version 0.9.6 released
|
2014-10-19 Nimrod version 0.9.6 released
|
||||||
========================================
|
========================================
|
||||||
|
|
||||||
**Note: 0.9.6 is the last release of Nimrod. The language has been renamed to
|
**Note: 0.9.6 is the last release of Nimrod. The language is being renamed to
|
||||||
Nim. Nim slightly breaks compatibility.**
|
Nim. Nim slightly breaks compatibility.**
|
||||||
|
|
||||||
This is a maintenance release. The upcoming 0.10.0 release has
|
This is a maintenance release. The upcoming 0.10.0 release has
|
||||||
|
|
@ -95,13 +85,20 @@ Changes affecting backwards compatibility
|
||||||
will disappear soon!
|
will disappear soon!
|
||||||
|
|
||||||
|
|
||||||
|
Compiler improvements
|
||||||
|
---------------------
|
||||||
|
|
||||||
|
- Multi method dispatching performance has been improved by a factor of 10x for
|
||||||
|
pathological cases.
|
||||||
|
|
||||||
|
|
||||||
Language Additions
|
Language Additions
|
||||||
------------------
|
------------------
|
||||||
|
|
||||||
- This version introduces the new ``deprecated`` pragma statement that is used
|
- This version introduces the ``deprecated`` pragma statement that is used
|
||||||
to handle the upcoming massive amount of symbol renames.
|
to handle the upcoming massive amount of symbol renames.
|
||||||
- ``spawn`` can now wrap proc that has a return value. It then returns a flow
|
- ``spawn`` can now wrap proc that has a return value. It then returns a data
|
||||||
variable of the wrapped return type.
|
flow variable of the wrapped return type.
|
||||||
|
|
||||||
|
|
||||||
Library Additions
|
Library Additions
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue