NimYAML
NimYAML copied to clipboard
Future compile-time error in dom.nim
When using the last tag (v0.16) or the cloned repo, I get this warning with Nim 1.6.6
yaml/dom.nim(195, 3)
Warning: Cannot prove that 'result' is initialized. This will become a compile time error in the future. [ProveInit]
Just reporting if you plan to update the code there, thanks for the library!
Frankly that warning has been around as long as this library. I won't believe this'll ever happen until it does.
I wouldn't know how to change the code to make this go away since the code does surely initialize result
unless an exception is raised. Hence this warning is more a Nim bug than a NimYAML bug.
Thanks for reporting, but this is not something I plan to spend my time on. Leaving this open in case someone else wants to.
Good to know :) Thanks for the prompt reply!
The warning lied to us. We are now in the Nim 2.0.0 future and instead of becoming a compile time error, the warning is gone :)
Closing the issue.