Post B4klbvfv7YVIJQH452 by fiore@brain.worm.pink
(DIR) More posts by fiore@brain.worm.pink
(DIR) Post #B4kcKXstQE0w13yhVY by fiore@brain.worm.pink
1 likes, 1 repeats
do people even agree nowadays on this
(DIR) Post #B4kcaOsWfonmiaMmuW by snacks@netzsphaere.xyz
1 likes, 0 repeats
@fiore i hate this because int* should be correct but if you dare to declare multiple pointers at once it falls apart. Stupid language
(DIR) Post #B4kcbPrIVyFk31HCF6 by ada@zoner.work
1 likes, 0 repeats
@fiore@brain.worm.pink i know one is less bug prone than the other but i forgot which and personally i just prefer the vibes of the first one
(DIR) Post #B4kcekHJ3HSWFL1sNk by lottie@social.vlhl.dev
0 likes, 0 repeats
@ada @fiore the second one is more logical because c declarations mirror expressions
(DIR) Post #B4kcekQsTh7Cj1VWIi by fiore@brain.worm.pink
0 likes, 0 repeats
@lottie @ada i agree but there are many cases where jt can lead to unexpected results . j still prefer it tho
(DIR) Post #B4kcgGBBveQ9TatJtw by fiore@brain.worm.pink
0 likes, 0 repeats
@twinspin6 :temSmug:
(DIR) Post #B4kciWI6zt8s1bCp7o by janneke@todon.nl
0 likes, 0 repeats
@fiore What aboutint*x;int * x;int * x ;
(DIR) Post #B4kciWRgQInYVHgT2m by fiore@brain.worm.pink
0 likes, 0 repeats
@janneke everyone knows those make no sense amd are ugly aswell
(DIR) Post #B4kcjAVzRi0imE0TJI by coolbean@brain.worm.pink
2 likes, 0 repeats
@fiore this is the sort of shit that drives me absolutely insane about c syntax pointers just should not be like this
(DIR) Post #B4kcvPcH7p1T5Vmhyy by coolbean@brain.worm.pink
2 likes, 0 repeats
@fiore like there are times when differences like this make semantic differences and there are times when they dont and i CANT TELL WHEN TO USE WHICH
(DIR) Post #B4kczK9zLxmZK9Q384 by aeweyrose@dyke.solutions
0 likes, 0 repeats
@fiore int *x
(DIR) Post #B4kczKOsSbgy4KNwKu by fiore@brain.worm.pink
0 likes, 0 repeats
@aeweyrose it just makes more sense doesnt it
(DIR) Post #B4kd0ZPE9giwti8o4W by novenary@akko.wtf
0 likes, 0 repeats
@fiore starting fights are we
(DIR) Post #B4kdmSDWBcUAVAUsWO by 0x0cb9d119@akko.wtf
1 likes, 0 repeats
@fiore it will write in both to confuse the reader {dont worry dolly wont, it isnt that mean}
(DIR) Post #B4kdoJPXtjRBlm0bjc by emmy@transfem.social
1 likes, 0 repeats
@fiore@brain.worm.pink Jens Gustedt uses int* x, and that's good enough for me.But you should also have a rule of never declaring more than one variable on the same line because int* x, y; does not do the obvious thing.
(DIR) Post #B4kdoJdj30mQTkdvpw by fiore@brain.worm.pink
0 likes, 0 repeats
@emmy oh yea thats agreeable
(DIR) Post #B4kdrUjYFzUhkrsrlg by janneke@todon.nl
0 likes, 0 repeats
@fiore What I mean to say, this has nothing to do with agreeing, or with nowadays, it's about policy. If you write GNU code, you use the GNU coding standards, and if you're unsure, you run indent.
(DIR) Post #B4kdrUzrHMXQZRVtBY by fiore@brain.worm.pink
0 likes, 0 repeats
@janneke if you write GNU code your C compiler should be taken away from you
(DIR) Post #B4kdvLMn1eIRrU4YyG by leinna@fedi.kemonomimi.pet
1 likes, 0 repeats
@fiore I mean int* just makes way more sense no? x is of type int*, you keep the whole type together. What reason is there for int *x?
(DIR) Post #B4kdvLXQO6nsOT33Y0 by fiore@brain.worm.pink
0 likes, 0 repeats
@leinna its because *x is of type int !
(DIR) Post #B4kix0qKnmJmYjVVE8 by shrew@oomfie.city
0 likes, 0 repeats
@fiore POINTER IS PART OF THE TYPE!! ITS A POINTER TO AN INT!!! ITS NOT LIKE YOU HAVE TO PUT * EVERY TIME YOU ACCESS THE VARIABLE!!! ARGHFFGVFBG :whyMelt:
(DIR) Post #B4kix1AtZKlTaV7vH6 by fiore@brain.worm.pink
0 likes, 0 repeats
@shrew falsenvke … im sorry …
(DIR) Post #B4klbvVHl5zrmRIZVI by yukijoou@fedi.kemonomimi.gay
0 likes, 0 repeats
@fiore i prefer the first one, so my favourite style is that + ban multiple variable declarations on the same line to avoid insane behaviour
(DIR) Post #B4klbvfv7YVIJQH452 by fiore@brain.worm.pink
0 likes, 0 repeats
@yukijoou yea if u prefer the first one u should never do multiple declarations , u shouldnt in general but left binding makes it much weirder doesnt it