On 9/25/07, Daniel Berlin <dberlin at dberlin.org> wrote:> On 9/24/07, Bill Wendling <isanbard at gmail.com> wrote: > > On Sep 24, 2007, at 3:15 PM, Dale Johannesen wrote: > > > > Weird. I see a potential problem, though. The code is like this: > > > > void dumpToDOUT(SparseBitVector<> *bitmap) { > > dump(*bitmap, DOUT); > > } > > > > where dump expects an llvm::OStream& for the second argument. > > However, when NDEBUG is #defined, DOUT is "llvm::OStream(0)", so it > > can't be passed by reference. > What compiler are you compiling with? > I build release and debug builds on darwin (and run the testsuite) > before i check in my changes :). >I'm just using GCC, though it's on Leopard. I'm not sure if they have a fix to catch this type of code.> You can feel free to remove the function, it is simply a GDB helper :) >I just put it inside #ifdef's, so it now works. :-) -bw
On 9/25/07, Bill Wendling <isanbard at gmail.com> wrote:> On 9/25/07, Daniel Berlin <dberlin at dberlin.org> wrote: > > On 9/24/07, Bill Wendling <isanbard at gmail.com> wrote: > > > On Sep 24, 2007, at 3:15 PM, Dale Johannesen wrote: > > > > > > Weird. I see a potential problem, though. The code is like this: > > > > > > void dumpToDOUT(SparseBitVector<> *bitmap) { > > > dump(*bitmap, DOUT); > > > } > > > > > > where dump expects an llvm::OStream& for the second argument. > > > However, when NDEBUG is #defined, DOUT is "llvm::OStream(0)", so it > > > can't be passed by reference. > > What compiler are you compiling with? > > I build release and debug builds on darwin (and run the testsuite) > > before i check in my changes :). > > > I'm just using GCC, though it's on Leopard. I'm not sure if they have > a fix to catch this type of code.I am also compiling on leopard, 9a559 :)
On 9/25/07, Daniel Berlin <dberlin at dberlin.org> wrote:> On 9/25/07, Bill Wendling <isanbard at gmail.com> wrote: > > On 9/25/07, Daniel Berlin <dberlin at dberlin.org> wrote: > > > On 9/24/07, Bill Wendling <isanbard at gmail.com> wrote: > > > What compiler are you compiling with? > > > I build release and debug builds on darwin (and run the testsuite) > > > before i check in my changes :). > > > > > I'm just using GCC, though it's on Leopard. I'm not sure if they have > > a fix to catch this type of code. > > I am also compiling on leopard, 9a559 :) >Okay. :-) I'm not sure what I'm doing differently. It could just be an artifact of how the Apple-style builds are done (it's a bit of a black-box to me). Anyway, It's actually more of a problem with the LLVM streams in general. -bw