Path: utzoo!utgpu!water!watmath!clyde!ima!haddock!karl From: karl@haddock.ISC.COM (Karl Heuer) Newsgroups: comp.lang.c++ Subject: Re: C++ as a better C (fact or fiction)? Message-ID: <4153@haddock.ISC.COM> Date: 24 May 88 00:05:06 GMT References: <6590041@hplsla.HP.COM> <706@vlot.cs.vu.nl> <456@polari.UUCP> <735@vlot.cs.vu.nl> Reply-To: karl@haddock.ima.isc.com (Karl Heuer) Organization: Interactive Systems, Boston Lines: 17 In article <735@vlot.cs.vu.nl> jos@cs.vu.nl (Jos Warmer) writes: >In this example [empty function] the message from lint is useless, and the >error that C++ found, was not detected by lint. > lint: hello defined( x.c(2) ), but never used > C++ : line 3: warning: no value returned from hello() I could just as easily say that the message from C++ is useless, and the error that lint found was not detected by C++. I'll grant that the C++ error messages may be more informative (though I don't think "illegal combination of pointer and integer, op =" is so bad once you get used to it; the only two things it could mean are "int = pointer" or "pointer = int"). But lint is, by design, stricter than C -- it will flag "questionable" constructs that are quite legal; it's not necessarily a Good Thing to include all of lint's warnings in C++. Karl W. Z. Heuer (ima!haddock!karl or karl@haddock.isc.com), The Walking Lint