https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65455
--- Comment #1 from joseph at codesourcery dot com <joseph at codesourcery dot com> --- By design, typeof removes qualifiers in certain cases. Currently it only removes them from atomic types (as needed for use in <stdatomic.h>), but arguably it should do so more generally - this would be useful for certain macros when passed const arguments, and would reflect that qualifiers on rvalues are not meaningful in C standard terms (so rvalues should always be considered to have unqualified type) but GCC's internal representation may or may not have them. /* For use in macros such as those in <stdatomic.h>, remove all qualifiers from atomic types. (const can be an issue for more macros using typeof than just the <stdatomic.h> ones.) */