What Was New in Version 7.00?
New Features | New
Options | Support for Embedded Systems | New
Messages | Designer's Notes
What's new in Version 7.50? | What's new in Version
Version 7.00 featured lots of new checks and features, including
inter-statement value tracking, to detect even
more of those hard-to-find-bugs.
We addressed a number of problems that users have been faced
with. In particular, support for long filenames.
We support incremental linting of C++ code and, therefore, we've discontinued
"PC-lint for C". PC-lint for C/C++ version 7.00 will process
a mixed suite of C and C++ modules and is upward compatible with all previous
versions of PC-lint.
- As discussed in the Designer's Notes,
the biggest 'New' is that Version 7.00 has inter-statement Value
Tracking. Values assigned to auto variables and data members of the
this class (for member functions) are recorded and/or deduced and this
information is retained across statement boundaries.
- With Value Tracking as an enabling technology,
the calls to a large number of standard functions are checked in a variety
of ways and these checks can be extended to user functions.
- Macros are subject to increased scrutiny. Unparenthesized parameters
and unparenthesized macro bodies in arithmetic contexts are flagged as
well as macro arguments with side-effects being passed to repeated parameters.
- Improvements have been made in detecting improper class constructions.
These include members not initialized by constructors (1541, 1741), destructors
that fail to free (1540), failing to check assignment to this
(1529), and failing to check sizeof(class) in
allocation functions (1531, 1921).
- Order of Initialization dependencies for C++'s famous static initialization
problem: The C++ language offers a great deal of freedom in initializing
static variables. The bad news is that you can create an order of initialization
dependency. The good news is that PC-lint/FlexeLint 7.00 will find it.
- Lint Object Modules are fully supported.
- New ways to torture-test your code include turning on flags +fsc
(string constants are const char) and +fpn (pointer parameters
may be NULL).
- Blanks are permitted within parenthesized options making them more
- A z softener (ignore 0) has been added to the strong type flags
A and J. Also, you can make some or all of the links in your strong type
hierarchy one way (up).
- Chapter 15 of the manual, Error Messages is provided in an ASCII
format as msg.txt
New Flag Options
- fff Fold Filenames (when OFF, filenames
will not be folded to a single case).
- ffn use Full (file) Names in messages
- fhd strong-Hierarchy-Down (normally ON)
when turned OFF, the default relationship of strong types is like father
rather than parent.
- fiq Ignore-default-Qualifier
- flc allow for long-char
- fll allow for long-long
- fpn Pointer-parameter-may-be-NULL
- fsc String constants are const char
New Error Inhibition Options
- -elibsym(#[,#]...) inhibits...
- +elibsym(#[,#]...) re-enables...
the numbered messages that are parameterized by library header symbols.
New Size Options
- -sll# specifies the size of long long
Other New (or Extended) Options
specifies the list of default extensions tried by PC-lint/FlexeLint
and the order in which they are tried when an extension-less filename is
provided as argument.
is like -parent except that it makes the relationship strict,
such that a Child type can be assigned to a Parent type but
add/remove an extension from the list of filename
extensions used to indicate indirect files.
increases the size of macro storage.
- -oe( filename )
redirects output intended for Standard Error (stderr) to
the named file.
The optional argument (width) denotes an upper bound on
the length of the output lines when in pre-processing mode.
More Support for Embedded Systems
Compilers for embedded systems often extend C in (non standard) ways
that could trip up PC-lint/FlexeLint. Accordingly, we have added several
options to support the most common extensions. +fba is the Bit
addressability flag that will allow, for example, n.3 to represent
the 3rd bit of integer variable n. Another extension allows for
specifying the address of a memory mapped object. For example,
Port pa = 0xFFFF0000;
We now support some of the unusual syntactic constructs of the Whitesmith
compiler. Use of the -cwh option allows us to support, for example,
@eeprom char x @base +1;
All together we've added 86 new messages in Version 7.00
Here is a sampling:
613 Possible use of null pointer in [left/right]
argument to operator 'String'
661 Possible access of out-of-bounds pointer by operator
662 Possible creation of out-of-bounds pointer by operator
665 Unparenthesized parameter 'Integer' in macro
'Symbol' is passed an expression
666 Expression with side effects passed to repeated
parameter 'Integer' of macro 'Symbol'
668 Possibly passing a null pointer to function 'Symbol',
669 Possible data overrun for function 'Symbol',
argument 'Integer' exceeds argument 'Integer'
670 Possible access beyond array for function 'Symbol',
argument 'Integer' exceeds 'Integer'
773 Expression-like macro 'Symbol' not parenthesized
1401 member 'Symbol' (Location) not initialized
1529 'Symbol' not first checking for assignment to
1540 pointer member 'Symbol' (Location) neither
freed nor zero’ed by destructor
1541 member 'Symbol' (Location) possibly not
initialized by constructor
1542 member 'Symbol' (Location) possibly not
1544 value of 'Symbol' (Location) indeterminate
(order of initialization)
1545 value of 'Symbol' used previously to initialize
1740 pointer member 'Symbol' (Location) not
directly freed or zero'ed by destructor
1744 member 'Symbol' (Location) possibly not
initialized by private constructor
Home | Contact | Order
Copyright © 2005, Gimpel Software