From f55ffabbe082e11a979271ed28e2ffe2a4845de4 Mon Sep 17 00:00:00 2001 From: Jane Tournois Date: Wed, 17 Jun 2020 13:36:04 +0200 Subject: [PATCH] add an assertion in make_canonical it also helps to make the code more explicit --- Triangulation_3/include/CGAL/Triangulation_3.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Triangulation_3/include/CGAL/Triangulation_3.h b/Triangulation_3/include/CGAL/Triangulation_3.h index b412b36471d..795aca2d6a0 100644 --- a/Triangulation_3/include/CGAL/Triangulation_3.h +++ b/Triangulation_3/include/CGAL/Triangulation_3.h @@ -4229,19 +4229,21 @@ make_canonical(Vertex_triple& t) const Vertex_handle tmp; switch(i) { - case 0: return; + case 0: break; case 1: tmp = t.first; t.first = t.second; t.second = t.third; t.third = tmp; - return; + break; default: tmp = t.first; t.first = t.third; t.third = t.second; t.second = tmp; } + + CGAL_assertion(t.first < t.second && t.first < t.third); } template < class GT, class Tds, class Lds >