-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
\private\scrolwin.nim(6, 58) Error: cannot convert 3221225472 to clong #21
Comments
Good catch! This was something that was changed in Nim at some point (that hex literals can't be negative signed numbers). But it is curious that I haven't seen this issue myself on Linux. Is the |
I got the same problem. My env is as follow: On win7 |
Was this from just running one of the examples? Or do you have a small code snippet I can try to reproduce this with? |
I just tested the examples of wxnim, which are in folder examples\purewx . And the wxWidgets version is 3.1.4 |
Hmm, I haven't tested with the newer 3.1.4 branch, only the 3.0.5 version. Could you try that? |
I get the same error with this minimal example:
Compiles in linux (wx 3.0.5, nim 1.4.2) using Fails crosscompiling using
Fails compiling in Windows 10 (wx 3.1.4, nim 1.4.2) using Installed wx-3.0.5 to get the same error. |
So it seems: |
Hmm, that is peculiar. The underlying issue is probably that recent-ish versions of Nim restricted the ways numbers could be converted between signed and unsigned types. I think changing line 6 of scrollwin.nim to |
That get rid of the "can't be converted", but the compilation still fails:
|
I think that's a completely separate issue, probably caused by this https://github.com/PMunch/wxnim/blob/master/wxnim/wxCompile.nim#L67. Someone else implemented this, so I don't really have much to go on here. Maybe @fredrikhr could help out? |
Ooops. That's a copy-paste error that has been there a loooong time 😮 It seems that I just copied Line 29 in 2250d01
/I for include, but G++ does not.
The fix is to change |
Error: type mismatch: got but expected 'clong = int32'
On win10
Nim Compiler Version 1.4.2 [Windows: amd64]
Seems to be some problem with 64bit/32bit definition for clong, as it expects int32 but the value is an unsigned 0xC000000
The text was updated successfully, but these errors were encountered: