To explain what's going on here you declared your `open` as a `func` instead of 
a `proc`. In Nim a `func` is closer to a pure mathematical function, or the 
functions found in functional programming languages. They can't do IO, they 
can't read global state, etc. A procedure in Nim is what your probably used to 
as a "function" in languages like C and JavaScript.

Reply via email to