Click here to Skip to main content
16,017,852 members

The Weird and The Wonderful

   

The Weird and The Wonderful forum is a place to post Coding Horrors, Worst Practices, and the occasional flash of brilliance.

We all come across code that simply boggles the mind. Lazy kludges, embarrassing mistakes, horrid workarounds and developers just not quite getting it. And then somedays we come across - or write - the truly sublime.

Post your Best, your worst, and your most interesting. But please - no programming questions . This forum is purely for amusement and discussions on code snippets. All actual programming questions will be removed.

 
GeneralRe: What the hell gcc? Pin
Rick York18-Jun-24 4:53
mveRick York18-Jun-24 4:53 
GeneralRe: What the hell gcc? Pin
honey the codewitch18-Jun-24 5:03
mvahoney the codewitch18-Jun-24 5:03 
GeneralRe: What the hell gcc? Pin
k505418-Jun-24 5:20
mvek505418-Jun-24 5:20 
GeneralRe: What the hell gcc? Pin
honey the codewitch18-Jun-24 5:38
mvahoney the codewitch18-Jun-24 5:38 
GeneralRe: What the hell gcc? Pin
k505418-Jun-24 5:47
mvek505418-Jun-24 5:47 
GeneralRe: What the hell gcc? Pin
honey the codewitch18-Jun-24 5:55
mvahoney the codewitch18-Jun-24 5:55 
GeneralRe: What the hell gcc? Pin
k505418-Jun-24 6:43
mvek505418-Jun-24 6:43 
GeneralRe: What the hell gcc? Pin
honey the codewitch18-Jun-24 6:48
mvahoney the codewitch18-Jun-24 6:48 
That's my theory, but I'm uncomfortable with it if nothing else because

a) I hate assuming compiler bugs. So often it's some effing intricacy of the C or C++ language that is at play, rather than the compiler in error.

b) You'd think it would have been found and fixed. Like I said, this isn't the first time I've run into it. The last time was a lot more innocuous - no type aliasing or fudging like that. it was an enum struct type declared as a local variable and initialized at declaration time. Confused | :confused: Roll eyes | :rolleyes:

I'd dig up the old example if i could, but I ended up working around it in order to get the warnings out of my code without using compiler specific pragmas.

Edit: Duh. I am not using the latest GCC. I didn't think about that. Could easily be a bug.
Check out my IoT graphics library here:
https://honeythecodewitch.com/gfx
And my IoT UI/User Experience library here:
https://honeythecodewitch.com/uix


modified 18-Jun-24 13:52pm.

GeneralRe: What the hell gcc? Pin
k505418-Jun-24 8:16
mvek505418-Jun-24 8:16 
GeneralRe: What the hell gcc? Pin
honey the codewitch18-Jun-24 8:21
mvahoney the codewitch18-Jun-24 8:21 
GeneralRe: What the hell gcc? Pin
Rick York18-Jun-24 8:17
mveRick York18-Jun-24 8:17 
GeneralRe: What the hell gcc? Pin
0x01AA18-Jun-24 9:35
mve0x01AA18-Jun-24 9:35 
GeneralRe: What the hell gcc? Pin
honey the codewitch18-Jun-24 9:36
mvahoney the codewitch18-Jun-24 9:36 
GeneralRe: What the hell gcc? Pin
0x01AA18-Jun-24 9:45
mve0x01AA18-Jun-24 9:45 
GeneralRe: What the hell gcc? Pin
honey the codewitch18-Jun-24 9:46
mvahoney the codewitch18-Jun-24 9:46 
GeneralRe: What the hell gcc? Pin
0x01AA18-Jun-24 9:52
mve0x01AA18-Jun-24 9:52 
GeneralWTF-8 Pin
PIEBALDconsult17-Jun-24 18:40
mvePIEBALDconsult17-Jun-24 18:40 
GeneralRe: WTF-8 Pin
Peter_in_278017-Jun-24 19:09
professionalPeter_in_278017-Jun-24 19:09 
GeneralRe: WTF-8 Pin
honey the codewitch17-Jun-24 21:16
mvahoney the codewitch17-Jun-24 21:16 
GeneralRe: WTF-8 Pin
PIEBALDconsult18-Jun-24 3:01
mvePIEBALDconsult18-Jun-24 3:01 
GeneralRe: WTF-8 Pin
honey the codewitch18-Jun-24 4:15
mvahoney the codewitch18-Jun-24 4:15 
GeneralRe: WTF-8 Pin
PIEBALDconsult18-Jun-24 14:07
mvePIEBALDconsult18-Jun-24 14:07 
GeneralRe: WTF-8 Pin
honey the codewitch18-Jun-24 6:01
mvahoney the codewitch18-Jun-24 6:01 
GeneralRe: WTF-8 Pin
PIEBALDconsult18-Jun-24 14:10
mvePIEBALDconsult18-Jun-24 14:10 
GeneralRe: WTF-8 Pin
honey the codewitch18-Jun-24 15:01
mvahoney the codewitch18-Jun-24 15:01 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.