Summary: | dev-libs/tvision-2.1.0_pre2-r3 : ../.../tdesktop.cc:147:29: error: call of overloaded ‘abs(unsigned int)’ is ambiguous | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Toralf Förster <toralf> |
Component: | Current packages | Assignee: | No maintainer - Look at https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers if you want to take care of it <maintainer-needed> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | plevine457, treecleaner |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
See Also: | https://bugs.gentoo.org/show_bug.cgi?id=632196 | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 582084 | ||
Attachments: |
dev-libs:tvision-2.1.0_pre2-r3:20160918-021147.log
emerge-history.txt environment tvision-2.1.0_pre2-gcc6.patch emerge-info.txt dev-libs:tvision-2.2.1.4:20171130-020921.log emerge-history.txt environment etc.portage.tbz2 logs.tbz2 temp.tbz2 |
Description
Toralf Förster
2016-09-18 08:55:55 UTC
Created attachment 446328 [details]
dev-libs:tvision-2.1.0_pre2-r3:20160918-021147.log
Created attachment 446330 [details]
emerge-history.txt
Created attachment 446332 [details]
environment
Created attachment 447484 [details, diff]
tvision-2.1.0_pre2-gcc6.patch
Post c++11, std::abs isn't defined for unsigned values nor should it be. IIRC, the result of any arithmetic between unsigned operands is itself unsigned. And the absolute value of an unsigned value is that same value, so the `abs` should be able to be safely omitted:
i.e., given:
unsigned int a;
unsigned int b;
then:
int c = abs(a - b);
is the same as
int c = a - b;
for any a or b
Probably sending the patches using github PR would help to get all your gcc6 fixed pushed earlier :) Since nothing seems to require this, maybe this could be treecleaned :/ Thanks, fixed in git commit 7ef2291f68b16dd0e5c53ee0e760a39c089e048a got at the unstable amd64 chroot image 13.0-desktop-plasma-systemd_abi32+64_20171128-221102 this : ../.../tdesktop.cc:151:29: error: call of overloaded abs(unsigned int) is ambiguous Created attachment 507310 [details]
emerge-info.txt
Created attachment 507312 [details]
dev-libs:tvision-2.2.1.4:20171130-020921.log
Created attachment 507314 [details]
emerge-history.txt
Created attachment 507316 [details]
environment
Created attachment 507318 [details]
etc.portage.tbz2
Created attachment 507320 [details]
logs.tbz2
Created attachment 507322 [details]
temp.tbz2
I would open a separate bug report because your last failure looks a gcc7 issue, not gcc6 |