fix #1001
This commit is contained in:
parent
cf8fe16a48
commit
4d2c948281
3 changed files with 3 additions and 2 deletions
|
|
@ -518,7 +518,7 @@ proc searchForInnerProcs(o: POuterContext, n: PNode) =
|
||||||
else:
|
else:
|
||||||
internalError(it.info, "transformOuter")
|
internalError(it.info, "transformOuter")
|
||||||
of nkProcDef, nkMethodDef, nkConverterDef, nkMacroDef, nkTemplateDef,
|
of nkProcDef, nkMethodDef, nkConverterDef, nkMacroDef, nkTemplateDef,
|
||||||
nkClosure:
|
nkClosure, nkTypeSection:
|
||||||
# don't recurse here:
|
# don't recurse here:
|
||||||
# XXX recurse here and setup 'up' pointers
|
# XXX recurse here and setup 'up' pointers
|
||||||
discard
|
discard
|
||||||
|
|
|
||||||
|
|
@ -34,6 +34,7 @@ type
|
||||||
T.x
|
T.x
|
||||||
y(T)
|
y(T)
|
||||||
intval T.y
|
intval T.y
|
||||||
|
let y = intval(T.y)
|
||||||
|
|
||||||
proc y(x: TObj): int = 10
|
proc y(x: TObj): int = 10
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ type
|
||||||
C.len is Ordinal
|
C.len is Ordinal
|
||||||
items(c) is iterator
|
items(c) is iterator
|
||||||
for value in C:
|
for value in C:
|
||||||
value.type is T
|
type(value) is T
|
||||||
|
|
||||||
proc takesIntContainer(c: Container[int]) =
|
proc takesIntContainer(c: Container[int]) =
|
||||||
for e in c: echo e
|
for e in c: echo e
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue