-
Notifications
You must be signed in to change notification settings - Fork 15
Fixed -O -inline and -release incompatibilty with Orange. #36
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
base: master
Are you sure you want to change the base?
Conversation
… for Windows. Exactly the same as unittest.sh, but ported to a batch file.
… unittests_and_release
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this issue reported?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, but tests failed when -O -inline was added to unittest.sh (and there was an obscure comment in the Makefile's). The output was the following:
orange.serialization.SerializationException.SerializationException@orange\serial
ization\SerializationException.d(25): Could not find an element "array" with the
attribute "key" with the value "arr".
----------------
0x004273EA in D6orange13serialization10Serializer10Serializer6__ctorMFC6orange13
serialization8archives7Archive7ArchiveZC6orange13serialization10Serializer10Seri
alizer9__lambda2MFNaNfC6orange13serialization22SerializationException22Serializa
tionExceptionZv
----------------
when compiling with -g -O -inline -release.
--jm
Fixed Primitive.d and added to pull request. |
Could you please squash these commits in to one. Or perhaps two, one for the Windows unit test file and one for the rest. |
No problem, I'll create one branch for the unittest.bat file and |
I'm a little busy today, I won't have time to separate the commits until tonight. |
No rush. |
…unittests_and_release
Are the commits squashed? I would prefer to not have an extra merge commit. Could you please do a rebase instead of a merge? |
Fixed -O -inline and -release incompatibilty with Orange. (inlining was omitting the 'else' block of the static ifs in toData and fromData).
I really needed to make it work with -O -inline, and I'm happy that I've found the problems. If there is a better way, please use that instead.
Also added an automatic "unittest.bat" runner for Windows ("ported" unittest.sh, gathering *.d in the same way in a batch file).
The "Primitive" test now passes in Windows, though the FP string zero representation should actually be portable? (Maybe I have a locale difference? "0x0.p+0" vs "0x0p+0").
--Juan Manuel Cabo