Path: utzoo!utgpu!news-server.csri.toronto.edu!clyde.concordia.ca!uunet!samsung!zaphod.mps.ohio-state.edu!sol.ctr.columbia.edu!lll-winken!decwrl!ucbvax!hplabs!hpfcso!hplisa!hplvli!boyne From: boyne@hplvli.HP.COM (Art Boyne) Newsgroups: comp.lang.c Subject: Re: Re: C style peeve (Yo people, try reading carefully next time!) Message-ID: <340018@hplvli.HP.COM> Date: 22 Mar 90 22:22:47 GMT References: <2205@osc.COM> Organization: Loveland Inst. Div Lines: 12 jgk@osc.COM (Joe Keane) writes: >Here's my biggest C style peeve. For some reason, many C programmers insist >on always putting parentheses around return values, even when they're not >necessary, which happens to be always. God knows why, but they write >`return(2+2);' instead of the obvious and K&R-approved style `return 2+2;'. While 'return value;' is legal according to K&R1 (see page 203), *every* example in my copy of the book uses 'return (value);'. Pretty obvious, therefore, why people code that way. Also, 'while', 'for', 'if', etc., all *require* parenthesis, so it's a reasonable habit to acquire. Art Boyne, boyne@hplvla.hp.com