Hi I already pushed a patch. It lets tcc pass the test comparing with clang reference. Tell me if it's OK for you. Christian Jullien ---------------- De : Michael Matz <[email protected]> Envoyé : jeudi 17 novembre 2022 15:12 À : [email protected]; [email protected] Objet : Re: [Tinycc-devel] clang 15.0 issue with tcctest.c
Hello, On Thu, 17 Nov 2022, Christian Jullien wrote: > Test later fails with > > tcctest.c:2903:17: error: incompatible pointer to integer conversion passing > 'void *' to parameter of type 'int' [-Wint-conversion] > > old_style_f((void *)1, 2, 3.0); > > ^~~~~~~~~ So, this is a warning promoted to an error with recent clang. We try to avoid such compatibility warnings explicitely (by compiling with -w), but clang doesn't heed this request anymore. The warning here is a bit on the border because this is an old style function definition, and parameter types are not compared for calls to such functions (though the call will be undefined behaviour if the types aren't compatible, which is indeed the case here, so a warning is somewhat justified). Can clang15 at least be convinced to not warn (and hence error out) here with -Wno-int-conversion? If so that would be the solution. If not, we have a problem, because tcc _wants_ to support exactly this situation (until we decide that we don't, then we need to adjust the testcase). Ciao, Michael. _______________________________________________ Tinycc-devel mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/tinycc-devel
