Summary: | GDB doesn't do Koenig lookup | ||
---|---|---|---|
Product: | gdb | Reporter: | David Carlton <carlton> |
Component: | c++ | Assignee: | Sami Wagiaalla <swagiaal> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | gdb-prs |
Priority: | P3 | ||
Version: | unknown | ||
Target Milestone: | 7.2 | ||
Host: | Target: | ||
Build: | Last reconfirmed: |
Description
David Carlton
2002-11-19 22:28:00 UTC
Fix: This will take a little while... Subject: Bug 7943 CVSROOT: /cvs/src Module name: src Changes by: swagiaal@sourceware.org 2010-05-07 14:46:29 Modified files: gdb : ChangeLog c-exp.y cp-support.c cp-support.h eval.c expprint.c expression.h parse.c valops.c value.h gdb/testsuite : ChangeLog Added files: gdb/testsuite/gdb.cp: koenig.cc koenig.exp Log message: Add ADL support 2010-05-07 Sami Wagiaalla <swagiaal@redhat.com> PR C++/7943: * valops.c (find_overload_match): Handle fsym == NULL case. Add int no_adl argument. (find_oload_champ_namespace_loop): Call make_symbol_overload_list_adl when appropriate. Add int no_adl argument. (find_oload_champ_namespace): Add int no_adl argument. * parse.c (operator_length_standard): Return length for OP_ADL_FUNC expression. * expprint.c (op_name_standard): Added string for OP_ADL_FUNC case. * eval.c (evaluate_subexp_standard): Added OP_ADL_FUNC case. Evaluate arguments and use them to perform ADL lookup. Pass no_adl argument to find_overload_match. Disable adl lookup when evaluating a fully qualified OP_FUNCALL. * cp-support.h: Added prototype for make_symbol_overload_list_namespace. * cp-support.c (make_symbol_overload_list_namespace): New function. (make_symbol_overload_list_adl_namespace): New function. (make_symbol_overload_list_adl): New function. (make_symbol_overload_list_using): Moved code to add function to overload set to make_symbol_overload_list_namespace. * c-exp.y: create UNKNOWN_CPP_NAME token. Add parse rule for ADL functions. (classify_name): Recognize an UNKNOWN_CPP_NAME. 2010-05-07 Sami Wagiaalla <swagiaal@redhat.com> * gdb.cp/koenig.exp: New test. * gdb.cp/koenig.cc: New test program. Patches: http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/ChangeLog.diff?cvsroot=src&r1=1.11762&r2=1.11763 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/c-exp.y.diff?cvsroot=src&r1=1.74&r2=1.75 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/cp-support.c.diff?cvsroot=src&r1=1.38&r2=1.39 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/cp-support.h.diff?cvsroot=src&r1=1.37&r2=1.38 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/eval.c.diff?cvsroot=src&r1=1.130&r2=1.131 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/expprint.c.diff?cvsroot=src&r1=1.42&r2=1.43 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/expression.h.diff?cvsroot=src&r1=1.34&r2=1.35 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/parse.c.diff?cvsroot=src&r1=1.97&r2=1.98 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/valops.c.diff?cvsroot=src&r1=1.240&r2=1.241 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/value.h.diff?cvsroot=src&r1=1.155&r2=1.156 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/testsuite/ChangeLog.diff?cvsroot=src&r1=1.2262&r2=1.2263 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/testsuite/gdb.cp/koenig.cc.diff?cvsroot=src&r1=NONE&r2=1.1 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/testsuite/gdb.cp/koenig.exp.diff?cvsroot=src&r1=NONE&r2=1.1 Fixed in 7.2. |