Merge branch 'master' of github.com:Araq/Nimrod

This commit is contained in:
Araq 2013-02-10 15:06:39 +01:00
commit fa14466b5b
3 changed files with 28 additions and 16 deletions

View file

@ -298,8 +298,18 @@ type
replaceData*: proc (start, len: int, text: cstring) {.nimcall.}
setAttribute*: proc (name, value: cstring) {.nimcall.}
setAttributeNode*: proc (attr: ref TNode) {.nimcall.}
when defined(kwin):
proc rawEcho {.compilerproc, nostackframe.} =
asm """
var buf = "";
for (var i = 0; i < arguments.length; ++i) {
buf += `toEcmaStr`(arguments[i]);
}
print(buf);
"""
when defined(nodejs):
elif defined(nodejs):
proc ewriteln(x: cstring) = log(x)
proc rawEcho {.compilerproc, nostackframe.} =