This commit is contained in:
Araq
2014-10-26 13:36:42 +01:00
parent a639824e5e
commit fdf996925b
3 changed files with 10 additions and 1 deletions

View File

@@ -448,6 +448,9 @@ proc semAsmOrEmit*(con: PContext, n: PNode, marker: char): PNode =
addSon(result, newSymNode(e))
else:
addSon(result, newStrNode(nkStrLit, sub))
else:
# an empty '``' produces a single '`'
addSon(result, newStrNode(nkStrLit, $marker))
if c < 0: break
a = c + 1
else: illFormedAst(n)

View File

@@ -382,7 +382,10 @@ Example:
{.pop.}
embedsC()
As can be seen from the example, to Nim symbols can be referred via backticks.
Use two backticks to produce a single verbatim backtick.
ImportCpp pragma
----------------

View File

@@ -49,6 +49,9 @@ News
os.getEnv, os.existsEnv, os.dirExists, os.fileExists,
system.writeFile
- Two backticks now produce a single backtick within an ``emit`` or ``asm``
statement.
2014-10-19 Nimrod version 0.9.6 released
========================================