[Bug c++/53012] unrelated friend operators in same namespace interfere with operator resolution outside of namespace
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53012 Adam H. Peterson changed: What|Removed |Added CC||alphaetapi at hotmail dot ||com --- Comment #1 from Adam H. Peterson 2012-04-16 23:22:47 UTC --- I get the same results here. I've also determined that the problem doesn't rely on using operator overloading or #include-ing . Here's a program that fails similarly without using either (and in fact has no #includes): namespace one { class A { }; } void func(const ::one::A& ) { } namespace two { class unrelated_a { friend void func( const unrelated_a& ); }; #if not defined MAKE_IT_WORK class unrelated_b { friend void func( const unrelated_b& ); }; #endif void output( const one::A& val ) { func(val); } } int main() { two::output( one::A() ); } With the above code, I get "'func' was not declared in this scope" inside output()'s body. While it's true that func() is not declared in namespace two, it is in the global scope. And in fact, apparently it is found if the definition for class unrelated_b is removed.
[Bug c++/69078] [C++14] function local static not initialized when only used in a generic/variadic lambda
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69078 Adam H. Peterson changed: What|Removed |Added CC||alphaetapi at hotmail dot com --- Comment #1 from Adam H. Peterson --- I'm seeing this too, in one of my work projects. And I also see the odd results when the variable is used both in the lambda and outside of it. #include template void run( F &&f ) { f(nullptr); } struct V { int i; }; int main() { static V const s={2}; std::cout << s.i << "\n"; run([](auto){ std::cout << s.i << "\n" ; }); } Expected output: 2 2 Actual output: 2 0 (The in-function use seems to have been inlined, while the lambda continues to access an uninitialized state.)
[Bug tree-optimization/26854] Inordinate compile times on large routines
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=26854 Adam H. Peterson changed: What|Removed |Added CC||alphaetapi at hotmail dot com --- Comment #137 from Adam H. Peterson --- Incidentally, my GCC version is 5.3: $ g++ --version g++ (Debian 5.3.1-13) 5.3.1 20160323 Copyright (C) 2015 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. My OS is Debian/Testing: $ uname -a Linux -desktop 4.4.0-1-amd64 #1 SMP Debian 4.4.6-1 (2016-03-17) x86_64 GNU/Linux
[Bug c++/69078] [C++14] function local static not initialized when only used in a generic/variadic lambda
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69078 --- Comment #2 from Adam H. Peterson --- Incidentally, my GCC version is 5.3: $ g++ --version g++ (Debian 5.3.1-13) 5.3.1 20160323 Copyright (C) 2015 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. My OS is Debian/Testing: $ uname -a Linux -desktop 4.4.0-1-amd64 #1 SMP Debian 4.4.6-1 (2016-03-17) x86_64 GNU/Linux
[Bug tree-optimization/26854] Inordinate compile times on large routines
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=26854 --- Comment #138 from Adam H. Peterson --- Disregard my comment above. I was dropped into the wrong bug.