tinvalidnot.nim 343 B

1234567891011121314151617181920
  1. discard """
  2. errormsg: "type mismatch"
  3. file: "tinvalidnot.nim"
  4. line: 14
  5. """
  6. # BUG: following compiles, but should not:
  7. proc nodeOfDegree(x: int): bool =
  8. result = false
  9. proc main =
  10. for j in 0..2:
  11. for i in 0..10:
  12. if not nodeOfDegree(1) >= 0: #ERROR_MSG type mismatch
  13. echo "Yes"
  14. else:
  15. echo "No"
  16. main()