3 ms·
Some of the examples are broken because they use C++ language constructs but they're being compiled as C code, which leads to error messages like: 13 : error
by teraflop 11y ago
Some of the examples are broken because they use C++ language constructs but they're being compiled as C code, which leads to error messages like:
13 : error: 'static_cast' undeclared (first use in this function)
input = static_cast<int*>(__builtin_assume_aligned(input, 64));
^
- ygra 11y agoRemove the -xc option. But agreed, it'd be nice if that kind of thing would be automatic, at least for the supplied examples.
- mattgodbolt 11y agoThe supplied examples by design don't override the settings you've chosen: this lets you play independently with the text and the settings. It seems the original link here on HN was to a canned example with settings for C, which I think caused the confusion.