Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C Programming > how to let gcc warn me when I use = in conditions

Reply
Thread Tools

how to let gcc warn me when I use = in conditions

 
 
Mark McIntyre
Guest
Posts: n/a
 
      07-05-2005
On Tue, 05 Jul 2005 11:16:20 -0700, in comp.lang.c , Alan Balmer
<(E-Mail Removed)> wrote:

>Hmm... That's amazing. How is it that you know what's more readable to
>me, and I, apparently, don't?


Come on, get real. How often have you, the software designer, given
users what they *really* want, and ignored what they claimed to want,
because your experience told you that it was merely what they were
used to?

>Am I deluding myself?


Almost certainly. Though I refuse to specify what about.


--
Mark McIntyre
CLC FAQ <http://www.eskimo.com/~scs/C-faq/top.html>
CLC readme: <http://www.ungerhu.com/jxh/clc.welcome.txt>

----== Posted via Newsfeeds.Com - Unlimited-Uncensored-Secure Usenet News==----
http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups
----= East and West-Coast Server Farms - Total Privacy via Encryption =----
 
Reply With Quote
 
 
 
 
Alan Balmer
Guest
Posts: n/a
 
      07-06-2005
On Tue, 05 Jul 2005 22:43:38 +0100, Mark McIntyre
<(E-Mail Removed)> wrote:

>On Tue, 05 Jul 2005 11:16:20 -0700, in comp.lang.c , Alan Balmer
><(E-Mail Removed)> wrote:
>
>>Hmm... That's amazing. How is it that you know what's more readable to
>>me, and I, apparently, don't?

>
>Come on, get real. How often have you, the software designer, given
>users what they *really* want, and ignored what they claimed to want,
>because your experience told you that it was merely what they were
>used to?


Without mentioning my own designs in particular, I suspect that this
happens less often than the reverse, where a software designer builds
something that seems the best way to him, but the customers hate it.
I'm not that much of an egomaniac. I will suggest "improvements", and
even implement them and ask customers to try them for a while, but I
won't be surprised if their idea of how to do their job is better than
mine.

In any case, this isn't the same situation. I have read much code,
including a good many conditionals written backward . I've seen
both ways, and I prefer mine. YMMV.
>
>>Am I deluding myself?

>
>Almost certainly. Though I refuse to specify what about.


Well, as long as it's not about the chocolate.

--
Al Balmer
Balmer Consulting
http://www.velocityreviews.com/forums/(E-Mail Removed)
 
Reply With Quote
 
 
 
 
Richard Bos
Guest
Posts: n/a
 
      07-07-2005
Mark McIntyre <(E-Mail Removed)> wrote:

> On Tue, 05 Jul 2005 14:37:37 GMT, in comp.lang.c ,
> (E-Mail Removed) (Richard Bos) wrote:
>
> >Mark McIntyre <(E-Mail Removed)> wrote:
> >
> >> On Thu, 30 Jun 2005 11:34:55 -0700, in comp.lang.c , Alan Balmer
> >> <(E-Mail Removed)> wrote:
> >>
> >> >Therefore, the second version is more readable for
> >> >me simply because I tell you it is.
> >>
> >> Horsefeathers.

> >
> >So, you would tell Alan that the second version is not, as he says, more
> >readable to him, because _you_ know better what is readable to _him_
> >than he himself?

>
> Joking aside, its frequently the case that the designer has a better
> idea of what the user wants than the user does.


We're not talking about a user and a designer here, we're talking about
two (or three) programmers: you, and Alan (and me).

> >What are you, an ergonomist?

>
> Did you just call my pint a jessie?


No. I called your pint a half of Heineken.

> >> >As it happens, a lot of people agree with me.
> >>
> >> And they're all called Napoleon. Or so the little green men told them.

> >
> >At least one of them is called Richard Bos.

>
> I'm unclear whether you agree with Alan that he knows what he likes,
> or that you also like odd ways of writing stuff, or that you're called
> napoleon.


I'm sure Alan knows better what he likes than you do, in this case I
agree with Alan in that the second version is more readable to me as
well, and I'm not called Napoleon but Richard Bos.

I make no comments about little green men, because they asked me not to.

Richard
 
Reply With Quote
 
Peter Pichler
Guest
Posts: n/a
 
      08-24-2005
Alan Balmer wrote:
> On 27 Jun 2005 02:55:20 -0700, "Rob Thorpe"
> <(E-Mail Removed)> wrote:
>>
>>For example, if you use GNU Emacs and enable cwarn-mode it will
>>highlight single "=" signs in if-statements in bright red.
>>
>>This is very useful, but can be irritating if you use them
>>deliberately.

>
> Another reason not to use them deliberately.


Alternatively, another reason not to use GNU Emacs

 
Reply With Quote
 
akarl
Guest
Posts: n/a
 
      08-24-2005
Peter Pichler wrote:
> Alan Balmer wrote:
>
>> On 27 Jun 2005 02:55:20 -0700, "Rob Thorpe"
>> <(E-Mail Removed)> wrote:
>>
>>>
>>> For example, if you use GNU Emacs and enable cwarn-mode it will
>>> highlight single "=" signs in if-statements in bright red.
>>>
>>> This is very useful, but can be irritating if you use them
>>> deliberately.

>>
>>
>> Another reason not to use them deliberately.

>
>
> Alternatively, another reason not to use GNU Emacs


I like your logic.

 
Reply With Quote
 
Rob Thorpe
Guest
Posts: n/a
 
      08-25-2005
Peter Pichler wrote:
> Alan Balmer wrote:
> > On 27 Jun 2005 02:55:20 -0700, "Rob Thorpe"
> > <(E-Mail Removed)> wrote:
> >>
> >>For example, if you use GNU Emacs and enable cwarn-mode it will
> >>highlight single "=" signs in if-statements in bright red.
> >>
> >>This is very useful, but can be irritating if you use them
> >>deliberately.

> >
> > Another reason not to use them deliberately.

>
> Alternatively, another reason not to use GNU Emacs


If you don't like it you don't have to enable it. Just like if you
don't like GNU Emacs you don't have to use it.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How include a large array? Edward A. Falk C Programming 1 04-04-2013 08:07 PM
do any compilers notice/warn on always false expressions used as conditions David Resnick C Programming 8 11-18-2010 11:43 PM
Why GCC does warn me when I using gets() function for accessing file Cuthbert C Programming 89 09-11-2006 02:59 PM
Re: how to let gcc warn me when I use = in conditions Alfred Z. Newmane C++ 11 06-27-2005 08:44 PM
Let or not let the text float Luigi Donatello Asero HTML 6 01-15-2004 04:08 PM



Advertisments