tassign_nil_strings.nim 218 B

1234567891011121314
  1. discard """
  2. cmd: "nim $target --nilseqs:off $options $file"
  3. output: "Hello"
  4. ccodecheck: "\\i@'a = ((NimStringDesc*) NIM_NIL)'"
  5. """
  6. proc main() =
  7. var a = "Hello"
  8. echo a
  9. a = ""
  10. doAssert a.len == 0
  11. main()