bugfix: #line generation for windows
This commit is contained in:
parent
d5dd4669df
commit
a1cdd6e7ff
3 changed files with 14 additions and 3 deletions
|
|
@ -18,8 +18,8 @@ proc genLineDir(p: BProc, t: PNode) =
|
||||||
if line < 0:
|
if line < 0:
|
||||||
line = 0 # negative numbers are not allowed in #line
|
line = 0 # negative numbers are not allowed in #line
|
||||||
if optLineDir in p.Options and line > 0:
|
if optLineDir in p.Options and line > 0:
|
||||||
appff(p.s[cpsStmts], "#line $2 \"$1\"$n", "; line $2 \"$1\"$n",
|
appff(p.s[cpsStmts], "#line $2 $1$n", "; line $2 \"$1\"$n",
|
||||||
[toRope(toFilename(t.info)), toRope(line)])
|
[makeCString(toFilename(t.info)), toRope(line)])
|
||||||
if ({optStackTrace, optEndb} * p.Options == {optStackTrace, optEndb}) and
|
if ({optStackTrace, optEndb} * p.Options == {optStackTrace, optEndb}) and
|
||||||
(p.prc == nil or sfPure notin p.prc.flags):
|
(p.prc == nil or sfPure notin p.prc.flags):
|
||||||
appcg(p, cpsStmts, "#endb($1);$n", [toRope(line)])
|
appcg(p, cpsStmts, "#endb($1);$n", [toRope(line)])
|
||||||
|
|
|
||||||
|
|
@ -2511,7 +2511,7 @@ special ``:`` syntax:
|
||||||
In the example the two ``writeln`` statements are bound to the ``actions``
|
In the example the two ``writeln`` statements are bound to the ``actions``
|
||||||
parameter.
|
parameter.
|
||||||
|
|
||||||
**Note:** Symbol binding rules for templates might change!
|
**Note:** The symbol binding rules for templates might change!
|
||||||
|
|
||||||
Symbol binding within templates happens after template instantation:
|
Symbol binding within templates happens after template instantation:
|
||||||
|
|
||||||
|
|
|
||||||
11
todo.txt
11
todo.txt
|
|
@ -48,6 +48,17 @@ version 0.9.XX
|
||||||
- checked exceptions
|
- checked exceptions
|
||||||
- fix implicit generic routines
|
- fix implicit generic routines
|
||||||
- think about ``{:}.toTable[int, string]()``
|
- think about ``{:}.toTable[int, string]()``
|
||||||
|
- nice idea:
|
||||||
|
|
||||||
|
p(a, b):
|
||||||
|
echo a
|
||||||
|
echo b
|
||||||
|
|
||||||
|
is the same as:
|
||||||
|
|
||||||
|
p(a, b, proc() =
|
||||||
|
echo a
|
||||||
|
echo b)
|
||||||
|
|
||||||
Library
|
Library
|
||||||
-------
|
-------
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue