[cfe-users] Bug report: Clang 5.0 (SVN r298093) cannot deduct class template arguments of tuple.

2017-03-29 Thread 312988...@qq.com via cfe-users
Hi, all,

Below cannot be compiled with clang 5.0 (SVN r298093) on Visual Studio 2017.

#include 

using namespace std;

int main()
{
tuple t{ 1, 3.14 };
}

The error message are as follows:

1>-- Build started: Project: cpptest, Configuration: Debug x64 --
1>main.cpp(19,8): error : no viable constructor or deduction guide for 
deduction of template arguments of 'tuple'
1>tuple t{ 1, 3.14 };
1>  ^
1>C:\Program Files (x86)\Microsoft Visual 
Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\utility(88,8):  note: 
candidate function template not viable: requires 0 arguments, but 2 were 
provided
1>class tuple;
1>  ^
1>C:\Program Files (x86)\Microsoft Visual 
Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\utility(88,8):  note: 
candidate function template not viable: requires 1 argument, but 2 were provided
1>1 error generated.
1>Done building project "cpptest.vcxproj" -- FAILED.
== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==

I have applied for an account for submitting bugs of clang, but no response 
from the administrators. So I have to send mail to this forum.



312988...@qq.com
___
cfe-users mailing list
cfe-users@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-users


Re: [cfe-users] Bug report: Clang 5.0 (SVN r298093) cannot deduct class template arguments of tuple.

2017-03-30 Thread 312988...@qq.com via cfe-users
Yes. I conpiled it with std=c++1z; but the bug still exists.



312988...@qq.com
 
From: Csaba Raduly
Date: 2017-03-30 15:44
To: 312988...@qq.com
CC: cfe-users
Subject: Re: [cfe-users] Bug report: Clang 5.0 (SVN r298093) cannot deduct 
class template arguments of tuple.
Hi,
 
 
Deducing template parameters for constructors is a C++17 feature. You
need to pass the -std=c++1z flag to the compiler.
 
On Thu, Mar 30, 2017 at 3:48 AM, 312988...@qq.com via cfe-users
 wrote:
> Hi, all,
>
> Below cannot be compiled with clang 5.0 (SVN r298093) on Visual Studio 2017.
>
> #include 
>
> using namespace std;
>
> int main()
> {
> tuple t{ 1, 3.14 };
> }
>
> The error message are as follows:
>
> 1>-- Build started: Project: cpptest, Configuration: Debug x64 --
> 1>main.cpp(19,8): error : no viable constructor or deduction guide for
> deduction of template arguments of 'tuple'
> 1>tuple t{ 1, 3.14 };
> 1>  ^
> 1>C:\Program Files (x86)\Microsoft Visual
> Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\utility(88,8):
> note: candidate function template not viable: requires 0 arguments, but 2
> were provided
> 1>class tuple;
> 1>  ^
> 1>C:\Program Files (x86)\Microsoft Visual
> Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\utility(88,8):
> note: candidate function template not viable: requires 1 argument, but 2
> were provided
> 1>1 error generated.
> 1>Done building project "cpptest.vcxproj" -- FAILED.
> == Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==
>
> I have applied for an account for submitting bugs of clang, but no response
> from the administrators. So I have to send mail to this forum.
>
> 
> 312988...@qq.com
>
> ___
> cfe-users mailing list
> cfe-users@lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-users
>
 
 
 
-- 
GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++
The Tao of math: The numbers you can count are not the real numbers.
Life is complex, with real and imaginary parts.
"Ok, it boots. Which means it must be bug-free and perfect. " -- Linus Torvalds
"People disagree with me. I just ignore them." -- Linus Torvalds
 
___
cfe-users mailing list
cfe-users@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-users


[cfe-users] Bug report: Clang 5.0 (SVN r298093) cannot deduct class template arguments of tuple.

2017-04-03 Thread 312988...@qq.com via cfe-users
Hi, all,

Below cannot be compiled with clang 5.0 (SVN r298093) on Visual Studio 2017.

#include 

using namespace std;

int main()
{
tuple t{ 1, 3.14 };
}

The error message are as follows:

1>-- Build started: Project: cpptest, Configuration: Debug x64 --
1>main.cpp(19,8): error : no viable constructor or deduction guide for 
deduction of template arguments of 'tuple'
1>tuple t{ 1, 3.14 };
1>  ^
1>C:\Program Files (x86)\Microsoft Visual 
Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\utility(88,8):  note: 
candidate function template not viable: requires 0 arguments, but 2 were 
provided
1>class tuple;
1>  ^
1>C:\Program Files (x86)\Microsoft Visual 
Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\utility(88,8):  note: 
candidate function template not viable: requires 1 argument, but 2 were provided
1>1 error generated.
1>Done building project "cpptest.vcxproj" -- FAILED.
== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==

I have applied for an account for submitting bugs of clang, but no response 
from the administrators. So I have to send mail to this forum.



312988...@qq.com
___
cfe-users mailing list
cfe-users@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-users