Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

How do you indent?

Name: Anonymous 2009-07-29 12:23

What is your preferred style of code indentation? I personally tend to use the GNU style indent.


static char *
concat (char *s1, char *s2)
{
    while (x == y)
      {
        something ();
        somethingelse ();
      }
    finalthing ();
}

Name: welcome to /prog/ 2009-07-29 19:51

>>40
Why yes, yes it is.

Name: Anonymous 2009-07-29 19:57

>>40
Thank you for your input Mr. Stallman

Name: Anonymous 2009-07-29 20:13

>>42
No, thank you for your input, Mr. Stallman

Name: Anonymous 2009-07-29 21:25

>>43
No, No, thank you for your input, Mr. Stalin.
Terrible!

Name: !MILKRIBS4k 2009-07-29 21:42

I usually don't indent my code! But it is something I think I will start doing!

Name: Anonymous 2009-07-29 21:50

static char *concat ( char *s1, char *s2 ) {
    while ( x == y ) {
        something();
        somethingelse();
    }
    finalthing();
}

My preference.

Name: Anonymous 2009-07-29 21:58

I use GNU style, and I enjoy it.

Name: Anonymous 2009-07-29 22:04

>>47
0/10

Name: Anonymous 2009-07-29 22:07


static char* concat(char *s1, char *s2) {
    while(x == y) {
        something();
        somethingelse();
    }
    finalthing();
}

Name: Anonymous 2009-07-29 22:12

>>44
No, No, thank you for your input, Mr. Stalin.
Awesome!

Name: Anonymous 2009-07-29 22:19

I use K&R style but with a twist

if (!foo){
    bar();
}
else {           // I just never like the whole "} else {" thing
    baz();
}

Name: Anonymous 2009-07-29 22:28

I use Sun's recommended style for Java.

No joke. K&R can eat my balls.

Name: Anonymous 2009-07-29 22:53

>>52
Sun's recommended style for Java is K&R, except for the opening brace of class and method blocks.

Name: Anonymous 2009-07-29 23:03

>>53
except for the opening brace of class and method blocks
Indeed; the worst part of K&R. Ladies and gentlemen, I rest my case.

Name: Anonymous 2009-07-29 23:44

whitespaceisforfaggots

Name: Anonymous 2009-07-29 23:51

FIOC uses brownspace for coding anal butt brownies

Name: Anonymous 2009-07-29 23:55

>>56
anal butt brownies
Could they possibly be anal cunt brownies?

Name: Anonymous 2009-07-30 4:20

int main(int argc, char **argv) {
 mode_t mode = 0666 & ~umask(0);
 int i, opt;
 while ((opt = getopt(argc, argv, "m:")) != -1) {
  switch(opt) {
  case 'm':
   mode = dectooct(atoi(optarg));
   break;
  case '?':
   mode = -1;
   goto outofwhile;
  }
 }
 outofwhile:
 if(mode == -1) {
  fprintf(stderr, "%s: invalid mode\n", argv[0]);
  return 1;
 }
 if(optind >= argc) {
  fprintf(stderr, "%s: missing operand\n", argv[0]);
  return 1;
 }
 for(i = optind; i < argc; i++) {
  if(mkfifo(argv[i], mode)) {
   fprintf(stderr, "%s: cannot create fifo `%s': %s\n",
   argv[0], argv[i], strerror(errno));
  }
 }
 return 0;
}

Name: Anonymous 2009-07-30 7:50

static char*
concat(char *s1, char *s2) {
  while (x == y) {
    something();
    somethingelse();
  }
  finalthing();
}

Name: Anonymous 2009-07-30 9:02

My indentation level is randomly generated by my editor, keeps me on my toes

Name: =+=*=F=R=O=Z=E=N==V=O=I=D=*=+= !frozEn/KIg 2009-07-30 12:29

I once tried to use python interpreter and got sick of it pretty fast.
 I don't waste any time on indentation, i'm not a loser who thinks his code must be some "quality product".
Art value is in code, not in its appearance.


___________________________________
http://xs135.xs.to/xs135/09042/av922.jpg
Velox Et Astrum gamedev forum: http://etastrum.phpbb3now.com
Experience is never limited, and it is never complete; it is an immense sensibility, a kind of huge spider-web of the finest silken threads suspended in the chamber of consciousness, and catching every air-borne particle in its tissue.

Name: Anonymous 2009-07-30 12:47

>>61
Yeah, except your code is is both horrible and shit.

Name: Anonymous 2009-07-30 12:50

Art value
It's funny that you use this term and yet you have no sense of aesthetics.

Name: =+=*=F=R=O=Z=E=N==V=O=I=D=*=+= !frozEn/KIg 2009-07-30 13:03

>>62 Thats your personal opinion. I don't expect people from the street to judge my code fair too.
>>63 I have a different set of aesthetics.I'm not impressed by outward qualities of a thing.


________________________________________
http://xs135.xs.to/xs135/09042/av922.jpg
Velox Et Astrum gamedev forum: http://etastrum.phpbb3now.com
When the tyrant has disposed of foreign enemies by conquest or treaty, and there is nothing more to fear from them, then he is always stirring up some war or other, in order that the people may require a leader.

Name: Anonymous 2009-07-30 13:29

>>64
I doubt there's anyone over the age of six who could think your code is beautiful and/or not shit.

Name: =+=*=F=R=O=Z=E=N==V=O=I=D=*=+= !frozEn/KIg 2009-07-30 13:31

>>65 People who can understand the art value of my code are rare on /prog/. 



_______________________________________________
http://xs135.xs.to/xs135/09042/av922.jpg
Velox Et Astrum gamedev forum: http://etastrum.phpbb3now.com
Bureaucracy destroys initiative. There is little that bureaucrats hate more than innovation, especially innovation that produces better results than the old routines. Improvements always make those at the top of the heap look inept.

Name: Anonymous 2009-07-30 13:41

>>66
I was talking in terms of the entire population of Earth.

Name: =+=*=F=R=O=Z=E=N==V=O=I=D=*=+= !frozEn/KIg 2009-07-30 13:45

>>67 Even some native Brazilian tribes? You represent so much and know so little.



________________________________________
http://xs135.xs.to/xs135/09042/av922.jpg
Velox Et Astrum gamedev forum: http://etastrum.phpbb3now.com
Even silence speaks

Name: Anonymous 2009-07-30 13:49

>>68
I happened to have talked to the specific tribes you refer to. They agree with me.

Name: Anonymous 2009-07-30 13:50

I think that if some Brazilian tribal guy saw your code, and indented and monospaced code, he would find the latter more aesthetic, as for him, your code would be just a bunch of random wriggles (as opposed to random wriggles laid out in with some regularity (``OOGA BOOGA LEFT SNAKE GLYPH RIGHT SNAKE GLYPH'')).

Name: =+=*=F=R=O=Z=E=N==V=O=I=D=*=+= !frozEn/KIg 2009-07-30 13:54

>>69 I don't believe it until you get a notarized voice recording and unbiased third-party translation. 



__________________________________________
http://xs135.xs.to/xs135/09042/av922.jpg
Velox Et Astrum gamedev forum: http://etastrum.phpbb3now.com
When despotism has established itself for ages in a country, as in France, it is not in the person of the king only that it resides. It has the appearance of being so in show, and in nominal authority; but it is not so in practice and in fact. It has its standard everywhere. Every office and department has its despotism, founded upon custom and usage. Every place has its Bastille, and every Bastille its despot. The original hereditary despotism resident in the person of the king, divides and sub-divides itself into a thousand shapes and forms, till at last the whole of it is acted by deputation. This was the case in France; and against this species of despotism, proceeding on through an endless labyrinth of office till the source of it is scarcely perceptible, there is no mode of redress. It strengthens itself by assuming the appearance of duty, and tyrannises under the pretence of obeying.

Name: Anonymous 2009-07-30 14:11

>>68-71
It doesn't even matter. If someone was to try to find the inner beauty FV speaks of, they would invariably need to know C.

>>71
You suck. Quit fagging up our craft.

Name: Anonymous 2009-07-30 14:17

>>72 again.
You suck. Quit fagging up our craft.
...and the board.

Name: =+=*=F=R=O=Z=E=N==V=O=I=D=*=+= !frozEn/KIg 2009-07-30 14:48

>>71 Well, i have my own sense of humor.
If you insist on representing everyone on Earth, you can represent me as well, but since i hold quite opposite views you cannot and your statement has a bogus quality in it.


__________________________________
http://xs135.xs.to/xs135/09042/av922.jpg
Velox Et Astrum gamedev forum: http://etastrum.phpbb3now.com
Better than a thousand hollow words

Name: Anonymous 2009-07-30 15:14

>>74
I don't count you as population. I think you're an entity that came into existence spontaneously as a result of condensed trolling and fail.
I also don't think you're over the age of six.

Name: =+=*=F=R=O=Z=E=N==V=O=I=D=*=+= !frozEn/KIg 2009-07-30 15:24

>>75 "entity"
 Better then voices in your head?


_________________________________________
http://xs135.xs.to/xs135/09042/av922.jpg
Velox Et Astrum gamedev forum: http://etastrum.phpbb3now.com
It is indeed a precious gift to understand the forces that guide oneself.

Name: Anonymous 2009-07-30 15:30

>>76
then
Nono, you can't do that.

Name: =+=*=F=R=O=Z=E=N==V=O=I=D=*=+= !frozEn/KIg 2009-07-30 15:33

>>77 Can't I? Then stop me.



_______________________________
http://xs135.xs.to/xs135/09042/av922.jpg
Velox Et Astrum gamedev forum: http://etastrum.phpbb3now.com
Humor is just another defense against the universe.

Name: Anonymous 2009-07-30 15:42

>>78
Don't you mean "than stop me"?

Name: Anonymous 2009-07-30 15:47

>>76
And this comes from a programmer? *sigh*, I know why people are blocking you. Bye bye.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List