The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > High Level Programming
Google UNIX.COM


High Level Programming Post questions about C, C++, Java, SQL, and other programming languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Scripting comments gliesian Shell Programming and Scripting 4 03-28-2008 05:32 AM
OMG BPMN 2: comments for CEP iBot Complex Event Processing RSS News 0 03-11-2008 09:20 AM
Purpose of lint in UNIX kumar_saurabh UNIX for Dummies Questions & Answers 1 09-25-2005 06:10 AM
Help from lint experts needed amatsaka High Level Programming 2 03-29-2002 04:42 AM
Remove comments... LivinFree UNIX for Dummies Questions & Answers 1 10-11-2001 06:43 AM

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-04-2006
Registered User
 

Join Date: Mar 2006
Posts: 45
lint comments

Hi
can anyone help me regarding the meaning of the following lint messages.
what is the use of having such lint comments in the c program.

/*lint -esym(534,cputs,fgets,cprintf) */
/*lint -efile(766,pragmas.h) */

Thanks a lot in advance.
Reply With Quote
Forum Sponsor
  #2 (permalink)  
Old 03-04-2006
Technorati Master
 

Join Date: Mar 2005
Location: Large scale systems...
Posts: 2,469
probably you should have made use of lint command for coding and syntax errors for enhancing portabilty

compiler suppresses warnings about certain conditions when you place these comments at specific points in the source.

for esym - message # is suppressed for the accompanying symbol with esym
Reply With Quote
  #3 (permalink)  
Old 03-05-2006
Registered User
 

Join Date: Mar 2006
Posts: 45
Thanks matrixmadhan,

Actually I was going through code written by somebody else.

what are those numbers(534 and 766) and options -esym and -efile in the comments.

Is there any online help regarding the same so that I can learn how to and where to place these comments to maintain the portability.
Reply With Quote
  #4 (permalink)  
Old 03-05-2006
...@...
 

Join Date: Feb 2004
Location: NM
Posts: 3,483
The numbers are a warning message reference.

Basically, when you run lint on code you should see ZERO warnings, the stuff above is defeating the purpose of lint. Some shops require a clean lint output in order to push code to production. The previous coder either thought the warnings were pointless, or did not know how to correctly code the statement that caused the problem.

Matrix & I are trying to tell you that there should be no lint complaints at all.
Reply With Quote
  #5 (permalink)  
Old 03-05-2006
Registered User
 

Join Date: Mar 2006
Posts: 45
Thanks Jim and matrix
Reply With Quote
  #6 (permalink)  
Old 01-05-2008
Registered User
 

Join Date: Oct 2007
Posts: 1
These are for Flexelint from Gimpel

Hi,

Found this thread while googling something related. Don't know if this is still an issue for you, but wanted to pass this info along:

We resell the Gimpel PC-lint/Flexelint product and the lint comments in question are for it.

-esym(534... instructs Flexelint to ignore the return value for the functions specified. Those are third-party calls and so can make sense to suppress analysis results on them.

-efile(766... instructs Flexelint to suppress message 766 for the file pragma.h. Message 766 tags #include directives whose named header file is not used at all in the enclosing source program. Again, since pragma.h is third-party, it can make sense to suppress analysis results on it.
Reply With Quote
Google UNIX.COM
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 10:02 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008 The CEP Blog All Rights Reserved -Ad Management by RedTyger Visit The Global Fact Book

Content Relevant URLs by vBSEO 3.2.0