From eaeb955212eb3b133fd98d98457f17bfea8891d1 Mon Sep 17 00:00:00 2001 From: "Kartik K. Agaram" Date: Thu, 6 Aug 2015 19:15:57 -0700 Subject: 1949 --- html/064random.cc.html | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'html/064random.cc.html') diff --git a/html/064random.cc.html b/html/064random.cc.html index 5cfdf676..393ea7f8 100644 --- a/html/064random.cc.html +++ b/html/064random.cc.html @@ -17,6 +17,7 @@ body { font-family: monospace; color: #eeeeee; background-color: #080808; } .Constant { color: #00a0a0; } .cSpecial { color: #008000; } .PreProc { color: #c000c0; } +.Normal { color: #eeeeee; background-color: #080808; padding-bottom: 1px; } .Comment { color: #9090ff; } .Delimiter { color: #a04060; } .Special { color: #ff6060; } @@ -37,7 +38,7 @@ RANDOM, :(before "End Primitive Recipe Numbers") Recipe_ordinal["random"] = RANDOM; :(before "End Primitive Recipe Implementations") -case RANDOM: { +case RANDOM: { // todo: limited range of numbers, might be imperfectly random // todo: thread state in extra ingredients and products products.resize(1); @@ -50,7 +51,7 @@ MAKE_RANDOM_NONDETERMINISTIC, :(before "End Primitive Recipe Numbers") Recipe_ordinal["make-random-nondeterministic"] = MAKE_RANDOM_NONDETERMINISTIC; :(before "End Primitive Recipe Implementations") -case MAKE_RANDOM_NONDETERMINISTIC: { +case MAKE_RANDOM_NONDETERMINISTIC: { srand(time(NULL)); break; } @@ -60,12 +61,12 @@ ROUND, :(before "End Primitive Recipe Numbers") Recipe_ordinal["round"] = ROUND; :(before "End Primitive Recipe Implementations") -case ROUND: { - if (SIZE(ingredients) != 1) { +case ROUND: { + if (SIZE(ingredients) != 1) { raise << current_recipe_name() << ": 'round' requires exactly one ingredient, but got " << current_instruction().to_string() << '\n' << end(); break; } - if (!scalar(ingredients.at(0))) { + if (!scalar(ingredients.at(0))) { raise << current_recipe_name() << ": first ingredient of 'round' should be a number, but got " << current_instruction().ingredients.at(0).original_string << '\n' << end(); break; } -- cgit 1.4.1-2-gfad0