[PATCH] Remove unreachable return stmt (PR c/53123)

2014-02-05 Thread Marek Polacek
This is not a regression, on the other hand it's so obvious that
it could go in nevertheless.  Ok?

2014-02-05  Marek Polacek  pola...@redhat.com

PR c/53123
c-family/
* c-omp.c (c_finish_omp_atomic): Remove unreachable return
statement.

diff --git gcc/c-family/c-omp.c gcc/c-family/c-omp.c
index 4ce51e4..dd0a45d 100644
--- gcc/c-family/c-omp.c
+++ gcc/c-family/c-omp.c
@@ -183,7 +183,6 @@ c_finish_omp_atomic (location_t loc, enum tree_code code,
   OMP_ATOMIC_SEQ_CST (x) = seq_cst;
   return build_modify_expr (loc, v, NULL_TREE, NOP_EXPR,
loc, x, NULL_TREE);
-  return x;
 }
 
   /* There are lots of warnings, errors, and conversions that need to happen

Marek


Re: [PATCH] Remove unreachable return stmt (PR c/53123)

2014-02-05 Thread Jakub Jelinek
On Wed, Feb 05, 2014 at 09:58:32PM +0100, Marek Polacek wrote:
 This is not a regression, on the other hand it's so obvious that
 it could go in nevertheless.  Ok?
 
 2014-02-05  Marek Polacek  pola...@redhat.com
 
   PR c/53123
 c-family/
   * c-omp.c (c_finish_omp_atomic): Remove unreachable return
   statement.

Ok, thanks.
 --- gcc/c-family/c-omp.c
 +++ gcc/c-family/c-omp.c
 @@ -183,7 +183,6 @@ c_finish_omp_atomic (location_t loc, enum tree_code code,
OMP_ATOMIC_SEQ_CST (x) = seq_cst;
return build_modify_expr (loc, v, NULL_TREE, NOP_EXPR,
   loc, x, NULL_TREE);
 -  return x;
  }
  
/* There are lots of warnings, errors, and conversions that need to happen

Jakub