[ros-dev] DPRINT

Royce Mitchell III royce3 at ev1.net
Thu Dec 9 14:02:25 CET 2004


Royce Mitchell III wrote:

> Well, first off I could do it in a way that DPRINT(foo) wouldn't 
> compile, so it would remind them automatically
>
> The only other solutions I've come up with are less pretty:
>
> 1)  DPRINT0(foo) DPRINT1(foo,a) DPRINT2(foo,a,b) etc...
>      a serious problem with this is that DPRINT1 already means 
> something different than DPRINT...
>
> 2) #define _C_ ,
>     DPRINT(foo _C_ a _C_ b)
>      this is ugly and probably couldn't be protected from uncaring 
> mingwers.

hardon pointed out that we are doing this for MSVC, which is a good 
enough solution, I guess:

#define DPRINT DbgPrint("(%s:%d) ",__FILE__,__LINE__); DbgPrint

The reason I brought all this up is because last time I started to try 
to compile for msvc I was running into this problem. I guess somebody 
fixed it while I was away.



More information about the Ros-dev mailing list