[PPL-devel] [GIT] ppl/ppl(master): Prefer early return to dummy assignment in unreachable code path.

Enea Zaffanella zaffanella at cs.unipr.it
Sat Dec 10 08:10:47 CET 2011


Module: ppl/ppl
Branch: master
Commit: 50504a0234039cab2e473884ed378a3058739412
URL:    http://www.cs.unipr.it/git/gitweb.cgi?p=ppl/ppl.git;a=commit;h=50504a0234039cab2e473884ed378a3058739412

Author: Enea Zaffanella <zaffanella at cs.unipr.it>
Date:   Sat Dec 10 07:42:51 2011 +0100

Prefer early return to dummy assignment in unreachable code path.

---

 src/Polyhedron_public.cc |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/src/Polyhedron_public.cc b/src/Polyhedron_public.cc
index a3f242b..8f61679 100644
--- a/src/Polyhedron_public.cc
+++ b/src/Polyhedron_public.cc
@@ -3017,8 +3017,7 @@ generalized_affine_preimage(const Variable var,
   default:
     // The EQUAL and NOT_EQUAL cases have been already dealt with.
     PPL_UNREACHABLE;
-    reversed_relsym = GREATER_OR_EQUAL;
-    break;
+    return;
   }
 
   // Check whether the preimage of this affine relation can be easily




More information about the PPL-devel mailing list