Do notation without parentheses

2017-06-05 Thread bluenote
I'm still getting confused about the do notation. In particular I'm surprised that the following gives an error "redefinition of x": import future proc takesFunc(f: () -> void) = f() takesFunc do: var x = 1 takesFunc do: var x = 1 Th

Re: Proxy difficulties

2017-06-05 Thread halibetlector
Ok, will do. Thanks!

Comparing AST symbols

2017-06-05 Thread ephja
How do I do this? I'm currently trying to write a macro that will ensure that a block references some or all of the members of a certain enum type. A 'case' statement can't always be used for this purpose.

Re: Difficulty writing wrapper using FFI

2017-06-05 Thread cmacmackin
@yglukhov I was thinking the same thing.

Re: Difficulty writing wrapper using FFI

2017-06-05 Thread yglukhov
As a side note, should not byCopy be an argument attribute instead of being a type attribute? And should not it be the default for importc procs?

Re: Difficulty writing wrapper using FFI

2017-06-05 Thread Araq
That is a c2nim bug, it should add `.bycopy`.

Re: How to use Visual Studio Code to configure NIM quickly

2017-06-05 Thread hcorion
Hi! This is bordering on spam. Please explain what your trying to 'configure'. Have you installed Nim: [https://nim-lang.org/install.html](https://nim-lang.org/install.html)

Re: Difficulty writing wrapper using FFI

2017-06-05 Thread cmacmackin
Adding the bycopy pragma fixed it. I must say, that's a pretty subtle requirement and it could do with a more prominent place in the documentation of the FFI.