IBM Support

LI78598: INVALID VIRTUAL FUNCTION DEFINITION CAUSING INTERNAL COMPILER ERROR

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • An invalid virtual function definition is causing an internal
    compiler error instead of a diagnostic message.
    
    
       === TEST CASE ===
    
    #include <memory>
    
    class Parent {
      public:
       virtual long test() const   = 0;
    };
    
    class ChildClass : public Parent {
      public:
        virtual long test() const;
    };
    
    template <typename T>
    class ChildTemplateClass : public Parent {};
    
    template <typename T>
    long ChildTemplateClass<T>::ChildClass::test() const
    {
      return 0;
    }
    
    std::auto_ptr<Parent> test()
    {
      return std::auto_ptr<Parent>( new ChildTemplateClass<int>());
    }
    
       === OUTPUT ===
    $ xlC apar.cpp
    xlC: 1501-230 (S) Internal compiler error; please contact your
    Service Representative. For more information visit:
    http://www.ibm.com/support/docview.wss?uid=swg21110810
    $
    
       === EXPECTED OUTPUT ===
    $ xlC apar.cpp
    "apar.cpp", line 17.29: 1540-0129 (S) The qualifier "ChildClass"
    is not defined in the current scope.
    $
    

Local fix

Problem summary

  • PROBLEM DESCRIPTION:
    The compiler is not correctly emitting the expected error
    message for the errror condition, causing an internal compiler
    error.
    
    USERS AFFECTED:
    The error might be seen after an implicit instantiation failed
    with a valid error message.
    

Problem conclusion

  • The problem has been resolved.
    

Temporary fix

Comments

APAR Information

  • APAR number

    LI78598

  • Reported component name

    XL C/C++ FOR BG

  • Reported component ID

    5799AG100

  • Reported release

    C10

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2015-05-25

  • Closed date

    2015-05-25

  • Last modified date

    2015-05-25

  • APAR is sysrouted FROM one or more of the following:

    IV69096

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    XL C/C++ FOR BG

  • Fixed component ID

    5799AG100

Applicable component levels

[{"Business Unit":{"code":"BU048","label":"IBM Software"},"Product":{"code":"SS2LWA","label":"XL C\/C++ for Blue Gene\/Q"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"12.1","Edition":"","Line of Business":{"code":"LOB73","label":"Power TPS"}}]

Document Information

Modified date:
05 September 2024