|
Message-ID: <20140725161449.GD4038@brightrain.aerifal.cx> Date: Fri, 25 Jul 2014 12:14:49 -0400 From: Rich Felker <dalias@...c.org> To: musl@...ts.openwall.com Subject: Re: C11 threads On Fri, Jul 25, 2014 at 03:04:39PM +0200, Szabolcs Nagy wrote: > > The term "inequal function pointer" had nothing pop up. Could you give > > a reference to the relevant part in POSIX that makes the requirement > > for a "strong" symbol? > > > hm i might be wrong: > > there is a requirement in c and posix that the address of a > standard function can be taken and that == is only true for > function pointers if they point to the same function > > but i don't see any requirement that each library function > must be distinct > > and there is a dr that implies the opposite: > > http://www.open-std.org/jtc1/sc22/wg14/www/docs/dr_078.html > > without explanation the response says h can return 0. Indeed there is no explanation. I don't think it could be related to macros because my understanding is that only function-like macros are allowed for the standard functions, i.e. you can override such macros by using (). Both C99 and C11 contain in 7.1.4 paragraph 1 a footnote (161 or 185, respectively) reading: "This means that an implementation shall provide an actual function for each library function, even if it also provides a macro for that function." This suggests to me that there should be a one-to-one correspondence between actual functions and library functions, but maybe I'm reading too much into it. > the musl math library currently defines distinct long double > functions even if long double and double have the same > representation, they could be weak aliases if the standard > allows this.. Indeed. If this issue is resolved to allow it, I think we should make this change and remove some otherwise-useless bloat. Rich
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.