re PR c++/71238 (Undeclared function message imprecisely points to error column)
authorPaolo Carlini <paolo.carlini@oracle.com>
Mon, 30 May 2016 19:18:13 +0000 (19:18 +0000)
committerPaolo Carlini <paolo@gcc.gnu.org>
Mon, 30 May 2016 19:18:13 +0000 (19:18 +0000)
commitb2f6675b74a6d16ab44202ac0e49587da8f7d4cf
treedbbf824a1e3f3eb03d521c288eda3737fe08defe
parent9ce542ba4a138f762697778f339da66beeb13991
re PR c++/71238 (Undeclared function message imprecisely points to error column)

/cp
2016-05-30  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/71238
* lex.c (unqualified_name_lookup_error): Take a location too.
(unqualified_fn_lookup_error): Take a cp_expr.
* cp-tree.h (unqualified_name_lookup_error,
unqualified_fn_lookup_error): Adjust declarations.
* semantics.c (perform_koenig_lookup): Adjust
unqualified_fn_lookup_error call, pass the location of
the identifier too as part of a cp_expr.

/testsuite
2016-05-30  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/71238
* g++.dg/parse/pr71238.C: New.
* g++.dg/concepts/friend1.C: Test column numbers too.
* g++.dg/cpp0x/initlist31.C: Likewise.
* g++.dg/cpp0x/pr51420.C: Likewise.
* g++.dg/cpp0x/udlit-declare-neg.C: Likewise.
* g++.dg/cpp0x/udlit-member-neg.C: Likewise.
* g++.dg/ext/builtin3.C: Likewise.
* g++.dg/lookup/friend12.C: Likewise.
* g++.dg/lookup/friend7.C: Likewise.
* g++.dg/lookup/koenig1.C: Likewise.
* g++.dg/lookup/koenig5.C: Likewise.
* g++.dg/lookup/used-before-declaration.C: Likewise.
* g++.dg/overload/koenig1.C: Likewise.
* g++.dg/template/crash65.C: Likewise.
* g++.dg/template/friend57.C: Likewise.
* g++.dg/warn/Wshadow-5.C: Likewise.
* g++.dg/warn/Wunused-8.C: Likewise.
* g++.old-deja/g++.bugs/900211_01.C: Likewise.
* g++.old-deja/g++.jason/lineno5.C: Likewise.
* g++.old-deja/g++.jason/member.C: Likewise.
* g++.old-deja/g++.jason/report.C: Likewise.
* g++.old-deja/g++.jason/scoping12.C: Likewise.
* g++.old-deja/g++.law/visibility20.C: Likewise.
* g++.old-deja/g++.ns/koenig5.C: Likewise.
* g++.old-deja/g++.other/static5.C: Likewise.
* g++.old-deja/g++.pt/overload2.C: Likewise.

From-SVN: r236896
31 files changed:
gcc/cp/ChangeLog
gcc/cp/cp-tree.h
gcc/cp/lex.c
gcc/cp/semantics.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/concepts/friend1.C
gcc/testsuite/g++.dg/cpp0x/initlist31.C
gcc/testsuite/g++.dg/cpp0x/pr51420.C
gcc/testsuite/g++.dg/cpp0x/udlit-declare-neg.C
gcc/testsuite/g++.dg/cpp0x/udlit-member-neg.C
gcc/testsuite/g++.dg/ext/builtin3.C
gcc/testsuite/g++.dg/lookup/friend12.C
gcc/testsuite/g++.dg/lookup/friend7.C
gcc/testsuite/g++.dg/lookup/koenig1.C
gcc/testsuite/g++.dg/lookup/koenig5.C
gcc/testsuite/g++.dg/lookup/used-before-declaration.C
gcc/testsuite/g++.dg/overload/koenig1.C
gcc/testsuite/g++.dg/parse/pr71238.C [new file with mode: 0644]
gcc/testsuite/g++.dg/template/crash65.C
gcc/testsuite/g++.dg/template/friend57.C
gcc/testsuite/g++.dg/warn/Wshadow-5.C
gcc/testsuite/g++.dg/warn/Wunused-8.C
gcc/testsuite/g++.old-deja/g++.bugs/900211_01.C
gcc/testsuite/g++.old-deja/g++.jason/lineno5.C
gcc/testsuite/g++.old-deja/g++.jason/member.C
gcc/testsuite/g++.old-deja/g++.jason/report.C
gcc/testsuite/g++.old-deja/g++.jason/scoping12.C
gcc/testsuite/g++.old-deja/g++.law/visibility20.C
gcc/testsuite/g++.old-deja/g++.ns/koenig5.C
gcc/testsuite/g++.old-deja/g++.other/static5.C
gcc/testsuite/g++.old-deja/g++.pt/overload2.C