Date: Thu, 12 May 2016 16:15:08 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-ports-bugs@FreeBSD.org Subject: [Bug 209467] devel/llvm37: clang++37 behaves differently on 9.3 and 10.3 Message-ID: <bug-209467-13@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D209467 Bug ID: 209467 Summary: devel/llvm37: clang++37 behaves differently on 9.3 and 10.3 Product: Ports & Packages Version: Latest Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: Individual Port(s) Assignee: brooks@FreeBSD.org Reporter: yuri@rawbw.com Flags: maintainer-feedback?(brooks@FreeBSD.org) Assignee: brooks@FreeBSD.org Using the same package, clang++NN successfully compiles test.cc on 10.3 and fails on 9.3. This is true for clang++34, clang++37 and probably for all of clang++NN. This is also true for clang-3.4.1 in the bases of 9.3 and 10.3. The same version of compiler should compile the same standalone C/C++ code = the same way, regardless of the OS version. --program test.cc--- #include <limits> int main() { const int vmax =3D std::numeric_limits<int>::max(); static_assert(vmax>0, ""); } ---command--- clang++37 -std=3Dc++11 -c test.cc ---error on 9.3--- test.cc:6:17: error: static_assert expression is not an integral constant expression static_assert(vmax>0, ""); ^~~~~~ test.cc:6:17: note: initializer of 'vmax' is not a constant expression test.cc:5:13: note: declared here const int vmax =3D std::numeric_limits<int>::max(); ^ 1 error generated. --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-209467-13>