bugThe FreeType Project - Bugs: bug #47955, Compiler Error with AIX Compiler...

 
 

bug #47955: Compiler Error with AIX Compiler extern "C++" into ftmemory.h

Submitted by:  None
Submitted on:  Wed 18 May 2016 10:26:18 AM UTC  
 
Severity: 3 - NormalItem Group: None
Status: FixedPrivacy: Public
Assigned to: Werner LEMBERG <wl>Open/Closed: Closed
Planned Release: 2.6.4

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sat 21 May 2016 09:21:00 AM UTC, comment #1:

Fixed in git. Thanks for the report!

Werner LEMBERG <wl>
Project AdministratorIn charge of this item.
Wed 18 May 2016 10:26:18 AM UTC, original submission:

OS: AIX 5.3.0.0
Compiler: C 8.0.0.1
IBM XL C/C++ Enterprise Edition V8.0 for AIX
Version: 08.00.0000.0001

Into ftmemory.h near line 68 we have this code:
#ifdef __cplusplus

extern "C++"
template <typename T> inline T*
cplusplus_typeof( T*,
void *v )
{
return static_cast <T*> ( v );
}

We encounter an error with AIX compiler:
freetype/internal/ftmemory.h", line 69.3: 1540-0063 (S) The text "template" is unexpected.

The compiler seems not correctly parsing the extern "C++" attached directly the template.
The fix is as easy as switching to extern "C++" {} around the template.
Regards...

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by wl (Posted a comment)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat 21 May 2016 09:21:00 AM UTCwlStatusNone=>Fixed
      Assigned toNone=>wl
      Open/ClosedOpen=>Closed
      Planned ReleaseNone=>2.6.4

    Back to the top


    Powered by Savane 3.1-cleanup1