AaronBallman wrote:

> > We could maybe presume glibc on ELF targets
> 
> Isn't that part of the triple? `aarch64-linux-gnu` gnu -> glibc (as opposed 
> to `aarch64-linux-musl` -> musl, or `aarch64-linux-android` -> bionic)

Oh -- I wasn't aware we tracked that in the triple, that's awesome! I'll give 
that a shot.

> Hopefully the number of constructors that expect getting arguments is 
> extremely rare. But I do worry that there is code out there that assumes 
> glibc behaviour, so it seems to me that err_ctor_dtor_attr_on_non_void_func 
> needs to be a warning-as-error that can be downgraded?

Hopefully we can avoid emitting the diagnostic at all for glibc, then we can 
leave it as a hard error for the other cases. My concern about turning that 
into a warning which defaults to an error is that a less thorough programmer 
may shut the warning up rather than realize their CRT doesn't support that.

https://github.com/llvm/llvm-project/pull/67360
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to