From 9718a5b0bcc65524f6f7259f73f89cd6eebafe53 Mon Sep 17 00:00:00 2001 From: Sylvain Pion Date: Fri, 29 Aug 2008 17:23:49 +0000 Subject: [PATCH] Make the "random generator" global. --- Intersections_2/test/Intersections_2/test_intersections_2.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Intersections_2/test/Intersections_2/test_intersections_2.cpp b/Intersections_2/test/Intersections_2/test_intersections_2.cpp index 36be548e611..2c2968e5a94 100644 --- a/Intersections_2/test/Intersections_2/test_intersections_2.cpp +++ b/Intersections_2/test/Intersections_2/test_intersections_2.cpp @@ -52,6 +52,8 @@ inline randomint::randomint() sequence[10] = 11; } +randomint ri; + inline double to_nt(int d) { return double(d); @@ -142,7 +144,6 @@ struct Test { P p(int x, int y) { - randomint ri; int w = ri.next(); return P(to_nt(x*w), to_nt(y*w), to_nt(w)); }