> Ben Allison wrote: > >> As mentioned before, this removes some of the 'inline' from the >> bitreader >> and bitwriter functions that were used in another translation unit. >> I'm >> surprised that this code works on other platform. It must be a bug in >> GCC, or maybe deliberately non-standard behavior. See 6.7.4 of the C99 >> spec for details. > > I've read section 6.7.4 from here: > > http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1124.pdf > > My reading of that section suggests that the usage in FLAC is valid and > correct.
Take, for example, the function FLAC__bitreader_is_consumed_byte_aligned. It is prototyped in bitreader.h It is used in stream_decoder.c, so it must be defined and made available to the linker ("external definition"). However, the only definition in bitreader.c has been declared inline. >From 6.7.4.6 An inline definition does not provide an external definition for the function, and does not forbid an external definition in another translation unit. An inline definition provides an alternative to an external definition, which a translator may use to implement any call to the function in the same translation unit. > As for the addition of safe_malloc_mul_2op_ to file src/share/utf8/utf8.c, > that simply should not be necessary. I suggest this is an error in the > Visual Studio project files. Correct. Rummaging through the code more, it appears that the 'grabbag_static' project isn't compiling grabbac/alloc.c, which is why this is undefined. When I get to the office I will fix up the project files. -Ben Allison _______________________________________________ flac-dev mailing list flac-dev@xiph.org http://lists.xiph.org/mailman/listinfo/flac-dev