https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84368

--- Comment #4 from Benjamin Buch <benni.buch at gmail dot com> ---
I can still reproduce it on R257659:

$ g++ -std=c++14 main.cpp 
main.cpp: In instantiation of 'foo(T ...) [with T = {int}]::<lambda(auto:1
...)> [with auto:1 = {int}]':
main.cpp:9:6:   required from 'void foo(T ...) [with T = {int}]'
main.cpp:13:10:   required from here
main.cpp:8:17: error: use of 'bar' before deduction of 'auto'
         sink(bar(v, T{}) ...);
              ~~~^~~~~~~~
$ g++ --version
g++ (GCC) 8.0.1 20180214 (experimental)
Copyright (C) 2018 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.


GCC trunk compiled on Intel(R) Core(TM) i7-6700K CPU, Ubuntu 16.04 (64 Bit)
with GCC 6.3:
$ g++-6 --version
g++-6 (Ubuntu/Linaro 6.3.0-18ubuntu2~16.04) 6.3.0 20170519
Copyright (C) 2016 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.

Reply via email to