Error in

For other topics related to the FreeBASIC project or its community.
Posts: 218
Joined: Mar 12, 2006 16:25

Error in

Postby RockTheSchock » May 22, 2015 11:36

I tried EGNP/ TSNE and found some errors in It seems to be a regression in preprocessor.

Sizeof((t)) with 2 parenthesis doesnt work anymore:

Code: Select all

#Define _A(t) (CLng(sizeof((t))) )
Screen 0
#Print _A(ULong)
Print _A(Ulong)


In you will need to fix sizeof((t)) with sizeof(t)

Code: Select all

#define _IOR(x, y, t) ...
#define _IOW(x, y, t)...

Then there are missing OpenSocket, Selectsocket. I added the 2 lines to Maybe not optimal.

Code: Select all

#define OpenSocket Socket
#Define Selectsocket select_

Then I replaced in all occurences of V_INT by V_INTEG.
EGNP / TSNE should use it's own namespace to avoid duplicated definition errors. But changing that is another task.
Site Admin
Posts: 3202
Joined: Jul 28, 2005 14:45
Location: Germany

Re: Error in

Postby dkl » May 23, 2015 19:45


both the sizeof() issue and the missing #defines should be fixed in Git now. Thanks for reporting. The former was a bug in the translation process (too many parentheses), the latter looks like an FB-specific extension of the Windows API headers that was lost when the new binding was made.

Return to “Community Discussion”

Who is online

Users browsing this forum: No registered users and 3 guests