PR c++/77777 improve location for diagnostic
authorJonathan Wakely <jwakely@redhat.com>
Wed, 30 May 2018 23:13:48 +0000 (00:13 +0100)
committerJonathan Wakely <redi@gcc.gnu.org>
Wed, 30 May 2018 23:13:48 +0000 (00:13 +0100)
commitd72a3672c5450f76ca056b0bcc45b8dd55965802
tree6b69441661652d6e8a63c134717bbe9eaf3f1894
parentb67b9225f72e4b2d58e535c78dbeff83f94c8f66
PR c++/77777 improve location for diagnostic

Pass in the location of the invalid expression, not the next input
location (which might be a comma or closing parenthesis on a different
line).

gcc/cp:

PR c++/77777
* call.c (resolve_args): Use location of expression, not current input
location.

gcc/testsuite:

PR c++/77777
* g++.dg/diagnostic/pr77777.C: New test.

From-SVN: r260979
gcc/cp/ChangeLog
gcc/cp/call.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/diagnostic/pr77777.C [new file with mode: 0644]