Denys Duchier wrote: > I had a couple of problems using some of Gecode macros because they > cannot all be safely followed by a semicolon. Here is a proposed > patch > that uses de "do {...} while (0)" pattern to make these macros safe. > This is an old trick that is used a great deal in the Linux kernel.
Right, it's even mentioned in the cpp documentation: http://gcc.gnu.org/onlinedocs/gcc-3.2.3/cpp/Swallowing-the-Semicolon.html Thanks, it's in the trunk now. Cheers, Guido _______________________________________________ Gecode users mailing list us...@gecode.org https://www.gecode.org/mailman/listinfo/gecode-users