Bug #662

RichEdit compilation fails with GCC

Added by Jan DolinĂ¡r over 7 years ago. Updated over 7 years ago.

Status:ApprovedStart date:01/24/2014
Priority:NormalDue date:
Assignee:Miroslav Fidler% Done:

0%

Category:RichEditSpent time:-
Target version:-

Description

Build for 6807 failed, because of amiguous call to abs with double parameter in RichEdit/Mouse.cpp.

/build/buildd/upp-6807/uppsrc/RichEdit/Mouse.cpp: In function 'bool Upp::IsObjectPercent(Upp::Sizef, int)':
/build/buildd/upp-6807/uppsrc/RichEdit/Mouse.cpp:201:27: error: call of overloaded 'abs(double)' is ambiguous
  return abs(percent.cx - p) < 1 && abs(percent.cy - p) < 1;
                           ^
/build/buildd/upp-6807/uppsrc/RichEdit/Mouse.cpp:201:27: note: candidates are:
In file included from uppsrc/Core/Core.h:44:0,
                 from uppsrc/Draw/Draw.h:6,
                 from uppsrc/RichText/RichText.h:4,
                 from uppsrc/CtrlCore/CtrlCore.h:4,
                 from uppsrc/CtrlLib/CtrlLib.h:4,
                 from /build/buildd/upp-6807/uppsrc/RichEdit/RichEdit.h:4,
                 from /build/buildd/upp-6807/uppsrc/RichEdit/Mouse.cpp:1:
/usr/include/stdlib.h:770:12: note: int abs(int)
 extern int abs (int __x) __THROW __attribute__ ((__const__)) __wur;
            ^
In file included from uppsrc/Draw/Draw.h:6:0,
                 from uppsrc/RichText/RichText.h:4,
                 from uppsrc/CtrlCore/CtrlCore.h:4,
                 from uppsrc/CtrlLib/CtrlLib.h:4,
                 from /build/buildd/upp-6807/uppsrc/RichEdit/RichEdit.h:4,
                 from /build/buildd/upp-6807/uppsrc/RichEdit/Mouse.cpp:1:
uppsrc/Core/Core.h:366:20: note: Upp::int64 abs(Upp::int64)
 inline UPP::int64  abs(UPP::int64 x)          { return x < 0 ? -x : x; }
                    ^
/build/buildd/upp-6807/uppsrc/RichEdit/Mouse.cpp:201:54: error: call of overloaded 'abs(double)' is ambiguous
  return abs(percent.cx - p) < 1 && abs(percent.cy - p) < 1;
                                                      ^
/build/buildd/upp-6807/uppsrc/RichEdit/Mouse.cpp:201:54: note: candidates are:
In file included from uppsrc/Core/Core.h:44:0,
                 from uppsrc/Draw/Draw.h:6,
                 from uppsrc/RichText/RichText.h:4,
                 from uppsrc/CtrlCore/CtrlCore.h:4,
                 from uppsrc/CtrlLib/CtrlLib.h:4,
                 from /build/buildd/upp-6807/uppsrc/RichEdit/RichEdit.h:4,
                 from /build/buildd/upp-6807/uppsrc/RichEdit/Mouse.cpp:1:
/usr/include/stdlib.h:770:12: note: int abs(int)
 extern int abs (int __x) __THROW __attribute__ ((__const__)) __wur;
            ^
In file included from uppsrc/Draw/Draw.h:6:0,
                 from uppsrc/RichText/RichText.h:4,
                 from uppsrc/CtrlCore/CtrlCore.h:4,
                 from uppsrc/CtrlLib/CtrlLib.h:4,
                 from /build/buildd/upp-6807/uppsrc/RichEdit/RichEdit.h:4,
                 from /build/buildd/upp-6807/uppsrc/RichEdit/Mouse.cpp:1:
uppsrc/Core/Core.h:366:20: note: Upp::int64 abs(Upp::int64)
 inline UPP::int64  abs(UPP::int64 x)          { return x < 0 ? -x : x; }

Full log: https://launchpadlibrarian.net/163241237/buildlog_ubuntu-saucy-i386.upp_6807-1~saucy0_FAILEDTOBUILD.txt.gz

History

#1 Updated by Jan DolinĂ¡r over 7 years ago

  • Status changed from New to Approved

Works now, thanks.

Also available in: Atom PDF