diff options
-rw-r--r-- | 043space.cc | 5 | ||||
-rw-r--r-- | 045closure_name.cc | 2 | ||||
-rw-r--r-- | 050scenario.cc | 2 | ||||
-rw-r--r-- | 054static_dispatch.cc | 4 | ||||
-rw-r--r-- | 062convert_ingredients_to_text.cc | 2 | ||||
-rw-r--r-- | 069hash.cc | 2 | ||||
-rw-r--r-- | 072recipe.cc | 2 | ||||
-rw-r--r-- | 082scenario_screen.cc | 2 | ||||
-rw-r--r-- | 085scenario_console.cc | 2 | ||||
-rw-r--r-- | 099hardware_checks.cc | 6 |
10 files changed, 14 insertions, 15 deletions
diff --git a/043space.cc b/043space.cc index c34cf5b0..c9d960aa 100644 --- a/043space.cc +++ b/043space.cc @@ -5,9 +5,8 @@ //: Spaces are often called 'scopes' in other languages. Stack frames are a //: limited form of space that can't outlive callers. //: -//: Warning: messing with 'default-space' can corrupt memory. Don't do things -//: like initialize default-space with some other function's default-space. -//: Later we'll see how to chain spaces safely. +//: Warning: messing with 'default-space' can corrupt memory. Don't share +//: default-space between recipes. Later we'll see how to chain spaces safely. //: Under the hood, a space is an array of locations in memory. :(before "End Mu Types Initialization") diff --git a/045closure_name.cc b/045closure_name.cc index 0f67e2d2..e478337d 100644 --- a/045closure_name.cc +++ b/045closure_name.cc @@ -3,7 +3,7 @@ //: the variable in the chained/surrounding space. /space:2 looks up the //: surrounding space of the surrounding space, etc. //: -//: todo: warn on default-space abuse. default-space for one function should +//: todo: warn on default-space abuse. default-space for one recipe should //: never come from another, otherwise memory will be corrupted. :(scenario closure) diff --git a/050scenario.cc b/050scenario.cc index 15ac93d5..edc57573 100644 --- a/050scenario.cc +++ b/050scenario.cc @@ -877,7 +877,7 @@ def main [ :(after "case _SYSTEM:") if (Current_scenario) break; -//:: Warn if people use '_' manually in function names. They're reserved for internal use. +//:: Warn if people use '_' manually in recipe names. They're reserved for internal use. :(scenario recipe_name_with_underscore) % Hide_errors = true; diff --git a/054static_dispatch.cc b/054static_dispatch.cc index 69dc30bd..8a026d90 100644 --- a/054static_dispatch.cc +++ b/054static_dispatch.cc @@ -342,10 +342,10 @@ const recipe& best_variant(const instruction& inst, vector<recipe_ordinal>& cand int min_index = 0; for (int i = 0; i < SIZE(candidates); ++i) { const recipe& candidate = get(Recipe, candidates.at(i)); - // prefer functions without extra or missing ingredients or products + // prefer variants without extra or missing ingredients or products int score = abs(SIZE(candidate.products)-SIZE(inst.products)) + abs(SIZE(candidate.ingredients)-SIZE(inst.ingredients)); - // prefer functions with non-address ingredients or products + // prefer variants with non-address ingredients or products for (int j = 0; j < SIZE(candidate.ingredients); ++j) { if (is_mu_address(candidate.ingredients.at(j))) ++score; diff --git a/062convert_ingredients_to_text.cc b/062convert_ingredients_to_text.cc index abbacb1e..dda7d4f0 100644 --- a/062convert_ingredients_to_text.cc +++ b/062convert_ingredients_to_text.cc @@ -1,4 +1,4 @@ -//: make some functions more friendly by trying to auto-convert their ingredients to text +//: make some recipes more friendly by trying to auto-convert their ingredients to text :(scenarios transform) :(scenario rewrite_stashes_to_text) diff --git a/069hash.cc b/069hash.cc index 75781ec6..8334e80c 100644 --- a/069hash.cc +++ b/069hash.cc @@ -1,4 +1,4 @@ -// A universal hash function that can handle objects of any type. +// Compute a hash for objects of any type. // // The way it's currently implemented, two objects will have the same hash if // all their non-address fields (all the way down) expand to the same sequence diff --git a/072recipe.cc b/072recipe.cc index 92ac83ac..ca8932ed 100644 --- a/072recipe.cc +++ b/072recipe.cc @@ -341,7 +341,7 @@ def f x:&:num -> y:num [ ] $error: 0 -//: make sure we don't accidentally break on a function literal +//: make sure we don't accidentally break on a recipe literal :(scenario jump_forbidden_on_recipe_literals) % Hide_errors = true; def foo [ diff --git a/082scenario_screen.cc b/082scenario_screen.cc index ad61d379..0c75fb6c 100644 --- a/082scenario_screen.cc +++ b/082scenario_screen.cc @@ -4,7 +4,7 @@ //: scenario. 'screen-should-contain' can check unicode characters in the fake //: screen -//: first make sure we don't mangle these functions in other transforms +//: first make sure we don't mangle these instructions in other transforms :(before "End initialize_transform_rewrite_literal_string_to_text()") recipes_taking_literal_strings.insert("screen-should-contain"); recipes_taking_literal_strings.insert("screen-should-contain-in-color"); diff --git a/085scenario_console.cc b/085scenario_console.cc index e7a8c39a..cb69bdb0 100644 --- a/085scenario_console.cc +++ b/085scenario_console.cc @@ -4,7 +4,7 @@ //: scenario. Like with the fake screen, 'assume-console' transparently //: supports unicode. -//: first make sure we don't mangle these functions in other transforms +//: first make sure we don't mangle this instruction in other transforms :(before "End initialize_transform_rewrite_literal_string_to_text()") recipes_taking_literal_strings.insert("assume-console"); diff --git a/099hardware_checks.cc b/099hardware_checks.cc index 0a6a1ebd..cee68bdb 100644 --- a/099hardware_checks.cc +++ b/099hardware_checks.cc @@ -1,6 +1,6 @@ -//: Let's raise errors when students use real hardware in any functions -//: besides 'main'. Part of the goal is to teach them testing hygiene and -//: dependency injection. +//: Let's raise errors when students use real hardware in any recipes besides +//: 'main'. Part of the goal is to teach them testing hygiene and dependency +//: injection. //: //: This is easy to sidestep, it's for feedback rather than safety. |