* return-nodebug.c: Don't include stdio.h.
(init): Delete. (func): Delete definition and provide extern declaration. (t): New. (main): Don't call printf. Call func and store its result in t. * return-nodebug1.c: New. * return-nodebug.exp: Don't expect stdio output. Instead, print the global variable t. Drop printf formatters and cast types from foreach loop. Don't use prepare_for_testing. Compile return-nodebug.c and return-nodebug1.c in separate steps. Don't define FORMAT or CAST.
This commit is contained in:
parent
42e5fcbf34
commit
51272cf2e9
4 changed files with 70 additions and 32 deletions
22
gdb/testsuite/gdb.base/return-nodebug1.c
Normal file
22
gdb/testsuite/gdb.base/return-nodebug1.c
Normal file
|
@ -0,0 +1,22 @@
|
|||
/* This testcase is part of GDB, the GNU debugger.
|
||||
|
||||
Copyright 2009 Free Software Foundation, Inc.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>. */
|
||||
|
||||
TYPE
|
||||
func (void)
|
||||
{
|
||||
return 31;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue