https://bz.apache.org/ooo/show_bug.cgi?id=126999

          Issue ID: 126999
        Issue Type: DEFECT
           Summary: vcl/source/glyphs/graphite_layout.cxx compile failure
                    with libc++ version 3.8.0
           Product: General
           Version: 4.2.0-dev
          Hardware: All
                OS: FreeBSD
            Status: CONFIRMED
          Severity: Normal
          Priority: P5 (lowest)
         Component: code
          Assignee: [email protected]
          Reporter: [email protected]

Created attachment 85576
  --> https://bz.apache.org/ooo/attachment.cgi?id=85576&action=edit
patch to fix graphite_layout.cxx compile failure with libc++ version 3.8.0

As documented here: <https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=209588>,
vcl/source/glyphs/graphite_layout.cxx fails to compile with libc++ version
3.8.0 with this error:

/wrkdirs/usr/ports/editors/openoffice-4/work/aoo-4.1.2/main/vcl/source/glyphs/graphite_layout.cxx:297:21:
error: call to 'round' is ambiguous
    long nXOffset = round(fMinX * fScaling);
                    ^~~~~
The problem is that graphite_layout.cxx defines this inline function:
    inline long round(const float n) {
        return long(n + (n < 0 ? -0.5 : 0.5));   
    }

which matches the overloaded float round(float [...]) library function other
than the return type.

Fix this problem by renaming the local function to round2long() to make it
unambiguous and better describe its functionality.  Adjust all of its callers
to match.

-- 
You are receiving this mail because:
You are the assignee for the issue.

Reply via email to