Scorpio's egbbprobe (bugs??)

Programming Topics (Computer Chess) and technical aspects as test techniques, book building, program tuning etc

Moderator: Andres Valverde

Scorpio's egbbprobe (bugs??)

Postby jason_lavigne » 24 Jun 2008, 11:57

Hi all,

going through the source of the egbbso.so, I recently downloaded from:

http://dshawul.googlepages.com/home

I have noticed that "size" in "EGBB::decode()", and "block_size" in "EGBB::get_score" are redeclared. Correct me if I am wrong on this. My previous experience suggests to me that this might turn into some nasty bugs later on. By the way, turning on some warnings in g++, I get:

...
egbbdll.cpp: In member function ‘UBMP64 EGBB::read_bytes(int)’:
egbbdll.cpp:465: warning: use of old-style cast
egbbdll.cpp:467: warning: use of old-style cast
egbbdll.cpp: In member function ‘int EGBB::decode(UBMP8*, UBMP8*, UBMP32)’:
egbbdll.cpp:479: warning: declaration of ‘size’ shadows a member of 'this'
egbbdll.cpp:536: warning: use of old-style cast
egbbdll.cpp: In member function ‘int EGBB::get_score(UBMP32, SEARCHER*)’:
egbbdll.cpp:572: warning: declaration of ‘block_size’ shadows a member of 'this'
egbbdll.cpp:591: warning: declaration of ‘block_size’ shadows a member of 'this'
...

Another thing, what's up with the old style casts? It would be much cleaner to use static_cast<...>(...), don't you think?

Thanks,
Jason Lavigne
jason_lavigne
 
Posts: 3
Joined: 22 Jun 2008, 15:58
Location: Canada, ON

Return to Programming and Technical Discussions

Who is online

Users browsing this forum: No registered users and 42 guests

cron