Specifications

Error! Style not defined. 757
Filename: LMAETAPA.DOC Project: MASM Environment and Tools
Template: MSGRIDA1.DOT Author: Nobody Last Saved By: Mike Eddy
Revision #: 136 Page: 757 of 73 Printed: 10/09/00 02:49 PM
HI4130
(level 4)
operator : logical operation on address of string constant
The operator was used with the address of a string literal. Unexpected code was
generated.
For example, the following code causes this warning:
char *pc;
pc = "Hello";
if (pc == "Hello") ...
The if statement compares the value stored in the pointer pc to the address of the string
“Hello” which is separately allocated each time it occurs in the code. It does not
compare the string pointed to by pc with the string “Hello.”
To compare strings, use the strcmp function.
HI4131
(level 4)
function : uses old-style declarator
The function declaration or definition is not a prototype.
New-style function declarations are in prototype form.
u old style
int addrec( name, id )
char *name;
int id;
{ }
u new style
int addrec( char *name, int id )
{ }
HI4132
(level 4)
object : const object should be initialized
The value of a const object cannot be changed, so the only way to give the const object
a value is to initialize it.
It will not be possible to assign a value to object.
HI4135
(level 3)
conversion between different integral types
Information was lost between two integral types.
For example, the following code causes this warning:
int intvar;
long longvar;
intvar = longvar;
If the information is merely interpreted differently, this warning is not given, as in the
following example:
unsigned uintvar = intvar;