Fixes are available
APAR status
Closed as program error.
Error description
The following redueced test case gives out invalid name lookup error message compiled on xlC: /* nt.cpp */ struct Base {}; struct Fifo{ void end(); }; // 38 struct FifoWithSync2:public Fifo{ typedef Fifo Base; Fifo* other() const; void end() { // 57 (S) other()->Base::end(); } }; $xlC nt.cpp "nt.cpp", line 16.18: 1540-0259 (S) The name lookups of "Base" do not yield the same type in the context of the expression and in the context of the class of the object expression. "nt.cpp", line 16.18: 1540-1209 (I) The name lookup in the context of "struct Fifo" resolved to "struct Base". "nt.cpp", line 16.18: 1540-1210 (I) Name lookup in the context of the expression resolved to "FifoWithSync2::Base".
Local fix
Change the tydef statement to another name, or remove it altogether. For example: typedef Fifo Base1; ... other()->Base1::end(); Or // typedef Fifo Base; ... other()->Fifo::end();
Problem summary
USER AFFECTED: The problem will only happen on a member access (. or ->) followed by a qualified name, when there is more than one name found by name lookup. PROBLEM DESCRIPTION: An incorrect name lookup caused the compiler to pick two names and report them in conflict.
Problem conclusion
The issue with name lookup has been fixed.
Temporary fix
Comments
APAR Information
APAR number
LI75334
Reported component name
XL C/C++ SLES10
Reported component ID
5724S7300
Reported release
900
Status
CLOSED PER
PE
NoPE
HIPER
NoHIPER
Special Attention
NoSpecatt
Submitted date
2010-03-11
Closed date
2010-03-11
Last modified date
2010-03-11
APAR is sysrouted FROM one or more of the following:
APAR is sysrouted TO one or more of the following:
Fix information
Fixed component name
XL C/C++ SLES10
Fixed component ID
5724S7300
Applicable component levels
R900 PSN IZ51545
UP06/09/13
[{"Business Unit":{"code":"BU054","label":"Systems w\/TPS"},"Product":{"code":"SSJT9L","label":"XL C\/C++"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"9.0","Line of Business":{"code":"LOB08","label":"Cognitive Systems"}}]
Document Information
Modified date:
16 October 2021