Files
Nim/tests/collections/ttableconstr.nim
Adam Strzelecki e80465dacf tests: Trim .nim files trailing whitespace
via OSX: find . -name '*.nim' -exec sed -i '' -E 's/[[:space:]]+$//' {} +
2015-09-04 23:04:32 +02:00

17 lines
305 B
Nim

# Test if the new table constructor syntax works:
template ignoreExpr(e: expr): stmt {.immediate.} =
discard
# test first class '..' syntactical citizen:
ignoreExpr x <> 2..4
# test table constructor:
ignoreExpr({:})
ignoreExpr({2: 3, "key": "value"})
# NEW:
assert 56 in 50..100
assert 56 in ..60