From: Ilya Enkovich Date: Mon, 16 Feb 2015 10:03:26 +0000 (+0000) Subject: pr65002.C: Move ... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=d39023b4d5a35bd5924eaa8593068a62894b9747;p=gcc.git pr65002.C: Move ... gcc/testsuite/ * gcc.dg/pr65002.C: Move ... * g++.dg/ipa/pr65002.C: ... here. From-SVN: r220731 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 875064beac5..01dc0725688 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2015-02-16 Ilya Enkovich + + * gcc.dg/pr65002.C: Move ... + * g++.dg/ipa/pr65002.C: ... here. + 2015-02-14 David Edelsohn * gcc.target/powerpc/pr64205.c: Skip on AIX. diff --git a/gcc/testsuite/g++.dg/ipa/pr65002.C b/gcc/testsuite/g++.dg/ipa/pr65002.C new file mode 100644 index 00000000000..ac7c66bd19a --- /dev/null +++ b/gcc/testsuite/g++.dg/ipa/pr65002.C @@ -0,0 +1,26 @@ +/* PR tree-optimization/65002 */ +/* { dg-do compile } */ +/* { dg-options "-O2" } */ + +namespace fastmath { + template float floor(const T &) __attribute__((const)); + template float floor(const T &p1) { return p1; } +} +using fastmath::floor; +class A { +public: + A(int, int); + virtual int m_fn1(float) const; +}; +class B : A { +public: + B(int, int p2) : A(entity, p2) {} + int m_fn1(float p1) const { long b(floor(p1)); } + int entity; +}; + +int a; +void Convert() { + if (int *c = 0) + B(*c, a); +} diff --git a/gcc/testsuite/gcc.dg/pr65002.C b/gcc/testsuite/gcc.dg/pr65002.C deleted file mode 100644 index ac7c66bd19a..00000000000 --- a/gcc/testsuite/gcc.dg/pr65002.C +++ /dev/null @@ -1,26 +0,0 @@ -/* PR tree-optimization/65002 */ -/* { dg-do compile } */ -/* { dg-options "-O2" } */ - -namespace fastmath { - template float floor(const T &) __attribute__((const)); - template float floor(const T &p1) { return p1; } -} -using fastmath::floor; -class A { -public: - A(int, int); - virtual int m_fn1(float) const; -}; -class B : A { -public: - B(int, int p2) : A(entity, p2) {} - int m_fn1(float p1) const { long b(floor(p1)); } - int entity; -}; - -int a; -void Convert() { - if (int *c = 0) - B(*c, a); -}