rdmenezes / ting

Automatically exported from code.google.com/p/ting
0 stars 0 forks source link

Missing namespace: using u32 directly instead of ting::u32 #33

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago

http://code.google.com/p/ting/source/browse/trunk/src/ting/timer.cpp#69

Replace:
{{{
void Lib::TimerThread::AddTimer_ts(Timer* timer, u32 timeout){
}}}

With:
{{{
void Lib::TimerThread::AddTimer_ts(Timer* timer, ting::u32 timeout){
}}}

Original issue reported on code.google.com by david.a...@gmail.com on 22 May 2012 at 6:11

GoogleCodeExporter commented 9 years ago
Please, merge with #34.

Original comment by david.a...@gmail.com on 22 May 2012 at 6:13

GoogleCodeExporter commented 9 years ago
Issue 34 has been merged into this issue.

Original comment by igagis@gmail.com on 22 May 2012 at 7:37

GoogleCodeExporter commented 9 years ago
Fixed on trunk, r881.

By the way, which compiler do you use? Does it complain about that u32 is used 
without specifying the name space? There is a "using namespace ting::timer" 
statement at the top of the file, and it looks like it makes all declarations 
from ting name space also visible, g++-4.6 compiler eats this without any 
complains.

Original comment by igagis@gmail.com on 22 May 2012 at 7:45

GoogleCodeExporter commented 9 years ago
In Visual Studio 2010, importing a symbol in a namespace only imports that 
symbol, so ting::timer is defined but u32 is not.

I don't know if this behaviour is conformant to the standard, but it happens 
here :-/

Original comment by david.a...@gmail.com on 23 May 2012 at 12:10

GoogleCodeExporter commented 9 years ago
Moving to Verified because the fix is trivial.

Original comment by igagis@gmail.com on 23 May 2012 at 9:07