Skip to content
Sign upLog in
This post is read-only. Explore Repls and connect with other creators on Community.View Community
The info in this post might be out of date, check out our docs instead. View docs
1

Destructuring in C

Pankak
Pankak

I was wondering if destructuring is possible in C. Here's an example in pseudocode of what I'm thinking of:

void func({ int foo; int foo2; }){ } struct { int foo; int foo2; } victim;

Not particularly necessary but I recall finding something about this or something similar, which I can't find now.

@Coder100
@xxpertHacker
smert ppl halp

2 years ago
You are viewing a single comment. View All
1
xxpertHacker
xxpertHacker

@Pankak
Lmao, just don't get the gf and you're safe all around.
Better yet, move out of the neighborhood, so you don't have to deal with either, your gf, or the evil neighbor. (equivalent to not using C at all)

There are legitimate uses for the preprocessor: handling different versions of the language and checking compiler flags.

Btw, what's so bad about sniping dogs?

2 years ago