Very Timely. grrrrrr. Cheers,
-- Jim On 10-Jan-07, at 8:35 PM, Reid Spencer wrote: > > > Changes in directory llvm/lib/System: > > DynamicLibrary.cpp updated: 1.19 -> 1.20 > --- > Log message: > > Avoid taking the address of a macro by checking to see if stdin is > defined > or not. This allows DynamicLibrary.cpp to compile on Darwin. > > > --- > Diffs of the changes: (+4 -0) > > DynamicLibrary.cpp | 4 ++++ > 1 files changed, 4 insertions(+) > > > Index: llvm/lib/System/DynamicLibrary.cpp > diff -u llvm/lib/System/DynamicLibrary.cpp:1.19 llvm/lib/System/ > DynamicLibrary.cpp:1.20 > --- llvm/lib/System/DynamicLibrary.cpp:1.19 Wed Jan 10 13:50:43 2007 > +++ llvm/lib/System/DynamicLibrary.cpp Wed Jan 10 18:35:10 2007 > @@ -167,10 +167,14 @@ > #define EXPLICIT_SYMBOL(SYM) \ > if (!strcmp(symbolName, #SYM)) return &SYM > // Try a few well known symbols just to give lli a shot at working. > + // Note that on some systems stdin, etc. are macros so we have to > + // avoid attempting to take the address of a macro :) > { > +#ifndef stdin > EXPLICIT_SYMBOL(stdin); > EXPLICIT_SYMBOL(stdout); > EXPLICIT_SYMBOL(stderr); > +#endif > } > #undef EXPLICIT_SYMBOL > > > > > _______________________________________________ > llvm-commits mailing list > llvm-commits@cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits