Skip to content

Commit

Permalink
[ARM] Fix more -Wreturn-type fallout
Browse files Browse the repository at this point in the history
This patch fixes a couple of more tests that are giving out warnings with -Wreturn-type:
- g++.dg/ext/pr57735.C
- gcc.target/arm/pr54300.C

*** gcc/testsuite/ChangeLog ***

2017-11-10  Sudakshina Das  <sudi.das@arm.com>

        * g++.dg/ext/pr57735.C: Add -Wno-return-type for test.
        * gcc.target/arm/pr54300.C (main): Add return type and
        return a value.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@254773 138bc75d-0d04-0410-961f-82ee72b054a4
  • Loading branch information
ktkachov committed Nov 15, 2017
1 parent 11ca88d commit 9d1de23
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
6 changes: 6 additions & 0 deletions gcc/testsuite/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
2017-11-15 Sudakshina Das <sudi.das@arm.com>

* g++.dg/ext/pr57735.C: Add -Wno-return-type for test.
* gcc.target/arm/pr54300.C (main): Add return type and
return a value.

2017-11-15 Tom de Vries <tom@codesourcery.com>

* gcc.dg/strncpy-fix-1.c: Add -Wno-stringop-truncation to dg-options.
Expand Down
2 changes: 1 addition & 1 deletion gcc/testsuite/g++.dg/ext/pr57735.C
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/* { dg-require-effective-target arm_arch_v5te_ok } */
/* { dg-require-effective-target arm_arm_ok } */
/* { dg-skip-if "do not override -mfloat-abi" { *-*-* } { "-mfloat-abi=*" } {"-mfloat-abi=soft" } } */
/* { dg-options "-march=armv5te -marm -mtune=xscale -mfloat-abi=soft -O1" } */
/* { dg-options "-march=armv5te -marm -mtune=xscale -mfloat-abi=soft -O1 -Wno-return-type" } */

typedef unsigned int size_t;
__extension__
Expand Down
2 changes: 2 additions & 0 deletions gcc/testsuite/gcc.target/arm/pr54300.C
Original file line number Diff line number Diff line change
Expand Up @@ -51,11 +51,13 @@ test(unsigned short *_Inp, int32_t *_Out,
vst1q_s32( _Out, c );
}

int
main()
{
unsigned short a[4] = {1, 2, 3, 4};
int32_t b[4] = {0, 0, 0, 0};
test(a, b, 1, 1, ~0);
if (b[0] != 1 || b[1] != 2 || b[2] != 3 || b[3] != 4)
abort();
return 0;
}

0 comments on commit 9d1de23

Please sign in to comment.