📄 bugfix80.txt
字号:
** This is our Bug Fix list for Patches to **
** PC-lint / FlexeLint Version 8.00 **
*************** Version 8.00w 7/27/2007 ***************
* We were complaining about the failure to have a case for an
enumerator in a switch even when the enumerator had the same
enumeration value as some other enumerator.
DEIS
* We now recognize Byte Order Marks (UTF-8 and friends) and make
appropriate comments.
BOMS
* Overloaded operators from two different namespaces could result
in an unjustified Error 55.
IUSO
* We would issue an unjustified 685 (Relational operator always
evaluates to false) when comparing an enum variable > an enum
constant even with the integer model for enumerations (+fie).
This warning is now not given for the integer model.
IMVT
* Template instantiation verbosity messages were improved by
(1) the end message now names the specialization that was just
completed and (2) the instantiation depth is noted.
IIVM
* We were not able to handle deeply nested template id's. E.g
B<B<B<B<B<B<B<B<B<B< ... > > > > > > > > > > > > > > > >
RQAP
* Class member enumerators encountered in different modules would result
in spurious messages suggesting that they were not previously defined.
HEMR
* When overload resolution involving a template could cause
template instantiation the instantiation could have triggered
a recursive overload resolution causing the first to fail.
PORD
* During overload resolution involving a function template and the
template function candidate is being synthesized from deduced
template arguments, we could fail to find parameter names of an
enclosing class template specialization.
TPAS
* There was an incorrect association of message 64 with
Misra 1998 Rule 29 and Misra 2004 Rule 5.4.
ILMM
* The -A option was decoupled from the -A(C...) option.
ASOA
* Internal Error 1207 was being issued during the template function
deduction phase of E::operator= in the example:
class E {
template< class T >
typename A<(C<T>::d)>::v operator=(T);
};
ETOS
* The probability that variable i in the following example could
exceed the array bound was getting lost in the following example:
void f( int i, int j )
{
int a[10];
if( i > 30 ) {}
while( j-- ) i = 0;
a[i] = 0;
}
DCVS
* A number of Microsoft pre-defined symbols are no longer predefined
for Visual Studio 6 and later. These include:
MSDOS, M_I86, LINT_ARGS, M_I86LM, M_I86CM, M_I86MM, M_I86SM
EPCM
* We no longer treat p - q where p and q are pointers as having
any of the properties of the constituent pointers. (such as auto,
new, etc.)
MPDA
* Our using declaration support was not adhering to the letter of
the standard; we now support a mix of functions and using declarations
which import functions, plus many other intricate and elaborate
using declaration combinations.
RIUD
* The malloc suspicous argument checking has been extended from
malloc( strlen(s+1) ) to include malloc( strlen(s-1) )
and malloc( strlen(1+s) )
ASMA
* In some cases we would not find names of entities with internal
linkage when the same scope contains identical names with external
linkage. E.g.
struct A{};
static int A( struct A * );
struct A q;
int n = A( &q );
The use of A in the last statement is now taken correctly to be
the function not the struct.
SSTE
* We issued a spurious 616 for namespace alias definitions appearing
after the beginning of a switch block.
NASS
* We were issuing a 522 ("expected a void type, assignment, increment
or decrement") rather than a 534 ("ignoring the return value of a
function") for the following statement:
ptr-to_function( arguments );
Where the pointed to function returns a non-void.
The 534 is a better fit and was the original message but was
inadvertently altered to a 522. Hence we are returning back to
issuing a 534.
IRVP
* We no longer issue a 533 for main() not returning a value provided
the main() function is found in a C++ program or in a C program
and the version of C is 1999 or greater.
NRMF
* We now issue an Error message (1093) when a pure specifier is given
for a non-virtual function.
PSRV
* We no longer report as unreferenced virtual overriders when the
context of a call to an overridden function could not rule out
calls to such overrides.
PCTO
* We no longer issue not-referenced messages for member functions
that are declared private and not defined.
FILU
* We were misprocessing default arguments for member functions when
they would refer to class members that have not yet been seen.
E.g.
class A { void f( int = abc ); int abc; };
DAV
* We were not always properly handling non-deducable array dimensions,
such as:
template<unsigned N> void f( int (&)[N+1] );
RDDA
* During function name lookup after the unqualified name lookup phase,
we were not searching the global namespace during the argument
dependent lookup phase. E.g.
class A{};
void g(A);
namespace N
{
void g(int);
void f()
{ g( A() ); }
}
N::g would be found in the unqualified name lookup but ::g would not
be found in the ADL.
MGAA
* We are now aware of the C99 format specifiers %t, %j, %z
(ptrdiff_t, intmax_t, size_t types). We also now recogize %l[ as
meaning pointer to wide char.
ERFS
* During unqualified lookup, a using directive of a given namespace
kicks in when the lookup reaches a namespace which encloses both
the using directive and the namespace.
NNUE
* We would issue an undeserved Error 1053 for a member function whose
class was defined identically in different file locations and in
different modules.
BCDC
* We did not recognize tagless types as having associated namespaces
during ADL.
TTAN
* We fixed a bug involving using declarations inside unnamed classes,
e.g. the following was not parsed correctly:
struct B { int f(); int f(int); };
typedef struct : public B { using B::f; } A;
UUDC
* We were issuing an undeserved 1030 in a situation in which
default arguments were being provided by two different declarations
for the same function.
ADAF
* Support was added for split default arguments. This is the situation
where default arguments within a declaration are supplemented by
additional default arguments added in the definition
* We now suppress message 122 (digit too large for radix) while
processing unknown pragmas.
SEUP
* Destructors now inherit the virtual property even though the base
class did not have an explicit destructor. Also non-copy assignment
operators were discovered to have not inherited the virtual property.
APSP
* An undeserved 1545 (value of ... used previously to initialize ...)
could be issued for a function as a result of it having been used
in a dynamic initialization of a static variable.
UCIM
*************** Version 8.00v 12/9/2006 ***************
* We had been looping when processing a class that has both
a declaration of a nested subclass followed by the definition
of that subclass.
LWAM
* Variables declared as selectany (Microsoft __declspec extension)
were being reported as multiply defined.
SVNM
* Fixed a problem that occurred when a member function template with
the same name as a member function in the same class (and appearing
physically after it). The template was presumed not to exist when
an explicit template argument list was provided for the template. E.g.:
template< class T > struct A
{
void f(int);
template< class T > void f(T);
};
A<char> ac;
Later ...
ac.f<>(1); // undeserved Error
EFTA
* The use of tmpname() has been discredited on at least one operating
system and the remedy offered was neither standard nor portable and
so the obscure portion of FlexeLint that employed a temporary file
name was rewritten to avoid its use.
RUOT
* The template keyword was confusing us. E.g.
p->template f<int>(n);
is now processed correctly
TKMA
* When an overloaded function name is passed to a template
whose parameter is a non-type template parameter typed as
a function pointer, we were not doing a proper overload selection
to determine the right function. E.g.
void f(char); void f(int);
template< void (*pf) (int) > struct A { ... };
A< &f > a; // should be OK
FONT
* We no longer report MISRA Rule 16.3 for generated class members.
GMEM
* In some cases the names of embedded subclasses were not fully
qualified when presented in error messages.
NCMQ
* We were issuing undeserved Misra 2 complaints when dealing with
Boolean expressions (those of the form A<=B, A && B, !B etc.).
When such expressions were assigned to variables whose underlying
type is signed integer we would issue Note 960, violation of
required rule 10.1.
MBUI
* We were not supporting fully externally defined nested classes
of class templates. E.g.
template< class T > class A { class B; };
template< class T > class A<T>::B { };
A<int>::B b; // 1080, definition for B not found
EDNC
* We fixed an infinite recursion in the context of ill-formed code
where a function definition was misinterpreted as a curly braced
initializer of a struct that contained itself as a member.
DRII
* Messages 1024 and 1025 ( "No function matches ..." ) could be
inaccurate or misleading when the overload candidate list included
a function template.
FTMT
* When member of a class template partial specialization is defined
externally to its class, we now use a procedure for selecting the
specialization which is simpler and more exact.
SPFD
* In some cases we were attempting to instantiate a class template
even though an explicit specialization existed to handle the case.
DIES
* In some cases we were not deducing the correct partial specialization
from a template-id. This was particularly noticeable when there
were many partial templates to choose from.
FTRP
* We were not distinguishing an nUL constant from nL nor an nULL
constant from an nLL constant. As a result overload discrimination
may not have resolved correctly when using UL constants or ULL
constants. In addition passing an LL constant to an overloaded
function could cause a crash. Technically LL constants are not
supported in official C++ and overloaded functions are not supported
in C so theoretically this should not have occurred.
ICBM
* We did not have full support for function template function parameters
of the form A< e > where A is a class template and e is a complex
expression involving template non-type parameters. E.g.
template< int i > class A { };
template< short s > void g( A<s+1> );
A<1> x;
... g<0>( x );
We now properly deduce that the intended specialization of g is
g( A<1> ).
CTAT
* We were not handling namespace alias definitions at block scope.
NABS
* A fully qualified name encountered as the mem-initializer-id within a
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -