Adapt testcase so it can be compiled with GCC 3.4.6.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@14194
This commit is contained in:
Florian Krohm 2014-07-26 11:36:50 +00:00
parent 282aac6b09
commit 5866bd2a56
4 changed files with 18 additions and 3 deletions

View File

@ -122,6 +122,7 @@ EXTRA_DIST = \
inlinfosupp.stderr.exp inlinfosupp.stdout.exp inlinfosupp.supp inlinfosupp.vgtest \
inlinfosuppobj.stderr.exp inlinfosuppobj.stdout.exp inlinfosuppobj.supp inlinfosuppobj.vgtest \
inltemplate.stderr.exp inltemplate.stdout.exp inltemplate.vgtest \
inltemplate.stderr.exp-old-gcc \
leak-0.vgtest leak-0.stderr.exp \
leak-cases-full.vgtest leak-cases-full.stderr.exp \
leak-cases-possible.vgtest leak-cases-possible.stderr.exp \

View File

@ -1,6 +1,15 @@
#include <stdio.h>
#include <valgrind.h>
/* GCC 3.4.6 will not compile inlined member template functions.
Let's assume GCC 4.x does */
#ifdef __GNUC__
#if __GNUC__ > 3
#define INLINE inline __attribute__((always_inline))
#else
#define INLINE
#endif
#endif
class X
{

View File

@ -1,5 +1,5 @@
Conditional jump or move depends on uninitialised value(s)
at 0x........: temp_member_func_b<int> (inltemplate.cpp:12)
by 0x........: int X::temp_member_func_noinline<int>(int) (inltemplate.cpp:19)
by 0x........: main (inltemplate.cpp:27)
at 0x........: temp_member_func_b<int> (inltemplate.cpp:21)
by 0x........: int X::temp_member_func_noinline<int>(int) (inltemplate.cpp:28)
by 0x........: main (inltemplate.cpp:36)

View File

@ -0,0 +1,5 @@
Conditional jump or move depends on uninitialised value(s)
at 0x........: int X::temp_member_func_b<int>(int) (inltemplate.cpp:21)
by 0x........: int X::temp_member_func_noinline<int>(int) (inltemplate.cpp:28)
by 0x........: main (inltemplate.cpp:36)