diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2018-11-08 08:15:10 +0100 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2018-11-08 09:15:15 +0100 |
commit | 05683e3aab430abdaeefba144a07f468d33aa8ee (patch) | |
tree | 6b86062ec6ddea7a96ca39d5fe94be6475f85376 /tests/parser | |
parent | d0a02fe66bb01ef49645a11562c72fa585170b8e (diff) | |
download | Nim-05683e3aab430abdaeefba144a07f468d33aa8ee.tar.gz |
fixes #9633
Diffstat (limited to 'tests/parser')
-rw-r--r-- | tests/parser/tprecedence.nim | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/tests/parser/tprecedence.nim b/tests/parser/tprecedence.nim index cdf4ad3ee..aff7c6aca 100644 --- a/tests/parser/tprecedence.nim +++ b/tests/parser/tprecedence.nim @@ -1,7 +1,8 @@ discard """ output: '''holla true -defabc 4''' +defabc 4 +0''' """ # Test top level semicolon works properly: @@ -24,3 +25,18 @@ echo "def".foo[:string, string]("abc"), " ", 4.bar[:int] proc isFalse(a: int): bool = false assert not isFalse(3) + +# bug #9633 + +type + MyField = object + b: seq[string] + + MyObject = object + f: MyField + +proc getX(x: MyObject): lent MyField {.inline.} = + x.f + +let a = MyObject() +echo a.getX.b.len |