binutils-gdb/gdb/testsuite/gdb.cp
Pedro Alves a60e07381c Fix racy output matching in gdb.base/cpcompletion.exp
With:

 $ make check-read1 TESTS="gdb.cp/cpcompletion.exp"

we get (from gdb.log):

 (gdb) complete break Foo::
 break Foo::Foo()
 break Foo::Foofoo()
 break Foo::get_foo()
 break Foo::set_foo(int)
 break Foo::~Foo()
 (gdb) FAIL: gdb.cp/cpcompletion.exp: complete class methods (Foo not found)

The problem is that the
  "break ${class}::\[A-Za-z0-9_~\]+"
regexp patches partial input, like:
  break Foo::F
  break Foo::Fo
  break Foo::Foo
etc.

Fix that by expecting each whole line.

gdb/testsuite/ChangeLog:
2017-11-09  Pedro Alves  <palves@redhat.com>

	* gdb.cp/cpcompletion.exp (test_class_complete): Tighten regex to
	match till end of line.
2017-11-09 22:46:06 +00:00
..
abstract-origin.cc
abstract-origin.exp
ambiguous.cc
ambiguous.exp
annota2.cc
annota2.exp Skip a few tests on targets that can't use the "run" commmand. 2017-10-13 18:11:31 +01:00
annota3.cc
annota3.exp Skip a few tests on targets that can't use the "run" commmand. 2017-10-13 18:11:31 +01:00
anon-ns2.cc
anon-ns.cc
anon-ns.exp
anon-struct.cc
anon-struct.exp
anon-union.cc
anon-union.exp
arg-reference.cc
arg-reference.exp
baseenum.cc
baseenum.exp
bool.cc
bool.exp
breakpoint.cc
breakpoint.exp
bs15503.cc
bs15503.exp
call-c-1.c
call-c.cc
call-c.exp
casts03.cc
casts.cc
casts.exp
chained-calls.cc
chained-calls.exp
class2.cc
class2.exp
classes.cc Fix broken recursion detection when printing static members 2017-10-26 22:26:08 -04:00
classes.exp Fix broken recursion detection when printing static members 2017-10-26 22:26:08 -04:00
cmpd-minsyms.cc
cmpd-minsyms.exp
converts.cc
converts.exp
cp-relocate.cc
cp-relocate.exp
cpcompletion.exp Fix racy output matching in gdb.base/cpcompletion.exp 2017-11-09 22:46:06 +00:00
cpexprs.cc Canonicalize conversion operators 2017-10-18 11:26:02 -07:00
cpexprs.exp Canonicalize conversion operators 2017-10-18 11:26:02 -07:00
cplabel.cc
cplabel.exp
cplusfuncs.cc
cplusfuncs.exp
cpsizeof.cc
cpsizeof.exp
ctti.exp
cttiadd1.cc
cttiadd2.cc
cttiadd3.cc
cttiadd.cc
debug-expr.exp
demangle.exp Add rvalue reference tests and docs 2017-03-20 13:47:59 -07:00
derivation2.cc
derivation.cc
derivation.exp
destrprint.cc
destrprint.exp
dispcxx.cc
dispcxx.exp
ena-dis-br-range.cc Allow enabling/disabling breakpoint location ranges 2017-11-07 11:00:31 +00:00
ena-dis-br-range.exp Add some more breakpoint/location range tests 2017-11-07 11:16:09 +00:00
enum-class.cc
enum-class.exp
exception.cc
exception.exp
exceptprint.cc
exceptprint.exp
expand-psymtabs-cxx.cc
expand-psymtabs-cxx.exp
expand-sals.cc
expand-sals.exp
extern-c.cc
extern-c.exp
filename.cc
filename.exp
formatted-ref.cc
formatted-ref.exp
fpointer.cc
fpointer.exp
gdb1355.cc
gdb1355.exp
gdb2384-base.cc
gdb2384-base.h
gdb2384.cc
gdb2384.exp
gdb2495.cc
gdb2495.exp
hang1.cc
hang2.cc
hang3.cc
hang.exp
hang.H
impl-this.cc
impl-this.exp
includefile
infcall-dlopen-lib.cc
infcall-dlopen.cc
infcall-dlopen.exp
inherit.exp
iostream.cc
iostream.exp
koenig.cc
koenig.exp
local-static.c Make "p S::method() const::static_var" work too 2017-09-04 20:21:16 +01:00
local-static.cc Handle "p S::method()::static_var" in the C++ parser 2017-09-04 20:21:15 +01:00
local-static.exp Make "p S::method() const::static_var" work too 2017-09-04 20:21:16 +01:00
local.cc
local.exp
m-data.cc
m-data.exp
m-static1.cc
m-static.cc
m-static.exp Handle "p 'S::method()::static_var'" (quoted) in symbol lookup 2017-09-04 20:21:16 +01:00
m-static.h
maint.exp
mb-ctor.cc
mb-ctor.exp
mb-inline1.cc
mb-inline2.cc
mb-inline.exp
mb-inline.h
mb-templates.cc
mb-templates.exp
member-name.cc
member-name.exp
member-ptr.cc
member-ptr.exp
meth-typedefs.cc
meth-typedefs.exp
method2.cc
method2.exp
method.cc
method.exp
minsym-fallback-main.cc
minsym-fallback.cc
minsym-fallback.exp
minsym-fallback.h
misc.cc
misc.exp
namelessclass.cc
namelessclass.exp
namelessclass.S
namespace1.cc
namespace-enum-main.cc
namespace-enum.cc
namespace-enum.exp
namespace-nested-import.cc
namespace-nested-import.exp
namespace.cc
namespace.exp
nextoverthrow.cc
nextoverthrow.exp
no-dmgl-verbose.cc
no-dmgl-verbose.exp
non-trivial-retval.cc
non-trivial-retval.exp
noparam.cc
noparam.exp
nsalias.cc
nsalias.exp
nsdecl.cc
nsdecl.exp
nsimport.cc
nsimport.exp
nsnested.cc
nsnested.exp
nsnoimports.cc
nsnoimports.exp
nsrecurs.cc
nsrecurs.exp
nsstress.cc
nsstress.exp
nsusing.cc
nsusing.exp
operator.cc
operator.exp
oranking.cc Make sure malloc is linked into gdb.cp/oranking.cc. 2017-05-03 12:41:09 -07:00
oranking.exp Fix overload resolution involving rvalue references and cv qualifiers. 2017-04-27 15:58:54 -07:00
overload-const.cc
overload-const.exp
overload.cc
overload.exp Make "list ambiguous" show symbol names too 2017-09-20 16:21:26 +01:00
ovldbreak.cc
ovldbreak.exp
ovsrch1.cc
ovsrch2.cc
ovsrch3.cc
ovsrch4.cc
ovsrch.exp
ovsrch.h
paren-type.cc
paren-type.exp
parse-lang.cc
parse-lang.exp
pass-by-ref.cc
pass-by-ref.exp
pr9067.cc
pr9067.exp
pr9167.cc
pr9167.exp
pr9594.cc
pr9631.cc
pr9631.exp
pr10687.cc
pr10687.exp
pr10728-x.cc
pr10728-x.h
pr10728-y.cc
pr10728.exp
pr12028.cc
pr12028.exp
pr17132.cc
pr17132.exp
pr17494.cc
pr17494.exp
pr-574.cc
pr-574.exp
pr-1023.cc
pr-1023.exp
pr-1210.cc
pr-1210.exp
printmethod.cc
printmethod.exp
psmang1.cc
psmang2.cc
psmang.exp
psymtab-parameter.cc
psymtab-parameter.exp
ptype-cv-cp.cc
ptype-cv-cp.exp
ptype-flags.cc
ptype-flags.exp
punctuator.exp
re-set-overloaded.cc
re-set-overloaded.exp
readnow-language.cc
readnow-language.exp
ref-params.cc
ref-params.exp
ref-types.cc
ref-types.exp
rtti1.cc
rtti2.cc
rtti.exp
rtti.h
rvalue-ref-casts.cc Add rvalue reference tests and docs 2017-03-20 13:47:59 -07:00
rvalue-ref-casts.exp Add rvalue reference tests and docs 2017-03-20 13:47:59 -07:00
rvalue-ref-overload.cc Add rvalue reference tests and docs 2017-03-20 13:47:59 -07:00
rvalue-ref-overload.exp Fix overload resolution involving rvalue references and cv qualifiers. 2017-04-27 15:58:54 -07:00
rvalue-ref-params.cc Add rvalue reference tests and docs 2017-03-20 13:47:59 -07:00
rvalue-ref-params.exp Fix overload resolution involving rvalue references and cv qualifiers. 2017-04-27 15:58:54 -07:00
rvalue-ref-sizeof.cc Add rvalue reference tests and docs 2017-03-20 13:47:59 -07:00
rvalue-ref-sizeof.exp Add rvalue reference tests and docs 2017-03-20 13:47:59 -07:00
rvalue-ref-types.cc Add rvalue reference tests and docs 2017-03-20 13:47:59 -07:00
rvalue-ref-types.exp Add rvalue reference tests and docs 2017-03-20 13:47:59 -07:00
scope-err.cc
scope-err.exp
shadow.cc
shadow.exp
smartp.cc
smartp.exp
static-method.cc
static-method.exp
static-print-quit.cc
static-print-quit.exp
temargs.cc
temargs.exp
templates.cc
templates.exp c++/8218: Destructors w/arguments. 2017-03-10 10:32:09 -08:00
try_catch.cc
try_catch.exp
typedef-operator.cc
typedef-operator.exp
typeid.cc
typeid.exp
userdef.cc
userdef.exp
using-crash.cc
using-crash.exp
var-tag-2.cc
var-tag-3.cc
var-tag-4.cc
var-tag.cc
var-tag.exp
virtbase.cc
virtbase.exp
virtfunc2.cc
virtfunc2.exp
virtfunc.cc
virtfunc.exp
vla-cxx.cc
vla-cxx.exp
wide_char_types.c Teach GDB that wchar_t is a built-in type in C++ mode 2017-04-12 14:06:40 +01:00
wide_char_types.exp Teach GDB that wchar_t is a built-in type in C++ mode 2017-04-12 14:06:40 +01:00