diff --git a/README.md b/README.md index 0f8fc0bc5..c49757fd7 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Inform 7 -v10.1.0-alpha.1+6R62 'Krypton' (26 March 2021) +v10.1.0-alpha.1+6R63 'Krypton' (27 March 2021) ## About Inform 7 diff --git a/build.txt b/build.txt index 8b17838da..d7b4f38c8 100644 --- a/build.txt +++ b/build.txt @@ -1,3 +1,3 @@ Prerelease: alpha.1 -Build Date: 26 March 2021 -Build Number: 6R62 +Build Date: 27 March 2021 +Build Number: 6R63 diff --git a/docs/assertions-module/2-ptmn.html b/docs/assertions-module/2-ptmn.html index 23decbaef..e79555201 100644 --- a/docs/assertions-module/2-ptmn.html +++ b/docs/assertions-module/2-ptmn.html @@ -123,7 +123,7 @@ but saves a deal of passing parameters around. if (pass == 2) Extend the pass to sentences needed when implicit kinds are set2.2; } - +

§2.1. Extend the pass to invented sentences from kinds2.1 =

@@ -328,7 +328,7 @@ two cases") and all others (such as "regular meaning are more subtle").

§3.1.3.

-void MajorNodes::try_special_meaning(int task, parse_node *p) {
+void MajorNodes::try_special_meaning(int task, parse_node *p) {
     SpecialMeanings::call(Node::get_special_meaning(p), task, p, NULL);
 }
 
diff --git a/docs/assertions-module/5-adf.html b/docs/assertions-module/5-adf.html index 1abd646ca..32a9226f5 100644 --- a/docs/assertions-module/5-adf.html +++ b/docs/assertions-module/5-adf.html @@ -73,23 +73,50 @@ function togglePopup(material_id) {

Imperative definitions of "Definition: X is Y: ..." adjectives.

-

§1.

+

§1. This family is used for adjective definitions, whether or not they run on +into substantial amounts of code. +

-imperative_defn_family *DEFINITIONAL_PHRASE_EFF_family = NULL;  "Definition: a container is roomy if: ..."
-
-

§2.

+imperative_defn_family *adjectival_idf = NULL; "Definition: a container is roomy if: ..." -
 void AdjectivalDefinitionFamily::create_family(void) {
-    DEFINITIONAL_PHRASE_EFF_family  = ImperativeDefinitionFamilies::new(I"DEFINITIONAL_PHRASE_EFF", FALSE);
-    METHOD_ADD(DEFINITIONAL_PHRASE_EFF_family, CLAIM_IMP_DEFN_MTID, AdjectivalDefinitionFamily::claim);
-    METHOD_ADD(DEFINITIONAL_PHRASE_EFF_family, NEW_PHRASE_IMP_DEFN_MTID, AdjectivalDefinitionFamily::new_phrase);
-    METHOD_ADD(DEFINITIONAL_PHRASE_EFF_family, ALLOWS_EMPTY_IMP_DEFN_MTID, AdjectivalDefinitionFamily::allows_empty);
-    METHOD_ADD(DEFINITIONAL_PHRASE_EFF_family, TO_PHTD_IMP_DEFN_MTID, AdjectivalDefinitionFamily::to_phtd);
-    METHOD_ADD(DEFINITIONAL_PHRASE_EFF_family, COMPILE_IMP_DEFN_MTID, AdjectivalDefinitionFamily::compile);
+    adjectival_idf  = ImperativeDefinitionFamilies::new(I"adjectival-idf", FALSE);
+    METHOD_ADD(adjectival_idf, IDENTIFY_IMP_DEFN_MTID, AdjectivalDefinitionFamily::identify);
+    METHOD_ADD(adjectival_idf, GIVEN_BODY_IMP_DEFN_MTID, AdjectivalDefinitionFamily::given_body);
+    METHOD_ADD(adjectival_idf, ALLOWS_EMPTY_IMP_DEFN_MTID, AdjectivalDefinitionFamily::allows_empty);
+    METHOD_ADD(adjectival_idf, COMPILE_IMP_DEFN_MTID, AdjectivalDefinitionFamily::compile);
 }
 
+

§2. Colons are used slightly differently in some adjectival definitions. Consider: +

+ +
+Definition: A container is roomy if its carrying capacity is greater than 10.
+Definition: A container is possessed by the Devil:
+    if its carrying capacity is 666, decide yes;
+    decide no.
+
+

To Inform this looks like three consecutive IMPERATIVE_NT nodes: +

+ +
+Definition:
+    A container is roomy if its carrying capacity is greater than 10.
+
+Definition:
+
+A container is possessed by the Devil:
+    if its carrying capacity is 666, decide yes;
+    decide no.
+
+

But we want to create just two imperative_defn objects, not three. So +when the second IMPERATIVE_NT node is identified as belonging to us, we +take the opportunity to change the type of the third node to DEFN_CONT_NT +("definition continuation"). That means it will not lead to an imperative_defn +of its own. +

+

§3.

@@ -100,10 +127,10 @@ function togglePopup(material_id) {
 

§4.

-void AdjectivalDefinitionFamily::claim(imperative_defn_family *self, imperative_defn *id) {
+void AdjectivalDefinitionFamily::identify(imperative_defn_family *self, imperative_defn *id) {
     wording W = Node::get_text(id->at);
     if (<definition-preamble>(W)) {
-        id->family = DEFINITIONAL_PHRASE_EFF_family;
+        id->family = adjectival_idf;
         if ((id->at->next) && (id->at->down == NULL) &&
             (Node::get_type(id->at->next) == IMPERATIVE_NT)) {
             ImperativeSubtrees::accept_body(id->at->next);
@@ -113,49 +140,45 @@ function togglePopup(material_id) {
     }
 }
 
-

§5. If a phrase defines an adjective, like so: -

- -
-

Definition: A container is capacious if: ...

-
- -

we need to make the pronoun "it" a local variable of kind "container" in the -stack frame used to compile the "..." part. If it uses a calling, like so: -

- -
-

Definition: A container (called the sack) is capacious if: ...

-
- -

then we also want the name "sack" to refer to this. Here's where we take care -of it: +

§5. Since the "Definition:" node might have no code under it (because the code +is actually under the continuation node):

-void AdjectivalDefinitionFamily::new_phrase(imperative_defn_family *self, imperative_defn *id, phrase *new_ph) {
-    wording CW = EMPTY_WORDING;
-    kind *K = NULL;
-    Phrases::Phrasal::define_adjective_by_phrase(id->at, new_ph, &CW, &K);
-    LocalVariables::add_pronoun(&(new_ph->stack_frame), CW, K);
-}
-
-

§6.

- -
-int AdjectivalDefinitionFamily::allows_empty(imperative_defn_family *self, imperative_defn *id) {
+int AdjectivalDefinitionFamily::allows_empty(imperative_defn_family *self, imperative_defn *id) {
     return TRUE;
 }
+
+

§6. The body of code under a definition needs to be set up so that: +

+ + +
+void AdjectivalDefinitionFamily::given_body(imperative_defn_family *self, imperative_defn *id) {
+    phrase *body = id->body_of_defn;
+
+    Phrases::TypeData::set_mor(&(body->type_data), DECIDES_CONDITION_MOR, NULL);
+
+    wording CALLW = EMPTY_WORDING;
+    kind *K = NULL;
+    Phrases::Phrasal::define_adjective_by_phrase(id->at, body, &CALLW, &K);
+    LocalVariables::add_pronoun(&(body->stack_frame), CALLW, K);
 
-void AdjectivalDefinitionFamily::to_phtd(imperative_defn_family *self, imperative_defn *id, ph_type_data *phtd, wording XW, wording *OW) {
-    Phrases::TypeData::set_mor(phtd, DECIDES_CONDITION_MOR, NULL);
 }
+
+

§7. The code body for any definition is compiled here: +

-void AdjectivalDefinitionFamily::compile(imperative_defn_family *self, +
+void AdjectivalDefinitionFamily::compile(imperative_defn_family *self,
     int *total_phrases_compiled, int total_phrases_to_compile) {
     imperative_defn *id;
     LOOP_OVER(id, imperative_defn)
-        if (id->family == DEFINITIONAL_PHRASE_EFF_family)
+        if (id->family == adjectival_idf)
             Phrases::compile(id->body_of_defn, total_phrases_compiled,
                 total_phrases_to_compile, NULL, NULL, NULL);
     RTAdjectives::compile_support_code();
diff --git a/docs/assertions-module/5-id.html b/docs/assertions-module/5-id.html
index 145334c99..c64b8da75 100644
--- a/docs/assertions-module/5-id.html
+++ b/docs/assertions-module/5-id.html
@@ -180,14 +180,15 @@ detailed look possible.
         current_sentence = id->at;
         ImperativeDefinitionFamilies::assess(id);
         if ((Node::is(id->at->next, DEFN_CONT_NT) == FALSE) && (id->at->down == NULL) &&
-            (ImperativeDefinitionFamilies::allows_empty(id) == FALSE)) {
+            (ImperativeDefinitionFamilies::allows_empty(id) == FALSE)) {
             StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_Undefined),
                 "there doesn't seem to be any definition here",
                 "so I can't see what this rule or phrase would do.");
         } else {
             phrase *body = Phrases::create_from_preamble(id);
             id->body_of_defn = body;
-            ImperativeDefinitionFamilies::given_body(id, body);
+            ImperativeDefinitionFamilies::given_body(id);
+            Phrases::prepare_stack_frame(body);
         }
     }
     if (initial_problem_count < problem_count) return;
@@ -199,7 +200,7 @@ detailed look possible.
 
     imperative_defn_family *idf;
     LOOP_OVER(idf, imperative_defn_family) {
-        ImperativeDefinitionFamilies::register(idf, initial_problem_count);
+        ImperativeDefinitionFamilies::register(idf);
         if (initial_problem_count < problem_count) return;
     }
 
@@ -211,7 +212,7 @@ detailed look possible. imperative_defn *id; LOOP_OVER(id, imperative_defn) id->body_of_defn->runtime_context_data = - ImperativeDefinitionFamilies::to_phrcd(id); + ImperativeDefinitionFamilies::to_phrcd(id); if (initial_problem_count < problem_count) return;
@@ -221,7 +222,7 @@ detailed look possible.
     imperative_defn_family *idf;
     LOOP_OVER(idf, imperative_defn_family) {
-        ImperativeDefinitionFamilies::assessment_complete(idf, initial_problem_count);
+        ImperativeDefinitionFamilies::assessment_complete(idf);
         if (initial_problem_count < problem_count) return;
     }
 
@@ -239,11 +240,11 @@ in two stages. Stage one: imperative_defn_family *idf; LOOP_OVER(idf, imperative_defn_family) if (idf->compile_last == FALSE) - ImperativeDefinitionFamilies::compile(idf, + ImperativeDefinitionFamilies::compile(idf, &total_phrases_compiled, total_phrases_to_compile); LOOP_OVER(idf, imperative_defn_family) if (idf->compile_last) - ImperativeDefinitionFamilies::compile(idf, + ImperativeDefinitionFamilies::compile(idf, &total_phrases_compiled, total_phrases_to_compile); }
@@ -267,7 +268,7 @@ any run-time resources which need to be made by the family. void ImperativeDefinitions::compile_as_needed(void) { imperative_defn_family *idf; LOOP_OVER(idf, imperative_defn_family) - ImperativeDefinitionFamilies::compile_as_needed(idf, + ImperativeDefinitionFamilies::compile_as_needed(idf, &total_phrases_compiled, total_phrases_to_compile); } diff --git a/docs/assertions-module/5-idf.html b/docs/assertions-module/5-idf.html index fe528de07..9bc2fd78c 100644 --- a/docs/assertions-module/5-idf.html +++ b/docs/assertions-module/5-idf.html @@ -72,8 +72,18 @@ function togglePopup(material_id) {

Different categories of imperative definition.

-

§1. There are very few of these, and an Inform source text cannot create more. -The following is called at startup, and then that's the lot: +


+ +

§1. Creation. See Imperative Definitions for what these families are. +

+ +

There are very few of them, and an Inform source text cannot create more. +The following is called at startup, and then that's the lot. +

+ +

The order of creation is important here, or at least, it's important that +the rule family comes last, because this affects the order of the loop in +ImperativeDefinitionFamilies::identify below.

@@ -81,9 +91,9 @@ The following is called at startup, and then that's the lot:
 
 void ImperativeDefinitionFamilies::create(void) {
     unknown_idf = ImperativeDefinitionFamilies::new(I"unknown-idf", FALSE);
-    AdjectivalDefinitionFamily::create_family();
+    AdjectivalDefinitionFamily::create_family();
     ToPhraseFamily::create_family();
-    RuleFamily::create_family();
+    RuleFamily::create_family();
 }
 

§2. Such a family is little more than a set of methods: @@ -97,7 +107,7 @@ The following is called at startup, and then that's the lot: CLASS_DEFINITION } imperative_defn_family; -imperative_defn_family *ImperativeDefinitionFamilies::new(text_stream *name, int last) { +imperative_defn_family *ImperativeDefinitionFamilies::new(text_stream *name, int last) { imperative_defn_family *family = CREATE(imperative_defn_family); family->family_name = Str::duplicate(name); family->methods = Methods::new_set(); @@ -106,28 +116,31 @@ The following is called at startup, and then that's the lot: }

-

§3. So, then, the rest of this section provides an API, in effect, for different +

§3. Identification. So, then, the rest of this section provides an API, in effect, for different users of imperative definitions to get their work done.

-

CLAIM_IMP_DEFN_MTID is for deciding from the syntax of a preamble whether -this definition should belong to the family or not. +

IDENTIFY_IMP_DEFN_MTID is for deciding from the syntax of a preamble whether +this definition should belong to the family or not. The recipient should set +id->family to itself if it wants the definition.

-
enum CLAIM_IMP_DEFN_MTID
+
enum IDENTIFY_IMP_DEFN_MTID
 
-VOID_METHOD_TYPE(CLAIM_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id)
+VOID_METHOD_TYPE(IDENTIFY_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id)
 
 void ImperativeDefinitionFamilies::identify(imperative_defn *id) {
     id->family = unknown_idf;
     imperative_defn_family *f;
     LOOP_OVER(f, imperative_defn_family)
         if (id->family == unknown_idf)
-            VOID_METHOD_CALL(f, CLAIM_IMP_DEFN_MTID, id);
+            VOID_METHOD_CALL(f, IDENTIFY_IMP_DEFN_MTID, id);
 }
 
-

§4. ASSESS_IMP_DEFN_MTID is for parsing it in more detail, later on. +

§4. Assessment. ASSESS_IMP_DEFN_MTID is for parsing the preamble in more detail, later on. +At the start of assessment, this is called on each of the IDs belonging to the +family in turn.

enum ASSESS_IMP_DEFN_MTID
@@ -139,53 +152,43 @@ this definition should belong to the family or not.
     VOID_METHOD_CALL(id->family, ASSESS_IMP_DEFN_MTID, id);
 }
 
-

§5. REGISTER_IMP_DEFN_MTID is called on the family when everything has -been assessed. +

§5. GIVEN_BODY_IMP_DEFN_MTID is called on an ID just after id->body_of_defn +has finally been created. +

+ +
enum GIVEN_BODY_IMP_DEFN_MTID
+
+
+VOID_METHOD_TYPE(GIVEN_BODY_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id)
+
+void ImperativeDefinitionFamilies::given_body(imperative_defn *id) {
+    VOID_METHOD_CALL(id->family, GIVEN_BODY_IMP_DEFN_MTID, id);
+}
+
+

§6. Next, REGISTER_IMP_DEFN_MTID is then called on the family when all of the +ASSESS_IMP_DEFN_MTID calls have been made, and all the bodies created.

enum REGISTER_IMP_DEFN_MTID
 
-VOID_METHOD_TYPE(REGISTER_IMP_DEFN_MTID, imperative_defn_family *f, int initial_problem_count)
+VOID_METHOD_TYPE(REGISTER_IMP_DEFN_MTID, imperative_defn_family *f)
 
-void ImperativeDefinitionFamilies::register(imperative_defn_family *f, int initial_problem_count) {
-    VOID_METHOD_CALL(f, REGISTER_IMP_DEFN_MTID, initial_problem_count);
+void ImperativeDefinitionFamilies::register(imperative_defn_family *f) {
+    VOID_METHOD_CALL_WITHOUT_ARGUMENTS(f, REGISTER_IMP_DEFN_MTID);
 }
 
-

§6. ASSESSMENT_COMPLETE_IMP_DEFN_MTID is called on the family when everything has -been assessed. -

- -
enum ASSESSMENT_COMPLETE_IMP_DEFN_MTID
-
-
-VOID_METHOD_TYPE(ASSESSMENT_COMPLETE_IMP_DEFN_MTID, imperative_defn_family *f, int initial_problem_count)
-
-void ImperativeDefinitionFamilies::assessment_complete(imperative_defn_family *f, int initial_problem_count) {
-    VOID_METHOD_CALL(f, ASSESSMENT_COMPLETE_IMP_DEFN_MTID, initial_problem_count);
-}
-
-

§7. NEW_PHRASE_IMP_DEFN_MTID is for ... -

- -
enum NEW_PHRASE_IMP_DEFN_MTID
-
-
-VOID_METHOD_TYPE(NEW_PHRASE_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id, phrase *new_ph)
-
-void ImperativeDefinitionFamilies::given_body(imperative_defn *id, phrase *new_ph) {
-    VOID_METHOD_CALL(id->family, NEW_PHRASE_IMP_DEFN_MTID, id, new_ph);
-}
-
-

§8. TO_RCD_IMP_DEFN_MTID is for... +

§7. A call to TO_RCD_IMP_DEFN_MTID is then made for each ID in turn, asking the +family to give the body its runtime context data.

enum TO_RCD_IMP_DEFN_MTID
 
-VOID_METHOD_TYPE(TO_RCD_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id, ph_runtime_context_data *rcd)
+VOID_METHOD_TYPE(TO_RCD_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id,
+    ph_runtime_context_data *rcd)
 
-ph_runtime_context_data ImperativeDefinitionFamilies::to_phrcd(imperative_defn *id) {
+ph_runtime_context_data ImperativeDefinitionFamilies::to_phrcd(imperative_defn *id) {
     current_sentence = id->at;
     Frames::make_current(&(id->body_of_defn->stack_frame));
     ph_runtime_context_data phrcd = Phrases::Context::new();
@@ -194,25 +197,32 @@ been assessed.
     return phrcd;
 }
 
-

§9. TO_PHTD_IMP_DEFN_MTID is for... +

§8. Finally, ASSESSMENT_COMPLETE_IMP_DEFN_MTID is called on the family when +everything has been assessed.

-
enum TO_PHTD_IMP_DEFN_MTID
+
enum ASSESSMENT_COMPLETE_IMP_DEFN_MTID
 
-VOID_METHOD_TYPE(TO_PHTD_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id, ph_type_data *phtd, wording XW, wording *OW)
+VOID_METHOD_TYPE(ASSESSMENT_COMPLETE_IMP_DEFN_MTID, imperative_defn_family *f)
 
-void ImperativeDefinitionFamilies::to_phtd(imperative_defn *id, ph_type_data *phtd, wording XW, wording *OW) {
-    VOID_METHOD_CALL(id->family, TO_PHTD_IMP_DEFN_MTID, id, phtd, XW, OW);
+void ImperativeDefinitionFamilies::assessment_complete(imperative_defn_family *f) {
+    VOID_METHOD_CALL_WITHOUT_ARGUMENTS(f, ASSESSMENT_COMPLETE_IMP_DEFN_MTID);
 }
 
-

§10. Whether phrases which end the current rulebook are allowed in the definition body. +

§9. What is allowed in the body. The body of the definition can for the most part be any Inform 7 code, but +there are a few restrictions which depend on what the definition family is. +

+ +

ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID should reply TRUE if phrases +intended to end rules or rulebooks can be used in the body; by default, not.

enum ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID
 
-INT_METHOD_TYPE(ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id)
+INT_METHOD_TYPE(ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID, imperative_defn_family *f,
+    imperative_defn *id)
 
 int ImperativeDefinitionFamilies::goes_in_rulebooks(imperative_defn *id) {
     int rv = FALSE;
@@ -220,8 +230,9 @@ been assessed.
     return rv;
 }
 
-

§11. Whether the definition body can be empty (as when a definition of an adjective -does not go on to contain code). +

§10. ALLOWS_EMPTY_IMP_DEFN_MTID should reply TRUE if the body is allowed to +be empty, that is, for there to be no code at all. This happens for some +adjective definitions which wrap up in a single line. The default is no.

enum ALLOWS_EMPTY_IMP_DEFN_MTID
@@ -235,7 +246,8 @@ does not go on to contain code).
     return rv;
 }
 
-

§12. Whether the definition body can be given as (- inline -) material. +

§11. ALLOWS_INLINE_IMP_DEFN_MTID should reply TRUE if the definition body can +be given as (- inline -) material. The default is no.

enum ALLOWS_INLINE_IMP_DEFN_MTID
@@ -249,7 +261,9 @@ does not go on to contain code).
     return rv;
 }
 
-

§13. COMPILE_IMP_DEFN_MTID is for . +

§12. Compilation and indexing. COMPILE_IMP_DEFN_MTID is called to ask the family to perform its main round +of compilation for any resources it will need — most obviously, of course, +it may want to turn its definition bodies into Inter functions.

enum COMPILE_IMP_DEFN_MTID
@@ -264,7 +278,9 @@ does not go on to contain code).
         total_phrases_compiled, total_phrases_to_compile);
 }
 
-

§14. COMPILE_IMP_DEFN_MTID is for . +

§13. COMPILE_AS_NEEDED_IMP_DEFN_MTID is then called as an opportunity to +compile any remaining resources, and should pick up anything needed since the +last time it was called: note that it can be called multiple times.

enum COMPILE_AS_NEEDED_IMP_DEFN_MTID
@@ -279,7 +295,8 @@ does not go on to contain code).
         total_phrases_compiled, total_phrases_to_compile);
 }
 
-

§15. PHRASEBOOK_INDEX_IMP_DEFN_MTID is for . +

§14. PHRASEBOOK_INDEX_IMP_DEFN_MTID should reply TRUE if the definition should +go into the Phrasebook page of the index.

enum PHRASEBOOK_INDEX_IMP_DEFN_MTID
diff --git a/docs/assertions-module/5-rf.html b/docs/assertions-module/5-rf.html
index e65742d73..2cad6afa9 100644
--- a/docs/assertions-module/5-rf.html
+++ b/docs/assertions-module/5-rf.html
@@ -73,63 +73,116 @@ function togglePopup(material_id) {
     
 

Imperative definitions of rules.

-
+
-

§1.

+

§1. Introduction. This family handles definitions of rules which give explicit Inform 7 +source text to show what they do. (It's also possible to create rules which +are implemented by Inter-level functions only, and those do not fall under +this section, because they have no imperative_defn.) For example: +

-imperative_defn_family *RULE_EFF_family = NULL;  "Before taking a container, ..."
-
-typedef struct rule_family_data {
-    struct wording reduced_stem;
-    struct wording constant_name;
-    struct wording pattern;
-    int not_in_rulebook;
-    int event_time;
-    struct wording event_name;
-    struct linked_list *uses_as_event;  of use_as_event
-    struct wording rule_parameter;  text of object or action parameter
-    struct wording whenwhile;  when/while for action/activity rulebooks
-    #ifdef IF_MODULE
-    struct parse_node *during_scene_spec;  what scene is currently under way
-    #endif
-    struct rulebook *owning_rulebook;  the primary booking for the phrase will be here
-    int owning_rulebook_placement;  ...and with this placement value: see Rulebooks
-    CLASS_DEFINITION
-} rule_family_data;
+Every turn:
+    say "The grandfather clock ticks reprovingly."
 
-
  • The structure rule_family_data is accessed in 5/tpf and here.
-

§2.

+

Some rules have names, some do not; some indicate explicitly what rulebook +they belong to, and others are placed in rulebooks with separate sentences. +So there's quite a lot to do. +

+imperative_defn_family *rule_idf = NULL;  "Before taking a container, ..."
 void RuleFamily::create_family(void) {
-    RULE_EFF_family = ImperativeDefinitionFamilies::new(I"RULE_EFF", FALSE);
-    METHOD_ADD(RULE_EFF_family, CLAIM_IMP_DEFN_MTID, RuleFamily::claim);
-    METHOD_ADD(RULE_EFF_family, ASSESS_IMP_DEFN_MTID, RuleFamily::assess);
-    METHOD_ADD(RULE_EFF_family, ASSESSMENT_COMPLETE_IMP_DEFN_MTID, RuleFamily::assessment_complete);
-    METHOD_ADD(RULE_EFF_family, ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID, RuleFamily::allows_rule_only_phrases);
-    METHOD_ADD(RULE_EFF_family, NEW_PHRASE_IMP_DEFN_MTID, RuleFamily::new_phrase);
-    METHOD_ADD(RULE_EFF_family, TO_RCD_IMP_DEFN_MTID, RuleFamily::to_rcd);
-    METHOD_ADD(RULE_EFF_family, TO_PHTD_IMP_DEFN_MTID, RuleFamily::to_phtd);
-    METHOD_ADD(RULE_EFF_family, COMPILE_IMP_DEFN_MTID, RuleFamily::compile);
+    rule_idf = ImperativeDefinitionFamilies::new(I"rule-idf", FALSE);
+    METHOD_ADD(rule_idf, IDENTIFY_IMP_DEFN_MTID, RuleFamily::identify);
+    METHOD_ADD(rule_idf, ASSESS_IMP_DEFN_MTID, RuleFamily::assess);
+    METHOD_ADD(rule_idf, ASSESSMENT_COMPLETE_IMP_DEFN_MTID, RuleFamily::assessment_complete);
+    METHOD_ADD(rule_idf, ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID, RuleFamily::allows_rule_only);
+    METHOD_ADD(rule_idf, GIVEN_BODY_IMP_DEFN_MTID, RuleFamily::given_body);
+    METHOD_ADD(rule_idf, TO_RCD_IMP_DEFN_MTID, RuleFamily::to_rcd);
+    METHOD_ADD(rule_idf, COMPILE_IMP_DEFN_MTID, RuleFamily::compile);
 }
 
-

§3.

+

§2. Each family member gets one of the following. In splitting up preambles, +the "usage preamble" is the part indicating when the rule should happen, and +this is divided up into smaller excerpts of text, as in the following examples: +

+ +
+rule instead    of          taking or dropping when Miss Bianca is in the Embassy:
+<---------------------------- usage_preamble ----------------------------------->
+     <- stem ---->          <------------------ applicability ------------------>
+     <- ps ->   <- bud ->   <--- prewhile --->      <-------- whenwhile -------->
+
+after examining    an open door during the Hurricane (this is the exit hunting rule):
+<----------------- usage preamble ----------------->              <- const name -->
+<---- stem ----->  <-- appl -->        <- during -->
+<- pruned stem ->  <-- pw ---->
+
+
+typedef struct rule_family_data {
+    struct wording usage_preamble;
+    struct wording pruned_stem;
+    struct wording constant_name;
+    struct wording prewhile_applicability;
+    struct wording applicability;
+    struct wording whenwhile;
+    struct parse_node *during_spec;  what scene is currently under way
+
+    int not_in_rulebook;
+    struct rule *defines;
+    struct rulebook *owning_rulebook;  the primary booking for the phrase will be here
+    int owning_rulebook_placement;  ...and with this placement value: see Rulebooks
+
+    void *plugin_rfd[MAX_PLUGINS];  storage for plugins to attach, if they want to
+    CLASS_DEFINITION
+} rule_family_data;
+
+rule_family_data *RuleFamily::new_data(void) {
+    rule_family_data *rfd = CREATE(rule_family_data);
+    rfd->pruned_stem = EMPTY_WORDING;
+    rfd->constant_name = EMPTY_WORDING;
+    rfd->usage_preamble = EMPTY_WORDING;
+    rfd->applicability = EMPTY_WORDING;
+    rfd->prewhile_applicability = EMPTY_WORDING;
+    rfd->whenwhile = EMPTY_WORDING;
+    rfd->during_spec = NULL;
+    rfd->not_in_rulebook = FALSE;
+    rfd->defines = NULL;
+    rfd->owning_rulebook = NULL;
+    rfd->owning_rulebook_placement = MIDDLE_PLACEMENT;
+    for (int i=0; i<MAX_PLUGINS; i++) rfd->plugin_rfd[i] = NULL;
+    return rfd;
+}
+
+
  • The structure rule_family_data is accessed in 5/tpf and here.
+

§3. These two macros provide access to plugin-specific rule family data: +

+ +
define RFD_PLUGIN_DATA(id, rfd)
+    ((id##_rfd_data *) rfd->plugin_rfd[id##_plugin->allocation_id])
+define CREATE_PLUGIN_RFD_DATA(id, rfd, creator)
+    (rfd)->plugin_rfd[id##_plugin->allocation_id] = (void *) (creator(rfd));
+
+

§4. Identification. We are going to claim as our own any definition whose name matches the +following nonterminal — and because of the last production, this will always +happen. (That's why it is important that we are the last family to claim.) +

 <rule-preamble> ::=
-    this is the {... rule} |                                  ==> { 1, - }
-    this is the rule |                                        ==> Issue PM_NamelessRule problem3.1
-    this is ... rule |                                        ==> Issue PM_UnarticledRule problem3.2
-    this is ... rules |                                       ==> Issue PM_PluralisedRule problem3.3
-    ... ( this is the {... rule} ) |                          ==> { 2, - }
-    ... ( this is the rule ) |                                ==> Issue PM_NamelessRule problem3.1
-    ... ( this is ... rule ) |                                ==> Issue PM_UnarticledRule problem3.2
-    ... ( this is ... rules ) |                               ==> Issue PM_PluralisedRule problem3.3
-    ...                                                       ==> { 3, - }
+    this is the {... rule} |            ==> { 1, - }
+    this is the rule |                  ==> Issue PM_NamelessRule problem4.1
+    this is ... rule |                  ==> Issue PM_UnarticledRule problem4.2
+    this is ... rules |                 ==> Issue PM_PluralisedRule problem4.3
+    ... ( this is the {... rule} ) |    ==> { 2, - }
+    ... ( this is the rule ) |          ==> Issue PM_NamelessRule problem4.1
+    ... ( this is ... rule ) |          ==> Issue PM_UnarticledRule problem4.2
+    ... ( this is ... rules ) |         ==> Issue PM_PluralisedRule problem4.3
+    ...                                 ==> { 3, - }
 
-

§3.1. Issue PM_NamelessRule problem3.1 = +

§4.1. Issue PM_NamelessRule problem4.1 =

@@ -139,8 +192,8 @@ function togglePopup(material_id) {
         "not just 'this is the rule'.");
     ==> { FALSE, - }
 
-
  • This code is used in §3 (twice).
-

§3.2. Issue PM_UnarticledRule problem3.2 = +

  • This code is used in §4 (twice).
+

§4.2. Issue PM_UnarticledRule problem4.2 =

@@ -151,8 +204,8 @@ function togglePopup(material_id) {
         "'this is promote dancing rule'.");
     ==> { FALSE, - }
 
-
  • This code is used in §3 (twice).
-

§3.3. Issue PM_PluralisedRule problem3.3 = +

  • This code is used in §4 (twice).
+

§4.3. Issue PM_PluralisedRule problem4.3 =

@@ -162,64 +215,17 @@ function togglePopup(material_id) {
         "contain many rules at once.");
     ==> { FALSE, - }
 
-
  • This code is used in §3 (twice).
-

§4.

- -
-<event-rule-preamble> ::=
-    at <clock-time> |         ==> { pass 1 }
-    at the time when ... |    ==> { NO_FIXED_TIME, - }
-    at the time that ... |    ==> Issue PM_AtTimeThat problem4.1
-    at ...                    ==> Issue PM_AtWithoutTime problem4.2
-
- -

§4.1. Issue PM_AtTimeThat problem4.1 = +

  • This code is used in §4 (twice).
+

§5. Forms 1 and 2 give a rule name; forms 2 and 3 say which rulebook it goes into.

-    StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_AtTimeThat),
-        "this seems to use 'that' where it should use 'when'",
-        "assuming it's trying to apply a rule to an event. (The convention is "
-        "that any rule beginning 'At' is a timed one. The time can either be a "
-        "fixed time, as in 'At 11:10 AM: ...', or the time when some named "
-        "event takes place, as in 'At the time when the clock chimes: ...'.)");
-
-
  • This code is used in §4.
-

§4.2. Issue PM_AtWithoutTime problem4.2 = -

- -
-    StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_AtWithoutTime),
-        "'at' what time? No description of a time is given",
-        "which means that this rule can never have effect. (The convention is "
-        "that any rule beginning 'At' is a timed one. The time can either be a "
-        "fixed time, as in 'At 11:10 AM: ...', or the time when some named "
-        "event takes place, as in 'At the time when the clock chimes: ...'.)");
-
-
  • This code is used in §4.
-

§5.

- -
-void RuleFamily::claim(imperative_defn_family *self, imperative_defn *id) {
+void RuleFamily::identify(imperative_defn_family *self, imperative_defn *id) {
     wording W = Node::get_text(id->at);
     if (<rule-preamble>(W)) {
         int form = <<r>>;
-        id->family = RULE_EFF_family;
-        rule_family_data *rfd = CREATE(rule_family_data);
-        rfd->not_in_rulebook = FALSE;
-        rfd->constant_name = EMPTY_WORDING;
-        rfd->pattern = EMPTY_WORDING;
-        rfd->event_time = NOT_A_TIMED_EVENT;
-        rfd->event_name = EMPTY_WORDING;
-        rfd->uses_as_event = NEW_LINKED_LIST(use_as_event);
-        rfd->rule_parameter = EMPTY_WORDING;
-        rfd->whenwhile = EMPTY_WORDING;
-        rfd->reduced_stem = EMPTY_WORDING;
-        #ifdef IF_MODULE
-        rfd->during_scene_spec = NULL;
-        #endif
-        rfd->owning_rulebook = NULL;
-        rfd->owning_rulebook_placement = MIDDLE_PLACEMENT;
+        id->family = rule_idf;
+        rule_family_data *rfd = RuleFamily::new_data();
 
         if (form == 1) rfd->not_in_rulebook = TRUE;
         id->family_specific_data = STORE_POINTER_rule_family_data(rfd);
@@ -237,54 +243,13 @@ function togglePopup(material_id) {
                 Rules::obtain(RW, TRUE);
             }
         }
-        if ((form == 2) || (form == 3)) rfd->pattern = GET_RW(<rule-preamble>, 1);
-        if (form == 3) {
-            if (<event-rule-preamble>(W)) {
-                rfd->pattern = EMPTY_WORDING;
-                rfd->not_in_rulebook = TRUE;
-                rfd->event_time = <<r>>;
-                if (rfd->event_time == NO_FIXED_TIME)
-                    rfd->event_name = GET_RW(<event-rule-preamble>, 1);
-            }
-        }
+        if ((form == 2) || (form == 3)) rfd->usage_preamble = GET_RW(<rule-preamble>, 1);
+
+        PluginCalls::new_rule_defn_notify(id, rfd);
     }
 }
 
-

§6.

- -
-void RuleFamily::assess(imperative_defn_family *self, imperative_defn *id) {
-    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
-    if (rfd->not_in_rulebook == FALSE)
-        Parse the rulebook stem in fine mode6.3;
-}
-
-void RuleFamily::assessment_complete(imperative_defn_family *self, int initial_problem_count) {
-    RuleBookings::make_automatic_placements();
-    if (initial_problem_count < problem_count) return;
-
-    SyntaxTree::traverse(Task::syntax_tree(), RuleFamily::visit_to_parse_placements);
-}
-
-

§6.1.

- -
enum TRAVERSE_FOR_RULE_FILING_SMFT
-
-
-void RuleFamily::visit_to_parse_placements(parse_node *p) {
-    if ((Node::get_type(p) == SENTENCE_NT) &&
-        (p->down) &&
-        (Node::get_type(p->down) == VERB_NT)) {
-        prevailing_mood = Annotations::read_int(p->down, verbal_certainty_ANNOT);
-        MajorNodes::try_special_meaning(TRAVERSE_FOR_RULE_FILING_SMFT, p->down);
-    }
-}
-
-int RuleFamily::allows_rule_only_phrases(imperative_defn_family *self, imperative_defn *id) {
-    return TRUE;
-}
-
-

§6.2. Much later on, Inform returns to the definition to look at it in fine detail: +

§6. Assessment. Now we take a closer look at the rule preamble.

@@ -308,184 +273,183 @@ function togglePopup(material_id) {
     of/for ... |                                          ==> { TRUE, - }
     rule about/for/on ... |                               ==> { TRUE, - }
     rule                                                  ==> { FALSE, - }
-
- -

§6.3. That's it for coarse mode. The rest is what happens in fine mode, which -affects rules giving a rulebook and some circumstances: -

-
-

Instead of taking a container: ...

-
- -

Here "Instead of" is the stem and "taking a container" the bud. -

- -

Parse the rulebook stem in fine mode6.3 = -

- -
-    wording W = rfd->pattern;
-    <rule-preamble-fine>(W);
-    parse_node *during_spec = <<rp>>;
-    int form = <<r>>;
-    rulebook_match *parsed_rm = Rulebooks::match();
-    W = GET_RW(<rule-preamble-finer>, 1);
-    if (form == NOT_APPLICABLE) {
-        <unrecognised-rule-stem-diagnosis>(W);
-    } else {
-        if (form) rfd->whenwhile = GET_RW(<rule-preamble-finer>, 2);
-        #ifdef IF_MODULE
-        rfd->during_scene_spec = during_spec;
-        #endif
-        rfd->owning_rulebook = parsed_rm->matched_rulebook;
-        if (rfd->owning_rulebook == NULL) internal_error("rulebook stem misparsed");
-        rfd->owning_rulebook_placement = parsed_rm->placement_requested;
-        Disallow the definite article for anonymous rules6.3.2;
-        Cut off the bud from the stem6.3.1;
-    }
-    rfd->reduced_stem = W;
-
-
  • This code is used in §6.
-

§6.3.1. The bud is not always present at all, and need not always be at the end -of the stem, so we have to be very careful: -

- -

Cut off the bud from the stem6.3.1 = -

- -
-    wording BUD = GET_RW(<rulebook-stem-embellished>, 1);
-    int b1 = Wordings::first_wn(BUD), b2 = Wordings::last_wn(BUD);
-    if ((b1 == -1) || (b1 > b2)) {
-        b1 = parsed_rm->match_from + parsed_rm->advance_words;
-        b2 = parsed_rm->match_from + parsed_rm->advance_words - 1;
-    }
-    b2 -= parsed_rm->tail_words;
-    wording BW = Wordings::new(b1, b2);
-    wording CW = EMPTY_WORDING;
-
-    if (parsed_rm->advance_words != parsed_rm->match_length) {
-        if (!((<rulebook-bud>(BW)) && (<<r>> == FALSE))) {
-            BW = Wordings::from(BW, parsed_rm->match_from + parsed_rm->match_length);
-            if (<rulebook-bud>(BW)) {
-                if (<<r>>) CW = GET_RW(<rulebook-bud>, 1);
-            } else {
-                CW = BW;
-            }
-        }
-    } else {
-        if (<rulebook-bud>(BW)) {
-            if (<<r>>) CW = GET_RW(<rulebook-bud>, 1);
-        } else {
-            CW = BW;
-        }
-    }
-
-    if (<rulebook-bud>(BW)) {
-        if (<<r>>) CW = GET_RW(<rulebook-bud>, 1);
-    } else if (parsed_rm->advance_words != parsed_rm->match_length) {
-        BW = Wordings::from(BW, parsed_rm->match_from + parsed_rm->match_length);
-        if (<rulebook-bud>(BW)) {
-            if (<<r>>) CW = GET_RW(<rulebook-bud>, 1);
-        } else {
-            CW = BW;
-        }
-    } else {
-        CW = BW;
-    }
-
-    if (Wordings::nonempty(CW)) rfd->rule_parameter = CW;
-
-    if ((rfd->owning_rulebook) &&
-        (Rulebooks::runs_during_activities(rfd->owning_rulebook) == FALSE) &&
-        (Rulebooks::action_focus(rfd->owning_rulebook)) &&
-        (Wordings::nonempty(rfd->rule_parameter)) &&
-        (Wordings::nonempty(rfd->whenwhile))) {
-        rfd->rule_parameter =
-            Wordings::new(Wordings::first_wn(rfd->rule_parameter),
-                Wordings::last_wn(rfd->whenwhile));
-        rfd->whenwhile = EMPTY_WORDING;
-    }
-
-
  • This code is used in §6.3.
-

§7. If we can't find a stem, the following chooses which problem to issue: -

- -
 <unrecognised-rule-stem-diagnosis> ::=
-    when *** |    ==> Issue PM_BadRulePreambleWhen problem7.1
-    ...                         ==> Issue PM_BadRulePreamble problem7.2
+    when *** |                            ==> Issue PM_BadRulePreambleWhen problem6.1
+    ...                                   ==> Issue PM_BadRulePreamble problem6.2
 
-

§7.1. Issue PM_BadRulePreambleWhen problem7.1 = +

§6.1. Issue PM_BadRulePreambleWhen problem6.1 =

     Problems::quote_source(1, current_sentence);
     StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_BadRulePreambleWhen));
     Problems::issue_problem_segment(
-        "The punctuation makes me think %1 should be a definition "
-        "of a phrase or a rule, but it doesn't begin as it should, "
-        "with either 'To' (e.g. 'To flood the riverplain:'), 'Definition:', "
-        "a name for a rule (e.g. 'This is the devilishly cunning rule:'), "
-        "'At' plus a time (e.g. 'At 11:12 PM:' or 'At the time when "
-        "the clock chimes:') or the name of a rulebook. %P"
-        "As your rule begins with 'When', it may be worth noting that in "
-        "December 2006 the syntax used by Inform for timed events changed: "
-        "the old syntax 'When the sky falls in:' to create a named "
-        "event, the sky falls in, became 'At the time when the sky "
-        "falls in:'. This was changed to avoid confusion with rules "
-        "relating to when scenes begin or end. %P"
-        "Or perhaps you meant to say that something would only happen "
-        "when some condition held. Inform often allows this, but the "
-        "'when...' part tends to be at the end, not up front - for "
-        "instance, 'Understand \"blue\" as the deep crevasse when the "
-        "location is the South Pole.'");
+        "The punctuation makes me think %1 should be a definition of a phrase or a rule, "
+        "but it doesn't begin as it should, with either 'To' (e.g. 'To flood the riverplain:'), "
+        "'Definition:', a name for a rule (e.g. 'This is the devilishly cunning rule:'), "
+        "'At' plus a time (e.g. 'At 11:12 PM:' or 'At the time when the clock chimes:') or "
+        "the name of a rulebook. %P"
+        "Perhaps you meant to say that something would only happen when some condition held. "
+        "Inform often allows this, but the 'when...' part tends to be at the end, not up "
+        "front - for instance, 'Understand \"blue\" as the deep crevasse when the location "
+        "is the South Pole.'");
     Problems::issue_problem_end();
 
-
  • This code is used in §7.
-

§7.2. Issue PM_BadRulePreamble problem7.2 = +

  • This code is used in §6.
+

§6.2. Issue PM_BadRulePreamble problem6.2 =

     StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_BadRulePreamble),
-        "the punctuation here ':' makes me think this should be a definition "
-        "of a phrase and it doesn't begin as it should",
-        "with either 'To' (e.g. 'To flood the riverplain:'), 'Definition:', "
-        "a name for a rule (e.g. 'This is the devilishly cunning rule:'), "
-        "'At' plus a time (e.g. 'At 11:12 PM:' or 'At the time when "
-        "the clock chimes') or the name of a rulebook, possibly followed "
-        "by some description of the action or value to apply to (e.g. "
+        "the punctuation here ':' makes me think this should be a definition of a phrase "
+        "and it doesn't begin as it should",
+        "with either 'To' (e.g. 'To flood the riverplain:'), 'Definition:', a name for a "
+        "rule (e.g. 'This is the devilishly cunning rule:'), 'At' plus a time (e.g. 'At "
+        "11:12 PM:' or 'At the time when the clock chimes') or the name of a rulebook, "
+        "possibly followed by some description of the action or value to apply to (e.g. "
         "'Instead of taking something:' or 'Every turn:').");
 
-
  • This code is used in §7.
-

§6.3.2. Disallow the definite article for anonymous rules6.3.2 = +

  • This code is used in §6.
+

§7. The crucial nonterminal in the above grammar is <rulebook-stem>, which tries +to make the longest match it can of a rulebook name; if it matches successfully, +then calling Rulebooks::match produces a detailed rundown of its findings, +which are too elaborate to pass back in a simple pointer. +

+ +
+void RuleFamily::assess(imperative_defn_family *self, imperative_defn *id) {
+    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
+    if (rfd->not_in_rulebook == FALSE) {
+        wording W = rfd->usage_preamble;
+        <rule-preamble-fine>(W);
+        parse_node *during_spec = <<rp>>;
+        int has_when = <<r>>;
+        rulebook_match *parsed_rm = Rulebooks::match();
+        W = GET_RW(<rule-preamble-finer>, 1);
+        if (has_when == NOT_APPLICABLE) {
+            <unrecognised-rule-stem-diagnosis>(W);
+        } else {
+            if (has_when) rfd->whenwhile = GET_RW(<rule-preamble-finer>, 2);
+            rfd->during_spec = during_spec;
+            rfd->owning_rulebook = parsed_rm->matched_rulebook;
+            rfd->owning_rulebook_placement = parsed_rm->placement_requested;
+            Disallow the definite article for middling rules7.1;
+            Cut off the bud from the stem7.2;
+            Merge the when/while text back into applicability, for actions7.3;
+        }
+        rfd->pruned_stem = W;
+    }
+}
+
+

§7.1. This is a super-pedantic problem message, and might cause problems in languages +other than English. +

+ +

Disallow the definite article for middling rules7.1 =

     if ((parsed_rm->article_used == definite_article) &&
         (parsed_rm->placement_requested == MIDDLE_PLACEMENT))
-        StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_RuleWithDefiniteArticle),
+        StandardProblems::sentence_problem(Task::syntax_tree(),
+            _p_(PM_RuleWithDefiniteArticle),
             "a rulebook can contain any number of rules",
-            "so (e.g.) 'the before rule: ...' is disallowed; you should "
-            "write 'a before rule: ...' instead.");
+            "so (e.g.) 'the before rule: ...' is disallowed; you should write 'a before "
+            "rule: ...' instead.");
 
-
  • This code is used in §6.3.
-

§8.

+
  • This code is used in §7.
+

§7.2. The bud is not always present at all, and need not always be at the end of the stem, +so we have to be very careful: +

+ +

Cut off the bud from the stem7.2 = +

-void RuleFamily::new_phrase(imperative_defn_family *self, imperative_defn *id, phrase *new_ph) {
-    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
-    if (rfd->not_in_rulebook)
-        RuleFamily::to_rule(id);
-    else
-        Rules::request_automatic_placement(RuleFamily::to_rule(id));
-    new_ph->compile_with_run_time_debugging = TRUE;
-}
+    wording BUDW = GET_RW(<rulebook-stem-embellished>, 1);
+    int b1 = Wordings::first_wn(BUDW), b2 = Wordings::last_wn(BUDW);
+    if ((b1 == -1) || (b1 > b2)) {
+        b1 = parsed_rm->match_from + parsed_rm->advance_words;
+        b2 = parsed_rm->match_from + parsed_rm->advance_words - 1;
+    }
+    b2 -= parsed_rm->tail_words;
+    BUDW = Wordings::new(b1, b2);
+
+    wording APPW = EMPTY_WORDING;
+
+    if (parsed_rm->advance_words != parsed_rm->match_length) {
+        if (!((<rulebook-bud>(BUDW)) && (<<r>> == FALSE))) {
+            BUDW = Wordings::from(BUDW, parsed_rm->match_from + parsed_rm->match_length);
+            if (<rulebook-bud>(BUDW)) {
+                if (<<r>>) APPW = GET_RW(<rulebook-bud>, 1);
+            } else {
+                APPW = BUDW;
+            }
+        }
+    } else {
+        if (<rulebook-bud>(BUDW)) {
+            if (<<r>>) APPW = GET_RW(<rulebook-bud>, 1);
+        } else {
+            APPW = BUDW;
+        }
+    }
+
+    if (<rulebook-bud>(BUDW)) {
+        if (<<r>>) APPW = GET_RW(<rulebook-bud>, 1);
+    } else if (parsed_rm->advance_words != parsed_rm->match_length) {
+        BUDW = Wordings::from(BUDW, parsed_rm->match_from + parsed_rm->match_length);
+        if (<rulebook-bud>(BUDW)) {
+            if (<<r>>) APPW = GET_RW(<rulebook-bud>, 1);
+        } else {
+            APPW = BUDW;
+        }
+    } else {
+        APPW = BUDW;
+    }
+
+    if (Wordings::nonempty(APPW)) {
+        rfd->applicability = APPW;
+        rfd->prewhile_applicability = APPW;
+    }
 
-

§9. The late-morning creations. A little later on, we've made a rule phrase, and it now has a proper PHUD. -If the rule is an anonymous one, such as: +

  • This code is used in §7.
+

§7.3. This unobvious manoeuvre puts the when/while text back again, so that: +

+ +
+rule instead of taking or dropping when Miss Bianca is in the Embassy:
+                <----- appl -----> <---------- whenwhile ----------->
+ ||
+\||/
+rule instead of taking or dropping when Miss Bianca is in the Embassy:
+                <----- appl ---------------------------------------->
+
+

This is done only where we now know that the stem specified a rulebook based +on actions, and the reason it's done is that action applicabilities are parsed +with a grammar much more sensitive to ambiguities, and in which "when..." +clauses are therefore better recognised. +

+ +

Merge the when/while text back into applicability, for actions7.3 = +

+ +
+    if ((rfd->owning_rulebook) &&
+        (Rulebooks::runs_during_activities(rfd->owning_rulebook) == FALSE) &&
+        (Rulebooks::action_focus(rfd->owning_rulebook)) &&
+        (Wordings::nonempty(rfd->applicability)) &&
+        (Wordings::nonempty(rfd->whenwhile))) {
+        rfd->applicability =
+            Wordings::new(Wordings::first_wn(rfd->applicability),
+                Wordings::last_wn(rfd->whenwhile));
+        rfd->whenwhile = EMPTY_WORDING;
+    }
+
+
  • This code is used in §7.
+

§8. Every rule corresponds to a rule structure. If the rule is an anonymous +one, such as:

@@ -505,41 +469,37 @@ connect this existing one to the phrase.

-rule *RuleFamily::to_rule(imperative_defn *id) {
+void RuleFamily::given_body(imperative_defn_family *self, imperative_defn *id) {
     rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
-    wording W = EMPTY_WORDING;
-    int explicitly = FALSE;
-    Find the name of the phrase, and whether or not it's explicitly given9.1;
-
     rule *R = NULL;
-    if (Wordings::nonempty(W)) R = Rules::by_name(W);
-    if (R) Check that this isn't duplicating the name of a rule already made9.2
-    else R = Rules::obtain(W, explicitly);
-    if (Wordings::empty(W))
-        Hierarchy::markup_wording(R->compilation_data.rule_package, RULE_NAME_HMD, Node::get_text(id->at));
-    Rules::set_imperative_definition(R, id);
-    phrase *ph = id->body_of_defn;
-    package_request *P = RTRules::package(R);
-    ph->ph_iname = Hierarchy::make_localised_iname_in(RULE_FN_HL, P, ph->owning_module);
+    Set R to a corresponding rule structure8.1;
+    rfd->defines = R;
+	if (rfd->not_in_rulebook == FALSE) Rules::request_automatic_placement(R);
 
-    Do some tedious business for indexing the rule later on9.3;
-
-    return R;
+    id->body_of_defn->compile_with_run_time_debugging = TRUE;
+    Phrases::TypeData::set_mor(&(id->body_of_defn->type_data),
+        DECIDES_NOTHING_AND_RETURNS_MOR, NULL);
 }
 
-

§9.1. Find the name of the phrase, and whether or not it's explicitly given9.1 = +

§8.1. Set R to a corresponding rule structure8.1 =

-    if (Wordings::nonempty(rfd->event_name)) {
-        W = Articles::remove_the(rfd->event_name);
-    } else if (Wordings::nonempty(rfd->constant_name)) {
+    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
+    wording W = EMPTY_WORDING;
+    int explicitly = FALSE;
+    if (Wordings::nonempty(rfd->constant_name)) {
         W = Articles::remove_the(rfd->constant_name);
         explicitly = TRUE;
     }
+    if (Wordings::nonempty(W)) R = Rules::by_name(W);
+    if (R) Check that this isn't duplicating the name of a rule already made8.1.1
+    else R = Rules::obtain(W, explicitly);
+    Rules::set_imperative_definition(R, id);
+    Merge the applicability and when/while text for indexing purposes8.1.2;
 
-
  • This code is used in §9.
-

§9.2. Check that this isn't duplicating the name of a rule already made9.2 = +

  • This code is used in §8.
+

§8.1.1. Check that this isn't duplicating the name of a rule already made8.1.1 =

@@ -554,255 +514,188 @@ connect this existing one to the phrase.
         Problems::issue_problem_end();
     }
 
-
  • This code is used in §9.
-

§9.3. This is simply to make the rule's entry in the Index more helpful. -

- -

Do some tedious business for indexing the rule later on9.3 = +

  • This code is used in §8.1.
+

§8.1.2. Merge the applicability and when/while text for indexing purposes8.1.2 =

-    wording IX = rfd->rule_parameter;
+    wording IX = rfd->applicability;
     if (Wordings::nonempty(rfd->whenwhile)) {
-        if (Wordings::first_wn(rfd->whenwhile) == Wordings::last_wn(rfd->rule_parameter) + 1) {
-            IX = Wordings::new(Wordings::first_wn(rfd->rule_parameter), Wordings::last_wn(rfd->whenwhile));
+        if (Wordings::first_wn(rfd->whenwhile) == Wordings::last_wn(rfd->applicability) + 1) {
+            IX = Wordings::new(Wordings::first_wn(rfd->applicability),
+                Wordings::last_wn(rfd->whenwhile));
         } else {
             IX = rfd->whenwhile;
         }
     }
     IXRules::set_italicised_index_text(R, IX);
 
-
  • This code is used in §9.
-

§10.

+
  • This code is used in §8.1.
+

§9. At the end of the assessment process, we can finally put the rules into their +rulebooks. We make "automatic placements" first — i.e., those where the usage +preamble specified which rulebook the rule belonged to; and then we make manual +placements, which may move or remove rules already place. See Rule Placement Requests +for how sentences specifying this are parsed. +

-
-int RuleFamily::get_timing_of_event(imperative_defn *id) {
-    if (id->family != RULE_EFF_family) return NOT_A_TIMED_EVENT;
-    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
-    return rfd->event_time;
-}
+
enum TRAVERSE_FOR_RULE_FILING_SMFT
 
-

§11. For example, for the rule -

- -
-

Instead of taking the box while the skylight is open: ...

-
- -

this returns "taking the box". -

-
-wording RuleFamily::get_prewhile_text(imperative_defn *id) {
-    if (id->family != RULE_EFF_family) return EMPTY_WORDING;
-    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
-    if (Wordings::nonempty(rfd->rule_parameter)) {
-        wording E = rfd->rule_parameter;
-        if (<when-while-clause>(E)) E = GET_RW(<when-while-clause>, 1);
-        return E;
+void RuleFamily::assessment_complete(imperative_defn_family *self) {
+    imperative_defn *id;
+    LOOP_OVER(id, imperative_defn)
+        if (id->family == rule_idf) {
+            rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
+            if (rfd->not_in_rulebook == FALSE) Rules::request_automatic_placement(rfd->defines);
+        }
+
+    int initial_problem_count = problem_count;
+    RuleBookings::make_automatic_placements();
+    if (initial_problem_count < problem_count) return;
+
+    SyntaxTree::traverse(Task::syntax_tree(), RuleFamily::visit_to_parse_placements);
+}
+
+void RuleFamily::visit_to_parse_placements(parse_node *p) {
+    if ((Node::get_type(p) == SENTENCE_NT) &&
+        (p->down) &&
+        (Node::get_type(p->down) == VERB_NT)) {
+        prevailing_mood = Annotations::read_int(p->down, verbal_certainty_ANNOT);
+        MajorNodes::try_special_meaning(TRAVERSE_FOR_RULE_FILING_SMFT, p->down);
     }
-    return EMPTY_WORDING;
 }
 
-

§12.

- -
-<when-while-clause> ::=
-    ... when/while ...
-
- -

§13. Miscellaneous. Some access routines. -

+

§10. Runtime context data.

-int RuleFamily::get_rulebook_placement(imperative_defn *id) {
-    if (id->family != RULE_EFF_family) return MIDDLE_PLACEMENT;
-    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
-    return rfd->owning_rulebook_placement;
-}
-
-rulebook *RuleFamily::get_rulebook(imperative_defn *id) {
-    if (id->family != RULE_EFF_family) return NULL;
-    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
-    return rfd->owning_rulebook;
-}
-
-void RuleFamily::set_rulebook(imperative_defn *id, rulebook *rb) {
-    if (id->family != RULE_EFF_family) internal_error("cannot set rulebook: not a rule");
-    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
-    rfd->owning_rulebook = rb;
-}
-
-linked_list *RuleFamily::get_uses_as_event(imperative_defn *id) {
-    if (id->family != RULE_EFF_family) return NULL;
-    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
-    return rfd->uses_as_event;
-}
-
 int NAP_problem_explained = FALSE;  pertains to Named Action Patterns
 int issuing_ANL_problem = FALSE;  pertains to Action Name Lists
 
-void RuleFamily::to_rcd(imperative_defn_family *self, imperative_defn *id, ph_runtime_context_data *rcd) {
+void RuleFamily::to_rcd(imperative_defn_family *self, imperative_defn *id,
+    ph_runtime_context_data *rcd) {
     rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
-    if (rfd->not_in_rulebook)
+    if (rfd->not_in_rulebook) {
         rcd->permit_all_outcomes = TRUE;
-    else
-        Finish work parsing the conditions for the rule to fire13.1;
+    } else {
+        if (Wordings::nonempty(rfd->applicability))
+            Parse the applicability text into the PHRCD10.1;
+        if (Wordings::nonempty(rfd->whenwhile))
+            rcd->activity_context =
+                Wordings::from(rfd->whenwhile, Wordings::first_wn(rfd->whenwhile) + 1);
+        if (rfd->during_spec) rcd->during_scene = rfd->during_spec;
+    }
 }
 
-

§13.1. All of this is just dumb copying... +

§10.1. Here we try the text first without its when clause, then with, and accept +whichever way works.

-

Finish work parsing the conditions for the rule to fire13.1 = +

Parse the applicability text into the PHRCD10.1 =

-
-    rcd->compile_for_rulebook = &(rfd->owning_rulebook);
-
-    if (Wordings::nonempty(rfd->rule_parameter)) Parse what used to be the bud into the PHRCD13.1.1;
-
-    if (Wordings::nonempty(rfd->whenwhile)) {
-        rcd->activity_context =
-            Wordings::new(
-                Wordings::first_wn(rfd->whenwhile) + 1,
-                Wordings::last_wn(rfd->whenwhile));
-        rcd->activity_where = current_sentence;
-    }
-
-    #ifdef IF_MODULE
-    if (rfd->during_scene_spec) rcd->during_scene = rfd->during_scene_spec;
-    #endif
-
-
  • This code is used in §13.
-

§13.1.1. ...except for this: -

- -

Parse what used to be the bud into the PHRCD13.1.1 = -

- -
-    #ifdef IF_MODULE
     if (Rulebooks::action_focus(rfd->owning_rulebook)) {
-        int saved = ParseActionPatterns::enter_mode(PERMIT_TRYING_OMISSION);
-        if (Rules::all_action_processing_variables())
-            Frames::set_stvol(
-                Frames::current_stack_frame(), Rules::all_action_processing_variables());
-        if (<action-pattern>(rfd->rule_parameter)) rcd->ap = <<rp>>;
-        Frames::remove_nonphrase_stack_frame();
-        ParseActionPatterns::restore_mode(saved);
-
-        if (rcd->ap == NULL)
-            Issue a problem message for a bad action13.1.1.1;
+        rcd->ap = ActionPatterns::parse_action_based(rfd->applicability);
+        if (rcd->ap == NULL) Issue a problem message for a bad action10.1.1;
     } else {
         kind *pk = Rulebooks::get_focus_kind(rfd->owning_rulebook);
-        rcd->ap = ActionPatterns::parse_parametric(rfd->rule_parameter, pk);
+        rcd->ap = ActionPatterns::parse_parametric(rfd->applicability, pk);
         if (rcd->ap == NULL) {
             if (Wordings::nonempty(rfd->whenwhile)) {
-                wording F = Wordings::up_to(rfd->rule_parameter, Wordings::last_wn(rfd->whenwhile));
+                wording F = Wordings::up_to(rfd->applicability, Wordings::last_wn(rfd->whenwhile));
                 rcd->ap = ActionPatterns::parse_parametric(F, pk);
                 if (rcd->ap) {
-                    rfd->rule_parameter = F;
+                    rfd->applicability = F;
                     rfd->whenwhile = EMPTY_WORDING;
                 }
             }
         }
-        if (rcd->ap == NULL) Issue a problem message for a bad parameter13.1.1.2;
+        if (rcd->ap == NULL) Issue a problem message for a bad parameter10.1.2;
     }
-    #endif
-    #ifndef IF_MODULE
-    kind *pk = Rulebooks::get_focus_kind(rfd->owning_rulebook);
-    Issue a problem message for a bad parameter13.1.1.2;
-    #endif
 
- -

§13.1.1.1. All that's left is to issue a "good" problem message, but this is quite -a large undertaking, because the situation as we currently know it is just -that something's wrong with the rule preamble — which covers an enormous -range of different faults. +

  • This code is used in §10.
+

§10.1.1. All that's left is to issue a "good" problem message, but this is quite a +large undertaking, because the situation as we currently know it is just that +something's wrong with the rule preamble — which covers an enormous range of +different faults.

-

The "PAP failure reason" is a sort of error code set by the action pattern +

The pap_failure_reason is a sort of error code set by the action pattern parser, recording how it most recently failed.

-

Issue a problem message for a bad action13.1.1.1 = +

Issue a problem message for a bad action10.1.1 =

     LOG("Bad action pattern: %W = $A\nPAP failure reason: %d\n",
-        rfd->rule_parameter, rcd->ap, pap_failure_reason);
+        rfd->applicability, rcd->ap, pap_failure_reason);
     Problems::quote_source(1, current_sentence);
-    Problems::quote_wording(2, rfd->rule_parameter);
-    if (<action-problem-diagnosis>(rfd->rule_parameter) == FALSE)
+    Problems::quote_wording(2, rfd->applicability);
+    if (<action-problem-diagnosis>(rfd->applicability) == FALSE)
         switch(pap_failure_reason) {
-            case MIXEDNOUNS_PAPF: Issue PM_APWithDisjunction problem13.1.1.1.1; break;
-            case NOPARTICIPLE_PAPF: Issue PM_APWithNoParticiple problem13.1.1.1.2; break;
-            case IMMISCIBLE_PAPF: Issue PM_APWithImmiscible problem13.1.1.1.3; break;
-            case WHEN_PAPF: Issue PM_APWithBadWhen problem13.1.1.1.4; break;
-            default: Issue PM_APUnknown problem13.1.1.1.5; break;
+            case MIXEDNOUNS_PAPF: Issue PM_APWithDisjunction problem10.1.1.1; break;
+            case NOPARTICIPLE_PAPF: Issue PM_APWithNoParticiple problem10.1.1.2; break;
+            case IMMISCIBLE_PAPF: Issue PM_APWithImmiscible problem10.1.1.3; break;
+            case WHEN_PAPF: Issue PM_APWithBadWhen problem10.1.1.4; break;
+            default: Issue PM_APUnknown problem10.1.1.5; break;
         }
 
- -

§13.1.1.1.1. Issue PM_APWithDisjunction problem13.1.1.1.1 = +

+

§10.1.1.1. Issue PM_APWithDisjunction problem10.1.1.1 =

     StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_APWithDisjunction));
     Problems::issue_problem_segment(
-        "You wrote %1, which seems to introduce a rule, but the "
-        "circumstances ('%2') seem to be too general for me to "
-        "understand in a single rule. I can understand a choice of "
-        "of actions, in a list such as 'taking or dropping the ball', "
-        "but there can only be one set of noun(s) supplied. So 'taking "
-        "the ball or taking the bat' is disallowed. You can get around "
-        "this by using named actions ('Taking the ball is being "
-        "mischievous. Taking the bat is being mischievous. Instead of "
-        "being mischievous...'), or it may be less bother just to "
-        "write more than one rule.");
+        "You wrote %1, which seems to introduce a rule, but the circumstances ('%2') seem "
+        "to be too general for me to understand in a single rule. I can understand a "
+        "choice of actions, in a list such as 'taking or dropping the ball', but there "
+        "can only be one set of noun(s) supplied. So 'taking the ball or taking the bat' "
+        "is disallowed. You can get around this by using named actions ('Taking the ball "
+        "is being mischievous. Taking the bat is being mischievous. Instead of being "
+        "mischievous...'), or it may be less bother just to write more than one rule.");
     Problems::issue_problem_end();
 
- -

§13.1.1.1.2. Issue PM_APWithNoParticiple problem13.1.1.1.2 = +

+

§10.1.1.2. Issue PM_APWithNoParticiple problem10.1.1.2 =

     StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_APWithNoParticiple));
     Problems::issue_problem_segment(
-        "You wrote %1, which seems to introduce a rule taking effect "
-        "only '%2'. But this does not look like an action, since "
-        "there is no sign of a participle ending '-ing' (as in "
-        "'taking the brick', say) - which makes me think I have "
-        "badly misunderstood what you intended.");
+        "You wrote %1, which seems to introduce a rule taking effect only '%2'. But this "
+        "does not look like an action, since there is no sign of a participle ending '-ing' "
+        "(as in 'taking the brick', say) - which makes me think I have badly misunderstood "
+        "what you intended.");
     Problems::issue_problem_end();
 
- -

§13.1.1.1.3. Issue PM_APWithImmiscible problem13.1.1.1.3 = +

+

§10.1.1.3. Issue PM_APWithImmiscible problem10.1.1.3 =

     StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_APWithImmiscible));
     Problems::issue_problem_segment(
-        "You wrote %1, which seems to introduce a rule taking effect "
-        "only '%2'. But this is a combination of actions which cannot "
-        "be mixed. The only alternatives where 'or' is allowed are "
-        "cases where a choice of actions is given but applying to "
-        "the same objects in each case. (So 'taking or dropping the "
-        "CD' is allowed, but 'dropping the CD or inserting the CD "
-        "into the jewel box' is not, because the alternatives there "
-        "would make different use of objects from each other.)");
+        "You wrote %1, which seems to introduce a rule taking effect only '%2'. But this "
+        "is a combination of actions which cannot be mixed. The only alternatives where "
+        "'or' is allowed are cases where a choice of actions is given but applying to "
+        "the same objects in each case. (So 'taking or dropping the CD' is allowed, but "
+        "'dropping the CD or inserting the CD into the jewel box' is not, because the "
+        "alternatives there would make different use of objects from each other.)");
     Problems::issue_problem_end();
 
- -

§13.1.1.1.4. Issue PM_APWithBadWhen problem13.1.1.1.4 = +

+

§10.1.1.4. Issue PM_APWithBadWhen problem10.1.1.4 =

     StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_APWithBadWhen));
-    wording Q = rfd->rule_parameter;
+    wording Q = rfd->applicability;
     int diagnosis = 0;
     if (<action-when-diagnosis>(Q)) {
-        Q = Wordings::new(<<cw1>>, <<cw2>>);
+        if (<<r>> == 1) Q = GET_RW(<action-when-diagnosis>, 3);
+        else Q = GET_RW(<action-when-diagnosis>, 2);
         diagnosis = <<r>>;
     }
     Problems::quote_wording(2, Q);
@@ -818,98 +711,93 @@ parser, recording how it most recently failed.
             "(Whereas 'no room' is usually allowed.)");
     }
     Problems::issue_problem_segment(
-        "You wrote %1, which seems to introduce a rule taking effect "
-        "only '%2'. But this condition did not make sense, %3");
+        "You wrote %1, which seems to introduce a rule taking effect only '%2'. But this "
+        "condition did not make sense, %3");
     if (diagnosis == 1)
         Problems::issue_problem_segment(
             "%PIt might be worth mentioning that a 'when' condition tacked on to "
             "an action like this is not allowed to mention or use 'called' values.");
     if (diagnosis == 4)
         Problems::issue_problem_segment(
-            "%PThe problem might be that 'and' has been followed by 'when' or "
-            "'while'. For example, to make a rule with two conditions, this is "
-            "okay: 'Instead of jumping when Peter is happy and Peter is in the "
-            "location'; but the same thing with '...and when Peter is...' is not allowed.");
+            "%PThe problem might be that 'and' has been followed by 'when' or 'while'. "
+            "For example, to make a rule with two conditions, this is okay: 'Instead of "
+            "jumping when Peter is happy and Peter is in the location'; but the same thing "
+            "with '...and when Peter is...' is not allowed.");
     Problems::issue_problem_end();
 
- -

§13.1.1.1.5. Issue PM_APUnknown problem13.1.1.1.5 = +

+

§10.1.1.5. Issue PM_APUnknown problem10.1.1.5 =

-    Problems::quote_wording(2, rfd->rule_parameter);
+    Problems::quote_wording(2, rfd->applicability);
     if (pap_failure_reason == WHENOKAY_PAPF)
         Problems::quote_text(3,
             "The part after 'when' (or 'while') was fine, but the earlier words");
     else Problems::quote_text(3, "But that");
     StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_APUnknown));
     Problems::issue_problem_segment(
-        "You wrote %1, which seems to introduce a rule taking effect only if the "
-        "action is '%2'. %3 did not make sense as a description of an action.");
-    See if it starts with a valid action name, at least13.1.1.1.5.1;
-    See if this might be a when-for confusion13.1.1.1.5.2;
-    Break down the action list and say which are okay13.1.1.1.5.3;
+        "You wrote %1, which seems to introduce a rule taking effect only if the action "
+        "is '%2'. %3 did not make sense as a description of an action.");
+    See if it starts with a valid action name, at least10.1.1.5.1;
+    See if this might be a when-for confusion10.1.1.5.2;
+    Break down the action list and say which are okay10.1.1.5.3;
     Problems::issue_problem_segment(
         " I am unable to place this rule into any rulebook.");
     Problems::issue_problem_end();
 
- -

§13.1.1.1.5.1. See if it starts with a valid action name, at least13.1.1.1.5.1 = +

+

§10.1.1.5.1. See if it starts with a valid action name, at least10.1.1.5.1 =

     action_name *an;
     LOOP_OVER(an, action_name)
-        if ((Wordings::length(rfd->rule_parameter) < Wordings::length(ActionNameNames::tensed(an, IS_TENSE))) &&
-            (Wordings::match(rfd->rule_parameter,
-                Wordings::truncate(ActionNameNames::tensed(an, IS_TENSE), Wordings::length(rfd->rule_parameter))))) {
+        if ((Wordings::length(rfd->applicability) <
+                Wordings::length(ActionNameNames::tensed(an, IS_TENSE))) &&
+            (Wordings::match(rfd->applicability,
+                Wordings::truncate(ActionNameNames::tensed(an, IS_TENSE),
+                    Wordings::length(rfd->applicability))))) {
             Problems::quote_wording(3, ActionNameNames::tensed(an, IS_TENSE));
             Problems::issue_problem_segment(
-                " I notice that there's an action called '%3', though: perhaps "
-                "this is what you meant?");
+                " I notice that there's an action called '%3', though: perhaps this is "
+                "what you meant?");
             break;
         }
 
- -

§13.1.1.1.5.2. See if this might be a when-for confusion13.1.1.1.5.2 = +

+

§10.1.1.5.2. See if this might be a when-for confusion10.1.1.5.2 =

     if (pap_failure_reason == WHENOKAY_PAPF) {
-        time_period *duration = Occurrence::parse(rfd->reduced_stem);
+        time_period *duration = Occurrence::parse(rfd->pruned_stem);
         if (duration) {
             Problems::quote_wording(3, Occurrence::used_wording(duration));
             Problems::issue_problem_segment(
-                " (I wonder if this might be because '%3', which looks like a "
-                "condition on the timing, is the wrong side of the 'when...' "
-                "clause?)");
+                " (I wonder if this might be because '%3', which looks like a condition "
+                "on the timing, is the wrong side of the 'when...' clause?)");
         }
     }
 
- -

§13.1.1.1.5.3. If the action pattern contains what looks like a list of action names, as -for example +

+

§10.1.1.5.3. If the action pattern contains what looks like a list of action names, as for example +"Instead of taking or dropping the magnet: ..." then the <anl-diagnosis> grammar will + parse this and return N equal to 2, the apparent number of action names. We then + run the grammar again, but this time allowing it to print comments on each apparent + action name it sees.

-
-

Instead of taking or dropping the magnet: ...

-
- -

then the anl-diagnosis grammar will parse this and return N equal to 2, the -apparent number of action names. We then run the grammar again, but this time -allowing it to print comments on each apparent action name it sees. -

- -

Break down the action list and say which are okay13.1.1.1.5.3 = +

Break down the action list and say which are okay10.1.1.5.3 =

     issuing_ANL_problem = FALSE; NAP_problem_explained = FALSE;
-    <anl-diagnosis>(rfd->rule_parameter);
+    <anl-diagnosis>(rfd->applicability);
     int N = <<r>>;
     if (N > 1) {
         int positive = TRUE;
-        ActionNameLists::parse(rfd->rule_parameter, IS_TENSE, &positive);
+        ActionNameLists::parse(rfd->applicability, IS_TENSE, &positive);
         if (positive == FALSE)
             Problems::issue_problem_segment(
                 " This looks like a list of actions to avoid: ");
@@ -917,105 +805,100 @@ allowing it to print comments on each apparent action name it sees.
             Problems::issue_problem_segment(
                 " Looking at this as a list of alternative actions: ");
         issuing_ANL_problem = TRUE; NAP_problem_explained = FALSE;
-        <anl-diagnosis>(rfd->rule_parameter);
+        <anl-diagnosis>(rfd->applicability);
         Problems::issue_problem_segment(" so");
     }
 
- -

§13.1.1.2. We have a much easier time if the rulebook was value-focused, so that +

+

§10.1.2. We have a much easier time if the rulebook was value-focused, so that the only possible problem is that the value was wrong.

-

Issue a problem message for a bad parameter13.1.1.2 = +

Issue a problem message for a bad parameter10.1.2 =

     Problems::quote_source(1, current_sentence);
-    Problems::quote_wording(2, rfd->rule_parameter);
+    Problems::quote_wording(2, rfd->applicability);
     Problems::quote_kind(3, pk);
-    <parametric-problem-diagnosis>(rfd->reduced_stem);
+    <parametric-problem-diagnosis>(rfd->pruned_stem);
 
- -

§14. And that is the end of the code as such, but we still have to define the +

+

§11. And that is the end of the code as such, but we still have to define the three diagnosis grammars we needed.

-

§15. Parametric rules are those applying to values not actions, and the following +

§12. Parametric rules are those applying to values not actions, and the following is used to choose a problem message if the value makes no sense.

 <parametric-problem-diagnosis> ::=
-    when the play begins/ends |    ==> Issue PM_WhenThePlay problem15.1
-    ...                                 ==> Issue PM_BadParameter problem15.2
+    when the play begins/ends |    ==> Issue PM_WhenThePlay problem12.1
+    ...                            ==> Issue PM_BadParameter problem12.2
 
-

§15.1. Issue PM_WhenThePlay problem15.1 = +

§12.1. Issue PM_WhenThePlay problem12.1 =

     StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_WhenThePlay),
         "there's no scene called 'the play'",
-        "so I think you need to remove 'the' - Inform has two "
-        "special rulebooks, 'When play begins' and 'When play ends', "
-        "and I think you probably mean to refer to one of those.");
+        "so I think you need to remove 'the' - Inform has two special rulebooks, 'When "
+        "play begins' and 'When play ends', and I think you probably mean to refer to "
+        "one of those.");
 
-
  • This code is used in §15.
-

§15.2. Issue PM_BadParameter problem15.2 = +

  • This code is used in §12.
+

§12.2. Issue PM_BadParameter problem12.2 =

     StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_BadParameter));
     Problems::issue_problem_segment(
-        "You wrote %1, but the description of the thing(s) to which the rule "
-        "applies ('%2') did not make sense. This is %3 based rulebook, so "
-        "that should have described %3.");
+        "You wrote %1, but the description of the thing(s) to which the rule applies ('%2') "
+        "did not make sense. This is %3 based rulebook, so that should have described %3.");
     Problems::issue_problem_end();
 
-
  • This code is used in §15.
-

§16. And here we choose a problem message if a rule applying to an action is used, +

  • This code is used in §12.
+

§13. And here we choose a problem message if a rule applying to an action is used, but the action isn't one we recognise.

 <action-problem-diagnosis> ::=
-    in the presence of ... |    ==> Issue PM_NonActionInPresenceOf problem16.1
-    in ...                          ==> Issue PM_NonActionIn problem16.2
+    in the presence of ... |    ==> Issue PM_NonActionInPresenceOf problem13.1
+    in ...                      ==> Issue PM_NonActionIn problem13.2
 
-

§16.1. Issue PM_NonActionInPresenceOf problem16.1 = +

§13.1. Issue PM_NonActionInPresenceOf problem13.1 =

     StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_NonActionInPresenceOf));
     Problems::issue_problem_segment(
-        "You wrote %1, but 'in the presence of...' is a clause which can "
-        "only be used to talk about an action: so, for instance, 'waiting "
-        "in the presence of...' is needed. "
-        "This problem arises especially with 'every turn' rules, where "
-        "'every turn in the presence of...' looks plausible but doesn't "
-        "work. This could be fixed by writing 'Every turn doing something "
-        "in the presence of...', but a neater solution talks about the "
-        "current situation instead: 'Every turn when the player can "
-        "see...'.");
+        "You wrote %1, but 'in the presence of...' is a clause which can only be used to "
+        "talk about an action: so, for instance, 'waiting in the presence of...' is needed. "
+        "This problem arises especially with 'every turn' rules, where 'every turn in the "
+        "presence of...' looks plausible but doesn't work. This could be fixed by writing "
+        "'Every turn doing something in the presence of...', but a neater solution talks "
+        "about the current situation instead: 'Every turn when the player can see...'.");
     Problems::issue_problem_end();
 
-
  • This code is used in §16.
-

§16.2. Issue PM_NonActionIn problem16.2 = +

  • This code is used in §13.
+

§13.2. Issue PM_NonActionIn problem13.2 =

     StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_NonActionIn));
     Problems::issue_problem_segment(
-        "You wrote %1, but 'in...' used in this way should really belong "
-        "to an action: for instance, 'Before waiting in the Library'. "
-        "Rules like 'Every turn in the Library' don't work, because "
-        "'every turn' is not an action; what's wanted is 'Every turn "
+        "You wrote %1, but 'in...' used in this way should really belong to an action: for "
+        "instance, 'Before waiting in the Library'. Rules like 'Every turn in the Library' "
+        "don't work, because 'every turn' is not an action; what's wanted is 'Every turn "
         "when in the Library'.");
     Problems::issue_problem_end();
 
-
  • This code is used in §16.
-

§17. The following is used to choose a problem when the trouble with the rule +

  • This code is used in §13.
+

§14. The following is used to choose a problem when the trouble with the rule occurred in a when/while condition at the end; while all five cases produce the PM_APWithBadWhen problem, they each provide different clues as to what might have gone wrong. @@ -1023,16 +906,12 @@ might have gone wrong.

 <action-when-diagnosis> ::=
-    ... called ... {when/while ...} |   ==> { 1, -, <<cw1>> = Wordings::first_wn(WR[3]), <<cw2>> = Wordings::last_wn(WR[3]) }
-    ... {when/while *** nothing ***} |  ==> { 2, -, <<cw1>> = Wordings::first_wn(WR[2]), <<cw2>> = Wordings::last_wn(WR[2]) }
-    ... {when/while *** nowhere ***} |  ==> { 3, -, <<cw1>> = Wordings::first_wn(WR[2]), <<cw2>> = Wordings::last_wn(WR[2]) }
-    ... and {when/while ...} |          ==> { 4, -, <<cw1>> = Wordings::first_wn(WR[2]), <<cw2>> = Wordings::last_wn(WR[2]) }
-    ... {when/while ...}                ==> { 5, -, <<cw1>> = Wordings::first_wn(WR[2]), <<cw2>> = Wordings::last_wn(WR[2]) }
-
- -

§18.

+ ... called ... {when/while ...} | ==> { 1, - } + ... {when/while *** nothing ***} | ==> { 2, - } + ... {when/while *** nowhere ***} | ==> { 3, - } + ... and {when/while ...} | ==> { 4, - } + ... {when/while ...} ==> { 5, - } -
 <anl-diagnosis> ::=
     <anl-inner-diagnosis> when/while ... |        ==> { pass 1 }
     <anl-inner-diagnosis>                         ==> { pass 1 }
@@ -1046,16 +925,15 @@ might have gone wrong.
     _,/or <anl-inner-diagnosis>                   ==> { pass 1 }
 
 <anl-entry-diagnosis> ::=
-    ......                                          ==> Diagnose problem with this ANL entry18.1
+    ......                                        ==> Diagnose problem with this ANL entry14.1
 
-

§18.1. Diagnose problem with this ANL entry18.1 = +

§14.1. Diagnose problem with this ANL entry14.1 =

     if ((issuing_ANL_problem) && (!preform_lookahead_mode)) {
         Problems::quote_wording(4, W);
-        #ifdef IF_MODULE
         if (<action-pattern>(W) == FALSE) {
             Problems::issue_problem_segment("'%4' did not make sense; ");
             return TRUE;
@@ -1092,20 +970,18 @@ might have gone wrong.
                 "which isn't allowed in a list like this; ");
             return TRUE;
         }
-        #endif
         Problems::issue_problem_segment("'%4' was okay; ");
     }
     ==> { 1, - };
 
-
  • This code is used in §18.
-

§19.

+
  • This code is used in §14.
+

§15. Compilation. We compile these in rulebook order first, and then pick up any rules not in +rulebooks. This is really just to make the Inter output tidily arranged; +any order would have done just as well. +

-void RuleFamily::to_phtd(imperative_defn_family *self, imperative_defn *id, ph_type_data *phtd, wording XW, wording *OW) {
-    Phrases::TypeData::set_mor(phtd, DECIDES_NOTHING_AND_RETURNS_MOR, NULL);
-}
-
-void RuleFamily::compile(imperative_defn_family *self,
+void RuleFamily::compile(imperative_defn_family *self,
     int *total_phrases_compiled, int total_phrases_to_compile) {
     rulebook *rb;
     LOOP_OVER(rb, rulebook)
@@ -1117,6 +993,37 @@ might have gone wrong.
             total_phrases_compiled, total_phrases_to_compile);
 }
 
+

§16. Miscellaneous access functions.

+ +
+wording RuleFamily::get_prewhile_text(imperative_defn *id) {
+    if (id->family != rule_idf) return EMPTY_WORDING;
+    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
+    return rfd->prewhile_applicability;
+}
+
+int RuleFamily::get_rulebook_placement(imperative_defn *id) {
+    if (id->family != rule_idf) return MIDDLE_PLACEMENT;
+    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
+    return rfd->owning_rulebook_placement;
+}
+
+rulebook *RuleFamily::get_rulebook(imperative_defn *id) {
+    if (id->family != rule_idf) return NULL;
+    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
+    return rfd->owning_rulebook;
+}
+
+void RuleFamily::set_rulebook(imperative_defn *id, rulebook *rb) {
+    if (id->family != rule_idf) internal_error("cannot set rulebook: not a rule");
+    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
+    rfd->owning_rulebook = rb;
+}
+
+int RuleFamily::allows_rule_only(imperative_defn_family *self, imperative_defn *id) {
+    return TRUE;
+}
+
diff --git a/docs/assertions-module/5-tpf.html b/docs/assertions-module/5-tpf.html index c53def4a6..e5938baa4 100644 --- a/docs/assertions-module/5-tpf.html +++ b/docs/assertions-module/5-tpf.html @@ -87,7 +87,8 @@ function togglePopup(material_id) { struct wording pattern; struct wording prototype_text; struct wording constant_name; - struct constant_phrase *constant_phrase_holder; + struct wording ph_documentation_symbol; the documentation reference, if any + struct constant_phrase *constant_phrase_holder; int explicit_name_used_in_maths; if so, this flag means it's like log() or sin() struct wording explicit_name_for_inverse; e.g. exp for log int to_begin; used in Basic mode only: this is to be the main phrase @@ -100,12 +101,11 @@ function togglePopup(material_id) {
 void ToPhraseFamily::create_family(void) {
     TO_PHRASE_EFF_family            = ImperativeDefinitionFamilies::new(I"TO_PHRASE_EFF", TRUE);
-    METHOD_ADD(TO_PHRASE_EFF_family, CLAIM_IMP_DEFN_MTID, ToPhraseFamily::claim);
+    METHOD_ADD(TO_PHRASE_EFF_family, IDENTIFY_IMP_DEFN_MTID, ToPhraseFamily::claim);
     METHOD_ADD(TO_PHRASE_EFF_family, ASSESS_IMP_DEFN_MTID, ToPhraseFamily::assess);
     METHOD_ADD(TO_PHRASE_EFF_family, REGISTER_IMP_DEFN_MTID, ToPhraseFamily::register);
-    METHOD_ADD(TO_PHRASE_EFF_family, NEW_PHRASE_IMP_DEFN_MTID, ToPhraseFamily::new_phrase);
+    METHOD_ADD(TO_PHRASE_EFF_family, GIVEN_BODY_IMP_DEFN_MTID, ToPhraseFamily::given_body);
     METHOD_ADD(TO_PHRASE_EFF_family, ALLOWS_INLINE_IMP_DEFN_MTID, ToPhraseFamily::allows_inline);
-    METHOD_ADD(TO_PHRASE_EFF_family, TO_PHTD_IMP_DEFN_MTID, ToPhraseFamily::to_phtd);
     METHOD_ADD(TO_PHRASE_EFF_family, COMPILE_IMP_DEFN_MTID, ToPhraseFamily::compile);
     METHOD_ADD(TO_PHRASE_EFF_family, COMPILE_AS_NEEDED_IMP_DEFN_MTID, ToPhraseFamily::compile_as_needed);
     METHOD_ADD(TO_PHRASE_EFF_family, PHRASEBOOK_INDEX_IMP_DEFN_MTID, ToPhraseFamily::include_in_Phrasebook_index);
@@ -168,13 +168,15 @@ function togglePopup(material_id) {
                     "because it already has a meaning.");
             } else {
                 tfd->constant_name = RW;
-                if (Phrases::Constants::parse(RW) == NULL)
-                    Phrases::Constants::create(RW, GET_RW(<to-phrase-preamble>, 1));
+                if (ToPhraseFamily::parse_constant(RW) == NULL)
+                    ToPhraseFamily::create_constant(RW, GET_RW(<to-phrase-preamble>, 1));
             }
             if ((form == 1) || (form == 2)) tfd->explicit_name_used_in_maths = TRUE;
             if (form == 1) tfd->explicit_name_for_inverse = Wordings::first_word(GET_RW(<to-phrase-preamble>, 3));
         }
-        tfd->prototype_text = GET_RW(<to-phrase-preamble>, 1);
+        wording PW = GET_RW(<to-phrase-preamble>, 1);
+        tfd->ph_documentation_symbol = Index::DocReferences::position_of_symbol(&PW);
+        tfd->prototype_text = PW;
     }
 }
 
@@ -231,9 +233,9 @@ mode, we can get that value back again if we look it up by name.
     wording NW = tfd->constant_name;
 
-    constant_phrase *cphr = Phrases::Constants::parse(NW);
-    if (Kinds::Behaviour::definite(cphr->cphr_kind) == FALSE) {
-        phrase *ph = Phrases::Constants::as_phrase(cphr);
+    constant_phrase *cphr = ToPhraseFamily::parse_constant(NW);
+    if (Kinds::Behaviour::definite(cphr->cphr_kind) == FALSE) {
+        phrase *ph = ToPhraseFamily::body_of_constant(cphr);
         if (ph) current_sentence = Phrases::declaration_node(ph);
         Problems::quote_source(1, Diagrams::new_UNPARSED_NOUN(Nouns::nominative_singular(cphr->name)));
         Problems::quote_wording(2, Nouns::nominative_singular(cphr->name));
@@ -246,7 +248,7 @@ mode, we can get that value back again if we look it up by name.
             "for every setting where it might be needed, and we can't "
             "predict in advance which one '%2' might need to be.");
         Problems::issue_problem_end();
-        LOG("CPHR failed at %d, %u\n", cphr->allocation_id, cphr->cphr_kind);
+        LOG("CPHR failed at %d, %u\n", cphr->allocation_id, cphr->cphr_kind);
     }
     tfd->constant_phrase_holder = cphr;
 
@@ -254,29 +256,31 @@ mode, we can get that value back again if we look it up by name.

§9.

-void ToPhraseFamily::register(imperative_defn_family *self, int initial_problem_count) {
+void ToPhraseFamily::register(imperative_defn_family *self) {
     Routines::ToPhrases::register_all();
 }
 
-void ToPhraseFamily::new_phrase(imperative_defn_family *self, imperative_defn *id, phrase *new_ph) {
+void ToPhraseFamily::given_body(imperative_defn_family *self, imperative_defn *id) {
     to_family_data *tfd = RETRIEVE_POINTER_to_family_data(id->family_specific_data);
-    if (tfd->to_begin) new_ph->to_begin = TRUE;
-    Routines::ToPhrases::new(new_ph);
+    if (tfd->to_begin) id->body_of_defn->to_begin = TRUE;
+
+    wording XW = ToPhraseFamily::get_prototype_text(id);
+    wording OW = EMPTY_WORDING;
+    Phrases::TypeData::Textual::parse(&(id->body_of_defn->type_data), XW, &OW);
+    Phrases::Options::parse_declared_options(&(id->body_of_defn->options_data), OW);
+
+    Routines::ToPhrases::new(id->body_of_defn);
 }
 
 int ToPhraseFamily::allows_inline(imperative_defn_family *self, imperative_defn *id) {
     return TRUE;
 }
 
-void ToPhraseFamily::to_phtd(imperative_defn_family *self, imperative_defn *id, ph_type_data *phtd, wording XW, wording *OW) {
-    Phrases::TypeData::Textual::parse(phtd, XW, OW);
-}
-
-int ToPhraseFamily::include_in_Phrasebook_index(imperative_defn_family *self, imperative_defn *id) {
+int ToPhraseFamily::include_in_Phrasebook_index(imperative_defn_family *self, imperative_defn *id) {
     return TRUE;
 }
 
-phrase *ToPhraseFamily::inverse(imperative_defn *id) {
+phrase *ToPhraseFamily::inverse(imperative_defn *id) {
     if (id->family != TO_PHRASE_EFF_family) return NULL;
     to_family_data *tfd = RETRIEVE_POINTER_to_family_data(id->family_specific_data);
     if (Wordings::nonempty(tfd->explicit_name_for_inverse)) {
@@ -291,7 +295,7 @@ mode, we can get that value back again if we look it up by name.
     return NULL;
 }
 
-constant_phrase *ToPhraseFamily::constant_phrase(imperative_defn *id) {
+constant_phrase *ToPhraseFamily::constant_phrase(imperative_defn *id) {
     if (id->family != TO_PHRASE_EFF_family) return NULL;
     to_family_data *tfd = RETRIEVE_POINTER_to_family_data(id->family_specific_data);
     return tfd->constant_phrase_holder;
@@ -319,18 +323,24 @@ mode, we can get that value back again if we look it up by name.
         return Wordings::first_word(Nouns::nominative_singular(tfd->constant_phrase_holder->name));
     return EMPTY_WORDING;
 }
+
+wording ToPhraseFamily::doc_ref(imperative_defn *id) {
+    if (id->family != TO_PHRASE_EFF_family) return EMPTY_WORDING;
+    to_family_data *tfd = RETRIEVE_POINTER_to_family_data(id->family_specific_data);
+    return tfd->ph_documentation_symbol;
+}
 

§10. Extracting the stem. A couple of routines to read but not really parse the stem and the bud.

-wording ToPhraseFamily::get_prototype_text(imperative_defn *id) {
+wording ToPhraseFamily::get_prototype_text(imperative_defn *id) {
     if (id->family != TO_PHRASE_EFF_family) return EMPTY_WORDING;
     to_family_data *tfd = RETRIEVE_POINTER_to_family_data(id->family_specific_data);
     return tfd->prototype_text;
 }
 
-void ToPhraseFamily::compile(imperative_defn_family *self,
+void ToPhraseFamily::compile(imperative_defn_family *self,
     int *total_phrases_compiled, int total_phrases_to_compile) {
     Mark To... phrases which have definite kinds for future compilation10.1;
     Throw problems for phrases with return kinds too vaguely defined10.2;
@@ -465,7 +475,7 @@ hand over to the others to generate more work.
 

-void ToPhraseFamily::compile_as_needed(imperative_defn_family *self,
+void ToPhraseFamily::compile_as_needed(imperative_defn_family *self,
     int *total_phrases_compiled, int total_phrases_to_compile) {
     int repeat = TRUE;
     while (repeat) {
@@ -486,6 +496,97 @@ hand over to the others to generate more work.
     }
 }
 
+

§12. A few "To..." phrases have names, and can therefore be used as values in their +own right, a functional-programming sort of device. For example: +

+ +
+

To decide what number is double (N - a number) (this is doubling):

+
+ +

has the name "doubling". Such a name is recorded here: +

+ +
+typedef struct constant_phrase {
+    struct noun *name;
+    struct phrase *phrase_meant;  if known at this point
+    struct kind *cphr_kind;  ditto
+    struct inter_name *cphr_iname;
+    struct wording associated_preamble_text;
+    CLASS_DEFINITION
+} constant_phrase;
+
+
  • The structure constant_phrase is accessed in 3/nuor, 3/dbtr, 3/rpr, 4/ass, 6/tc, 6/tbl, 6/eqt and here.
+

§13. Here we create a new named phrase ("doubling", say): +

+ +
+constant_phrase *ToPhraseFamily::create_constant(wording NW, wording RW) {
+    constant_phrase *cphr = CREATE(constant_phrase);
+    cphr->phrase_meant = NULL;  we won't know until later
+    cphr->cphr_kind = NULL;  nor this
+    cphr->associated_preamble_text = RW;
+    cphr->name = Nouns::new_proper_noun(NW, NEUTER_GENDER, ADD_TO_LEXICON_NTOPT,
+        PHRASE_CONSTANT_MC, Rvalues::from_constant_phrase(cphr), Task::language_of_syntax());
+    cphr->cphr_iname = NULL;
+    return cphr;
+}
+
+

§14. ...and parse for an existing one: +

+ +
+constant_phrase *ToPhraseFamily::parse_constant(wording NW) {
+    if (<s-value>(NW)) {
+        parse_node *spec = <<rp>>;
+        if (Rvalues::is_CONSTANT_construction(spec, CON_phrase)) {
+            constant_phrase *cphr = Rvalues::to_constant_phrase(spec);
+            ToPhraseFamily::kind(cphr);
+            return cphr;
+        }
+    }
+    return NULL;
+}
+
+

§15. As often happens with Inform constants, the kind of a constant phrase can't +be known when its name first comes up, and must be filled in later. (In +particular, before the second traverse many kinds do not yet exist.) So +the following takes a patch-it-later approach. +

+ +
+kind *ToPhraseFamily::kind(constant_phrase *cphr) {
+    if (cphr == NULL) return NULL;
+    if (global_pass_state.pass < 2) return Kinds::binary_con(CON_phrase, K_value, K_value);
+    if (cphr->cphr_kind == NULL) {
+        wording OW = EMPTY_WORDING;
+        ph_type_data phtd = Phrases::TypeData::new();
+        Phrases::TypeData::Textual::parse(&phtd,
+            cphr->associated_preamble_text, &OW);
+        cphr->cphr_kind = Phrases::TypeData::kind(&phtd);
+    }
+    return cphr->cphr_kind;
+}
+
+

§16. And similarly for the phrase structure this name corresponds to. +

+ +
+phrase *ToPhraseFamily::body_of_constant(constant_phrase *cphr) {
+    if (cphr == NULL) internal_error("null cphr");
+    if (cphr->phrase_meant == NULL) {
+        imperative_defn *id;
+        LOOP_OVER(id, imperative_defn) {
+            if (ToPhraseFamily::constant_phrase(id) == cphr) {
+                cphr->phrase_meant = id->body_of_defn;
+                break;
+            }
+        }
+    }
+    return cphr->phrase_meant;
+}
+
diff --git a/docs/core-module/1-cp.html b/docs/core-module/1-cp.html index 11f952e64..48dde19c3 100644 --- a/docs/core-module/1-cp.html +++ b/docs/core-module/1-cp.html @@ -87,6 +87,7 @@ We begin with core itself. enum adjective_meaning_family_CLASS enum application_CLASS enum by_routine_bp_data_CLASS +enum constant_phrase_CLASS enum equivalence_bp_data_CLASS enum explicit_bp_data_CLASS enum generalisation_CLASS @@ -106,6 +107,7 @@ We begin with core itself. DECLARE_CLASS(adjective_meaning) DECLARE_CLASS(adjective_meaning_family) DECLARE_CLASS_ALLOCATED_IN_ARRAYS(application, 100) +DECLARE_CLASS(constant_phrase) DECLARE_CLASS(generalisation) DECLARE_CLASS(by_routine_bp_data) DECLARE_CLASS(equivalence_bp_data) @@ -227,8 +229,7 @@ We begin with core itself.

§5. imperative

-
enum constant_phrase_CLASS
-enum invocation_options_CLASS
+
enum invocation_options_CLASS
 enum local_variable_CLASS
 enum past_tense_action_record_CLASS
 enum past_tense_condition_record_CLASS
@@ -238,10 +239,8 @@ We begin with core itself.
 enum phrase_option_CLASS
 enum pointer_allocation_CLASS
 enum to_phrase_request_CLASS
-enum use_as_event_CLASS
 
-DECLARE_CLASS(constant_phrase)
 DECLARE_CLASS_ALLOCATED_IN_ARRAYS(invocation_options, 100)
 DECLARE_CLASS_ALLOCATED_IN_ARRAYS(local_variable, 100)
 DECLARE_CLASS(past_tense_action_record)
@@ -252,7 +251,6 @@ We begin with core itself.
 DECLARE_CLASS_ALLOCATED_IN_ARRAYS(phrase_option, 100)
 DECLARE_CLASS(pointer_allocation)
 DECLARE_CLASS(to_phrase_request)
-DECLARE_CLASS(use_as_event)
 

§6. runtime

@@ -347,6 +345,7 @@ We begin with core itself. enum release_instructions_CLASS enum scene_CLASS enum spatial_data_CLASS +enum timed_rules_rfd_data_CLASS enum anl_clause_CLASS enum anl_entry_CLASS enum action_pattern_CLASS @@ -380,6 +379,7 @@ We begin with core itself. DECLARE_CLASS(release_instructions) DECLARE_CLASS(scene) DECLARE_CLASS(spatial_data) +DECLARE_CLASS(timed_rules_rfd_data) DECLARE_CLASS_ALLOCATED_IN_ARRAYS(anl_clause, 1000) DECLARE_CLASS_ALLOCATED_IN_ARRAYS(anl_entry, 1000) diff --git a/docs/core-module/1-htc.html b/docs/core-module/1-htc.html index ab1b22995..d4a745b62 100644 --- a/docs/core-module/1-htc.html +++ b/docs/core-module/1-htc.html @@ -369,9 +369,6 @@ so on. Those absolute basics are made here. BENCH(Phrases::Constants::compile_closures) BENCH(RTKinds::compile_structures) BENCH(Rules::check_response_usages) - BENCH(Phrases::Timed::check_for_unused) - BENCH(Phrases::Timed::TimedEventsTable) - BENCH(Phrases::Timed::TimedEventTimesTable) BENCH(RTUseOptions::configure_template) BENCH(RTBibliographicData::IFID_text);
diff --git a/docs/core-module/3-pc.html b/docs/core-module/3-pc.html index e288f3794..a10f7a734 100644 --- a/docs/core-module/3-pc.html +++ b/docs/core-module/3-pc.html @@ -72,7 +72,7 @@ function togglePopup(material_id) {

The interface between the main compiler and its plugins.

-
+

§1. The following set of functions is an API for the main compiler to consult with the plugins; put another way, it is also an API for the plugins to @@ -285,7 +285,18 @@ is now being assigned a value by an explicit assertion sentence. PLUGINS_CALL(VARIABLE_VALUE_NOTIFY_PLUG, q, val); }

-

§16. Influencing values. Called from Rvalues (in values) to allow plugins to help decide whether values +

§16. Called from Rule Family (in assertions) to warn plugins that a new rule +definition has been found in the source text. +

+ +
enum NEW_RULE_DEFN_NOTIFY_PLUG
+
+
+int PluginCalls::new_rule_defn_notify(imperative_defn *id, rule_family_data *rfd) {
+    PLUGINS_CALL(NEW_RULE_DEFN_NOTIFY_PLUG, id, rfd);
+}
+
+

§17. Influencing values. Called from Rvalues (in values) to allow plugins to help decide whether values of the same kind would be equal if evaluated at runtime. For example, the "scenes" plugin uses this to determine if two K_scene constants are equal. To make a decision, set rv to either TRUE or FALSE and return TRUE. @@ -299,7 +310,7 @@ To make no decision, return F PLUGINS_CALL(COMPARE_CONSTANT_PLUG, c1, c2, rv); }

-

§17. Called from Rvalues (in values) to allow plugins to compile rvalues in +

§18. Called from Rvalues (in values) to allow plugins to compile rvalues in eccentric ways of their own: not in fact just for the whimsy of it, but to make it possible for plugins to support base kinds of their own. For example, the "actions" plugin needs this to deal with the "stored action" kind. @@ -312,7 +323,7 @@ the "actions" plugin needs this to deal with the "stored action" kind. PLUGINS_CALL(COMPILE_CONSTANT_PLUG, VH, K, spec); }

-

§18. Called from Conditions (in values) to allow plugins to compile conditions in +

§19. Called from Conditions (in values) to allow plugins to compile conditions in their own way. For example, the "actions" plugin needs this to compile matches of the current action against an action pattern.

@@ -324,7 +335,7 @@ of the current action against an action pattern. PLUGINS_CALL(COMPILE_CONDITION_PLUG, VH, spec); }
-

§19. Called from Specifications (in values) to ask if there is some reason why +

§20. Called from Specifications (in values) to ask if there is some reason why a rule about I1 should be thought broader in scope than one about I2. This is used by the regions plugin when one is a sub-region of the other. This is expected to behave as a strcmp-like sorting function, with a positive @@ -338,7 +349,7 @@ return value saying I1 PLUGINS_CALL(MORE_SPECIFIC_PLUG, I1, I2); }

-

§20. Called from Constants and Descriptions (in values) to give plugins a chance +

§21. Called from Constants and Descriptions (in values) to give plugins a chance to parse text which might otherwise be meaningless (or mean something different) and make it a "composite noun-quantifier" such as "everywhere" or "nothing". The main compiler does not recognise "everywhere" because it has no concept @@ -353,7 +364,7 @@ of space, but the spatial plugin does, and this is how. PLUGINS_CALL(PARSE_COMPOSITE_NQS_PLUG, W, DW, quantifier_used, some_kind); } -

§21. Influencing knowledge. Called from The Model World (in knowledge) to invite the plugin to participate +

§22. Influencing knowledge. Called from The Model World (in knowledge) to invite the plugin to participate in stages I to V of the completion process. This may involve using contextual reasoning to draw further inferences.

@@ -365,7 +376,7 @@ reasoning to draw further inferences. PLUGINS_CALL(COMPLETE_MODEL_PLUG, stage); } -

§22. Called from Inference Subjects (in knowledge) to invite the plugin to +

§23. Called from Inference Subjects (in knowledge) to invite the plugin to create any additional inference subjects it might want to reason about. In practice, this tends to be used to create preliminary subjects to stand in for significant kinds before those kinds are ready to be created. @@ -378,7 +389,7 @@ for significant kinds before those kinds are ready to be created. PLUGINS_CALLV(CREATE_INFERENCE_SUBJECTS_PLUG); } -

§23. Called from Indefinite Appearance (in knowledge) to ask the plugins what +

§24. Called from Indefinite Appearance (in knowledge) to ask the plugins what inferences, if any, to draw from a double-quoted text standing as an entire sentence. The infs is the subject which was being talked about at the time the text was quoted, and therefore presumably is what the text should describe. @@ -391,7 +402,7 @@ the text was quoted, and therefore presumably is what the text should describe. PLUGINS_CALL(DEFAULT_APPEARANCE_PLUG, infs, txt); } -

§24. Called from Inferences (in knowledge) when an inference is drawn about +

§25. Called from Inferences (in knowledge) when an inference is drawn about something. This does not, of course, necessarily mean that this will actually be the property of something: the inference might turn out to be mistaken. The mapping plugin uses this to infer further that if something is said to be a @@ -405,7 +416,7 @@ map connection to somewhere else, then it is probably a room. PLUGINS_CALL(INFERENCE_DRAWN_NOTIFY_PLUG, I, subj); } -

§25. Called from Kind Subjects (in knowledge). Early in the run, before some kinds +

§26. Called from Kind Subjects (in knowledge). Early in the run, before some kinds are created, placeholder inference subjects are created to stand in for them; this call enables plugins to recognise certain texts as referring to those.

@@ -417,7 +428,7 @@ this call enables plugins to recognise certain texts as referring to those. PLUGINS_CALL(NAME_TO_EARLY_INFS_PLUG, W, infs); } -

§26. Called from Kind Subjects (in knowledge) to warn plugins about a new kind, +

§27. Called from Kind Subjects (in knowledge) to warn plugins about a new kind, which in practice enables them to spot from the name that it is actually a kind they want to provide built-in support for: thus the actions plugin reacts to the name "stored action", for example. K is the newcomer, super its super-kind, @@ -433,7 +444,7 @@ source text (such as "container"). PLUGINS_CALL(NEW_BASE_KIND_NOTIFY_PLUG, K, d, W); } -

§27. Called from Instances (in knowledge) to warn plugins that a new instance has +

§28. Called from Instances (in knowledge) to warn plugins that a new instance has been created. For example, the figures plugin needs to know this so that it can see when a new illustration has been created.

@@ -450,7 +461,7 @@ sure you're not dealing with an object. PLUGINS_CALL(NEW_INSTANCE_NOTIFY_PLUG, nc); } -

§28. Called from Property Permissions (in knowledge) to warn plugins that a subject +

§29. Called from Property Permissions (in knowledge) to warn plugins that a subject has been given permission to hold a property; the parsing plugin, for example, uses this to attach a visibility flag.

@@ -462,7 +473,7 @@ uses this to attach a visibility flag. PLUGINS_CALL(NEW_PERMISSION_NOTIFY_PLUG, pp); } -

§29. Called from Properties (in knowledge) to warn plugins that a property has +

§30. Called from Properties (in knowledge) to warn plugins that a property has been created, which they can use to spot properties with special significance to them.

@@ -474,7 +485,7 @@ to them. PLUGINS_CALL(NEW_PROPERTY_NOTIFY_PLUG, prn); } -

§30. Called from Inference Subjects (in knowledge) to warn plugins that a subject +

§31. Called from Inference Subjects (in knowledge) to warn plugins that a subject has been created, which they can use to spot subjects with special significance to them.

@@ -486,7 +497,7 @@ to them. PLUGINS_CALL(NEW_SUBJECT_NOTIFY_PLUG, subj); } -

§31. Called from Nonlocal Variables (in knowledge) to warn plugins that a new +

§32. Called from Nonlocal Variables (in knowledge) to warn plugins that a new variable has been created, which they can use to spot variables with special significance to them.

@@ -498,7 +509,7 @@ significance to them. PLUGINS_CALL(NEW_VARIABLE_NOTIFY_PLUG, q); } -

§32. Called from Instances (in knowledge) to warn plugins that the kind of an +

§33. Called from Instances (in knowledge) to warn plugins that the kind of an instance is about to be set. This happens most often when the instance is created, but can also happen again, refining the kind to a subkind, when the instance is an object. @@ -511,7 +522,7 @@ the instance is an object. PLUGINS_CALL(SET_KIND_NOTIFY_PLUG, I, k); } -

§33. Called from Kind Subjects (in knowledge) when one kind of object is made a +

§34. Called from Kind Subjects (in knowledge) when one kind of object is made a subkind of another, as for example when "container" is a made a subkind of "thing". The plugin should return TRUE if it wishes to forbid this, and if so, it had better throw a problem message, or the user will be @@ -529,7 +540,7 @@ regions plugin does with the "region" kind. PLUGINS_CALL(SET_SUBKIND_NOTIFY_PLUG, sub, super); } -

§34. Influencing the imperative plugin. Called from Rule Bookings (in imperative) to give plugins a chance to move +

§35. Influencing the imperative plugin. Called from Rule Bookings (in imperative) to give plugins a chance to move automatically placed rules from one rulebook to another. The actions plugin uses this to break up what would otherwise be unwieldy before and after rulebooks into smaller ones for each action. @@ -546,7 +557,7 @@ and return TRUE PLUGINS_CALL(PLACE_RULE_PLUG, R, original_owner, new_owner); } -

§35. Called from Rulebooks (in imperative). This is very similar, but runs in all cases, +

§36. Called from Rulebooks (in imperative). This is very similar, but runs in all cases, and not only for automatic placement.

@@ -557,7 +568,7 @@ and not only for automatic placement. PLUGINS_CALL(RULE_PLACEMENT_NOTIFY_PLUG, R, original_owner, side, ref_rule); } -

§36.

+

§37.

enum COMPILE_TEST_HEAD_PLUG
 
@@ -566,7 +577,7 @@ and not only for automatic placement. PLUGINS_CALL(COMPILE_TEST_HEAD_PLUG, ph, R, tests); } -

§37.

+

§38.

enum COMPILE_TEST_TAIL_PLUG
 
@@ -575,7 +586,19 @@ and not only for automatic placement. PLUGINS_CALL(COMPILE_TEST_TAIL_PLUG, ph, R); } -

§38. Influencing the actions plugin. We now have a whole run of functions called only by the actions plugin, and +

§39. Called from Compile Invocations Inline (in imperative), but only when an +annotation arises which the regular machinery doesn't know how to handle. +This is currently only used by Timed Rules (in if). +

+ +
enum INLINE_ANNOTATION_PLUG
+
+
+int PluginCalls::nonstandard_inline_annotation(int annot, parse_node *supplied) {
+    PLUGINS_CALL(INLINE_ANNOTATION_PLUG, annot, supplied);
+}
+
+

§40. Influencing the actions plugin. We now have a whole run of functions called only by the actions plugin, and therefore only when it is active.

@@ -590,7 +613,7 @@ created. For example, the going plugin uses this to spot the arrival of "going". PLUGINS_CALL(NEW_ACTION_NOTIFY_PLUG, an); } -

§39. Called from Action Pattern Clauses (in if) to invite plugins to change the +

§41. Called from Action Pattern Clauses (in if) to invite plugins to change the action pattern clause ID associated with a given action variable. This may be needed in order to cross-reference between multiple such clauses, as with the going action variables. @@ -604,7 +627,7 @@ the going action variables. PLUGINS_CALL(DIVERT_AP_CLAUSE_PLUG, stv, id); } -

§40. Called from Action Pattern Clauses (in if) to ask plugins to print a helpful +

§42. Called from Action Pattern Clauses (in if) to ask plugins to print a helpful name for the debugging log for any new clause ID C which they have created.

@@ -615,7 +638,7 @@ name for the debugging log for any new clause ID PLUGINS_CALL(WRITE_AP_CLAUSE_ID_PLUG, OUT, C); } -

§41. Called from Action Pattern Clauses (in if) to ask for the *_APCA aspect +

§43. Called from Action Pattern Clauses (in if) to ask for the *_APCA aspect for the clause ID C, where C is a new clause ID created by the plugin. If this is not given, then the aspect will be MISC_APCA.

@@ -627,7 +650,7 @@ this is not given, then the aspect will be PLUGINS_CALL(ASPECT_OF_AP_CLAUSE_ID_PLUG, C, A); } -

§42. Called from Action Pattern Clauses (in if) to give plugins a chance to +

§44. Called from Action Pattern Clauses (in if) to give plugins a chance to decide which AP is more specific, on the basis of the extra clauses defined in the plugin.

@@ -651,7 +674,7 @@ to let the usual machinery take its course. PLUGINS_CALL(COMPARE_AP_SPECIFICITY_PLUG, ap1, ap2, rv, ignore_in); } -

§43. Called from Action Pattern Clauses (in if) to notify plugins that a clause +

§45. Called from Action Pattern Clauses (in if) to notify plugins that a clause matching an action variable has just been added to an action pattern.

@@ -662,7 +685,7 @@ matching an action variable has just been added to an action pattern. PLUGINS_CALL(NEW_AP_CLAUSE_PLUG, ap, apoc); } -

§44. Called from Parse Clauses (in if) to give plugins a chance to intervene in +

§46. Called from Parse Clauses (in if) to give plugins a chance to intervene in the normal process of evaluating the meaning of text in an action pattern clause: for example, in parsing "going nowhere", the going plugin uses this to detect that the NOUN_AP_CLAUSE, with text "nowhere", should not be parsed @@ -681,7 +704,7 @@ text of the clause in the normal way. PLUGINS_CALL(PARSE_AP_CLAUSE_PLUG, an, c, bits); } -

§45. Called from Parse Clauses (in if) to give plugins a chance to intervene in +

§47. Called from Parse Clauses (in if) to give plugins a chance to intervene in the type-checking process for a clause. Ordinarily, this would just check that the contents have the right kind: if matching an action variable of kind K then it must be a value compatible with K or a description of such. @@ -699,7 +722,7 @@ or FALSE (it is PLUGINS_CALL(VALIDATE_AP_CLAUSE_PLUG, an, c, outcome); } -

§46. Called from Parse Clauses (in if) to deal with the options bitmap set +

§48. Called from Parse Clauses (in if) to deal with the options bitmap set previously by a PARSE_AP_CLAUSE_PLUG call: see above.

@@ -710,7 +733,7 @@ previously by a PARSE_AP_CLAU PLUGINS_CALL(ACT_ON_ANL_ENTRY_OPTIONS_PLUG, entry, entry_options, fail); } -

§47. Called from Action Patterns (in runtime) when assembling the requirement +

§49. Called from Action Patterns (in runtime) when assembling the requirement clauses for compiling a mattern match; this gives plugins a chance to act extra stipulations, which are not explicit in clauses already in the pattern.

@@ -723,7 +746,7 @@ extra stipulations, which are not explicit in clauses already in the pattern. PLUGINS_CALL(SET_PATTERN_MATCH_REQUIREMENTS_PLUG, ap, cpm, needed, needed_apoc); } -

§48. Called from Action Patterns (in runtime) when compiling any additional +

§50. Called from Action Patterns (in runtime) when compiling any additional requirements set by SET_PATTERN_MATCH_REQUIREMENTS_PLUG.

@@ -735,7 +758,7 @@ requirements set by SET_PATTE PLUGINS_CALL(COMPILE_PATTERN_MATCH_CLAUSE_PLUG, VH, ap, cpmc); } -

§49. Influencing index. Called from Index Physical World (in index) to add something (if it wishes) +

§51. Influencing index. Called from Index Physical World (in index) to add something (if it wishes) to the index description of an instance in the spatial model. For example, the regions plugin uses this to put colour chips next to names of regions.

@@ -747,7 +770,7 @@ the regions plugin uses this to put colour chips next to names of regions. PLUGINS_CALL(ADD_TO_WORLD_INDEX_PLUG, OUT, O); } -

§50. Called from Index Physical World (in index) to add something (if it wishes) +

§52. Called from Index Physical World (in index) to add something (if it wishes) to the textual description of an instance in the spatial model. For example, the mapping plugin uses this to say where a door leads.

diff --git a/docs/if-module/1-im.html b/docs/if-module/1-im.html index 069c75984..2fad16b3d 100644 --- a/docs/if-module/1-im.html +++ b/docs/if-module/1-im.html @@ -167,7 +167,7 @@ nothing except to be a parent to them; it has no activation function. *backdrops_plugin, *bibliographic_plugin, *chronology_plugin, *devices_plugin, *map_plugin, *parsing_plugin, *persons_plugin, *player_plugin, *regions_plugin, *scenes_plugin, *scoring_plugin, *showme_plugin, *spatial_plugin, - *times_plugin; + *timed_rules_plugin, *times_plugin;

§5.

@@ -188,6 +188,7 @@ nothing except to be a parent to them; it has no activation function. regions_plugin = PluginManager::new(&Regions::start, I"regions", ifp); scenes_plugin = PluginManager::new(&Scenes::start, I"scenes", ifp); scoring_plugin = PluginManager::new(&TheScore::start, I"scoring", ifp); + timed_rules_plugin = PluginManager::new(TimedRules::start, I"timed rules", ifp); times_plugin = PluginManager::new(TimesOfDay::start, I"times of day", ifp); actions_plugin = PluginManager::new(&ActionsPlugin::start, I"actions", ifp); diff --git a/docs/if-module/3-bck.html b/docs/if-module/3-bck.html index 03fd9e771..3b820520e 100644 --- a/docs/if-module/3-bck.html +++ b/docs/if-module/3-bck.html @@ -405,7 +405,7 @@ backdrop. } diff --git a/docs/if-module/3-dvc.html b/docs/if-module/3-dvc.html index 6ce846a51..f44518a23 100644 --- a/docs/if-module/3-dvc.html +++ b/docs/if-module/3-dvc.html @@ -117,7 +117,7 @@ is no need to translate this. } diff --git a/docs/if-module/3-enah.html b/docs/if-module/3-enah.html index 872e9668b..4020b04c9 100644 --- a/docs/if-module/3-enah.html +++ b/docs/if-module/3-enah.html @@ -304,7 +304,7 @@ and put the issue aside for now. } diff --git a/docs/if-module/3-mcr.html b/docs/if-module/3-mcr.html index e5bc17725..874822b65 100644 --- a/docs/if-module/3-mcr.html +++ b/docs/if-module/3-mcr.html @@ -337,7 +337,7 @@ such. } diff --git a/docs/if-module/3-prs.html b/docs/if-module/3-prs.html index 8b8bbfa90..cdd049dcf 100644 --- a/docs/if-module/3-prs.html +++ b/docs/if-module/3-prs.html @@ -102,7 +102,7 @@ tomfoolery. } diff --git a/docs/if-module/3-rgn.html b/docs/if-module/3-rgn.html index b4900ead2..4e340b93f 100644 --- a/docs/if-module/3-rgn.html +++ b/docs/if-module/3-rgn.html @@ -450,7 +450,7 @@ to be a region already:
  • This code is used in §17.
diff --git a/docs/if-module/3-scn.html b/docs/if-module/3-scn.html index f60ae1432..c3febf7df 100644 --- a/docs/if-module/3-scn.html +++ b/docs/if-module/3-scn.html @@ -790,7 +790,7 @@ collection of them:
  • This code is used in §26.
diff --git a/docs/if-module/3-si.html b/docs/if-module/3-si.html index 8cc0d1e9d..5c5697b49 100644 --- a/docs/if-module/3-si.html +++ b/docs/if-module/3-si.html @@ -315,7 +315,7 @@ single function to return this: } diff --git a/docs/if-module/3-sm.html b/docs/if-module/3-sm.html index bb5e6cbcc..bc13475b6 100644 --- a/docs/if-module/3-sm.html +++ b/docs/if-module/3-sm.html @@ -1466,7 +1466,7 @@ empty. } diff --git a/docs/if-module/3-sr.html b/docs/if-module/3-sr.html index 99d6b1673..dc5317a6f 100644 --- a/docs/if-module/3-sr.html +++ b/docs/if-module/3-sr.html @@ -388,7 +388,7 @@ special to make it work, so this doesn't seem worth the trouble.) } diff --git a/docs/if-module/3-tm.html b/docs/if-module/3-tm.html index 289670c48..4e131854c 100644 --- a/docs/if-module/3-tm.html +++ b/docs/if-module/3-tm.html @@ -1171,7 +1171,7 @@ why we don't need to compile diff --git a/docs/if-module/3-tp.html b/docs/if-module/3-tp.html index 0677c9ccb..7cee41412 100644 --- a/docs/if-module/3-tp.html +++ b/docs/if-module/3-tp.html @@ -458,7 +458,7 @@ will do. But otherwise:
  • This code is used in §10.
diff --git a/docs/if-module/3-tr.html b/docs/if-module/3-tr.html new file mode 100644 index 000000000..d3179a4a5 --- /dev/null +++ b/docs/if-module/3-tr.html @@ -0,0 +1,275 @@ + + + + Timed Rules + + + + + + + + + + + + + + + + + + + +
+ + +

A plugin to support rules like "At 12:03AM: ...".

+ +

§1. This plugin makes a special set of rules for timed events; the :timedrules +test group may be useful in testing it. +

+ +

Each such rule has a time at which it should spontaneously happen. This is +ordinarily a time of day, such as "At 9:00 AM: ...", represented by a number +from 0 to 1439, measuring minutes since midnight. These negative values have +special significance: +

+ +
define NOT_A_TIMED_EVENT -1  as for the vast majority of rules
+define NO_FIXED_TIME -2  for phrases like "When the clock strikes: ..."
+define NOT_AN_EVENT -3  not even syntactically
+
+
+void TimedRules::start(void) {
+    PluginManager::plug(NEW_RULE_DEFN_NOTIFY_PLUG, TimedRules::new_rule_defn_notify);
+    PluginManager::plug(INLINE_ANNOTATION_PLUG, TimedRules::inline_annotation);
+    PluginManager::plug(PRODUCTION_LINE_PLUG, TimedRules::production_line);
+}
+
+int TimedRules::production_line(int stage, int debugging, stopwatch_timer *sequence_timer) {
+    if (stage == INTER5_CSEQ) {
+        BENCH(TimedRules::check_for_unused)
+        BENCH(RTTimedRules::TimedEventsTable)
+        BENCH(RTTimedRules::TimedEventTimesTable)
+    }
+    return FALSE;
+}
+
+

§2. Event rules are recognised by the initial word "At": +

+ +
+<event-rule-preamble> ::=
+    at <clock-time> |         ==> { pass 1 }
+    at the time when ... |    ==> { NO_FIXED_TIME, - }
+    at the time that ... |    ==> Issue PM_AtTimeThat problem2.1
+    at ...                    ==> Issue PM_AtWithoutTime problem2.2
+
+ +

§2.1. Issue PM_AtTimeThat problem2.1 = +

+ +
+    StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_AtTimeThat),
+        "this seems to use 'that' where it should use 'when'",
+        "assuming it's trying to apply a rule to an event. (The convention is that any "
+        "rule beginning 'At' is a timed one. The time can either be a fixed time, as in "
+        "'At 11:10 AM: ...', or the time when some named event takes place, as in 'At the "
+        "time when the clock chimes: ...'.)");
+
+
  • This code is used in §2.
+

§2.2. Issue PM_AtWithoutTime problem2.2 = +

+ +
+    StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_AtWithoutTime),
+        "'at' what time? No description of a time is given",
+        "which means that this rule can never have effect. (The convention is that any "
+        "rule beginning 'At' is a timed one. The time can either be a fixed time, as in "
+        "'At 11:10 AM: ...', or the time when some named event takes place, as in 'At the "
+        "time when the clock chimes: ...'.)");
+
+
  • This code is used in §2.
+

§3.

+ +
+int TimedRules::new_rule_defn_notify(imperative_defn *id, rule_family_data *rfd) {
+    CREATE_PLUGIN_RFD_DATA(timed_rules, rfd, TimedRules::new_rfd_data);
+    wording W = rfd->usage_preamble;
+    if (<event-rule-preamble>(W)) {
+        int t = <<r>>;
+        rfd->usage_preamble = EMPTY_WORDING;
+        rfd->not_in_rulebook = TRUE;
+        RFD_PLUGIN_DATA(timed_rules, rfd)->event_time = t;
+        if (t == NO_FIXED_TIME) {
+            wording EW = GET_RW(<event-rule-preamble>, 1);
+            EW = Articles::remove_the(EW);
+            RFD_PLUGIN_DATA(timed_rules, rfd)->event_name = EW;
+            rfd->constant_name = EW;
+        }
+    }
+    return FALSE;
+}
+
+

§4. The above therefore attaches one of these to each set of rule data: +

+ +
+typedef struct timed_rules_rfd_data {
+    int event_time;  0 to 1339, or one of the special values above
+    struct wording event_name;  if one is given
+    struct linked_list *uses_as_event;  of parse_node
+    CLASS_DEFINITION
+} timed_rules_rfd_data;
+
+timed_rules_rfd_data *TimedRules::new_rfd_data(rule_family_data *rfd) {
+    timed_rules_rfd_data *trfd = CREATE(timed_rules_rfd_data);
+    trfd->event_time = NOT_A_TIMED_EVENT;
+    trfd->event_name = EMPTY_WORDING;
+    trfd->uses_as_event = NEW_LINKED_LIST(parse_node);
+    return trfd;
+}
+
+
  • The structure timed_rules_rfd_data is private to this section.
+

§5. And that data can be read back with: +

+ +
+linked_list *TimedRules::get_uses_as_event(imperative_defn *id) {
+    if (id->family != rule_idf) return NULL;
+    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
+    return RFD_PLUGIN_DATA(timed_rules, rfd)->uses_as_event;
+}
+
+int TimedRules::get_timing_of_event(imperative_defn *id) {
+    if (id->family != rule_idf) return NOT_A_TIMED_EVENT;
+    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
+    return RFD_PLUGIN_DATA(timed_rules, rfd)->event_time;
+}
+
+wording TimedRules::get_wording_of_event(imperative_defn *id) {
+    if (id->family != rule_idf) return EMPTY_WORDING;
+    rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data);
+    return RFD_PLUGIN_DATA(timed_rules, rfd)->event_name;
+}
+
+

§6. When a rule has no explicit timing, it needs to be triggered by a phrase +like "spawn fresh zombies in 4 turns from now". Here, "spawn fresh zombies" +is the name of the rule. But this has the same kind as any other rule, so +the Dash typechecker is not able to make sure "spawn fresh zombies" is indeed +timed, and not some other rule. +

+ +

We fix this by defining the trigger phrase to use the inline annotation +{-mark-event-used:R} on the rule R. That in turn results in the following +being called: +

+ +
+int TimedRules::inline_annotation(int annot, parse_node *supplied) {
+    if (annot == mark_event_used_ISINC) {
+        if (Rvalues::is_CONSTANT_construction(supplied, CON_rule)) {
+            rule *R = Rvalues::to_rule(supplied);
+            imperative_defn *id = Rules::get_imperative_definition(R);
+            if (id) {
+                int t = TimedRules::get_timing_of_event(id);
+                if (t == NO_FIXED_TIME) {
+                    linked_list *L = TimedRules::get_uses_as_event(id);
+                    ADD_TO_LINKED_LIST(current_sentence, parse_node, L);
+                } else Not an event rule6.1;
+            } else Not an event rule6.1;
+        } else Not an event rule6.1;
+        return TRUE;
+    }
+    return FALSE;
+}
+
+

§6.1. Not an event rule6.1 = +

+ +
+    Problems::quote_source(1, current_sentence);
+    Problems::quote_wording(2, Node::get_text(supplied));
+    StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_NonconstantEvent));
+    Problems::issue_problem_segment(
+        "You wrote %1, but '%2' isn't the name of any timed event that I know of. "
+        "(These need to be set up in a special way, like so - 'At the time when stuff "
+        "happens: ...' creates a timed event called 'stuff happens'.)");
+    Problems::issue_problem_end();
+
+
  • This code is used in §6 (three times).
+

§7. An interesting case where the Problem is arguably only a warning and arguably +shouldn't block compilation. Then again... +

+ +
+void TimedRules::check_for_unused(void) {
+    imperative_defn *id;
+    LOOP_OVER(id, imperative_defn)
+        if (TimedRules::get_timing_of_event(id) == NO_FIXED_TIME)
+            if (LinkedLists::len(TimedRules::get_uses_as_event(id)) == 0) {
+                current_sentence = id->at;
+                StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_UnusedTimedEvent),
+                    "this sets up a timed event which is never used",
+                    "since you never use any of the phrases which could cause it. (A timed "
+                    "event is just a name, and it needs other instructions elsewhere before "
+                    "it can have any effect.)");
+            }
+}
+
+ + +
+ + + diff --git a/docs/if-module/3-ts.html b/docs/if-module/3-ts.html index 4451cef94..8bf0a56a9 100644 --- a/docs/if-module/3-ts.html +++ b/docs/if-module/3-ts.html @@ -173,7 +173,7 @@ be the score corresponding to successful completion and the highest rank. } diff --git a/docs/if-module/4-ap2.html b/docs/if-module/4-ap2.html index 420d5e746..f9da908c6 100644 --- a/docs/if-module/4-ap2.html +++ b/docs/if-module/4-ap2.html @@ -193,11 +193,22 @@ of the text they came from; for which, see }
} -

§6. This simple parser converts text to a parametric AP of kind K. The parser -for action-based APs is very much more complicated: see Parse Action Patterns. +

§6. These functions are used when parsing rule applicability:

+action_pattern *ActionPatterns::parse_action_based(wording W) {
+    action_pattern *ap = NULL;
+    int saved = ParseActionPatterns::enter_mode(PERMIT_TRYING_OMISSION);
+    if (Rules::all_action_processing_variables())
+        Frames::set_stvol(
+            Frames::current_stack_frame(), Rules::all_action_processing_variables());
+    if (<action-pattern>(W)) ap = <<rp>>;
+    Frames::remove_nonphrase_stack_frame();
+    ParseActionPatterns::restore_mode(saved);
+    return ap;
+}
+
 action_pattern *ActionPatterns::parse_parametric(wording W, kind *K) {
     parse_node *spec = NULL;
     if (<s-ap-parameter>(W)) spec = <<rp>>;
diff --git a/docs/if-module/4-pap.html b/docs/if-module/4-pap.html
index 528af8b4e..fc1b0a5a1 100644
--- a/docs/if-module/4-pap.html
+++ b/docs/if-module/4-pap.html
@@ -119,7 +119,7 @@ rigged always to fail.
 
 int parse_action_pattern_mode = 0;
 
-int ParseActionPatterns::enter_mode(int pm) {
+int ParseActionPatterns::enter_mode(int pm) {
     int was = parse_action_pattern_mode;
     parse_action_pattern_mode |= pm;
     return was;
@@ -132,7 +132,7 @@ rigged always to fail.
     return was;
 }
 
-void ParseActionPatterns::restore_mode(int saved) {
+void ParseActionPatterns::restore_mode(int saved) {
     parse_action_pattern_mode = saved;
 }
 
diff --git a/docs/if-module/index.html b/docs/if-module/index.html index 3a3725fc7..4512c88ac 100644 --- a/docs/if-module/index.html +++ b/docs/if-module/index.html @@ -171,6 +171,11 @@ Map Connection Relations - To define one binary predicate for each map direction, such as "mapped north of".

+
  • +

    + Timed Rules - + A plugin to support rules like "At 12:03AM: ...".

    +
  • Scenes - diff --git a/docs/imperative-module/1-im.html b/docs/imperative-module/1-im.html index 26c768767..bfce8c4f8 100644 --- a/docs/imperative-module/1-im.html +++ b/docs/imperative-module/1-im.html @@ -88,7 +88,7 @@ which use this module: COMPILE_WRITER(parse_node *, Invocations::log) COMPILE_WRITER(ph_type_data *, Phrases::TypeData::Textual::log) COMPILE_WRITER(local_variable *, LocalVariables::log) -COMPILE_WRITER(phrase *, Phrases::log) +COMPILE_WRITER(phrase *, Phrases::log) void ImperativeModule::start(void) { Writers::register_writer('L', &LocalVariables::writer); @@ -96,7 +96,7 @@ which use this module: REGISTER_WRITER('e', Invocations::log); REGISTER_WRITER('h', Phrases::TypeData::Textual::log); REGISTER_WRITER('k', LocalVariables::log); - REGISTER_WRITER('R', Phrases::log); + REGISTER_WRITER('R', Phrases::log); Memory::reason_name(INV_LIST_MREASON, "lists for type-checking invocations"); Log::declare_aspect(DESCRIPTION_COMPILATION_DA, L"description compilation", FALSE, FALSE); Log::declare_aspect(EXPRESSIONS_DA, L"expressions", FALSE, FALSE); diff --git a/docs/imperative-module/2-act.html b/docs/imperative-module/2-act.html index 4f2d8a841..be051f9d6 100644 --- a/docs/imperative-module/2-act.html +++ b/docs/imperative-module/2-act.html @@ -92,7 +92,7 @@ and a shared set of variables, so this will not be a long section of code. CLASS_DEFINITION } activity;

  • -
    • The structure activity is accessed in 2/rls, 2/rlb, 2/fao, 3/prcd, 3/po, 3/pav, 4/sv, 6/cii, 6/cste and here.
    +
    • The structure activity is accessed in 2/rls, 2/rlb, 2/fao, 3/prcd, 3/po, 4/sv, 6/cii, 6/cste and here.

    §2. Whereas rulebooks can turn values into other values, activities are more like void functions: they work on a value, but produce nothing.

    diff --git a/docs/imperative-module/2-fao.html b/docs/imperative-module/2-fao.html index ede0eba7c..ac6f5a304 100644 --- a/docs/imperative-module/2-fao.html +++ b/docs/imperative-module/2-fao.html @@ -170,7 +170,7 @@ structures rulebook_outcome and
    CLASS_DEFINITION } named_rulebook_outcome; -
    • The structure named_rulebook_outcome is accessed in 2/rls, 2/act, 3/po, 3/pav, 4/sv, 6/cii, 6/cste and here.
    +
    • The structure named_rulebook_outcome is accessed in 2/rls, 2/act, 3/po, 4/sv, 6/cii, 6/cste and here.

    §5. That awkward distinction between a rulebook_outcome and a named_rulebook_outcome brings us edge cases if a rule has been written for use in one rulebook, but then has been explicitly listed in another, or is more than one rulebook. diff --git a/docs/imperative-module/2-rls.html b/docs/imperative-module/2-rls.html index c29e1cc89..a35be068d 100644 --- a/docs/imperative-module/2-rls.html +++ b/docs/imperative-module/2-rls.html @@ -124,7 +124,7 @@ different dynamics altogether. In short, then: rules are not phrases. CLASS_DEFINITION } rule; -

    • The structure rule is accessed in 2/rlb, 2/fao, 2/act, 3/prcd, 3/po, 3/pav, 4/sv, 6/cii, 6/cste and here.
    +
    • The structure rule is accessed in 2/rlb, 2/fao, 2/act, 3/prcd, 3/po, 4/sv, 6/cii, 6/cste and here.

    §2. Rules are created before their definitions can be parsed or compiled. A typical rule like so:

    @@ -320,9 +320,10 @@ of a phrase as follows:
     void Rules::set_imperative_definition(rule *R, imperative_defn *id) {
         R->defn_as_I7_source = id;
    +    RTRules::prepare_rule(id, R);
     }
     
    -imperative_defn *Rules::get_imperative_definition(rule *R) {
    +imperative_defn *Rules::get_imperative_definition(rule *R) {
         if (R == NULL) return NULL;
         return R->defn_as_I7_source;
     }
    @@ -651,7 +652,7 @@ possibility we store one of these:
         return R->responses[code].used;
     }
     
    -
    • The structure rule_response is accessed in 3/prcd and here.
    +
    • The structure rule_response is private to this section.

    §21. When a response is defined in the body of a rule, the message is created with Rules::set_response:

    diff --git a/docs/imperative-module/3-dptd.html b/docs/imperative-module/3-dptd.html index 91491c21e..510cd1565 100644 --- a/docs/imperative-module/3-dptd.html +++ b/docs/imperative-module/3-dptd.html @@ -119,7 +119,7 @@ The debugging log is simple:

    -void Phrases::TypeData::Textual::log_briefly(ph_type_data *phtd) {
    +void Phrases::TypeData::Textual::log_briefly(ph_type_data *phtd) {
         if (phtd == NULL) { LOG("NULL-PHTD"); return; }
         LOG("\"%W\"", phtd->registration_text);
         switch(phtd->manner_of_return) {
    @@ -142,7 +142,7 @@ match is shown.
     define INDEX_PHRASE_FORMAT 2  a simpler version good enough for most purposes
     
    -void Phrases::TypeData::Textual::write_HTML_representation(OUTPUT_STREAM,
    +void Phrases::TypeData::Textual::write_HTML_representation(OUTPUT_STREAM,
         ph_type_data *phtd, int paste_format, parse_node *inv) {
     
         int seq_from = 0, seq_to = phtd->no_words;
    @@ -304,9 +304,9 @@ match is shown.
         phrase *ph = Node::get_phrase_invoked(inv);
         if (ph) {
             ph_type_data *phtd = &(ph->type_data);
    -        if (Wordings::nonempty(ph->ph_documentation_symbol)) {
    +        if (Wordings::nonempty(ToPhraseFamily::doc_ref(ph->from))) {
                 TEMPORARY_TEXT(pds)
    -            WRITE_TO(pds, "%+W", Wordings::one_word(Wordings::first_wn(ph->ph_documentation_symbol)));
    +            WRITE_TO(pds, "%+W", Wordings::one_word(Wordings::first_wn(ToPhraseFamily::doc_ref(ph->from))));
                 Index::DocReferences::link_to(OUT, pds, -1);
                 DISCARD_TEXT(pds)
             } else
    @@ -329,7 +329,7 @@ match is shown.
     void Phrases::TypeData::Textual::write_index_representation(OUTPUT_STREAM, ph_type_data *phtd, phrase *ph) {
         if (phtd->manner_of_return == DECIDES_CONDITION_MOR)
             WRITE("<i>if</i> ");
    -    Phrases::write_HTML_representation(OUT, ph, INDEX_PHRASE_FORMAT);
    +    Phrases::write_HTML_representation(OUT, ph, INDEX_PHRASE_FORMAT);
         if (phtd->return_kind == NULL) {
             if (phtd->manner_of_return == DECIDES_CONDITION_MOR) WRITE("<i>:</i>");
         } else {
    @@ -368,7 +368,7 @@ This is the routine which prints those details.
     
     
         TEMPORARY_TEXT(TEMP)
    -    Phrases::write_HTML_representation(TEMP, ph, PASTE_PHRASE_FORMAT);
    +    Phrases::write_HTML_representation(TEMP, ph, PASTE_PHRASE_FORMAT);
         PasteButtons::paste_text(OUT, TEMP);
         DISCARD_TEXT(TEMP)
         WRITE("&nbsp;");
    @@ -382,10 +382,10 @@ of course.
     

    -    if (Wordings::nonempty(ph->ph_documentation_symbol)) {
    +    if (Wordings::nonempty(ToPhraseFamily::doc_ref(ph->from))) {
             HTML_CLOSE("p");
             TEMPORARY_TEXT(pds)
    -        WRITE_TO(pds, "%+W", Wordings::one_word(Wordings::first_wn(ph->ph_documentation_symbol)));
    +        WRITE_TO(pds, "%+W", Wordings::one_word(Wordings::first_wn(ToPhraseFamily::doc_ref(ph->from))));
             Index::DocReferences::doc_fragment(OUT, pds);
             HTML_OPEN("p"); WRITE("<b>See</b> ");
             Index::DocReferences::fully_link(OUT, pds);
    @@ -490,7 +490,7 @@ correctly set.
     

    -void Phrases::TypeData::Textual::parse(ph_type_data *phtd, wording XW, wording *OW) {
    +void Phrases::TypeData::Textual::parse(ph_type_data *phtd, wording XW, wording *OW) {
         int say_flag = FALSE;  is this going to be a "say" phrase?
     
         if (Wordings::nonempty(XW)) XW = Phrases::TypeData::Textual::phtd_parse_return_data(phtd, XW);              trim return data from the front
    @@ -716,7 +716,7 @@ haven't yet been parsed, so that we don't yet know it will be meaningful.
     
     
     int no_truth_state_returns = 0;
    -wording Phrases::TypeData::Textual::phtd_parse_return_data(ph_type_data *phtd, wording XW) {
    +wording Phrases::TypeData::Textual::phtd_parse_return_data(ph_type_data *phtd, wording XW) {
         phtd->return_kind = NULL;
         if (<to-return-data>(XW)) {
             XW = GET_RW(<to-return-data>, 1);
    @@ -749,7 +749,7 @@ preamble word range backwards — it returns the current last word number.
     

    -wording Phrases::TypeData::Textual::phtd_parse_doodads(ph_type_data *phtd, wording W, int *say_flag) {
    +wording Phrases::TypeData::Textual::phtd_parse_doodads(ph_type_data *phtd, wording W, int *say_flag) {
         <<operation>> = -1; <<assignment>> = FALSE; <<deprecated>> = FALSE; <<run-on>> = FALSE;
         <phrase-preamble>(W);  guaranteed to match any non-empty text
         if (<<r>> == SAY_ANN) W = GET_RW(<say-preamble>, 1);
    @@ -979,7 +979,7 @@ form the word and token sequences:
     

    -void Phrases::TypeData::Textual::phtd_parse_word_sequence(ph_type_data *phtd) {
    +void Phrases::TypeData::Textual::phtd_parse_word_sequence(ph_type_data *phtd) {
         phtd->no_tokens = 0;
         phtd->no_words = 0;
     
    @@ -1184,7 +1184,7 @@ such as "list of numbers", it returns 0.)
     

    -int Phrases::TypeData::Textual::find_kind_variable_domains(kind *K, int *usages, kind **declarations) {
    +int Phrases::TypeData::Textual::find_kind_variable_domains(kind *K, int *usages, kind **declarations) {
         int t = 0;
         if (K) {
             int N = Kinds::get_variable_number(K);
    @@ -1236,7 +1236,7 @@ in exactly one place: for example,
     
    • This code is used in §21.
    diff --git a/docs/imperative-module/3-itp.html b/docs/imperative-module/3-itp.html index f28355945..13b7a7a3b 100644 --- a/docs/imperative-module/3-itp.html +++ b/docs/imperative-module/3-itp.html @@ -228,7 +228,7 @@ significant timing difficulties.

    diff --git a/docs/imperative-module/3-pav.html b/docs/imperative-module/3-pav.html deleted file mode 100644 index b89bb6d07..000000000 --- a/docs/imperative-module/3-pav.html +++ /dev/null @@ -1,323 +0,0 @@ - - - - Phrases as Values - - - - - - - - - - - - - - - - - - -
    - - -

    To provide the names of phrases as first-class values.

    - -

    §1. A few "To..." phrases have names, and can therefore be used as values in their -own right, a functional-programming sort of device. For example: -

    - -
    -

    To decide what number is double (N - a number) (this is doubling):

    -
    - -

    has the name "doubling". Such a name is recorded here: -

    - -
    -typedef struct constant_phrase {
    -    struct noun *name;
    -    struct phrase *phrase_meant;  if known at this point
    -    struct kind *cphr_kind;  ditto
    -    struct inter_name *cphr_iname;
    -    struct wording associated_preamble_text;
    -    CLASS_DEFINITION
    -} constant_phrase;
    -
    -
    • The structure constant_phrase is accessed in 2/rls, 2/fao, 2/act, 3/po, 4/sv, 6/cii, 6/cste and here.
    -

    §2. Here we create a new named phrase ("doubling", say): -

    - -
    -constant_phrase *Phrases::Constants::create(wording NW, wording RW) {
    -    constant_phrase *cphr = CREATE(constant_phrase);
    -    cphr->phrase_meant = NULL;  we won't know until later
    -    cphr->cphr_kind = NULL;  nor this
    -    cphr->associated_preamble_text = RW;
    -    cphr->name = Nouns::new_proper_noun(NW, NEUTER_GENDER, ADD_TO_LEXICON_NTOPT,
    -        PHRASE_CONSTANT_MC, Rvalues::from_constant_phrase(cphr), Task::language_of_syntax());
    -    cphr->cphr_iname = NULL;
    -    return cphr;
    -}
    -
    -

    §3. ...and parse for an existing one: -

    - -
    -constant_phrase *Phrases::Constants::parse(wording NW) {
    -    if (<s-value>(NW)) {
    -        parse_node *spec = <<rp>>;
    -        if (Rvalues::is_CONSTANT_construction(spec, CON_phrase)) {
    -            constant_phrase *cphr = Rvalues::to_constant_phrase(spec);
    -            Phrases::Constants::kind(cphr);
    -            return cphr;
    -        }
    -    }
    -    return NULL;
    -}
    -
    -

    §4. As often happens with Inform constants, the kind of a constant phrase can't -be known when its name first comes up, and must be filled in later. (In -particular, before the second traverse many kinds do not yet exist.) So -the following takes a patch-it-later approach. -

    - -
    -kind *Phrases::Constants::kind(constant_phrase *cphr) {
    -    if (cphr == NULL) return NULL;
    -    if (global_pass_state.pass < 2) return Kinds::binary_con(CON_phrase, K_value, K_value);
    -    if (cphr->cphr_kind == NULL) {
    -        wording OW = EMPTY_WORDING;
    -        ph_type_data phtd = Phrases::TypeData::new();
    -        Phrases::TypeData::Textual::parse(&phtd,
    -            cphr->associated_preamble_text, &OW);
    -        cphr->cphr_kind = Phrases::TypeData::kind(&phtd);
    -    }
    -    return cphr->cphr_kind;
    -}
    -
    -

    §5. And similarly for the phrase structure this name corresponds to. -

    - -
    -phrase *Phrases::Constants::as_phrase(constant_phrase *cphr) {
    -    if (cphr == NULL) internal_error("null cphr");
    -    if (cphr->phrase_meant == NULL) {
    -        imperative_defn *id;
    -        LOOP_OVER(id, imperative_defn) {
    -            if (ToPhraseFamily::constant_phrase(id) == cphr) {
    -                cphr->phrase_meant = id->body_of_defn;
    -                break;
    -            }
    -        }
    -    }
    -    return cphr->phrase_meant;
    -}
    -
    -

    §6. So much for setting up constant phrases. Now we come to compilation, and -a surprise. It might be expected that a constant phrase compiles simply to -an I6 routine name, but no: it compiles to a small array called a "closure". -

    - -
    -inter_name *Phrases::Constants::compile(constant_phrase *cphr) {
    -    phrase *ph = Phrases::Constants::as_phrase(cphr);
    -    if (ph == NULL) internal_error("cannot reconstruct phrase from cphr");
    -    if (Phrases::compiled_inline(ph) == FALSE)
    -        Routines::ToPhrases::make_request(ph,
    -            Phrases::Constants::kind(cphr), NULL, EMPTY_WORDING);
    -    return Phrases::Constants::iname(cphr);
    -}
    -
    -inter_name *Phrases::Constants::iname(constant_phrase *cphr) {
    -    if (cphr->cphr_iname == NULL) {
    -        phrase *ph = Phrases::Constants::as_phrase(cphr);
    -        if (ph == NULL) internal_error("cannot reconstruct phrase from cphr");
    -        package_request *P = Hierarchy::package_within(CLOSURES_HAP, ph->requests_package);
    -        cphr->cphr_iname = Hierarchy::make_iname_in(CLOSURE_DATA_HL, P);
    -    }
    -    return cphr->cphr_iname;
    -}
    -
    -

    §7. And this is where those arrays are made: -

    - -
    -void Phrases::Constants::compile_closures(void) {
    -    constant_phrase *cphr;
    -    LOOP_OVER(cphr, constant_phrase) {
    -        phrase *ph = Phrases::Constants::as_phrase(cphr);
    -        if (ph == NULL) internal_error("cannot reconstruct phrase from cphr");
    -        Phrases::Constants::kind(cphr);
    -        Compile the closure array for this constant phrase7.1;
    -    }
    -}
    -
    -

    §7.1. The closure array consists of three words: the strong kind ID, the address -of the routine, and the text of the name. (The latter enables us to print -phrase values efficiently.) Note that we make a compilation request for the -phrase in order to make sure somebody has actually compiled it: this is in -case the phrase occurs as a constant but is never explicitly invoked. -

    - -

    Compile the closure array for this constant phrase7.1 = -

    - -
    -    inter_name *iname = Phrases::Constants::iname(cphr);
    -    packaging_state save = Emit::named_array_begin(iname, K_value);
    -
    -    RTKinds::emit_strong_id(cphr->cphr_kind);
    -
    -    inter_name *RS = Routines::ToPhrases::make_iname(ph,
    -        Phrases::Constants::kind(cphr));
    -    Emit::array_iname_entry(RS);
    -
    -    TEMPORARY_TEXT(name)
    -    WRITE_TO(name, "%W", Nouns::nominative_singular(cphr->name));
    -    Emit::array_text_entry(name);
    -    DISCARD_TEXT(name)
    -
    -    Emit::array_end(save);
    -
    -
    • This code is used in §7.
    -

    §8. Now we come to something trickier. We want default values for kinds of phrases, -because otherwise we can't have variables holding phrases unless they are -always initialised explicitly, and so on. Clearly the default value for a -phrase to nothing is one that does nothing, and for a phrase to some kind K -is one that returns the default value of kind K. For example, the default -value of -

    - -
    -    phrase (text, time) -> number
    -
    -

    is the function which takes any pair of a text and a time, does nothing with -them, and always returns 0. But this means we need to actually compile such -routines. Since there are in principle an infinite number of distinct phrase -kinds, we will only compile them for the phrase kinds which arise during -compilation. -

    - -
    -void Phrases::Constants::compile_default_closure(inter_name *closure_identifier, kind *K) {
    -    package_request *P = Kinds::Behaviour::package(K);
    -    inter_name *rname = Hierarchy::make_iname_in(DEFAULT_CLOSURE_FN_HL, P);
    -
    -    Compile the default routine8.2;
    -    Compile the default closure8.1;
    -}
    -
    -

    §8.1. This must have exactly the same three-word form as the closure arrays -made above. -

    - -

    Compile the default closure8.1 = -

    - -
    -    packaging_state save = Emit::named_array_begin(closure_identifier, K_value);
    -    RTKinds::emit_strong_id(K);
    -    Emit::array_iname_entry(rname);
    -    TEMPORARY_TEXT(DVT)
    -    WRITE_TO(DVT, "default value of "); Kinds::Textual::write(DVT, K);
    -    Emit::array_text_entry(DVT);
    -    DISCARD_TEXT(DVT)
    -    Emit::array_end(save);
    -
    -
    • This code is used in §8.
    -

    §8.2. And here is the function that refers to: -

    - -

    Compile the default routine8.2 = -

    - -
    -    packaging_state save = Routines::begin(rname);
    -    LocalVariables::add_named_call(I"a");
    -    LocalVariables::add_named_call(I"b");
    -    LocalVariables::add_named_call(I"c");
    -    LocalVariables::add_named_call(I"d");
    -    LocalVariables::add_named_call(I"e");
    -    LocalVariables::add_named_call(I"f");
    -    LocalVariables::add_named_call(I"g");
    -    LocalVariables::add_named_call(I"h");
    -    kind *result = NULL;
    -    Kinds::binary_construction_material(K, NULL, &result);
    -    if (Kinds::get_construct(result) != CON_NIL) {
    -        Produce::inv_primitive(Emit::tree(), RETURN_BIP);
    -        Produce::down(Emit::tree());
    -
    -        if (Kinds::Behaviour::uses_pointer_values(result)) {
    -            inter_name *iname = Hierarchy::find(BLKVALUECREATE_HL);
    -            Produce::inv_call_iname(Emit::tree(), iname);
    -            Produce::down(Emit::tree());
    -            RTKinds::emit_strong_id_as_val(result);
    -            Produce::up(Emit::tree());
    -        } else {
    -            if (RTKinds::emit_default_value_as_val(result, EMPTY_WORDING, NULL) != TRUE)
    -                Produce::val(Emit::tree(), K_number, LITERAL_IVAL, 0);
    -        }
    -
    -        Produce::up(Emit::tree());
    -    }
    -    Routines::end(save);
    -
    -
    • This code is used in §8.
    - - -
    - - - diff --git a/docs/imperative-module/3-phr.html b/docs/imperative-module/3-phr.html index 570f578ad..65232e3c0 100644 --- a/docs/imperative-module/3-phr.html +++ b/docs/imperative-module/3-phr.html @@ -73,7 +73,7 @@ function togglePopup(material_id) {

    To create one |phrase| object for each phrase declaration in the source text.

    -
    +

    §1. As noted in the introduction to this chapter, a phrase structure is created for each "To..." definition and each rule in the source text. It is @@ -111,7 +111,6 @@ code below. struct inter_schema *inter_tail_defn; inline definition translated to inter, if possible int inter_defn_converted; has this been tried yet? int inline_mor; manner of return for inline I6 definition, or UNKNOWN_NT - struct wording ph_documentation_symbol; cross-reference with documentation struct compilation_unit *owning_module; struct package_request *requests_package; @@ -132,7 +131,7 @@ code below. CLASS_DEFINITION } phrase;

    -
    • The structure phrase is accessed in 2/rls, 2/rb, 3/prcd, 3/ptd, 3/dptd, 3/po, 3/pav, 3/tph, 3/tp, 6/inv, 6/pi, 6/ci, 6/cii, 6/cp, 6/cste and here.
    +
    • The structure phrase is accessed in 2/rls, 2/rb, 3/prcd, 3/ptd, 3/dptd, 3/po, 3/tph, 6/inv, 6/pi, 6/ci, 6/cii, 6/cp, 6/cste and here.

    §4. "To..." phrases, though no others, are listed in logical precedence order:

    @@ -154,8 +153,6 @@ invocation which is given as verbatim I6. internal_error("a phrase preamble should be at a IMPERATIVE_NT node"); int inline_wn = -1; the word number of an inline I6 definition if any int mor = DONT_KNOW_MOR; and its manner of return - wording OW = EMPTY_WORDING; the text of the phrase options, if any - wording documentation_W = EMPTY_WORDING; the documentation reference, if any Look for an inline definition5.1; @@ -167,8 +164,8 @@ invocation which is given as verbatim I6. if ((inline_wn >= 0) && (ImperativeDefinitionFamilies::allows_inline(id) == FALSE)) Inline is for To... phrases only5.7; - Construct the PHTD, find the phrase options, find the documentation reference5.2; - Construct the PHOD5.3; + Construct the PHOD5.2; + Construct the PHTD, find the phrase options, find the documentation reference5.3; Construct the PHSF, using the PHTD and PHOD5.4; Construct the PHRCD5.5; @@ -191,22 +188,19 @@ invocation which is given as verbatim I6. }
    • This code is used in §5.
    -

    §5.2. Construct the PHTD, find the phrase options, find the documentation reference5.2 = +

    §5.2. Construct the PHOD5.2 =

    -    wording XW = ToPhraseFamily::get_prototype_text(id);
    -    documentation_W = Index::DocReferences::position_of_symbol(&XW);
    -    phtd = Phrases::TypeData::new();
    -    if (inline_wn >= 0) Phrases::TypeData::make_inline(&phtd);
    -    ImperativeDefinitionFamilies::to_phtd(id, &phtd, XW, &OW);
    +    phod = Phrases::Options::new(EMPTY_WORDING);
     
    • This code is used in §5.
    -

    §5.3. Construct the PHOD5.3 = +

    §5.3. Construct the PHTD, find the phrase options, find the documentation reference5.3 =

    -    phod = Phrases::Options::parse_declared_options(OW);
    +    phtd = Phrases::TypeData::new();
    +    if (inline_wn >= 0) Phrases::TypeData::make_inline(&phtd);
     
    • This code is used in §5.

    §5.4. The stack frame needs to know the kind of this phrase — something like @@ -226,10 +220,6 @@ inline definitions.

         phsf = Frames::new();
    -    Phrases::TypeData::into_stack_frame(&phsf, &phtd,
    -        Phrases::TypeData::kind(&phtd), TRUE);
    -    if (Phrases::Options::allows_options(&phod))
    -        LocalVariables::options_parameter_is_needed(&phsf);
     
    • This code is used in §5.

    §5.5. Construct the PHRCD5.5 = @@ -272,8 +262,6 @@ inline definitions. new_ph->next_in_logical_order = NULL; new_ph->sequence_count = -1; - - new_ph->ph_documentation_symbol = documentation_W;

    • This code is used in §5.

    §5.1.1. That just leaves two problem messages about inline definitions: @@ -341,20 +329,30 @@ what number is...", for instance. if (<inline-phrase-definition>(W)) { *wn = <<inlinecode>>; *mor = <<r>>; } }

    -

    §8. Miscellaneous. That completes the process of creation. Here's how we log them: +

    §8.

    + +
    +void Phrases::prepare_stack_frame(phrase *body) {
    +    Phrases::TypeData::into_stack_frame(&(body->stack_frame), &(body->type_data),
    +        Phrases::TypeData::kind(&(body->type_data)), TRUE);
    +    if (Phrases::Options::allows_options(&(body->options_data)))
    +        LocalVariables::options_parameter_is_needed(&(body->stack_frame));
    +}
    +
    +

    §9. Miscellaneous. That completes the process of creation. Here's how we log them:

     void Phrases::log(phrase *ph) {
         if (ph == NULL) { LOG("RULE:NULL"); return; }
    -    LOG("%n", Phrases::iname(ph));
    +    LOG("%n", Phrases::iname(ph));
     }
     
     void Phrases::log_briefly(phrase *ph) {
         Phrases::TypeData::Textual::log_briefly(&(ph->type_data));
     }
     
    -

    §9. Relatedly, for indexing purposes: +

    §10. Relatedly, for indexing purposes:

    @@ -362,11 +360,11 @@ what number is...", for instance.
         Phrases::TypeData::Textual::write_HTML_representation(OUT, &(ph->type_data), format, NULL);
     }
     
    -

    §10. Some access functions: +

    §11. Some access functions:

    -int Phrases::compiled_inline(phrase *ph) {
    +int Phrases::compiled_inline(phrase *ph) {
         if (ph->inline_wn < 0) return FALSE;
         return TRUE;
     }
    @@ -380,7 +378,7 @@ what number is...", for instance.
     inter_schema *Phrases::get_inter_head(phrase *ph) {
         if (ph->inter_defn_converted == FALSE) {
             if (ph->inline_wn >= 0) {
    -            InterSchemas::from_inline_phrase_definition(Phrases::get_inline_definition(ph), &(ph->inter_head_defn), &(ph->inter_tail_defn));
    +            InterSchemas::from_inline_phrase_definition(Phrases::get_inline_definition(ph), &(ph->inter_head_defn), &(ph->inter_tail_defn));
             }
             ph->inter_defn_converted = TRUE;
         }
    @@ -390,14 +388,14 @@ what number is...", for instance.
     inter_schema *Phrases::get_inter_tail(phrase *ph) {
         if (ph->inter_defn_converted == FALSE) {
             if (ph->inline_wn >= 0) {
    -            InterSchemas::from_inline_phrase_definition(Phrases::get_inline_definition(ph), &(ph->inter_head_defn), &(ph->inter_tail_defn));
    +            InterSchemas::from_inline_phrase_definition(Phrases::get_inline_definition(ph), &(ph->inter_head_defn), &(ph->inter_tail_defn));
             }
             ph->inter_defn_converted = TRUE;
         }
         return ph->inter_tail_defn;
     }
     
    -inter_name *Phrases::iname(phrase *ph) {
    +inter_name *Phrases::iname(phrase *ph) {
         if (ph->ph_iname == NULL) {
             package_request *PR = Hierarchy::package(ph->owning_module, ADJECTIVE_PHRASES_HAP);
             ph->ph_iname = Hierarchy::make_iname_in(DEFINITION_FN_HL, PR);
    @@ -409,7 +407,7 @@ what number is...", for instance.
         return ph->from->at;
     }
     
    -

    §11. Compilation. The following is called to give us an opportunity to compile a routine defining +

    §12. Compilation. The following is called to give us an opportunity to compile a routine defining a phrase. As was mentioned in the introduction, "To..." phrases are sometimes compiled multiple times, for different kinds of tokens, and are compiled in response to "requests". All other phrases are compiled just once. @@ -425,11 +423,11 @@ response to "requests". All other phrases are compiled just once. if (ph->imported) return; if ((req) || (ph->at_least_one_compiled_form_needed)) { Routines::Compile::routine(ph, legible, req, R); - Move along the progress bar if it's this phrase's first compilation11.1; + Move along the progress bar if it's this phrase's first compilation12.1; } }

    -

    §11.1. Move along the progress bar if it's this phrase's first compilation11.1 = +

    §12.1. Move along the progress bar if it's this phrase's first compilation12.1 =

    @@ -439,8 +437,8 @@ response to "requests". All other phrases are compiled just once.
             ProgressBar::update(4, ((float) (*i))/((float) max_i));
         }
     
    -
    • This code is used in §11.
    -

    §12. Basic mode main.

    +
    • This code is used in §12.
    +

    §13. Basic mode main.

     void Phrases::invoke_to_begin(void) {
    @@ -458,7 +456,7 @@ response to "requests". All other phrases are compiled just once.
                             "and in Basic mode, Inform expects to see exactly one of "
                             "these, specifying where execution should begin.");
                     } else {
    -                    if (Phrases::compiled_inline(ph)) {
    +                    if (Phrases::compiled_inline(ph)) {
                             StandardProblems::sentence_problem(Task::syntax_tree(), _p_(...),
                                 "the 'to begin' phrase seems to be defined inline",
                                 "which in Basic mode is not allowed.");
    @@ -485,7 +483,7 @@ response to "requests". All other phrases are compiled just once.
     }
     
    diff --git a/docs/imperative-module/3-po.html b/docs/imperative-module/3-po.html index fa7288705..086c74368 100644 --- a/docs/imperative-module/3-po.html +++ b/docs/imperative-module/3-po.html @@ -108,12 +108,12 @@ valid as values, since a condition is not also a value in Inform 7. struct wording name; text of name } phrase_option;
    -
    • The structure phrase_option is accessed in 2/rls, 2/fao, 2/act, 3/pav, 4/sv, 6/cii, 6/cste and here.
    +
    • The structure phrase_option is accessed in 2/rls, 2/fao, 2/act, 4/sv, 6/cii, 6/cste and here.

    §3. Creation. By default, a phrase has no options.

    -ph_options_data Phrases::Options::new(wording W) {
    +ph_options_data Phrases::Options::new(wording W) {
         ph_options_data phod;
         phod.no_options_permitted = 0;
         phod.multiple_options_permitted = FALSE;
    @@ -121,7 +121,7 @@ valid as values, since a condition is not also a value in Inform 7.
         return phod;
     }
     
    -int Phrases::Options::allows_options(ph_options_data *phod) {
    +int Phrases::Options::allows_options(ph_options_data *phod) {
         if (phod->no_options_permitted > 0) return TRUE;
         return FALSE;
     }
    @@ -169,14 +169,13 @@ these are relatively rare in Inform source text.
     ph_options_data *phod_being_parsed = NULL;
     phrase *ph_being_parsed = NULL;
     
    -ph_options_data Phrases::Options::parse_declared_options(wording W) {
    -    ph_options_data phod = Phrases::Options::new(W);
    +void Phrases::Options::parse_declared_options(ph_options_data *phod, wording W) {
         if (Wordings::nonempty(W)) {
    -        phod_being_parsed = &phod;
    +        phod->options_declaration = W;
    +        phod_being_parsed = phod;
             <phrase-option-declaration-list>(W);
    -        if (<<r>>) phod.multiple_options_permitted = TRUE;
    +        if (<<r>>) phod->multiple_options_permitted = TRUE;
         }
    -    return phod;
     }
     

    §7. I have to say that I regret the syntax for phrase options, which makes @@ -242,7 +241,7 @@ For example, in:

     int too_many_POs_error = FALSE;
    -void Phrases::Options::phod_add_phrase_option(ph_options_data *phod, wording W) {
    +void Phrases::Options::phod_add_phrase_option(ph_options_data *phod, wording W) {
         LOGIF(PHRASE_CREATIONS, "Adding phrase option <%W>\n", W);
         if (phod->no_options_permitted >= MAX_OPTIONS_PER_PHRASE) {
             if (too_many_POs_error == FALSE)
    @@ -407,7 +406,7 @@ by "and":
     
    diff --git a/docs/imperative-module/3-prcd.html b/docs/imperative-module/3-prcd.html index 22c1c94a3..5779921b3 100644 --- a/docs/imperative-module/3-prcd.html +++ b/docs/imperative-module/3-prcd.html @@ -114,7 +114,6 @@ rulebooks reach them.
     typedef struct ph_runtime_context_data {
         struct wording activity_context;  happens only while any activities go on?
    -    struct parse_node *activity_where;  and who says?
         struct activity_list *avl;
         #ifdef IF_MODULE
         struct parse_node *during_scene;  ...happens only during a scene matching this?
    @@ -123,7 +122,6 @@ rulebooks reach them.
         int never_test_actor;  ...for instance, for a parametrised rather than action rulebook
         int marked_for_anyone;  any actor is allowed to perform this action
         #endif
    -    struct rulebook **compile_for_rulebook;  ...used for the default outcome
         int permit_all_outcomes;  waive the usual restrictions on rule outcomes
     } ph_runtime_context_data;
     
    @@ -185,7 +183,6 @@ the following only blanks out a PHRCD structure ready for that to happen.
     ph_runtime_context_data Phrases::Context::new(void) {
         ph_runtime_context_data phrcd;
         phrcd.activity_context = EMPTY_WORDING;
    -    phrcd.activity_where = NULL;
         phrcd.avl = NULL;
         #ifdef IF_MODULE
         phrcd.during_scene = NULL;
    @@ -195,7 +192,6 @@ the following only blanks out a PHRCD structure ready for that to happen.
         phrcd.marked_for_anyone = FALSE;
         #endif
         phrcd.permit_all_outcomes = FALSE;
    -    phrcd.compile_for_rulebook = NULL;
         return phrcd;
     }
     
    @@ -450,7 +446,7 @@ process. ph_runtime_context_data *rcd = &(ph->runtime_context_data); if (Wordings::nonempty(rcd->activity_context)) { parse_node *save_cs = current_sentence; - current_sentence = rcd->activity_where; + current_sentence = id->at; ph_stack_frame *phsf = &(ph->stack_frame); Frames::make_current(phsf); @@ -487,7 +483,7 @@ much.
     int Phrases::Context::compile_test_head(phrase *ph, rule *R) {
    -    inter_name *identifier = Phrases::iname(ph);
    +    inter_name *identifier = Phrases::iname(ph);
         ph_runtime_context_data *phrcd = &(ph->runtime_context_data);
     
         if (RTRules::compile_constraint(R) == TRUE) return TRUE;
    @@ -529,7 +525,7 @@ much.
     }
     
     int Phrases::Context::actions_compile_test_tail(phrase *ph, rule *R) {
    -    inter_name *identifier = Phrases::iname(ph);
    +    inter_name *identifier = Phrases::iname(ph);
         ph_runtime_context_data *phrcd = &(ph->runtime_context_data);
         #ifdef IF_MODULE
         if (phrcd->ap) Compile an action test tail9.6
    @@ -545,15 +541,12 @@ with the default outcome return (see above).
     
     
     void Phrases::Context::compile_test_tail(phrase *ph, rule *R) {
    -    inter_name *identifier = Phrases::iname(ph);
    +    inter_name *identifier = Phrases::iname(ph);
         ph_runtime_context_data *phrcd = &(ph->runtime_context_data);
    -
    -    if (phrcd->compile_for_rulebook) {
    -        rulebook *rb = *(phrcd->compile_for_rulebook);
    -        if (rb) RTRules::compile_default_outcome(Rulebooks::get_outcomes(rb));
    -    }
    -
    -    if (Wordings::nonempty(phrcd->activity_context)) Compile an activity or explicit condition test tail9.1.1;
    +    rulebook *rb = RuleFamily::get_rulebook(ph->from);
    +    if (rb) RTRules::compile_default_outcome(Rulebooks::get_outcomes(rb));
    +    if (Wordings::nonempty(phrcd->activity_context))
    +        Compile an activity or explicit condition test tail9.1.1;
         if (PluginCalls::compile_test_tail(ph, R) == FALSE) {
             if (phrcd->ap) Compile an action test tail9.6;
         }
    @@ -735,7 +728,7 @@ with the default outcome return (see above).
         return n;
     }
     
    -
    • The structure activity_list is accessed in 2/rlb, 2/act, 3/phr, 3/tph, 3/tp, 4/lv, 4/sv, 4/sf, 5/dtd, 5/cdp, 6/inv, 6/pi, 6/cii, 6/cp, 6/cste and here.
    +
    • The structure activity_list is accessed in 2/rlb, 2/act, 3/phr, 3/tph, 4/lv, 4/sv, 4/sf, 5/dtd, 5/cdp, 6/inv, 6/pi, 6/cii, 6/cp, 6/cste and here.

    §11. Run-time contexts are seen in the "while" clauses at the end of rules. For example:

    @@ -902,7 +895,7 @@ values, of the kind to which the activity applies. }
    diff --git a/docs/imperative-module/3-ptd.html b/docs/imperative-module/3-ptd.html index 2a046a9ef..3399fc0fb 100644 --- a/docs/imperative-module/3-ptd.html +++ b/docs/imperative-module/3-ptd.html @@ -296,7 +296,7 @@ whistles and doodads which regular phrases don't.

    §9. Creation.

    -ph_type_data Phrases::TypeData::new(void) {
    +ph_type_data Phrases::TypeData::new(void) {
         ph_type_data phtd;
         phtd.registration_text = EMPTY_WORDING;
     
    @@ -403,7 +403,7 @@ logic, since one argument is in effect a kind rather than a value.)
     

    -kind *Phrases::TypeData::kind(ph_type_data *phtd) {
    +kind *Phrases::TypeData::kind(ph_type_data *phtd) {
         kind *argument_kinds[MAX_TOKENS_PER_PHRASE];
         int i, j = 0;
         for (i=0; i<phtd->no_tokens; i++)
    @@ -528,7 +528,7 @@ variables "new entry" and "L" with those kinds.
     

    -void Phrases::TypeData::into_stack_frame(ph_stack_frame *phsf,
    +void Phrases::TypeData::into_stack_frame(ph_stack_frame *phsf,
         ph_type_data *phtd, kind *kind_in_this_compilation, int first) {
         if (Kinds::get_construct(kind_in_this_compilation) != CON_phrase)
             internal_error("no function kind");
    @@ -914,7 +914,7 @@ by than name.
     

    §25.

    -void Phrases::TypeData::make_inline(ph_type_data *phtd) {
    +void Phrases::TypeData::make_inline(ph_type_data *phtd) {
         phtd->as_inline.invoked_inline_not_as_call = TRUE;
     }
     
    @@ -991,7 +991,7 @@ source text.
     }
     
    diff --git a/docs/imperative-module/3-tp.html b/docs/imperative-module/3-tp.html deleted file mode 100644 index 233e35162..000000000 --- a/docs/imperative-module/3-tp.html +++ /dev/null @@ -1,250 +0,0 @@ - - - - Timed Phrases - - - - - - - - - - - - - - - - - - -
    - - -

    Another way phrases can be invoked is as timed events, which need no special Inform data structure and are simply compiled into a pair of timetable I6 arrays to be processed at run-time.

    - -

    §1. The timing of an event records the time at which a phrase should -spontaneously happen. This is ordinarily a time value, in minutes from 12 -midnight, for a phrase happening at a specific time — for instance, one -defined as "At 9:00 AM: ..." But two values are special: -

    - -
    define NOT_A_TIMED_EVENT -1  as for the vast majority of phrases
    -define NO_FIXED_TIME -2  for phrases like "When the clock strikes: ..."
    -define NOT_AN_EVENT -3  not even syntactically
    -
    -

    §2. And here we record where events are used: -

    - -
    -typedef struct use_as_event {
    -    struct parse_node *where_triggered;  sentence which specifies when this occurs
    -    struct use_as_event *next;
    -    CLASS_DEFINITION
    -} use_as_event;
    -
    -
    • The structure use_as_event is accessed in 2/rlb, 2/act, 3/phr, 3/prcd, 3/tph, 4/lv, 4/sv, 4/sf, 5/dtd, 5/cdp, 6/inv, 6/pi, 6/cii, 6/cp, 6/cste and here.
    -

    §3. Timed events are stored in two simple arrays, processed by run-time code. -

    - -
    -void Phrases::Timed::TimedEventsTable(void) {
    -    inter_name *iname = Hierarchy::find(TIMEDEVENTSTABLE_HL);
    -    packaging_state save = Emit::named_table_array_begin(iname, K_value);
    -    int when_count = 0;
    -    phrase *ph;
    -    LOOP_OVER(ph, phrase) {
    -        int t = RuleFamily::get_timing_of_event(ph->from);
    -        if (t == NOT_A_TIMED_EVENT) continue;
    -        if (t == NO_FIXED_TIME) when_count++;
    -        else Emit::array_iname_entry(Phrases::iname(ph));
    -    }
    -
    -    for (int i=0; i<when_count+1; i++) {
    -        Emit::array_numeric_entry(0);
    -        Emit::array_numeric_entry(0);
    -    }
    -    Emit::array_end(save);
    -    Hierarchy::make_available(Emit::tree(), iname);
    -}
    -
    -void Phrases::Timed::TimedEventTimesTable(void) {
    -    inter_name *iname = Hierarchy::find(TIMEDEVENTTIMESTABLE_HL);
    -    packaging_state save = Emit::named_table_array_begin(iname, K_number);
    -    int when_count = 0;
    -    phrase *ph;
    -    LOOP_OVER(ph, phrase) {
    -        int t = RuleFamily::get_timing_of_event(ph->from);
    -        if (t == NOT_A_TIMED_EVENT) continue;
    -        if (t == NO_FIXED_TIME) when_count++;
    -        else Emit::array_numeric_entry((inter_ti) t);
    -    }
    -
    -    for (int i=0; i<when_count+1; i++) {
    -        Emit::array_numeric_entry(0);
    -        Emit::array_numeric_entry(0);
    -    }
    -    Emit::array_end(save);
    -    Hierarchy::make_available(Emit::tree(), iname);
    -}
    -
    -

    §4. That's it, really: everything else is just indexing. -

    - -
    -void Phrases::Timed::note_usage(phrase *ph, parse_node *at) {
    -    int t = RuleFamily::get_timing_of_event(ph->from);
    -    if (t == NO_FIXED_TIME) {
    -        use_as_event *uae = CREATE(use_as_event);
    -        uae->where_triggered = at;
    -        uae->next = NULL;
    -        linked_list *L = RuleFamily::get_uses_as_event(ph->from);
    -        if (L) ADD_TO_LINKED_LIST(uae, use_as_event, L);
    -    }
    -}
    -
    -

    §5. An interesting case where the Problem is arguably only a warning and -arguably shouldn't block compilation. Then again... -

    - -
    -void Phrases::Timed::check_for_unused(void) {
    -    phrase *ph;
    -    LOOP_OVER(ph, phrase)
    -        if (RuleFamily::get_timing_of_event(ph->from) == NO_FIXED_TIME) {
    -            linked_list *L = RuleFamily::get_uses_as_event(ph->from);
    -            if (LinkedLists::len(L) == 0) {
    -                current_sentence = ph->from->at;
    -                StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_UnusedTimedEvent),
    -                    "this sets up a timed event which is never used",
    -                    "since you never use any of the phrases which could cause it. "
    -                    "(A timed event is just a name, and it needs other instructions "
    -                    "elsewhere before it can have any effect.)");
    -            }
    -        }
    -}
    -
    -

    §6. And here's the actual index segment. -

    - -
    -void Phrases::Timed::index(OUTPUT_STREAM) {
    -    int when_count = 0, tt_count = 0;
    -    Index events with no specific time6.1;
    -    Index timetabled events6.2;
    -    if ((when_count == 0) && (tt_count == 0)) {
    -        HTML_OPEN("p"); WRITE("<i>None.</i>"); HTML_CLOSE("p");
    -    }
    -}
    -
    -

    §6.1. Index events with no specific time6.1 = -

    - -
    -    phrase *ph;
    -    LOOP_OVER(ph, phrase) {
    -        int t = RuleFamily::get_timing_of_event(ph->from);
    -        if (t == NO_FIXED_TIME) {
    -            if (when_count == 0) {
    -                HTML_OPEN("p");
    -                WRITE("<i>Events with no specific time</i>");
    -                HTML_CLOSE("p");
    -            }
    -            when_count++;
    -            HTML_OPEN_WITH("p", "class=\"tightin2\"");
    -            ImperativeDefinitions::index_preamble(OUT, ph->from);
    -            if ((ph->from->at) &&
    -                (Wordings::nonempty(Node::get_text(ph->from->at))))
    -                Index::link(OUT, Wordings::first_wn(Node::get_text(ph->from->at)));
    -            WRITE(" (where triggered: ");
    -            linked_list *L = RuleFamily::get_uses_as_event(ph->from);
    -            use_as_event *uae;
    -            LOOP_OVER_LINKED_LIST(uae, use_as_event, L)
    -                Index::link(OUT, Wordings::first_wn(Node::get_text(uae->where_triggered)));
    -            WRITE(")");
    -            HTML_CLOSE("p");
    -        }
    -    }
    -
    -
    • This code is used in §6.
    -

    §6.2. Index timetabled events6.2 = -

    - -
    -    phrase *ph;
    -    LOOP_OVER(ph, phrase) {
    -        int t = RuleFamily::get_timing_of_event(ph->from);
    -        if (t >= 0) {  i.e., an actual time of day in minutes since midnight
    -            if (tt_count == 0) {
    -                HTML_OPEN("p");
    -                WRITE("<i>Timetable</i>");
    -                HTML_CLOSE("p");
    -            }
    -            tt_count++;
    -            HTML_OPEN_WITH("p", "class=\"in2\"");
    -            ImperativeDefinitions::index_preamble(OUT, ph->from);
    -            if ((ph->from->at) &&
    -                (Wordings::nonempty(Node::get_text(ph->from->at))))
    -                Index::link(OUT, Wordings::first_wn(Node::get_text(ph->from->at)));
    -            HTML_CLOSE("p");
    -        }
    -    }
    -
    -
    • This code is used in §6.
    - - -
    - - - diff --git a/docs/imperative-module/3-tph.html b/docs/imperative-module/3-tph.html index 9c191a831..4371e1a2e 100644 --- a/docs/imperative-module/3-tph.html +++ b/docs/imperative-module/3-tph.html @@ -124,7 +124,7 @@ variety of values: if ((Log::aspect_switched_on(PHRASE_COMPARISONS_DA)) || (r == CONFLICTED_PH)) { LOG("Phrase comparison ("); - Phrases::write_HTML_representation(DL, ph1, PASTE_PHRASE_FORMAT); + Phrases::write_HTML_representation(DL, ph1, PASTE_PHRASE_FORMAT); LOG(") "); switch(r) { case INCOMPARABLE_PH: LOG("~~"); break; @@ -136,13 +136,13 @@ variety of values: case CONFLICTED_PH: LOG("!!"); break; } LOG(" ("); - Phrases::write_HTML_representation(DL, ph2, PASTE_PHRASE_FORMAT); + Phrases::write_HTML_representation(DL, ph2, PASTE_PHRASE_FORMAT); LOG(")\n"); } if (r == CONFLICTED_PH) { - Problems::quote_source(1, Phrases::declaration_node(ph1)); - Problems::quote_source(2, Phrases::declaration_node(ph2)); + Problems::quote_source(1, Phrases::declaration_node(ph1)); + Problems::quote_source(2, Phrases::declaration_node(ph2)); StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_ConflictedReturnKinds)); Problems::issue_problem_segment( "The two phrase definitions %1 and %2 make the same wording " @@ -202,7 +202,7 @@ reasons, that is, to make the compiled code more legible. int Routines::ToPhrases::sequence_count(phrase *ph) { if (ph == NULL) return 0; if (ph->sequence_count == -1) { - Phrases::log(ph); + Phrases::log(ph); internal_error("Sequence count not ready"); } return ph->sequence_count; @@ -234,7 +234,7 @@ values in force, so that there is no possible ambiguity in how we read K.

    -to_phrase_request *Routines::ToPhrases::make_request(phrase *ph, kind *K,
    +to_phrase_request *Routines::ToPhrases::make_request(phrase *ph, kind *K,
         kind_variable_declaration *kvd, wording W) {
         if ((ph == NULL) || (K == NULL)) internal_error("bad request");
     
    @@ -274,7 +274,7 @@ list is a list of. The result would be:
     

    -    Problems::quote_source(1, Phrases::declaration_node(ph));
    +    Problems::quote_source(1, Phrases::declaration_node(ph));
         StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_UndeterminedKind));
         if (Wordings::empty(W)) {
             Problems::issue_problem_segment(
    @@ -296,10 +296,10 @@ I6 routine.
     

    -inter_name *Routines::ToPhrases::make_iname(phrase *ph, kind *req_kind) {
    +inter_name *Routines::ToPhrases::make_iname(phrase *ph, kind *req_kind) {
         if (Phrases::TypeData::invoked_inline(ph)) {
             TEMPORARY_TEXT(identifier)
    -        wchar_t *p = Phrases::get_inline_definition(ph);
    +        wchar_t *p = Phrases::get_inline_definition(ph);
             int found = FALSE;
             for (int i=0; p[i]; i++)
                 if (Characters::isalpha(p[i])) {
    @@ -310,7 +310,7 @@ I6 routine.
                     break;
                 }
             if (found == FALSE) {
    -            current_sentence = Phrases::declaration_node(ph);
    +            current_sentence = Phrases::declaration_node(ph);
                 Problems::quote_source(1, current_sentence);
                 Problems::quote_phrase(2, ph);
                 StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_PhraseNamedI6Failed));
    @@ -347,7 +347,7 @@ since the last time it was called.
             if (req == NULL) break;
     
             latest_request_granted = req;
    -        Phrases::compile(latest_request_granted->requested_phrase,
    +        Phrases::compile(latest_request_granted->requested_phrase,
                 i, max_i, NULL, latest_request_granted, NULL);
             N++;
         }
    @@ -403,7 +403,7 @@ is confined to the current Chapter.
     }
     
    diff --git a/docs/imperative-module/4-lv.html b/docs/imperative-module/4-lv.html index cef35a093..04bb49426 100644 --- a/docs/imperative-module/4-lv.html +++ b/docs/imperative-module/4-lv.html @@ -148,7 +148,7 @@ marks it as deallocated. CLASS_DEFINITION } local_variable;
    -
    • The structure local_variable is accessed in 2/rlb, 2/act, 3/phr, 3/prcd, 3/tph, 3/tp, 4/sv, 4/sf, 5/dtd, 5/cdp, 6/inv, 6/pi, 6/cii, 6/cp, 6/cste and here.
    +
    • The structure local_variable is accessed in 2/rlb, 2/act, 3/phr, 3/prcd, 3/tph, 4/sv, 4/sf, 5/dtd, 5/cdp, 6/inv, 6/pi, 6/cii, 6/cp, 6/cste and here.

    §3. A local variable needs to be stored somewhere at run-time. The obvious correspondence is to put these into I6 local variables, which are, in effect, CPU registers. We won't need to do much in the way of register-allocation, @@ -389,7 +389,7 @@ scratch work-space which can be used in the compiled code. return LocalVariables::declare_this(v, FALSE, 8); } -local_variable *LocalVariables::add_named_call(text_stream *name) { +local_variable *LocalVariables::add_named_call(text_stream *name) { ph_stack_frame *phsf = Frames::current_stack_frame(); if (phsf) return LocalVariables::add_internal(&(phsf->local_value_variables), name, @@ -456,7 +456,7 @@ passed to its I6 routine, and this occupies a pseudo-call-parameter:

    -void LocalVariables::options_parameter_is_needed(ph_stack_frame *phsf) {
    +void LocalVariables::options_parameter_is_needed(ph_stack_frame *phsf) {
         LocalVariables::add_internal(&(phsf->local_value_variables),
             I"phrase_options", OTHER_CALL_PARAMETER_LV);
     }
    @@ -1368,7 +1368,7 @@ need in the compilation of any given routine:
     }
     
    diff --git a/docs/imperative-module/4-sv.html b/docs/imperative-module/4-sv.html index 3e0f5b78d..1b752697d 100644 --- a/docs/imperative-module/4-sv.html +++ b/docs/imperative-module/4-sv.html @@ -107,7 +107,7 @@ function togglePopup(material_id) { CLASS_DEFINITION } stacked_variable_owner_list;
    -
    • The structure stacked_variable is accessed in 2/rls, 2/fao, 2/act, 3/po, 3/pav, 6/cii, 6/cste and here.
    • The structure stacked_variable_list is accessed in 2/rlb, 2/act, 3/phr, 3/prcd, 3/tph, 3/tp, 4/lv, 4/sf, 5/dtd, 5/cdp, 6/inv, 6/pi, 6/cii, 6/cp, 6/cste and here.
    • The structure stacked_variable_owner is private to this section.
    • The structure stacked_variable_owner_list is accessed in 2/rlb, 2/act, 3/phr, 3/prcd, 3/tph, 3/tp, 4/lv, 4/sf, 5/dtd, 5/cdp, 6/inv, 6/pi, 6/cii, 6/cp, 6/cste and here.
    +
    • The structure stacked_variable is accessed in 2/rls, 2/fao, 2/act, 3/po, 6/cii, 6/cste and here.
    • The structure stacked_variable_list is accessed in 2/rlb, 2/act, 3/phr, 3/prcd, 3/tph, 4/lv, 4/sf, 5/dtd, 5/cdp, 6/inv, 6/pi, 6/cii, 6/cp, 6/cste and here.
    • The structure stacked_variable_owner is private to this section.
    • The structure stacked_variable_owner_list is accessed in 2/rlb, 2/act, 3/phr, 3/prcd, 3/tph, 4/lv, 4/sf, 5/dtd, 5/cdp, 6/inv, 6/pi, 6/cii, 6/cp, 6/cste and here.

    §2.

    diff --git a/docs/imperative-module/6-cii.html b/docs/imperative-module/6-cii.html
    index 7ace2e271..cd031be28 100644
    --- a/docs/imperative-module/6-cii.html
    +++ b/docs/imperative-module/6-cii.html
    @@ -210,8 +210,8 @@ head goes to OUT
     
     
    -    Invocations::Inline::csi_inline_inner(VH, Phrases::get_inter_head(ph), &CSIS);
    -    if (Phrases::get_inter_tail(ph)) tail_schema = Phrases::get_inter_tail(ph);
    +    Invocations::Inline::csi_inline_inner(VH, Phrases::get_inter_head(ph), &CSIS);
    +    if (Phrases::get_inter_tail(ph)) tail_schema = Phrases::get_inter_tail(ph);
     
    • This code is used in §1.

    §1.4. Suppose there's a phrase with both head and tail. Then the tail won't appear @@ -1220,43 +1220,14 @@ token, because that would be "property name". Instead: return;

    -

    §3.1.1.4.12. This little annotation is used for the phrases about timed rule firing: -

    - -
    -

    To (R - rule) in (t - number) turn/turns from now: ...

    -
    - -

    has the inline definition: -

    - -
    -    SetTimedEvent({-mark-event-used:R}, {t}+1, 0);
    -
    -

    The annotation makes no difference to how R is compiled, except that it -sneaks in a sanity check (R must be explicitly named and must be an event -rule), and also makes a note for indexing purposes. +

    §3.1.1.4.12. This little annotation is used in Timed Rules (in if).

    Inline annotation "mark-event-used"3.1.1.4.12 =

    -    if (Rvalues::is_CONSTANT_construction(supplied, CON_rule)) {
    -        rule *R = Rvalues::to_rule(supplied);
    -        imperative_defn *id = Rules::get_imperative_definition(R);
    -        if (id) Phrases::Timed::note_usage(id->body_of_defn, current_sentence);
    -    } else {
    -        Problems::quote_source(1, current_sentence);
    -        Problems::quote_wording(2, Node::get_text(supplied));
    -        StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_NonconstantEvent));
    -        Problems::issue_problem_segment(
    -            "You wrote %1, but '%2' isn't the name of any timed event that "
    -            "I know of. (These need to be set up in a special way, like so - "
    -            "'At the time when stuff happens: ...' creates a timed event "
    -            "called 'stuff happens'.)");
    -        Problems::issue_problem_end();
    -    }
    +    PluginCalls::nonstandard_inline_annotation(sche->inline_command, supplied);
         valid_annotation = TRUE;
     
    diff --git a/docs/imperative-module/6-cp.html b/docs/imperative-module/6-cp.html index da7c1cc35..f500f1398 100644 --- a/docs/imperative-module/6-cp.html +++ b/docs/imperative-module/6-cp.html @@ -99,7 +99,7 @@ should always be supplied for "To..." phrases, but left null for rules.

    -void Routines::Compile::routine(phrase *ph,
    +void Routines::Compile::routine(phrase *ph,
         stacked_variable_owner_list *legible, to_phrase_request *req,
         rule *R) {
         parse_node *code_at = ph->from->at;
    @@ -205,9 +205,9 @@ phrase to be different from the number version, and so on.
     

    -inter_name *Routines::Compile::iname(phrase *ph, to_phrase_request *req) {
    +inter_name *Routines::Compile::iname(phrase *ph, to_phrase_request *req) {
         if (req) return req->req_iname;
    -    return Phrases::iname(ph);
    +    return Phrases::iname(ph);
     }
     

    §4.

    diff --git a/docs/imperative-module/6-inv.html b/docs/imperative-module/6-inv.html index 66437ae82..2ec8337cb 100644 --- a/docs/imperative-module/6-inv.html +++ b/docs/imperative-module/6-inv.html @@ -268,7 +268,7 @@ for different invocations of, say, "+". } else if (Node::get_say_adjective(inv)) { LOG("adj:%d", Node::get_say_adjective(inv)->allocation_id); } else { - Phrases::log_briefly(Node::get_phrase_invoked(inv)); + Phrases::log_briefly(Node::get_phrase_invoked(inv)); for (i=0; i<Invocations::get_no_tokens(inv); i++) { LOG(" ($P", Invocations::get_token_as_parsed(inv, i)); if (Invocations::get_token_check_to_do(inv, i)) diff --git a/docs/imperative-module/index.html b/docs/imperative-module/index.html index 42e9e2117..1334ccbb9 100644 --- a/docs/imperative-module/index.html +++ b/docs/imperative-module/index.html @@ -156,21 +156,11 @@ Phrase Options - To create and subsequently parse against the list of phrase options with which the user can choose to invoke a To phrase.

    -
  • -

    - Phrases as Values - - To provide the names of phrases as first-class values.

    -
  • To Phrases - To manage the sorting of To... phrases in logical precedence order, and keep track of which kinds they are being applied to.

  • -
  • -

    - Timed Phrases - - Another way phrases can be invoked is as timed events, which need no special Inform data structure and are simply compiled into a pair of timetable I6 arrays to be processed at run-time.

    -
  • diff --git a/docs/index-module/2-ifs.html b/docs/index-module/2-ifs.html index e863cea86..623b618b0 100644 --- a/docs/index-module/2-ifs.html +++ b/docs/index-module/2-ifs.html @@ -818,7 +818,7 @@ to show, hide and colour things: return; } if (Str::eq_wide_string(elt, L"Ev")) { - Phrases::Timed::index(OUT); rules which happen at set times of day + IXRules::index_timed_rules(OUT); rules which happen at set times of day return; } if (Str::eq_wide_string(elt, L"RS")) { @@ -941,7 +941,7 @@ the source text in the application.

    -void Index::link(OUTPUT_STREAM, int wn) {
    +void Index::link(OUTPUT_STREAM, int wn) {
         Index::link_to_location(OUT, Lexer::word_location(wn), TRUE);
     }
     
    diff --git a/docs/index-module/2-pi.html b/docs/index-module/2-pi.html
    index a4338b57e..293972ba0 100644
    --- a/docs/index-module/2-pi.html
    +++ b/docs/index-module/2-pi.html
    @@ -309,10 +309,10 @@ a single shared reveal-box:
     
     int Phrases::Index::ph_same_doc(phrase *p1, phrase *p2) {
         if ((p1 == NULL) || (p2 == NULL) ||
    -        (Wordings::empty(p1->ph_documentation_symbol)) ||
    -            (Wordings::empty(p2->ph_documentation_symbol)))
    +        (Wordings::empty(ToPhraseFamily::doc_ref(p1->from))) ||
    +            (Wordings::empty(ToPhraseFamily::doc_ref(p2->from))))
             return FALSE;
    -    if (Wordings::match(p1->ph_documentation_symbol, p2->ph_documentation_symbol))
    +    if (Wordings::match(ToPhraseFamily::doc_ref(p1->from), ToPhraseFamily::doc_ref(p2->from)))
             return TRUE;
         return FALSE;
     }
    diff --git a/docs/index-module/2-rls.html b/docs/index-module/2-rls.html
    index db07bc217..1222dc309 100644
    --- a/docs/index-module/2-rls.html
    +++ b/docs/index-module/2-rls.html
    @@ -801,6 +801,72 @@ have affected it in this way:
     }
     
    • The structure rulebook_indexing_data is private to this section.
    • The structure placement_affecting is accessed in 2/ins, 2/act, 3/scn, 4/em and here.
    +

    §10.

    + +
    +void IXRules::index_timed_rules(OUTPUT_STREAM) {
    +    int when_count = 0, tt_count = 0;
    +    Index events with no specific time10.1;
    +    Index timetabled events10.2;
    +    if ((when_count == 0) && (tt_count == 0)) {
    +        HTML_OPEN("p"); WRITE("<i>None.</i>"); HTML_CLOSE("p");
    +    }
    +}
    +
    +

    §10.1. Index events with no specific time10.1 = +

    + +
    +    phrase *ph;
    +    LOOP_OVER(ph, phrase) {
    +        int t = TimedRules::get_timing_of_event(ph->from);
    +        if (t == NO_FIXED_TIME) {
    +            if (when_count == 0) {
    +                HTML_OPEN("p");
    +                WRITE("<i>Events with no specific time</i>");
    +                HTML_CLOSE("p");
    +            }
    +            when_count++;
    +            HTML_OPEN_WITH("p", "class=\"tightin2\"");
    +            ImperativeDefinitions::index_preamble(OUT, ph->from);
    +            if ((ph->from->at) &&
    +                (Wordings::nonempty(Node::get_text(ph->from->at))))
    +                Index::link(OUT, Wordings::first_wn(Node::get_text(ph->from->at)));
    +            WRITE(" (where triggered: ");
    +            linked_list *L = TimedRules::get_uses_as_event(ph->from);
    +            parse_node *p;
    +            LOOP_OVER_LINKED_LIST(p, parse_node, L)
    +                Index::link(OUT, Wordings::first_wn(Node::get_text(p)));
    +            WRITE(")");
    +            HTML_CLOSE("p");
    +        }
    +    }
    +
    +
    • This code is used in §10.
    +

    §10.2. Index timetabled events10.2 = +

    + +
    +    phrase *ph;
    +    LOOP_OVER(ph, phrase) {
    +        int t = TimedRules::get_timing_of_event(ph->from);
    +        if (t >= 0) {  i.e., an actual time of day in minutes since midnight
    +            if (tt_count == 0) {
    +                HTML_OPEN("p");
    +                WRITE("<i>Timetable</i>");
    +                HTML_CLOSE("p");
    +            }
    +            tt_count++;
    +            HTML_OPEN_WITH("p", "class=\"in2\"");
    +            ImperativeDefinitions::index_preamble(OUT, ph->from);
    +            if ((ph->from->at) &&
    +                (Wordings::nonempty(Node::get_text(ph->from->at))))
    +                Index::link(OUT, Wordings::first_wn(Node::get_text(ph->from->at)));
    +            HTML_CLOSE("p");
    +        }
    +    }
    +
    +
    • This code is used in §10.
    diff --git a/docs/runtime-module/2-emt.html b/docs/runtime-module/2-emt.html index f0509c5c6..9884f1588 100644 --- a/docs/runtime-module/2-emt.html +++ b/docs/runtime-module/2-emt.html @@ -84,7 +84,7 @@ function togglePopup(material_id) { inter_tree *I7_generation_tree = NULL; -inter_tree *Emit::tree(void) { +inter_tree *Emit::tree(void) { return I7_generation_tree; } @@ -399,7 +399,7 @@ insert them into the Inter stream close to the top. return save; } -packaging_state Emit::named_table_array_begin(inter_name *name, kind *K) { +packaging_state Emit::named_table_array_begin(inter_name *name, kind *K) { packaging_state save = Emit::named_array_begin(name, K); Produce::annotate_iname_i(name, TABLEARRAY_IANN, 1); return save; @@ -502,7 +502,7 @@ insert them into the Inter stream close to the top. return save; } -packaging_state Emit::named_array_begin(inter_name *N, kind *K) { +packaging_state Emit::named_array_begin(inter_name *N, kind *K) { packaging_state save = Packaging::enter_home_of(N); inter_symbol *symb = Produce::define_symbol(N); Emit::push_array(); @@ -512,7 +512,7 @@ insert them into the Inter stream close to the top. return save; } -void Emit::array_iname_entry(inter_name *iname) { +void Emit::array_iname_entry(inter_name *iname) { if (current_A == NULL) internal_error("entry outside of inter array"); inter_symbol *alias; if (iname == NULL) alias = Site::veneer_symbol(Emit::tree(), NOTHING_VSYMB); @@ -547,7 +547,7 @@ insert them into the Inter stream close to the top. } #endif -void Emit::array_text_entry(text_stream *content) { +void Emit::array_text_entry(text_stream *content) { if (current_A == NULL) internal_error("entry outside of inter array"); inter_ti v1 = 0, v2 = 0; Produce::text_value(Emit::tree(), &v1, &v2, content); @@ -568,7 +568,7 @@ insert them into the Inter stream close to the top. Emit::add_entry(v1, v2); } -void Emit::array_numeric_entry(inter_ti N) { +void Emit::array_numeric_entry(inter_ti N) { if (current_A == NULL) internal_error("entry outside of inter array"); Emit::add_entry(LITERAL_IVAL, N); } @@ -586,7 +586,7 @@ insert them into the Inter stream close to the top. return IBM; } -void Emit::array_end(packaging_state save) { +void Emit::array_end(packaging_state save) { if (current_A == NULL) internal_error("inter array not opened"); inter_symbol *con_name = current_A->array_name_symbol; inter_bookmark *IBM = Packaging::at(Emit::tree()); diff --git a/docs/runtime-module/2-hrr.html b/docs/runtime-module/2-hrr.html index 1a412a33a..7b7ba235e 100644 --- a/docs/runtime-module/2-hrr.html +++ b/docs/runtime-module/2-hrr.html @@ -1723,11 +1723,11 @@ function togglePopup(material_id) {

    §4.

    -inter_name *Hierarchy::find(int id) {
    +inter_name *Hierarchy::find(int id) {
         return HierarchyLocations::find(Emit::tree(), id);
     }
     
    -void Hierarchy::make_available(inter_tree *I, inter_name *iname) {
    +void Hierarchy::make_available(inter_tree *I, inter_name *iname) {
         text_stream *ma_as = Produce::get_translation(iname);
         if (Str::len(ma_as) == 0) ma_as = Emit::to_text(iname);
         PackageTypes::get(I, I"_linkage");
    @@ -1751,11 +1751,11 @@ function togglePopup(material_id) {
         return HierarchyLocations::attach_new_package(Emit::tree(), NULL, Packaging::enclosure(Emit::tree()), hap_id);
     }
     
    -package_request *Hierarchy::package_within(int hap_id, package_request *super) {
    +package_request *Hierarchy::package_within(int hap_id, package_request *super) {
         return HierarchyLocations::attach_new_package(Emit::tree(), NULL, super, hap_id);
     }
     
    -inter_name *Hierarchy::make_iname_in(int id, package_request *P) {
    +inter_name *Hierarchy::make_iname_in(int id, package_request *P) {
         return HierarchyLocations::find_in_package(Emit::tree(), id, P, EMPTY_WORDING, NULL, -1, NULL);
     }
     
    @@ -1767,29 +1767,29 @@ function togglePopup(material_id) {
         return HierarchyLocations::find_in_package(Emit::tree(), id, P, EMPTY_WORDING, derive_from, -1, NULL);
     }
     
    -inter_name *Hierarchy::make_localised_iname_in(int id, package_request *P, compilation_unit *C) {
    +inter_name *Hierarchy::make_localised_iname_in(int id, package_request *P, compilation_unit *C) {
         return HierarchyLocations::find_in_package(Emit::tree(), id, P, EMPTY_WORDING, NULL, -1, NULL);
     }
     
    -inter_name *Hierarchy::make_iname_with_memo(int id, package_request *P, wording W) {
    +inter_name *Hierarchy::make_iname_with_memo(int id, package_request *P, wording W) {
         return HierarchyLocations::find_in_package(Emit::tree(), id, P, W, NULL, -1, NULL);
     }
     
    -inter_name *Hierarchy::make_iname_with_memo_and_value(int id, package_request *P, wording W, int x) {
    +inter_name *Hierarchy::make_iname_with_memo_and_value(int id, package_request *P, wording W, int x) {
         inter_name *iname = HierarchyLocations::find_in_package(Emit::tree(), id, P, W, NULL, x, NULL);
         Hierarchy::make_available(Emit::tree(), iname);
         return iname;
     }
     
    -package_request *Hierarchy::make_package_in(int id, package_request *P) {
    +package_request *Hierarchy::make_package_in(int id, package_request *P) {
         return HierarchyLocations::package_in_package(Emit::tree(), id, P);
     }
     
    -void Hierarchy::markup(package_request *R, int hm_id, text_stream *value) {
    +void Hierarchy::markup(package_request *R, int hm_id, text_stream *value) {
         HierarchyLocations::markup(Emit::tree(), R, hm_id, value);
     }
     
    -void Hierarchy::markup_wording(package_request *R, int hm_id, wording W) {
    +void Hierarchy::markup_wording(package_request *R, int hm_id, wording W) {
         TEMPORARY_TEXT(ANT)
         WRITE_TO(ANT, "%W", W);
         Hierarchy::markup(R, hm_id, ANT);
    diff --git a/docs/runtime-module/4-act.html b/docs/runtime-module/4-act.html
    index 8297202d6..2167c7a4d 100644
    --- a/docs/runtime-module/4-act.html
    +++ b/docs/runtime-module/4-act.html
    @@ -225,7 +225,7 @@
     }
     
    diff --git a/docs/runtime-module/4-adj.html b/docs/runtime-module/4-adj.html index 5d9c23498..499df5b24 100644 --- a/docs/runtime-module/4-adj.html +++ b/docs/runtime-module/4-adj.html @@ -465,7 +465,7 @@ objects, if there is one; otherwise the first-declared meaning. }
    diff --git a/docs/runtime-module/4-cl.html b/docs/runtime-module/4-cl.html index e30ebb13f..4261873f9 100644 --- a/docs/runtime-module/4-cl.html +++ b/docs/runtime-module/4-cl.html @@ -160,7 +160,7 @@ the list!); }
  • diff --git a/docs/runtime-module/4-cls.html b/docs/runtime-module/4-cls.html new file mode 100644 index 000000000..b31136fd6 --- /dev/null +++ b/docs/runtime-module/4-cls.html @@ -0,0 +1,232 @@ + + + + Phrases as Values + + + + + + + + + + + + + + + + + + +
    + + +

    To provide the names of phrases as first-class values.

    + +

    §1. So much for setting up constant phrases. Now we come to compilation, and +a surprise. It might be expected that a constant phrase compiles simply to +an I6 routine name, but no: it compiles to a small array called a "closure". +

    + +
    +inter_name *Phrases::Constants::compile(constant_phrase *cphr) {
    +    phrase *ph = ToPhraseFamily::body_of_constant(cphr);
    +    if (ph == NULL) internal_error("cannot reconstruct phrase from cphr");
    +    if (Phrases::compiled_inline(ph) == FALSE)
    +        Routines::ToPhrases::make_request(ph,
    +            ToPhraseFamily::kind(cphr), NULL, EMPTY_WORDING);
    +    return Phrases::Constants::iname(cphr);
    +}
    +
    +inter_name *Phrases::Constants::iname(constant_phrase *cphr) {
    +    if (cphr->cphr_iname == NULL) {
    +        phrase *ph = ToPhraseFamily::body_of_constant(cphr);
    +        if (ph == NULL) internal_error("cannot reconstruct phrase from cphr");
    +        package_request *P = Hierarchy::package_within(CLOSURES_HAP, ph->requests_package);
    +        cphr->cphr_iname = Hierarchy::make_iname_in(CLOSURE_DATA_HL, P);
    +    }
    +    return cphr->cphr_iname;
    +}
    +
    +

    §2. And this is where those arrays are made: +

    + +
    +void Phrases::Constants::compile_closures(void) {
    +    constant_phrase *cphr;
    +    LOOP_OVER(cphr, constant_phrase) {
    +        phrase *ph = ToPhraseFamily::body_of_constant(cphr);
    +        if (ph == NULL) internal_error("cannot reconstruct phrase from cphr");
    +        ToPhraseFamily::kind(cphr);
    +        Compile the closure array for this constant phrase2.1;
    +    }
    +}
    +
    +

    §2.1. The closure array consists of three words: the strong kind ID, the address +of the routine, and the text of the name. (The latter enables us to print +phrase values efficiently.) Note that we make a compilation request for the +phrase in order to make sure somebody has actually compiled it: this is in +case the phrase occurs as a constant but is never explicitly invoked. +

    + +

    Compile the closure array for this constant phrase2.1 = +

    + +
    +    inter_name *iname = Phrases::Constants::iname(cphr);
    +    packaging_state save = Emit::named_array_begin(iname, K_value);
    +
    +    RTKinds::emit_strong_id(cphr->cphr_kind);
    +
    +    inter_name *RS = Routines::ToPhrases::make_iname(ph,
    +        ToPhraseFamily::kind(cphr));
    +    Emit::array_iname_entry(RS);
    +
    +    TEMPORARY_TEXT(name)
    +    WRITE_TO(name, "%W", Nouns::nominative_singular(cphr->name));
    +    Emit::array_text_entry(name);
    +    DISCARD_TEXT(name)
    +
    +    Emit::array_end(save);
    +
    +
    • This code is used in §2.
    +

    §3. Now we come to something trickier. We want default values for kinds of phrases, +because otherwise we can't have variables holding phrases unless they are +always initialised explicitly, and so on. Clearly the default value for a +phrase to nothing is one that does nothing, and for a phrase to some kind K +is one that returns the default value of kind K. For example, the default +value of +

    + +
    +    phrase (text, time) -> number
    +
    +

    is the function which takes any pair of a text and a time, does nothing with +them, and always returns 0. But this means we need to actually compile such +routines. Since there are in principle an infinite number of distinct phrase +kinds, we will only compile them for the phrase kinds which arise during +compilation. +

    + +
    +void Phrases::Constants::compile_default_closure(inter_name *closure_identifier, kind *K) {
    +    package_request *P = Kinds::Behaviour::package(K);
    +    inter_name *rname = Hierarchy::make_iname_in(DEFAULT_CLOSURE_FN_HL, P);
    +
    +    Compile the default routine3.2;
    +    Compile the default closure3.1;
    +}
    +
    +

    §3.1. This must have exactly the same three-word form as the closure arrays +made above. +

    + +

    Compile the default closure3.1 = +

    + +
    +    packaging_state save = Emit::named_array_begin(closure_identifier, K_value);
    +    RTKinds::emit_strong_id(K);
    +    Emit::array_iname_entry(rname);
    +    TEMPORARY_TEXT(DVT)
    +    WRITE_TO(DVT, "default value of "); Kinds::Textual::write(DVT, K);
    +    Emit::array_text_entry(DVT);
    +    DISCARD_TEXT(DVT)
    +    Emit::array_end(save);
    +
    +
    • This code is used in §3.
    +

    §3.2. And here is the function that refers to: +

    + +

    Compile the default routine3.2 = +

    + +
    +    packaging_state save = Routines::begin(rname);
    +    LocalVariables::add_named_call(I"a");
    +    LocalVariables::add_named_call(I"b");
    +    LocalVariables::add_named_call(I"c");
    +    LocalVariables::add_named_call(I"d");
    +    LocalVariables::add_named_call(I"e");
    +    LocalVariables::add_named_call(I"f");
    +    LocalVariables::add_named_call(I"g");
    +    LocalVariables::add_named_call(I"h");
    +    kind *result = NULL;
    +    Kinds::binary_construction_material(K, NULL, &result);
    +    if (Kinds::get_construct(result) != CON_NIL) {
    +        Produce::inv_primitive(Emit::tree(), RETURN_BIP);
    +        Produce::down(Emit::tree());
    +
    +        if (Kinds::Behaviour::uses_pointer_values(result)) {
    +            inter_name *iname = Hierarchy::find(BLKVALUECREATE_HL);
    +            Produce::inv_call_iname(Emit::tree(), iname);
    +            Produce::down(Emit::tree());
    +            RTKinds::emit_strong_id_as_val(result);
    +            Produce::up(Emit::tree());
    +        } else {
    +            if (RTKinds::emit_default_value_as_val(result, EMPTY_WORDING, NULL) != TRUE)
    +                Produce::val(Emit::tree(), K_number, LITERAL_IVAL, 0);
    +        }
    +
    +        Produce::up(Emit::tree());
    +    }
    +    Routines::end(save);
    +
    +
    • This code is used in §3.
    + + +
    + + + diff --git a/docs/runtime-module/4-ct.html b/docs/runtime-module/4-ct.html index 4b473e4dd..5984fafb7 100644 --- a/docs/runtime-module/4-ct.html +++ b/docs/runtime-module/4-ct.html @@ -470,7 +470,7 @@ exceptional case. }
    diff --git a/docs/runtime-module/4-efart.html b/docs/runtime-module/4-efart.html index f8effb87c..66c3c468d 100644 --- a/docs/runtime-module/4-efart.html +++ b/docs/runtime-module/4-efart.html @@ -178,7 +178,7 @@ and author. }
    diff --git a/docs/runtime-module/4-epv.html b/docs/runtime-module/4-epv.html index c2587800c..bb581ba69 100644 --- a/docs/runtime-module/4-epv.html +++ b/docs/runtime-module/4-epv.html @@ -387,7 +387,7 @@ the property-permission symbol accordingly: }
    diff --git a/docs/runtime-module/4-es.html b/docs/runtime-module/4-es.html index fa447cf87..b9acf1c39 100644 --- a/docs/runtime-module/4-es.html +++ b/docs/runtime-module/4-es.html @@ -89,7 +89,7 @@ they provide values different from each other and from all other functions. }
    diff --git a/docs/runtime-module/4-fc.html b/docs/runtime-module/4-fc.html index 5c39aa3d8..20b26e0a7 100644 --- a/docs/runtime-module/4-fc.html +++ b/docs/runtime-module/4-fc.html @@ -216,7 +216,7 @@ Inform's own version number), but it belongs nowhere else either, so: } diff --git a/docs/runtime-module/4-i6i.html b/docs/runtime-module/4-i6i.html index bf1d43b33..2ea881afc 100644 --- a/docs/runtime-module/4-i6i.html +++ b/docs/runtime-module/4-i6i.html @@ -315,7 +315,7 @@ requests, which, again, we do by instructing the Template code. } diff --git a/docs/runtime-module/4-ic.html b/docs/runtime-module/4-ic.html index 4967799b4..d3bbebbed 100644 --- a/docs/runtime-module/4-ic.html +++ b/docs/runtime-module/4-ic.html @@ -502,7 +502,7 @@ constants, and use the Link constants to progress; we stop at } diff --git a/docs/runtime-module/4-ins.html b/docs/runtime-module/4-ins.html index bd989bf28..8295b4b44 100644 --- a/docs/runtime-module/4-ins.html +++ b/docs/runtime-module/4-ins.html @@ -158,7 +158,7 @@ declarations) and finally return } diff --git a/docs/runtime-module/4-itc.html b/docs/runtime-module/4-itc.html index c1dfa13df..dbaa3701c 100644 --- a/docs/runtime-module/4-itc.html +++ b/docs/runtime-module/4-itc.html @@ -648,7 +648,7 @@ only and may change at any time without notice.
    • This code is used in §4.
    diff --git a/docs/runtime-module/4-iti.html b/docs/runtime-module/4-iti.html index 70750a2d6..48cc69704 100644 --- a/docs/runtime-module/4-iti.html +++ b/docs/runtime-module/4-iti.html @@ -420,7 +420,7 @@ time.) {-index:name}} diff --git a/docs/runtime-module/4-jl.html b/docs/runtime-module/4-jl.html index ff6d6472f..438614411 100644 --- a/docs/runtime-module/4-jl.html +++ b/docs/runtime-module/4-jl.html @@ -202,7 +202,7 @@ specification --> 0 } diff --git a/docs/runtime-module/4-lpart.html b/docs/runtime-module/4-lpart.html index 980c0d945..52546d0f0 100644 --- a/docs/runtime-module/4-lpart.html +++ b/docs/runtime-module/4-lpart.html @@ -1551,7 +1551,7 @@ the sorting measure. } diff --git a/docs/runtime-module/4-lt.html b/docs/runtime-module/4-lt.html index 0d2feff13..e98bcfcff 100644 --- a/docs/runtime-module/4-lt.html +++ b/docs/runtime-module/4-lt.html @@ -182,7 +182,7 @@ is significant to the run-time list-printing code.
    • This code is used in §3.
    diff --git a/docs/runtime-module/4-msr.html b/docs/runtime-module/4-msr.html index c85c74455..0363590e8 100644 --- a/docs/runtime-module/4-msr.html +++ b/docs/runtime-module/4-msr.html @@ -128,7 +128,7 @@
    • The structure measurement_compilation_data is private to this section.
    diff --git a/docs/runtime-module/4-ni.html b/docs/runtime-module/4-ni.html index 6bc97386e..1e8e2bb1f 100644 --- a/docs/runtime-module/4-ni.html +++ b/docs/runtime-module/4-ni.html @@ -159,7 +159,7 @@ instance, the Standard Rules want the player-character object to be called } diff --git a/docs/runtime-module/4-prp.html b/docs/runtime-module/4-prp.html index a1ad74d2c..e5e3b6811 100644 --- a/docs/runtime-module/4-prp.html +++ b/docs/runtime-module/4-prp.html @@ -597,7 +597,7 @@ answer now. } diff --git a/docs/runtime-module/4-rart.html b/docs/runtime-module/4-rart.html index 66141727f..534990ac6 100644 --- a/docs/runtime-module/4-rart.html +++ b/docs/runtime-module/4-rart.html @@ -2174,7 +2174,7 @@ matches the specific necessary kind of object if there is one. } diff --git a/docs/runtime-module/4-rls.html b/docs/runtime-module/4-rls.html index a202b927d..611af4a47 100644 --- a/docs/runtime-module/4-rls.html +++ b/docs/runtime-module/4-rls.html @@ -113,6 +113,14 @@ function togglePopup(material_id) { return &(R->defn_as_I7_source->body_of_defn->stack_frame); } +void RTRules::prepare_rule(imperative_defn *id, rule *R) { + rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); + package_request *P = RTRules::package(R); + if (Wordings::empty(rfd->constant_name)) + Hierarchy::markup_wording(P, RULE_NAME_HMD, Node::get_text(id->at)); + id->body_of_defn->ph_iname = Hierarchy::make_localised_iname_in(RULE_FN_HL, P, id->body_of_defn->owning_module); +} + package_request *RTRules::package(rule *R) { return R->compilation_data.rule_package; } @@ -1093,7 +1101,7 @@ code are the real outcome of the code in this section. } diff --git a/docs/runtime-module/4-rsfk.html b/docs/runtime-module/4-rsfk.html index a8761e11a..ff86744b9 100644 --- a/docs/runtime-module/4-rsfk.html +++ b/docs/runtime-module/4-rsfk.html @@ -174,7 +174,7 @@ chosen), but no problem message has been issued about this, or Emit::array_generic_entry(v1, v2); return rv; } -int RTKinds::emit_default_value_as_val(kind *K, wording W, char *storage_name) { +int RTKinds::emit_default_value_as_val(kind *K, wording W, char *storage_name) { value_holster VH = Holsters::new(INTER_DATA_VHMODE); int rv = RTKinds::compile_default_value_vh(&VH, K, W, storage_name); Holsters::to_val_mode(Emit::tree(), &VH); @@ -677,7 +677,7 @@ turns up. This means remembering everything we've seen, using a new structure:

    -void RTKinds::emit_strong_id(kind *K) {
    +void RTKinds::emit_strong_id(kind *K) {
         runtime_kind_structure *rks = RTKinds::get_rks(K);
         if (rks) {
             Emit::array_iname_entry(rks->rks_iname);
    @@ -686,7 +686,7 @@ turns up. This means remembering everything we've seen, using a new structure:
         }
     }
     
    -void RTKinds::emit_strong_id_as_val(kind *K) {
    +void RTKinds::emit_strong_id_as_val(kind *K) {
         runtime_kind_structure *rks = RTKinds::get_rks(K);
         if (rks) {
             Produce::val_iname(Emit::tree(), K_value, rks->rks_iname);
    @@ -920,7 +920,7 @@ recursively scanned through for us, so that if we have seen a construction
         inter_name *identifier = rks->rks_dv_iname;
         current_sentence = rks->default_requested_here;
         if (Kinds::get_construct(K) == CON_phrase) {
    -        Phrases::Constants::compile_default_closure(identifier, K);
    +        Phrases::Constants::compile_default_closure(identifier, K);
         } else if (Kinds::get_construct(K) == CON_relation) {
             RTRelations::compile_default_relation(identifier, K);
         } else if (Kinds::get_construct(K) == CON_list_of) {
    @@ -2285,7 +2285,7 @@ and it seems best to reject the extra complexity needed.
     
    • This code is used in §32.
    diff --git a/docs/runtime-module/4-rsft.html b/docs/runtime-module/4-rsft.html index a34a34ab2..0c75b6296 100644 --- a/docs/runtime-module/4-rsft.html +++ b/docs/runtime-module/4-rsft.html @@ -542,7 +542,7 @@ should return FALSE} diff --git a/docs/runtime-module/4-rsp.html b/docs/runtime-module/4-rsp.html index a77366167..d7002d202 100644 --- a/docs/runtime-module/4-rsp.html +++ b/docs/runtime-module/4-rsp.html @@ -697,7 +697,7 @@ text needs to be printed in a particular way. diff --git a/docs/runtime-module/4-rtn.html b/docs/runtime-module/4-rtn.html index b3ee27663..ad3f4157c 100644 --- a/docs/runtime-module/4-rtn.html +++ b/docs/runtime-module/4-rtn.html @@ -81,7 +81,7 @@ already been set up, or not. Here's not:

    -packaging_state Routines::begin(inter_name *name) {
    +packaging_state Routines::begin(inter_name *name) {
         return Routines::begin_framed(name, NULL);
     }
     
    @@ -140,7 +140,7 @@ did not.

    -void Routines::end(packaging_state save) {
    +void Routines::end(packaging_state save) {
         kind *R_kind = LocalVariables::deduced_function_kind(currently_compiling_in_frame);
     
         inter_name *kernel_name = NULL, *public_name = currently_compiling_iname;
    @@ -307,7 +307,7 @@ after the call parameters, and is used only as a scratch variable.
     
    • This code is used in §4.
    diff --git a/docs/runtime-module/4-tl.html b/docs/runtime-module/4-tl.html index 6e269abe5..47d38357d 100644 --- a/docs/runtime-module/4-tl.html +++ b/docs/runtime-module/4-tl.html @@ -445,7 +445,7 @@ number -1). } diff --git a/docs/runtime-module/4-ts.html b/docs/runtime-module/4-ts.html index f3ff18c42..f71e73b56 100644 --- a/docs/runtime-module/4-ts.html +++ b/docs/runtime-module/4-ts.html @@ -460,7 +460,7 @@ we aren't doing very much; most TSs will be passed quickly over. } diff --git a/docs/runtime-module/4-ts2.html b/docs/runtime-module/4-ts2.html index 463041c1c..29d0a8a90 100644 --- a/docs/runtime-module/4-ts2.html +++ b/docs/runtime-module/4-ts2.html @@ -92,7 +92,7 @@ stipulations on place and possessions attached. CLASS_DEFINITION } test_scenario; -
    • The structure test_scenario is accessed in 4/rsp, 4/rls, 4/act, 4/uoart, 4/vrb, 4/prp, 5/sc, 5/gpr and here.
    +
    • The structure test_scenario is accessed in 4/rsp, 4/rls, 4/act, 4/uoart, 4/vrb, 4/prp, 4/cls, 5/sc, 5/gpr and here.

    §2.

    @@ -297,7 +297,7 @@ stipulations on place and possessions attached.
     }
     
    diff --git a/docs/runtime-module/4-tv.html b/docs/runtime-module/4-tv.html index 40e85c375..da59475a9 100644 --- a/docs/runtime-module/4-tv.html +++ b/docs/runtime-module/4-tv.html @@ -169,7 +169,7 @@ hacky constructs which only the SR should ever refer to. } diff --git a/docs/runtime-module/4-uoart.html b/docs/runtime-module/4-uoart.html index 7a20edd75..43f2b8866 100644 --- a/docs/runtime-module/4-uoart.html +++ b/docs/runtime-module/4-uoart.html @@ -205,7 +205,7 @@ source code: see the DM4 for details. } diff --git a/docs/runtime-module/4-vart.html b/docs/runtime-module/4-vart.html index a41d65693..122e5a3c1 100644 --- a/docs/runtime-module/4-vart.html +++ b/docs/runtime-module/4-vart.html @@ -649,7 +649,7 @@ usages to the debugging log. } diff --git a/docs/runtime-module/4-vrb.html b/docs/runtime-module/4-vrb.html index d79f87e71..47adeba50 100644 --- a/docs/runtime-module/4-vrb.html +++ b/docs/runtime-module/4-vrb.html @@ -476,7 +476,7 @@ which makes its kind safe. Hence the error messages.
    • This code is used in §6.
    diff --git a/docs/runtime-module/5-act.html b/docs/runtime-module/5-act.html index af838eb37..318a5ac17 100644 --- a/docs/runtime-module/5-act.html +++ b/docs/runtime-module/5-act.html @@ -502,7 +502,7 @@ infrastructure, and we access it with a single call. } diff --git a/docs/runtime-module/5-ap.html b/docs/runtime-module/5-ap.html index 8b6521198..39dff3b30 100644 --- a/docs/runtime-module/5-ap.html +++ b/docs/runtime-module/5-ap.html @@ -911,7 +911,7 @@ and in this case we therefore ignore
  • This code is used in §7.
  • diff --git a/docs/runtime-module/5-bck.html b/docs/runtime-module/5-bck.html index fa6bb3389..c1f232add 100644 --- a/docs/runtime-module/5-bck.html +++ b/docs/runtime-module/5-bck.html @@ -142,7 +142,7 @@
    • This code is used in §2.
    diff --git a/docs/runtime-module/5-bd.html b/docs/runtime-module/5-bd.html index 26cdec9d6..752a35ee0 100644 --- a/docs/runtime-module/5-bd.html +++ b/docs/runtime-module/5-bd.html @@ -211,7 +211,7 @@ around it, in byte-accessible memory. } diff --git a/docs/runtime-module/5-cg.html b/docs/runtime-module/5-cg.html index ef621bbd4..c1dde37f6 100644 --- a/docs/runtime-module/5-cg.html +++ b/docs/runtime-module/5-cg.html @@ -455,7 +455,7 @@ next priority, and so on up the hierarchy. } diff --git a/docs/runtime-module/5-cgl.html b/docs/runtime-module/5-cgl.html index 087e4a02d..d7750ae15 100644 --- a/docs/runtime-module/5-cgl.html +++ b/docs/runtime-module/5-cgl.html @@ -1635,7 +1635,7 @@ nothing else. diff --git a/docs/runtime-module/5-ef.html b/docs/runtime-module/5-ef.html index 2cc082aea..45265a42f 100644 --- a/docs/runtime-module/5-ef.html +++ b/docs/runtime-module/5-ef.html @@ -129,7 +129,7 @@
    • The structure external_file_compilation_data is private to this section.
    diff --git a/docs/runtime-module/5-fgr.html b/docs/runtime-module/5-fgr.html index f57e07260..f1f3cbd8e 100644 --- a/docs/runtime-module/5-fgr.html +++ b/docs/runtime-module/5-fgr.html @@ -77,7 +77,7 @@ } diff --git a/docs/runtime-module/5-gng.html b/docs/runtime-module/5-gng.html index e605a6cd6..401a08bee 100644 --- a/docs/runtime-module/5-gng.html +++ b/docs/runtime-module/5-gng.html @@ -134,7 +134,7 @@ } diff --git a/docs/runtime-module/5-gpr.html b/docs/runtime-module/5-gpr.html index 976b7455b..0e04c96f8 100644 --- a/docs/runtime-module/5-gpr.html +++ b/docs/runtime-module/5-gpr.html @@ -1326,7 +1326,7 @@ alter the value of self} diff --git a/docs/runtime-module/5-los.html b/docs/runtime-module/5-los.html index 928c06c14..2ad2a0ab4 100644 --- a/docs/runtime-module/5-los.html +++ b/docs/runtime-module/5-los.html @@ -149,7 +149,7 @@ function togglePopup(material_id) {
    • This code is used in §2.
    diff --git a/docs/runtime-module/5-nap.html b/docs/runtime-module/5-nap.html index d79f4aa1b..5719a2388 100644 --- a/docs/runtime-module/5-nap.html +++ b/docs/runtime-module/5-nap.html @@ -112,7 +112,7 @@ function togglePopup(material_id) {
    • The structure nap_compilation_data is private to this section.
    diff --git a/docs/runtime-module/5-nft.html b/docs/runtime-module/5-nft.html index dac548975..0b047f51b 100644 --- a/docs/runtime-module/5-nft.html +++ b/docs/runtime-module/5-nft.html @@ -352,7 +352,7 @@ that's why.) } diff --git a/docs/runtime-module/5-nmn.html b/docs/runtime-module/5-nmn.html index 993ce656b..87ecc37eb 100644 --- a/docs/runtime-module/5-nmn.html +++ b/docs/runtime-module/5-nmn.html @@ -186,7 +186,7 @@ function togglePopup(material_id) {
    • The structure short_name_notice is private to this section.
    diff --git a/docs/runtime-module/5-prs.html b/docs/runtime-module/5-prs.html index ed88462c6..34ade2a85 100644 --- a/docs/runtime-module/5-prs.html +++ b/docs/runtime-module/5-prs.html @@ -188,7 +188,7 @@ for the kinds we inherit from.
    • The structure cached_understanding is private to this section.
    diff --git a/docs/runtime-module/5-rgn.html b/docs/runtime-module/5-rgn.html index dbf6fb4fc..fe963f7ac 100644 --- a/docs/runtime-module/5-rgn.html +++ b/docs/runtime-module/5-rgn.html @@ -108,7 +108,7 @@ function togglePopup(material_id) { } diff --git a/docs/runtime-module/5-sc.html b/docs/runtime-module/5-sc.html index 4e336c10b..bd6fc15a2 100644 --- a/docs/runtime-module/5-sc.html +++ b/docs/runtime-module/5-sc.html @@ -440,7 +440,7 @@ turn by turn.
    • This code is used in §4.2.
    diff --git a/docs/runtime-module/5-scn.html b/docs/runtime-module/5-scn.html index c4f25ea57..0f0afb037 100644 --- a/docs/runtime-module/5-scn.html +++ b/docs/runtime-module/5-scn.html @@ -782,7 +782,7 @@ actually running: } diff --git a/docs/runtime-module/5-se.html b/docs/runtime-module/5-se.html index d7648a762..12dadfcdb 100644 --- a/docs/runtime-module/5-se.html +++ b/docs/runtime-module/5-se.html @@ -77,7 +77,7 @@ } diff --git a/docs/runtime-module/5-spt.html b/docs/runtime-module/5-spt.html index 7f34edac4..6f93e0ca0 100644 --- a/docs/runtime-module/5-spt.html +++ b/docs/runtime-module/5-spt.html @@ -142,7 +142,7 @@ be compiled, so this code is never used. } diff --git a/docs/runtime-module/5-tm.html b/docs/runtime-module/5-tm.html index 8a8d00779..9cc3af289 100644 --- a/docs/runtime-module/5-tm.html +++ b/docs/runtime-module/5-tm.html @@ -341,7 +341,7 @@ identifier names for instance have not yet been settled. } diff --git a/docs/runtime-module/5-tp.html b/docs/runtime-module/5-tp.html index 06c5da6b6..2182a8d51 100644 --- a/docs/runtime-module/5-tp.html +++ b/docs/runtime-module/5-tp.html @@ -114,7 +114,7 @@ the function ChangePlayer} diff --git a/docs/runtime-module/5-tpv.html b/docs/runtime-module/5-tpv.html index 17ba49c2f..e26073866 100644 --- a/docs/runtime-module/5-tpv.html +++ b/docs/runtime-module/5-tpv.html @@ -384,7 +384,7 @@ function togglePopup(material_id) {
    • This code is used in §1.1 (three times).
    diff --git a/docs/runtime-module/5-tr.html b/docs/runtime-module/5-tr.html new file mode 100644 index 000000000..0b107c670 --- /dev/null +++ b/docs/runtime-module/5-tr.html @@ -0,0 +1,118 @@ + + + + Timed Rules + + + + + + + + + + + + + + + +
    + + +

    Code to support rules like "At 12:03AM: ...".

    + +

    §1. Timed events are stored in two simple arrays, processed by run-time code. +

    + +
    +void RTTimedRules::TimedEventsTable(void) {
    +    inter_name *iname = Hierarchy::find(TIMEDEVENTSTABLE_HL);
    +    packaging_state save = Emit::named_table_array_begin(iname, K_value);
    +    int when_count = 0;
    +    phrase *ph;
    +    LOOP_OVER(ph, phrase) {
    +        int t = TimedRules::get_timing_of_event(ph->from);
    +        if (t == NOT_A_TIMED_EVENT) continue;
    +        if (t == NO_FIXED_TIME) when_count++;
    +        else Emit::array_iname_entry(Phrases::iname(ph));
    +    }
    +
    +    for (int i=0; i<when_count+1; i++) {
    +        Emit::array_numeric_entry(0);
    +        Emit::array_numeric_entry(0);
    +    }
    +    Emit::array_end(save);
    +    Hierarchy::make_available(Emit::tree(), iname);
    +}
    +
    +void RTTimedRules::TimedEventTimesTable(void) {
    +    inter_name *iname = Hierarchy::find(TIMEDEVENTTIMESTABLE_HL);
    +    packaging_state save = Emit::named_table_array_begin(iname, K_number);
    +    int when_count = 0;
    +    phrase *ph;
    +    LOOP_OVER(ph, phrase) {
    +        int t = TimedRules::get_timing_of_event(ph->from);
    +        if (t == NOT_A_TIMED_EVENT) continue;
    +        if (t == NO_FIXED_TIME) when_count++;
    +        else Emit::array_numeric_entry((inter_ti) t);
    +    }
    +
    +    for (int i=0; i<when_count+1; i++) {
    +        Emit::array_numeric_entry(0);
    +        Emit::array_numeric_entry(0);
    +    }
    +    Emit::array_end(save);
    +    Hierarchy::make_available(Emit::tree(), iname);
    +}
    +
    + + +
    + + + diff --git a/docs/runtime-module/5-ts.html b/docs/runtime-module/5-ts.html index ed7ee5f69..99ed03605 100644 --- a/docs/runtime-module/5-ts.html +++ b/docs/runtime-module/5-ts.html @@ -88,7 +88,7 @@ } diff --git a/docs/runtime-module/index.html b/docs/runtime-module/index.html index 5d1db5fad..261828cd8 100644 --- a/docs/runtime-module/index.html +++ b/docs/runtime-module/index.html @@ -303,6 +303,11 @@ Runtime Support for Tables
    - To compile run-time data structures holding tables.

    +
  • +

    + Phrases as Values - + To provide the names of phrases as first-class values.

    +
  • @@ -374,6 +379,11 @@ The Score -

  • +
  • +

    + Timed Rules - + Code to support rules like "At 12:03AM: ...".

    +
  • Scenes - diff --git a/docs/values-module/2-dsh.html b/docs/values-module/2-dsh.html index c03f2c99f..b39c54b8b 100644 --- a/docs/values-module/2-dsh.html +++ b/docs/values-module/2-dsh.html @@ -2268,7 +2268,7 @@ extensions). Invocations::mark_unproven(inv); } if (ph) { - wording NW = ph->ph_documentation_symbol; + wording NW = ToPhraseFamily::doc_ref(ph->from); if (Wordings::nonempty(NW)) { TEMPORARY_TEXT(pds) WRITE_TO(pds, "%+W", Wordings::one_word(Wordings::first_wn(NW))); diff --git a/docs/values-module/2-rvl.html b/docs/values-module/2-rvl.html index 6166e0a84..e3e3fe138 100644 --- a/docs/values-module/2-rvl.html +++ b/docs/values-module/2-rvl.html @@ -640,7 +640,7 @@ assertion traverse:

    -    return Phrases::Constants::kind(Rvalues::to_constant_phrase(spec));
    +    return ToPhraseFamily::kind(Rvalues::to_constant_phrase(spec));
     
    • This code is used in §24.

    §24.7. This too is tricky. Some phrases to decide values are unambiguous. If diff --git a/inform7/Downloads/preform-diagnostics.txt b/inform7/Downloads/preform-diagnostics.txt index f0fe41b6b..cce371ff4 100644 --- a/inform7/Downloads/preform-diagnostics.txt +++ b/inform7/Downloads/preform-diagnostics.txt @@ -1,10 +1,10 @@ - internal nti 26 constraint (none) extremes [1, 1] + internal nti 25 constraint (none) extremes [1, 1] - internal hits 1022/5458 nti 27 constraint (none) extremes [0, 0] + internal hits 1168/7638 nti 26 constraint (none) extremes [0, 0] - internal hits 3873/7958 nti 28 constraint (none) extremes [0, 0] + internal hits 3873/7958 nti 27 constraint (none) extremes [0, 0] - hits 746/1492 nti 29 constraint (none) extremes [1, infinity) + hits 746/1492 nti 28 constraint (none) extremes [1, infinity) English: {......} (hits 746/746) (matched long text) constraint (none) extremes [1, infinity) @@ -14,24 +14,24 @@ {......} , {......} (hits 6/13) (matched long text) constraint DS = {15} extremes [3, infinity) - internal nti 30 constraint (none) extremes [1, 1] + internal nti 29 constraint (none) extremes [1, 1] - internal hits 2898/25202 nti 31 constraint (none) extremes [1, 1] + internal hits 2898/25202 nti 30 constraint (none) extremes [1, 1] - internal nti 6 constraint (none) extremes [1, 1] + internal nti 31 constraint (none) extremes [1, 1] - internal hits 25/50 nti 7 constraint (none) extremes [1, 1] + internal hits 25/50 nti 6 constraint (none) extremes [1, 1] - internal nti 8 constraint (none) extremes [1, 1] + internal nti 7 constraint (none) extremes [1, 1] - internal hits 2/12958 nti 9 constraint (none) extremes [0, 0] + internal hits 2/12958 nti 8 constraint (none) extremes [0, 0] hits 0/18 nti 16 constraint DS = {16} extremes [3, infinity) English: {......} , _or {......} - (hits 0/9) constraint DS = {16} extremes [4, infinity) + (hits 0/3) constraint DS = {16} extremes [4, infinity) {......} _or {......} - (hits 0/9) constraint DS = {16} extremes [3, infinity) + (hits 0/3) constraint DS = {16} extremes [3, infinity) nti 17 constraint DS = {17} extremes [3, infinity) English: @@ -73,11 +73,11 @@ {...} than constraint DS = {22} extremes [2, infinity) - internal nti 10 constraint (none) extremes [1, infinity) + internal nti 9 constraint (none) extremes [1, infinity) - internal nti 11 constraint (none) extremes [1, infinity) + internal nti 10 constraint (none) extremes [1, infinity) - nti 12 constraint CW = {23, 24, 25} extremes [2, 2] + nti 11 constraint CW = {23, 24, 25} extremes [2, 2] English: constraint CS = {23} extremes [2, 2] @@ -339,7 +339,7 @@ yw* an constraint CS = {25} extremes [2, 2] - nti 13 constraint DW = {6, 7, 26, 27, 28, 29, 30, 31} extremes [3, infinity) + nti 12 constraint DW = {6, 7, 26, 27, 28, 29, 30, 31} extremes [3, infinity) English: {...} constraint DS = {26} extremes [3, infinity) @@ -1499,7 +1499,7 @@ shouldn't shouldn't constraint CS = {25} extremes [2, 2] - nti 14 constraint DW = {12, 13, 14, 15, 16} extremes [3, infinity) + nti 13 constraint DW = {12, 13, 14, 15, 16} extremes [3, infinity) English: {...} constraint DS = {12} extremes [3, infinity) @@ -2025,7 +2025,7 @@ * 0ing constraint CS = {16} extremes [2, 2] - nti 15 constraint DW = {17, 18, 19, 20, 21, 22} extremes [2, infinity) + nti 14 constraint DW = {17, 18, 19, 20, 21, 22} extremes [2, infinity) English: constraint CS = {17} extremes [2, 2] @@ -2337,7 +2337,7 @@ write written constraint CS = {17} extremes [2, 2] - nti 16 constraint DW = {6, 7, 26, 27, 28, 29, 30, 31} extremes [2, infinity) + nti 15 constraint DW = {6, 7, 26, 27, 28, 29, 30, 31} extremes [2, infinity) English: constraint CS = {30} extremes [2, 2] @@ -2353,7 +2353,7 @@ do does constraint CS = {30} extremes [2, 2] - nti 17 constraint DW = {18, 19, 20, 21, 22} extremes [3, infinity) + nti 16 constraint DW = {18, 19, 20, 21, 22} extremes [3, infinity) English: {...} constraint DS = {18} extremes [3, infinity) @@ -3595,7 +3595,7 @@ * 0ed constraint CS = {22} extremes [2, 2] - nti 18 constraint DW = {9, 10, 11} extremes [2, infinity) + nti 17 constraint DW = {9, 10, 11} extremes [2, infinity) English: constraint CS = {9} extremes [2, 2] @@ -4642,7 +4642,7 @@ * 1 constraint CS = {21} extremes [2, 2] - nti 19 constraint CS = {22} extremes [1, 1] + nti 18 constraint CS = {22} extremes [1, 1] English: constraint CS = {22} extremes [1, 1] @@ -4728,45 +4728,45 @@ twelfth constraint CS = {27} extremes [1, 1] - internal hits 200/22414 nti r0 constraint CS = {r0} extremes [1, 1] + internal hits 200/24864 nti r0 constraint CS = {r0} extremes [1, 1] internal nti r1 constraint CS = {r1} extremes [1, 1] - internal hits 36/72 nti 20 constraint (none) extremes [1, 1] + internal hits 36/72 nti 19 constraint (none) extremes [1, 1] - internal hits 0/258 nti 25 constraint (none) extremes [1, infinity) + internal hits 0/258 nti 24 constraint (none) extremes [1, infinity) - hits 36283/72566 nti 21 constraint (none) extremes [1, infinity) + hits 36283/72566 nti 20 constraint (none) extremes [1, infinity) English: {...} (hits 7821/36283) (matched long text) constraint (none) extremes [2, infinity) {...} (hits 28462/28462) (matched long text) constraint (none) extremes [1, infinity) - nti 22 constraint (none) extremes [1, infinity) + nti 21 constraint (none) extremes [1, infinity) English: {...} constraint (none) extremes [2, infinity) {...} constraint (none) extremes [1, infinity) - hits 82853/165706 nti 23 constraint (none) extremes [1, infinity) + hits 82853/165706 nti 22 constraint (none) extremes [1, infinity) English:

    {...} (hits 16065/47390) (matched long text) constraint (none) extremes [2, infinity) {...} (hits 66788/66788) (matched long text) constraint (none) extremes [1, infinity) - nti 24 constraint (none) extremes [2, infinity) + nti 23 constraint (none) extremes [2, infinity) English:
    {...} constraint (none) extremes [2, infinity)
    internal hits 16515/98328 nti r2 constraint (none) extremes [1, 1] - internal hits 20294/236178 nti r2 constraint (none) extremes [1, 1] + internal hits 20294/236180 nti r2 constraint (none) extremes [1, 1] - internal hits 2445/41202 nti r2 constraint (none) extremes [1, 1] + internal hits 2270/40830 nti r2 constraint (none) extremes [1, 1] nti r2 constraint CS = {r2} extremes [6, 6] English: @@ -4830,37 +4830,37 @@ hits 16/21832 nti 29 constraint DS = {29} extremes [2, infinity) English: not {...} - (hits 16/4757) (matched long text) constraint DS = {29} extremes [2, infinity) + (hits 16/5683) (matched long text) constraint DS = {29} extremes [2, infinity) hits 79/158 nti 30 constraint (none) extremes [1, infinity) English: of the {...} - (hits 0/8) constraint DS = {30} extremes [3, infinity) + (hits 0/16) constraint DS = {30} extremes [3, infinity) of {...} - (hits 0/8) constraint DS = {30} extremes [2, infinity) + (hits 0/24) constraint DS = {30} extremes [2, infinity) {...} (hits 79/79) (matched: 'dvd carried by the person asked') constraint (none) extremes [1, infinity) hits 0/21548 nti 31 constraint DS = {31} extremes [2, infinity) English: no one {***} - (hits 0/5862) constraint DS = {31} extremes [2, infinity) + (hits 0/5933) constraint DS = {31} extremes [2, infinity) - internal hits 92/1206 nti 25 constraint (none) extremes [1, 1] + internal hits 92/1206 nti 24 constraint (none) extremes [1, 1] - internal hits 7/56 nti 26 constraint (none) extremes [1, 1] + internal hits 7/56 nti 25 constraint (none) extremes [1, 1] - internal hits 239/18292 nti 27 constraint (none) extremes [1, 1] + internal hits 239/18292 nti 26 constraint (none) extremes [1, 1] - internal nti 28 constraint (none) extremes [1, 1] + internal nti 27 constraint (none) extremes [1, 1] - internal nti 29 constraint (none) extremes [1, 1] + internal nti 28 constraint (none) extremes [1, 1] - internal hits 0/444 nti 30 constraint (none) extremes [1, 1] + internal hits 0/444 nti 29 constraint (none) extremes [1, 1] - internal hits 0/176 nti 31 constraint (none) extremes [1, 1] + internal hits 0/176 nti 30 constraint (none) extremes [1, 1] - internal hits 0/690 nti 6 constraint (none) extremes [1, 1] + internal hits 0/690 nti 31 constraint (none) extremes [1, 1] nti 6 constraint CS = {6} extremes [6, 6] English: @@ -4911,51 +4911,51 @@ here here here here here here constraint CS = {12} extremes [6, 6] - internal hits 3922/8828 nti 6 constraint FS = {6} extremes [1, infinity) + internal hits 4154/9292 nti 6 constraint FS = {6} extremes [1, infinity) internal hits 16/128 nti 7 constraint FS = {7} extremes [1, infinity) - internal hits 1/8238 nti 8 constraint FS = {8} extremes [1, infinity) + internal hits 1/8778 nti 8 constraint FS = {8} extremes [1, infinity) - internal hits 0/2036 nti 9 constraint FS = {9} extremes [1, infinity) + internal hits 0/1846 nti 9 constraint FS = {9} extremes [1, infinity) internal nti 10 constraint FS = {10} extremes [1, infinity) internal nti 11 constraint FS = {11} extremes [1, infinity) - internal hits 210/5162 nti 7 constraint (none) extremes [1, infinity) + internal hits 210/5162 nti 6 constraint (none) extremes [1, infinity) - internal hits 59/4030 nti 8 constraint (none) extremes [1, infinity) + internal hits 59/4030 nti 7 constraint (none) extremes [1, infinity) - internal hits 1/2 nti 9 constraint (none) extremes [1, infinity) + internal hits 1/2 nti 8 constraint (none) extremes [1, infinity) - internal nti 10 constraint (none) extremes [1, infinity) + internal nti 9 constraint (none) extremes [1, infinity) - internal hits 58/118 nti 11 constraint (none) extremes [1, infinity) + internal hits 58/118 nti 10 constraint (none) extremes [1, infinity) internal nti 12 constraint DS = {12} extremes [1, infinity) - internal hits 635/18496 nti 13 constraint DS = {13} extremes [1, infinity) + internal hits 635/19966 nti 13 constraint DS = {13} extremes [1, infinity) - internal hits 258/7836 nti 14 constraint DS = {14} extremes [1, infinity) + internal hits 258/8308 nti 14 constraint DS = {14} extremes [1, infinity) - hits 67/4302 nti 13 constraint CS = {13} extremes [1, 1] + hits 67/4344 nti 13 constraint CS = {13} extremes [1, 1] English: always/certainly - (hits 10/885) (matched: 'always') constraint CS = {13} extremes [1, 1] + (hits 10/909) (matched: 'always') constraint CS = {13} extremes [1, 1] usually/normally - (hits 53/875) (matched: 'usually') constraint CS = {13} extremes [1, 1] + (hits 53/899) (matched: 'usually') constraint CS = {13} extremes [1, 1] rarely/seldom - (hits 0/822) constraint CS = {13} extremes [1, 1] + (hits 0/846) constraint CS = {13} extremes [1, 1] never - (hits 4/822) (matched: 'never') constraint CS = {13} extremes [1, 1] + (hits 4/846) (matched: 'never') constraint CS = {13} extremes [1, 1] initially - (hits 0/818) constraint CS = {13} extremes [1, 1] + (hits 0/842) constraint CS = {13} extremes [1, 1] hits 0/4304 nti 14 constraint DS = {14} extremes [1, infinity) English: {***} once/twice/thrice/turn/turns/time/times - (hits 0/1582) constraint DS = {14} extremes [1, infinity) + (hits 0/1779) constraint DS = {14} extremes [1, infinity) nti 18 constraint DW = {15, 16, 17, 18} extremes [1, 9] English: @@ -4983,7 +4983,7 @@ constraint DW = {15, 16} extremes [1, 6] - nti 12 constraint DW = {15, 16} extremes [1, 6] + nti 11 constraint DW = {15, 16} extremes [1, 6] English: constraint DS = {15} extremes [1, 6] @@ -5010,7 +5010,7 @@ turn/turns constraint DS = {16} extremes [2, 3] - nti 13 constraint (none) extremes [1, 2] + nti 12 constraint (none) extremes [1, 2] English: constraint (none) extremes [2, 2] @@ -5019,24 +5019,24 @@ constraint CS = {r0} extremes [1, 1] - hits 3152/6304 nti 14 constraint (none) extremes [1, infinity) + hits 3152/6304 nti 13 constraint (none) extremes [1, infinity) English: {...} (hits 3152/3152) (matched long text) constraint (none) extremes [1, infinity) - hits 60/120 nti 15 constraint (none) extremes [0, infinity) + hits 60/120 nti 14 constraint (none) extremes [0, infinity) English: ^ (hits 0/60) constraint (none) extremes [0, infinity) (hits 60/60) (matched: 'fixed in place') constraint (none) extremes [1, infinity) - hits 33/109954 nti 19 constraint CS = {19} extremes [1, 1] + hits 33/108354 nti 19 constraint CS = {19} extremes [1, 1] English: there - (hits 33/279) (matched: 'there') constraint CS = {19} extremes [1, 1] + (hits 33/51) (matched: 'there') constraint CS = {19} extremes [1, 1] - hits 2081/4162 nti 16 constraint (none) extremes [1, infinity) + hits 2081/4162 nti 15 constraint (none) extremes [1, infinity) English: {...} (hits 99/2081) (matched: '"(considering the first sixteen objects only)[command clarification break]" ( a )') constraint (none) extremes [1, infinity) @@ -5047,46 +5047,46 @@ (hits 999/999) (matched long text) constraint (none) extremes [1, infinity) - hits 255/510 nti 17 constraint (none) extremes [0, infinity) + hits 255/510 nti 16 constraint (none) extremes [0, infinity) English: ^ (hits 0/255) constraint (none) extremes [0, infinity) (hits 255/255) (matched long text) constraint (none) extremes [1, infinity) - hits 279/558 nti 18 constraint (none) extremes [1, infinity) + hits 279/558 nti 17 constraint (none) extremes [1, infinity) English: {...} (hits 99/279) (matched long text) constraint (none) extremes [1, infinity) - (hits 99/117) (matched long text) constraint DS = {20} extremes [2, infinity) + (hits 99/152) (matched long text) constraint DS = {20} extremes [2, infinity) (hits 81/81) (matched long text) constraint (none) extremes [1, infinity) - hits 198/1078 nti 20 constraint DS = {20} extremes [2, infinity) + hits 198/1290 nti 20 constraint DS = {20} extremes [2, infinity) English: , _{and} - (hits 0/502) constraint DS = {20} extremes [3, infinity) + (hits 0/538) constraint DS = {20} extremes [3, infinity) _{,/and} - (hits 198/517) (matched long text) constraint DS = {20} extremes [2, infinity) + (hits 198/588) (matched long text) constraint DS = {20} extremes [2, infinity) - hits 103/206 nti 19 constraint (none) extremes [1, infinity) + hits 103/206 nti 18 constraint (none) extremes [1, infinity) English: {...} (hits 30/103) (matched: 'unmarked for listing') constraint (none) extremes [1, infinity) - (hits 30/32) (matched: 'marked for listing or unmarked for listing') constraint DS = {21} extremes [2, infinity) + (hits 30/33) (matched: 'marked for listing or unmarked for listing') constraint DS = {21} extremes [2, infinity) (hits 43/43) (matched: 'pushable between rooms') constraint (none) extremes [1, infinity) - hits 60/142 nti 21 constraint DS = {21} extremes [2, infinity) + hits 60/144 nti 21 constraint DS = {21} extremes [2, infinity) English: , _{or} (hits 0/13) constraint DS = {21} extremes [3, infinity) _{,/or} (hits 60/69) (matched: 'or unmarked for listing') constraint DS = {21} extremes [2, infinity) - hits 460/920 nti 20 constraint (none) extremes [1, infinity) + hits 460/920 nti 19 constraint (none) extremes [1, infinity) English: constraint CS = {19} extremes [1, 1] @@ -5095,23 +5095,23 @@ (hits 460/460) (matched long text) constraint (none) extremes [1, infinity) - hits 576/1152 nti 21 constraint (none) extremes [1, infinity) + hits 576/1152 nti 20 constraint (none) extremes [1, infinity) English: (hits 0/576) constraint (none) extremes [1, infinity) (hits 576/576) (matched long text) constraint (none) extremes [1, infinity) - hits 0/920 nti 22 constraint (none) extremes [1, infinity) + hits 0/920 nti 21 constraint (none) extremes [1, infinity) English: - (hits 0/2) constraint CS = {22} extremes [1, 2] + constraint CS = {22} extremes [1, 2] {***} (hits 0/453) constraint (none) extremes [1, infinity) (hits 0/361) constraint DS = {14} extremes [2, infinity) - hits 0/1962 nti 23 constraint (none) extremes [1, infinity) + hits 0/1962 nti 22 constraint (none) extremes [1, infinity) English: constraint CS = {22} extremes [1, 2] @@ -5123,38 +5123,38 @@ thing/something (hits 83/83) (matched: 'thing') constraint CS = {29} extremes [1, 1] - internal hits 476/23876 nti 24 constraint (none) extremes [1, 1] + internal hits 476/23876 nti 23 constraint (none) extremes [1, 1] - hits 0/4 nti 22 constraint CS = {22} extremes [1, 2] + nti 22 constraint CS = {22} extremes [1, 2] English: worn constraint CS = {22} extremes [1, 1] carried constraint CS = {22} extremes [1, 1] initially carried - (hits 0/2) constraint CS = {22} extremes [2, 2] + constraint CS = {22} extremes [2, 2] hits 0/2684 nti 28 constraint DS = {14} extremes [2, infinity) English: _,/and {...} - (hits 0/512) constraint DS = {14, 28} extremes [3, infinity) + (hits 0/516) constraint DS = {14, 28} extremes [3, infinity) _,/and - (hits 0/559) constraint DS = {14, 28} extremes [2, infinity) + (hits 0/571) constraint DS = {14, 28} extremes [2, infinity) - (hits 0/856) constraint DS = {14} extremes [2, infinity) + (hits 0/862) constraint DS = {14} extremes [2, infinity) hits 1467/2934 nti 27 constraint (none) extremes [1, infinity) English: {...} (hits 174/1467) (matched long text) constraint (none) extremes [1, infinity) {called} - (hits 57/409) (matched long text) constraint DS = {27} extremes [1, infinity) + (hits 57/655) (matched long text) constraint DS = {27} extremes [1, infinity) - (hits 0/749) constraint DS = {24} extremes [2, infinity) + (hits 0/752) constraint DS = {24} extremes [2, infinity) - (hits 87/528) (matched long text) constraint DS = {25} extremes [1, infinity) + (hits 87/607) (matched long text) constraint DS = {25} extremes [1, infinity) - (hits 30/503) (matched: 'a kind of supporter that is portable') constraint DS = {26} extremes [1, infinity) + (hits 30/266) (matched: 'a kind of supporter that is portable') constraint DS = {26} extremes [1, infinity) (hits 4/349) (matched: 'it') constraint (none) extremes [1, 1] @@ -5162,7 +5162,7 @@ (hits 1115/1115) (matched long text) constraint (none) extremes [1, infinity) - hits 431/862 nti 25 constraint (none) extremes [0, infinity) + hits 431/862 nti 24 constraint (none) extremes [0, infinity) English: (hits 0/431) constraint (none) extremes [1, infinity) @@ -5171,18 +5171,18 @@ (hits 431/431) (matched long text) constraint (none) extremes [1, infinity) - hits 0/10882 nti 24 constraint DS = {24} extremes [2, infinity) + hits 0/10924 nti 24 constraint DS = {24} extremes [2, infinity) English: it with action {***} - (hits 0/3893) constraint DS = {24} extremes [3, infinity) + (hits 0/3841) constraint DS = {24} extremes [3, infinity) {with/having} (/) {***} - (hits 0/4050) constraint DS = {24} extremes [2, infinity) + (hits 0/3997) constraint DS = {24} extremes [2, infinity) {with/having} {...} ( ) - (hits 0/3526) constraint DS = {24} extremes [5, infinity) + (hits 0/3497) constraint DS = {24} extremes [5, infinity) {with/having} - (hits 0/4050) constraint DS = {24} extremes [2, infinity) + (hits 0/3997) constraint DS = {24} extremes [2, infinity) - nti 26 constraint (none) extremes [1, infinity) + nti 25 constraint (none) extremes [1, infinity) English: {...} constraint (none) extremes [1, infinity) @@ -5198,55 +5198,55 @@ _{,/and} constraint DS = {23} extremes [2, infinity) - nti 27 constraint (none) extremes [1, infinity) + nti 26 constraint (none) extremes [1, infinity) English: {...} constraint (none) extremes [1, infinity) - hits 174/3738 nti 25 constraint DS = {25} extremes [1, infinity) + hits 174/3710 nti 25 constraint DS = {25} extremes [1, infinity) English: , _{and} - (hits 8/1200) (matched: ', and didn't understand addressee's last name error') constraint DS = {25} extremes [2, infinity) + (hits 8/875) (matched: ', and didn't understand addressee's last name error') constraint DS = {25} extremes [2, infinity) _{,/and} - (hits 166/1286) (matched long text) constraint DS = {25} extremes [1, infinity) + (hits 166/921) (matched long text) constraint DS = {25} extremes [1, infinity) - hits 30/1006 nti 28 constraint DS = {26} extremes [1, infinity) + hits 30/532 nti 27 constraint DS = {26} extremes [1, infinity) English: - (hits 30/501) (matched: 'a kind of supporter that is portable') constraint DS = {26} extremes [2, infinity) + (hits 30/262) (matched: 'a kind of supporter that is portable') constraint DS = {26} extremes [2, infinity) - (hits 0/473) constraint DS = {26} extremes [1, infinity) + (hits 0/236) constraint DS = {26} extremes [1, infinity) - hits 30/1610 nti 26 constraint DS = {26} extremes [1, infinity) + hits 30/636 nti 26 constraint DS = {26} extremes [1, infinity) English: kind/kinds - (hits 4/42) (matched: 'kind') constraint CS = {26} extremes [1, 1] + (hits 4/8) (matched: 'kind') constraint CS = {26} extremes [1, 1] kind/kinds of - (hits 26/517) (matched: 'kind of supporter that is portable') constraint DS = {26} extremes [2, infinity) + (hits 26/260) (matched: 'kind of supporter that is portable') constraint DS = {26} extremes [2, infinity) - internal nti 29 constraint (none) extremes [1, infinity) + internal nti 28 constraint (none) extremes [1, infinity) - internal hits 1357/2714 nti 30 constraint (none) extremes [1, infinity) + internal hits 1357/2714 nti 29 constraint (none) extremes [1, infinity) - hits 0/2764 nti 31 constraint DS = {13} extremes [2, infinity) + hits 0/2764 nti 30 constraint DS = {13} extremes [2, infinity) English: {...} (hits 0/1005) constraint DS = {13} extremes [2, infinity) - hits 67/2764 nti 6 constraint DS = {13} extremes [2, infinity) + hits 67/2764 nti 31 constraint DS = {13} extremes [2, infinity) English: {...} - (hits 67/1146) (matched: 'usually table of general chitchat') constraint DS = {13} extremes [2, infinity) + (hits 67/1167) (matched: 'usually table of general chitchat') constraint DS = {13} extremes [2, infinity) - hits 765/25864 nti 30 constraint CS = {30} extremes [1, 1] + hits 793/26066 nti 30 constraint CS = {30} extremes [1, 1] English: which/who/that - (hits 765/6022) (matched: 'which') constraint CS = {30} extremes [1, 1] + (hits 793/5957) (matched: 'which') constraint CS = {30} extremes [1, 1] - hits 2/2742 nti 7 constraint DS = {30} extremes [2, infinity) + hits 2/2742 nti 6 constraint DS = {30} extremes [2, infinity) English: {...} - (hits 2/820) (matched: 'answering it that') constraint DS = {30} extremes [2, infinity) + (hits 2/804) (matched: 'answering it that') constraint DS = {30} extremes [2, infinity) nti 31 constraint DS = {31} extremes [3, infinity) English: @@ -5256,7 +5256,7 @@ hits 196/9062 nti 6 constraint DS = {6} extremes [2, infinity) English: of {...} - (hits 196/2411) (matched: 'of day -- documented at var_time --') constraint DS = {6} extremes [2, infinity) + (hits 196/2521) (matched: 'of day -- documented at var_time --') constraint DS = {6} extremes [2, infinity) hits 5/60 nti 7 constraint CS = {7} extremes [2, 2] English: @@ -5271,9 +5271,9 @@ grammatical case (hits 1/1) (matched: 'grammatical case') constraint CS = {7} extremes [2, 2] - internal hits 2474/41934 nti 8 constraint (none) extremes [0, 0] + internal hits 2474/41934 nti 7 constraint (none) extremes [0, 0] - internal hits 164/328 nti 9 constraint (none) extremes [1, infinity) + internal hits 164/328 nti 8 constraint (none) extremes [1, infinity) hits 24/68 nti 9 constraint DS = {9} extremes [3, infinity) English: @@ -5312,7 +5312,7 @@ (hits 359/5851) (matched long text) constraint CW = {r2, r5} extremes [1, infinity) - hits 40/338 nti 10 constraint (none) extremes [1, infinity) + hits 40/338 nti 9 constraint (none) extremes [1, infinity) English: (hits 32/55) (matched: 'an object') constraint (none) extremes [2, infinity) @@ -5406,7 +5406,7 @@ internal hits 220/1414 nti r5 constraint CW = {r2, r5} extremes [1, 1] - internal hits 0/772 nti 11 constraint (none) extremes [1, 1] + internal hits 0/772 nti 10 constraint (none) extremes [1, 1] nti r5 constraint CS = {r5} extremes [1, 1] English: @@ -5463,7 +5463,7 @@ z/zs constraint CS = {r5} extremes [1, 1] - internal hits 47/104 nti 12 constraint (none) extremes [1, infinity) + internal hits 47/104 nti 11 constraint (none) extremes [1, infinity) hits 4/8 nti 10 constraint (none) extremes [1, infinity) English: @@ -5472,34 +5472,34 @@ {...} (hits 1/1) (matched long text) constraint (none) extremes [1, infinity) - internal nti 13 constraint (none) extremes [1, infinity) + internal nti 12 constraint (none) extremes [1, infinity) - hits 199/10188 nti 14 constraint DW = {11, 12} extremes [2, infinity) + hits 199/10188 nti 13 constraint DW = {11, 12} extremes [2, infinity) English: - (hits 191/2715) (matched long text) constraint DS = {11} extremes [2, infinity) + (hits 191/3805) (matched long text) constraint DS = {11} extremes [2, infinity) - (hits 8/3193) (matched long text) constraint DS = {12} extremes [3, infinity) + (hits 8/2585) (matched long text) constraint DS = {12} extremes [3, infinity) - hits 191/2016 nti 11 constraint DS = {11} extremes [2, infinity) + hits 191/2308 nti 11 constraint DS = {11} extremes [2, infinity) English: volume {...} - (hits 6/1008) (matched long text) constraint DS = {11} extremes [2, infinity) + (hits 6/1154) (matched long text) constraint DS = {11} extremes [2, infinity) book {...} - (hits 0/1002) constraint DS = {11} extremes [2, infinity) + (hits 0/1148) constraint DS = {11} extremes [2, infinity) part {...} - (hits 14/1002) (matched: 'part two - the physical world model') constraint DS = {11} extremes [2, infinity) + (hits 14/1148) (matched: 'part two - the physical world model') constraint DS = {11} extremes [2, infinity) chapter {...} - (hits 20/988) (matched long text) constraint DS = {11} extremes [2, infinity) + (hits 20/1134) (matched long text) constraint DS = {11} extremes [2, infinity) section {...} - (hits 151/968) (matched long text) constraint DS = {11} extremes [2, infinity) + (hits 151/1114) (matched long text) constraint DS = {11} extremes [2, infinity) - hits 8/6386 nti 12 constraint DS = {12} extremes [3, infinity) + hits 8/5170 nti 12 constraint DS = {12} extremes [3, infinity) English: {...} begin/begins here - (hits 4/3193) (matched long text) constraint DS = {12} extremes [3, infinity) + (hits 4/2585) (matched long text) constraint DS = {12} extremes [3, infinity) {...} end/ends here - (hits 4/3189) (matched: 'the standard rules end here') constraint DS = {12} extremes [3, infinity) + (hits 4/2581) (matched: 'the standard rules end here') constraint DS = {12} extremes [3, infinity) hits 32/12958 nti 14 constraint (none) extremes [1, infinity) English: @@ -5508,52 +5508,52 @@ {...} (hits 0/6459) constraint (none) extremes [2, infinity) - (hits 0/6418) constraint DS = {13} extremes [4, infinity) + (hits 0/6296) constraint DS = {13} extremes [4, infinity) * constraint CS = {14} extremes [1, 1] * constraint DS = {14} extremes [2, 2] table {...} - (hits 14/6202) (matched long text) constraint DS = {14} extremes [2, infinity) + (hits 14/6267) (matched long text) constraint DS = {14} extremes [2, infinity) equation {...} - (hits 0/6188) constraint DS = {14} extremes [2, infinity) + (hits 0/6253) constraint DS = {14} extremes [2, infinity) include the {...} by {...} - (hits 0/6166) constraint DS = {14} extremes [5, infinity) + (hits 0/6232) constraint DS = {14} extremes [5, infinity) include {...} by {...} - (hits 18/6187) (matched long text) constraint DS = {14} extremes [4, infinity) + (hits 18/6253) (matched long text) constraint DS = {14} extremes [4, infinity) include (- {...} - (hits 0/6170) constraint DS = {14} extremes [3, infinity) + (hits 0/6235) constraint DS = {14} extremes [3, infinity) hits 9/2788 nti 15 constraint DS = {15} extremes [2, infinity) English: instead of {...} - (hits 0/955) constraint DS = {15} extremes [3, infinity) + (hits 0/1096) constraint DS = {15} extremes [3, infinity) every turn {***} - (hits 1/955) (matched: 'every turn rules is a rulebook') constraint DS = {15} extremes [2, infinity) + (hits 1/1096) (matched: 'every turn rules is a rulebook') constraint DS = {15} extremes [2, infinity) before {...} - (hits 2/954) (matched long text) constraint DS = {15} extremes [2, infinity) + (hits 2/1095) (matched long text) constraint DS = {15} extremes [2, infinity) after {...} - (hits 2/952) (matched long text) constraint DS = {15} extremes [2, infinity) + (hits 2/1093) (matched long text) constraint DS = {15} extremes [2, infinity) when {...} - (hits 4/950) (matched: 'when scene begins is a scene based rulebook') constraint DS = {15} extremes [2, infinity) + (hits 4/1091) (matched: 'when scene begins is a scene based rulebook') constraint DS = {15} extremes [2, infinity) - hits 0/12836 nti 13 constraint DS = {13} extremes [4, infinity) + hits 0/12592 nti 13 constraint DS = {13} extremes [4, infinity) English: include (- {###} in the preform grammar - (hits 0/135) constraint DS = {13} extremes [7, 7] + (hits 0/131) constraint DS = {13} extremes [7, 7] use {...} language element/elements - (hits 0/6418) constraint DS = {13} extremes [4, infinity) + (hits 0/6296) constraint DS = {13} extremes [4, infinity) hits 30/442 nti 21 constraint DS = {21} extremes [2, infinity) English: {...} ( ) - (hits 13/221) (matched long text) constraint DS = {21} extremes [4, infinity) + (hits 13/154) (matched long text) constraint DS = {21} extremes [4, infinity) {...} not for release - (hits 1/208) (matched long text) constraint DS = {21} extremes [4, infinity) + (hits 1/141) (matched long text) constraint DS = {21} extremes [4, infinity) {...} for release only - (hits 0/207) constraint DS = {21} extremes [4, infinity) + (hits 0/140) constraint DS = {21} extremes [4, infinity) {...} unindexed - (hits 16/207) (matched long text) constraint DS = {21} extremes [2, infinity) + (hits 16/140) (matched long text) constraint DS = {21} extremes [2, infinity) hits 13/26 nti 20 constraint DW = {17, 19, 20} extremes [1, infinity) English: @@ -5604,7 +5604,7 @@ {......} by {......} constraint DS = {18} extremes [3, infinity) - internal hits 7/14 nti 15 constraint (none) extremes [1, infinity) + internal hits 7/14 nti 14 constraint (none) extremes [1, infinity) nti 23 constraint (none) extremes [1, infinity) English: @@ -5625,7 +5625,7 @@ use . constraint DS = {26} extremes [3, infinity) - nti 16 constraint (none) extremes [1, infinity) + nti 15 constraint (none) extremes [1, infinity) English: {...} constraint (none) extremes [1, infinity) @@ -5641,7 +5641,7 @@ _,/and constraint DS = {25} extremes [2, infinity) - nti 17 constraint (none) extremes [1, infinity) + nti 16 constraint (none) extremes [1, infinity) English: constraint CS = {24} extremes [1, 3] @@ -5666,14 +5666,14 @@ (hits 10/10) (matched: 'basic inform') constraint (none) extremes [1, infinity) - hits 10/20 nti 18 constraint (none) extremes [1, infinity) + hits 10/20 nti 17 constraint (none) extremes [1, infinity) English: {***} (hits 0/10) constraint (none) extremes [1, infinity) {...} (hits 10/10) (matched: 'basic inform') constraint (none) extremes [1, infinity) - internal hits 6/12 nti 19 constraint (none) extremes [1, 1] + internal hits 6/12 nti 18 constraint (none) extremes [1, 1] hits 4/8 nti 29 constraint (none) extremes [1, infinity) English: @@ -5690,41 +5690,41 @@ hits 2873/18796 nti 31 constraint DS = {31} extremes [1, infinity) English: if {...} is begin - (hits 0/4856) constraint DS = {31} extremes [4, infinity) + (hits 0/4846) constraint DS = {31} extremes [4, infinity) if {...} is - (hits 0/5449) constraint DS = {31} extremes [3, infinity) + (hits 0/5451) constraint DS = {31} extremes [3, infinity) if/unless {...} - (hits 2123/5449) (matched long text) constraint DS = {31} extremes [2, infinity) + (hits 2123/6687) (matched long text) constraint DS = {31} extremes [2, infinity) repeat {...} - (hits 101/3326) (matched long text) constraint DS = {31} extremes [2, infinity) + (hits 101/4564) (matched long text) constraint DS = {31} extremes [2, infinity) while {...} - (hits 31/3225) (matched long text) constraint DS = {31} extremes [2, infinity) + (hits 31/4463) (matched long text) constraint DS = {31} extremes [2, infinity) else/otherwise (hits 330/345) (matched: 'otherwise') constraint CS = {31} extremes [1, 1] else/otherwise if/unless {...} - (hits 231/3194) (matched long text) constraint DS = {31} extremes [3, infinity) + (hits 231/3196) (matched long text) constraint DS = {31} extremes [3, infinity) else/otherwise {...} - (hits 57/2963) (matched long text) constraint DS = {31} extremes [2, infinity) + (hits 57/4201) (matched long text) constraint DS = {31} extremes [2, infinity) -- otherwise constraint CS = {31} extremes [2, 2] -- {...} - (hits 0/2906) constraint DS = {31} extremes [2, infinity) + (hits 0/4144) constraint DS = {31} extremes [2, infinity) hits 0/12004 nti 6 constraint CS = {6} extremes [2, 2] English: end if/unless - constraint CS = {6} extremes [2, 2] + (hits 0/6) constraint CS = {6} extremes [2, 2] end while - constraint CS = {6} extremes [2, 2] + (hits 0/6) constraint CS = {6} extremes [2, 2] end repeat - constraint CS = {6} extremes [2, 2] + (hits 0/6) constraint CS = {6} extremes [2, 2] hits 756/14584 nti 7 constraint DS = {7} extremes [2, infinity) English: say {...} - (hits 584/3538) (matched: 'say run paragraph on with special look spacing') constraint DS = {7} extremes [2, infinity) + (hits 584/2402) (matched: 'say run paragraph on with special look spacing') constraint DS = {7} extremes [2, infinity) now {...} - (hits 172/2954) (matched long text) constraint DS = {7} extremes [2, infinity) + (hits 172/1818) (matched long text) constraint DS = {7} extremes [2, infinity) hits 2306/7528 nti 8 constraint DS = {8} extremes [3, infinity) English: @@ -5734,18 +5734,18 @@ hits 30/9858 nti 9 constraint DS = {9} extremes [2, infinity) English: instead {...} - (hits 0/1695) constraint DS = {9} extremes [2, infinity) + (hits 0/1696) constraint DS = {9} extremes [2, infinity) {...} instead - (hits 30/1695) (matched long text) constraint DS = {9} extremes [2, infinity) + (hits 30/1696) (matched long text) constraint DS = {9} extremes [2, infinity) hits 0/880 nti 10 constraint DS = {10} extremes [2, infinity) English: {...} begin - (hits 0/429) constraint DS = {10} extremes [2, infinity) + (hits 0/432) constraint DS = {10} extremes [2, infinity) - internal nti 20 constraint (none) extremes [1, 1] + internal nti 19 constraint (none) extremes [1, 1] - internal hits 7/14 nti 21 constraint (none) extremes [1, infinity) + internal hits 7/14 nti 20 constraint (none) extremes [1, infinity) hits 21/58 nti 24 constraint CS = {24} extremes [1, 3] English: @@ -5792,7 +5792,7 @@ superbrief room descriptions (hits 1/1) (matched: 'superbrief room descriptions') constraint CS = {24} extremes [3, 3] - internal hits 6/12 nti 22 constraint (none) extremes [1, infinity) + internal hits 6/12 nti 21 constraint (none) extremes [1, infinity) nti 11 constraint CS = {11} extremes [1, 1] English: @@ -5861,7 +5861,7 @@ {...} constraint (none) extremes [1, infinity) - nti 23 constraint (none) extremes [2, infinity) + nti 22 constraint (none) extremes [2, infinity) English: {...} constraint DS = {13, 30} extremes [4, infinity) @@ -5882,18 +5882,18 @@ hits 104/208 nti 15 constraint (none) extremes [1, infinity) English: {...} that varies - (hits 0/8) constraint DS = {15} extremes [3, infinity) + (hits 0/9) constraint DS = {15} extremes [3, infinity) {...} variable - (hits 0/8) constraint DS = {15} extremes [2, infinity) + (hits 0/19) constraint DS = {15} extremes [2, infinity) {...} (hits 104/104) (matched: 'the removing it from action') constraint (none) extremes [1, infinity) - hits 40/176 nti 24 constraint DW = {16, 17, 18} extremes [2, infinity) + hits 40/176 nti 23 constraint DW = {16, 17, 18} extremes [2, infinity) English: (hits 26/28) (matched: 'unlocking keylessly action') constraint DS = {16} extremes [2, infinity) - constraint DS = {17} extremes [2, infinity) + (hits 0/14) constraint DS = {17} extremes [2, infinity) (hits 14/14) (matched: 'specific action-processing rulebook') constraint DS = {18} extremes [2, infinity) @@ -5902,17 +5902,17 @@ {...} action (hits 26/28) (matched: 'unlocking keylessly action') constraint DS = {16} extremes [2, infinity) - nti 17 constraint DS = {17} extremes [2, infinity) + hits 0/28 nti 17 constraint DS = {17} extremes [2, infinity) English: {...} activity - constraint DS = {17} extremes [2, infinity) + (hits 0/14) constraint DS = {17} extremes [2, infinity) hits 21/42 nti 18 constraint DS = {18} extremes [2, infinity) English: {...} rulebook (hits 21/21) (matched: 'specific action-processing rulebook') constraint DS = {18} extremes [2, infinity) - hits 24/48 nti 25 constraint (none) extremes [1, infinity) + hits 24/48 nti 24 constraint (none) extremes [1, infinity) English: constraint DS = {20} extremes [3, infinity) @@ -5933,7 +5933,7 @@ presence constraint CS = {19} extremes [1, 1] {***} , {***} - (hits 0/7) constraint DS = {19} extremes [1, infinity) + (hits 0/1) constraint DS = {19} extremes [1, infinity) {***} {***} (hits 0/24) constraint (none) extremes [1, infinity) {...} @@ -5978,16 +5978,16 @@ hits 4/1112 nti 25 constraint DS = {25} extremes [3, infinity) English:
    plural of - (hits 4/271) (matched: 'the plural of person') constraint DS = {25} extremes [4, infinity) + (hits 4/241) (matched: 'the plural of person') constraint DS = {25} extremes [4, infinity) plural of - (hits 0/325) constraint DS = {25} extremes [3, infinity) + (hits 0/265) constraint DS = {25} extremes [3, infinity) - nti 26 constraint (none) extremes [1, infinity) + nti 25 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) - nti 27 constraint (none) extremes [1, infinity) + nti 26 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) @@ -5997,16 +5997,16 @@ hits 0/444 nti 26 constraint CS = {26} extremes [1, 1] English: unicode - constraint CS = {26} extremes [1, 1] + (hits 0/2) constraint CS = {26} extremes [1, 1] - nti 28 constraint (none) extremes [1, infinity) + nti 27 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - nti 29 constraint (none) extremes [1, infinity) + nti 28 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, 1] @@ -6096,7 +6096,7 @@ {...} constraint (none) extremes [1, infinity) - hits 1/2 nti 30 constraint (none) extremes [1, infinity) + hits 1/2 nti 29 constraint (none) extremes [1, infinity) English: (hits 1/1) (matched: 'go to cold comfort / z / z / z / z / ask vanessa for french vanilla / ask vanessa for chocolate / ask vanessa about flavors / ask vanessa for chocolate chocolate chip') constraint (none) extremes [1, 1] @@ -6105,7 +6105,7 @@ {...} constraint (none) extremes [1, infinity) - nti 31 constraint (none) extremes [1, infinity) + nti 30 constraint (none) extremes [1, infinity) English: {...} constraint (none) extremes [1, infinity) @@ -6130,9 +6130,9 @@ hits 0/856 nti 13 constraint DS = {13} extremes [3, infinity) English: defined by - (hits 0/190) constraint DS = {13} extremes [3, infinity) + (hits 0/192) constraint DS = {13} extremes [3, infinity) - nti 6 constraint (none) extremes [1, infinity) + nti 31 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) @@ -6160,26 +6160,26 @@ not listed (hits 1/1) (matched: 'not listed in any rulebook') constraint DS = {16} extremes [3, infinity) - hits 113/932 nti 7 constraint (none) extremes [1, infinity) + hits 113/932 nti 6 constraint (none) extremes [1, infinity) English: {...} (hits 30/466) (matched long text) constraint (none) extremes [1, infinity) - (hits 0/211) constraint DS = {17, 18} extremes [4, infinity) + (hits 0/229) constraint DS = {17, 18} extremes [4, infinity) - (hits 83/303) (matched long text) constraint DS = {17} extremes [2, infinity) + (hits 83/316) (matched long text) constraint DS = {17} extremes [2, infinity) - hits 30/2436 nti 18 constraint DS = {18} extremes [2, infinity) + hits 30/2556 nti 18 constraint DS = {18} extremes [2, infinity) English: , _{and} - (hits 1/742) (matched: ', and the library') constraint DS = {18} extremes [3, infinity) + (hits 1/605) (matched: ', and the library') constraint DS = {18} extremes [3, infinity) _{,/and} - (hits 29/927) (matched long text) constraint DS = {18} extremes [2, infinity) + (hits 29/722) (matched long text) constraint DS = {18} extremes [2, infinity) - hits 83/666 nti 17 constraint DS = {17} extremes [2, infinity) + hits 83/692 nti 17 constraint DS = {17} extremes [2, infinity) English: {...} rule - (hits 83/329) (matched long text) constraint DS = {17} extremes [2, infinity) + (hits 83/346) (matched long text) constraint DS = {17} extremes [2, infinity) nti 19 constraint DS = {17} extremes [2, infinity) English: @@ -6190,14 +6190,14 @@ unless constraint DS = {17, 19} extremes [4, infinity) - nti 8 constraint (none) extremes [1, infinity) + nti 7 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - nti 9 constraint (none) extremes [1, infinity) + nti 8 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) @@ -6209,14 +6209,14 @@ nothing constraint CS = {20} extremes [1, 1] - nti 10 constraint (none) extremes [1, infinity) + nti 9 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - hits 83/166 nti 11 constraint (none) extremes [1, infinity) + hits 83/166 nti 10 constraint (none) extremes [1, infinity) English: (hits 83/83) (matched long text) constraint (none) extremes [1, infinity) @@ -6260,7 +6260,7 @@ {...} constraint (none) extremes [1, infinity) - hits 78/156 nti 12 constraint (none) extremes [1, infinity) + hits 78/156 nti 11 constraint (none) extremes [1, infinity) English: (hits 78/78) (matched long text) constraint (none) extremes [1, infinity) @@ -6270,7 +6270,7 @@ hits 34/1104 nti 22 constraint DS = {22} extremes [1, 2] English:
    activity - (hits 34/35) (matched: 'an activity') constraint DS = {22} extremes [2, 2] + (hits 34/34) (matched: 'an activity') constraint DS = {22} extremes [2, 2] activity constraint CS = {22} extremes [1, 1] @@ -6285,7 +6285,7 @@ {...} constraint (none) extremes [1, infinity) - nti 13 constraint (none) extremes [1, infinity) + nti 12 constraint (none) extremes [1, infinity) English: constraint DS = {24} extremes [3, infinity) @@ -6312,14 +6312,14 @@ {......} constraint (none) extremes [1, infinity) - nti 14 constraint (none) extremes [1, infinity) + nti 13 constraint (none) extremes [1, infinity) English: constraint DW = {13, 31} extremes [3, infinity) constraint (none) extremes [1, infinity) - nti 15 constraint (none) extremes [1, infinity) + nti 14 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) @@ -6348,7 +6348,7 @@ scaled at constraint DS = {31} extremes [3, infinity) - nti 16 constraint (none) extremes [1, infinity) + nti 15 constraint (none) extremes [1, infinity) English: constraint CS = {r0} extremes [1, 1] @@ -6373,7 +6373,7 @@ constraint (none) extremes [0, infinity) - nti 17 constraint (none) extremes [1, infinity) + nti 16 constraint (none) extremes [1, infinity) English: constraint DS = {27} extremes [3, infinity) @@ -6440,9 +6440,9 @@ hits 10/20 nti 15 constraint (none) extremes [1, infinity) English: one {...} - (hits 4/8) (matched: 'one room') constraint DS = {15} extremes [2, infinity) + (hits 4/10) (matched: 'one room') constraint DS = {15} extremes [2, infinity) various {...} - (hits 4/4) (matched: 'various doors') constraint DS = {15} extremes [2, infinity) + (hits 4/6) (matched: 'various doors') constraint DS = {15} extremes [2, infinity) {...} (hits 2/2) (matched: 'a door') constraint (none) extremes [1, infinity) @@ -6459,7 +6459,7 @@ hits 0/856 nti 22 constraint DS = {22} extremes [2, infinity) English: either - (hits 0/133) constraint DS = {22} extremes [2, infinity) + (hits 0/107) constraint DS = {22} extremes [2, infinity) hits 0/86 nti 23 constraint (none) extremes [1, 2] English: @@ -6473,11 +6473,11 @@ hits 43/86 nti 26 constraint (none) extremes [1, infinity) English: either ( ) - (hits 0/2) constraint DS = {26} extremes [5, infinity) + constraint DS = {26} extremes [5, infinity) ( ) - (hits 0/2) constraint DS = {26} extremes [4, infinity) + constraint DS = {26} extremes [4, infinity) either - (hits 0/2) constraint DS = {26} extremes [2, infinity) + constraint DS = {26} extremes [2, infinity) (hits 43/43) (matched: 'marked for listing or unmarked for listing') constraint (none) extremes [1, infinity) @@ -6488,7 +6488,7 @@ constraint (none) extremes [1, infinity) - nti 18 constraint (none) extremes [1, infinity) + nti 17 constraint (none) extremes [1, infinity) English:
    constraint (none) extremes [2, infinity) @@ -6504,23 +6504,23 @@ constraint (none) extremes [1, infinity) - hits 74/1260 nti 19 constraint DS = {27} extremes [1, infinity) + hits 74/1260 nti 18 constraint DS = {27} extremes [1, infinity) English: - (hits 74/314) (matched: 'a verb') constraint DS = {27} extremes [2, infinity) + (hits 74/408) (matched: 'a verb') constraint DS = {27} extremes [2, infinity) - (hits 0/245) constraint DS = {27} extremes [1, infinity) + (hits 0/336) constraint DS = {27} extremes [1, infinity) - hits 74/980 nti 27 constraint DS = {27} extremes [1, infinity) + hits 74/1376 nti 27 constraint DS = {27} extremes [1, infinity) English: verb - (hits 74/79) (matched: 'verb') constraint CS = {27} extremes [1, 1] + (hits 74/76) (matched: 'verb') constraint CS = {27} extremes [1, 1] verb implying/meaning nounphrase-unparsed> - (hits 0/60) constraint DS = {27} extremes [4, 4] + (hits 0/86) constraint DS = {27} extremes [4, 4] verb implying/meaning - (hits 0/318) constraint DS = {27} extremes [3, infinity) + (hits 0/362) constraint DS = {27} extremes [3, infinity) - hits 82/168 nti 20 constraint DS = {28} extremes [2, infinity) + hits 82/168 nti 19 constraint DS = {28} extremes [2, infinity) English: (hits 82/84) (matched long text) constraint DS = {28} extremes [3, infinity) @@ -6591,28 +6591,28 @@ {...} (hits 3/3) (matched: 'he conceals') constraint (none) extremes [2, infinity) - hits 1/4 nti 21 constraint (none) extremes [1, infinity) + hits 1/4 nti 20 constraint (none) extremes [1, infinity) English: {***} (hits 1/2) (matched: 'concealing') constraint (none) extremes [1, infinity) {***} (hits 0/1) constraint (none) extremes [1, infinity) - hits 0/856 nti 22 constraint DS = {8} extremes [1, infinity) + hits 0/856 nti 21 constraint DS = {8} extremes [1, infinity) English: - (hits 0/86) constraint DS = {8} extremes [2, infinity) + (hits 0/63) constraint DS = {8} extremes [2, infinity) - (hits 0/88) constraint DS = {8} extremes [1, infinity) + (hits 0/64) constraint DS = {8} extremes [1, infinity) - hits 0/272 nti 8 constraint DS = {8} extremes [1, infinity) + hits 0/180 nti 8 constraint DS = {8} extremes [1, infinity) English: adjective - (hits 0/2) constraint CS = {8} extremes [1, 1] + (hits 0/1) constraint CS = {8} extremes [1, 1] adjective implying/meaning - (hits 0/79) constraint DS = {8} extremes [4, infinity) + (hits 0/58) constraint DS = {8} extremes [4, infinity) adjective implying/meaning - (hits 0/114) constraint DS = {8} extremes [3, infinity) + (hits 0/89) constraint DS = {8} extremes [3, infinity) nti 9 constraint (none) extremes [1, infinity) English: @@ -6626,7 +6626,7 @@ variable (hits 0/13) constraint CS = {10} extremes [1, 1] action of - (hits 0/91) constraint DS = {10} extremes [3, infinity) + (hits 0/160) constraint DS = {10} extremes [3, infinity) (hits 728/978) (matched: 'action name based rule producing nothing that varies') constraint (none) extremes [1, infinity) @@ -6635,7 +6635,7 @@ hits 0/514 nti 12 constraint DS = {11, 12} extremes [4, infinity) English: {...} ( ) - (hits 0/15) constraint DS = {11, 12} extremes [4, infinity) + (hits 0/25) constraint DS = {11, 12} extremes [4, infinity) nti 11 constraint CS = {11} extremes [1, 1] English: @@ -6651,49 +6651,49 @@
    (hits 0/73) constraint (none) extremes [1, 1] (/)/(- {***} - (hits 0/92) constraint DS = {13} extremes [1, infinity) + (hits 0/103) constraint DS = {13} extremes [1, infinity) {***} (/)/(- - (hits 0/92) constraint DS = {13} extremes [1, infinity) + (hits 0/103) constraint DS = {13} extremes [1, infinity) {...} (/)/(- {...} - (hits 0/68) constraint DS = {13} extremes [3, infinity) + (hits 0/75) constraint DS = {13} extremes [3, infinity) ni--crash--1 - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] ni--crash--10 - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] ni--crash--11 - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] , {...} - (hits 0/80) constraint DS = {13} extremes [2, infinity) + (hits 0/88) constraint DS = {13} extremes [2, infinity) {...} , - (hits 0/80) constraint DS = {13} extremes [2, infinity) + (hits 0/88) constraint DS = {13} extremes [2, infinity) {...} when/while {...} - (hits 0/68) constraint DS = {13} extremes [3, infinity) + (hits 0/75) constraint DS = {13} extremes [3, infinity) {***} {***} (hits 0/273) constraint (none) extremes [1, infinity) condition - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] conditions - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] storage - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] storages - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] variable - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] variables - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] property-value - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] property-values - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] table-reference - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] table-references - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] list-entry - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] list-entries - (hits 0/12) constraint CS = {13} extremes [1, 1] + (hits 0/15) constraint CS = {13} extremes [1, 1] hits 0/18 nti 14 constraint DS = {14} extremes [5, infinity) English: @@ -6705,14 +6705,14 @@ hits 19/2150 nti 15 constraint DS = {15} extremes [5, infinity) English: {...} ( called {...} ) {***} - (hits 19/312) (matched long text) constraint DS = {15} extremes [5, infinity) + (hits 19/443) (matched long text) constraint DS = {15} extremes [5, infinity) hits 0/1978 nti 16 constraint (none) extremes [1, infinity) English:
    (hits 0/156) constraint (none) extremes [1, 1] {***} (/)/{/}/,/./(- {***} - (hits 0/210) constraint DS = {16} extremes [1, infinity) + (hits 0/703) constraint DS = {16} extremes [1, infinity) {***} {***} (hits 0/919) constraint (none) extremes [1, infinity) @@ -6721,14 +6721,14 @@ (hits 0/661) constraint (none) extremes [1, 1] {***} (/)/{/}/,/. {***} - (hits 0/28) constraint DS = {17} extremes [1, infinity) + (hits 0/7) constraint DS = {17} extremes [1, infinity) {***} {***} (hits 0/806) constraint (none) extremes [1, infinity) hits 0/50 nti 18 constraint (none) extremes [1, infinity) English: {...} with/having/and/or {...} - (hits 0/14) constraint DS = {18} extremes [3, infinity) + (hits 0/13) constraint DS = {18} extremes [3, infinity) (hits 0/25) constraint (none) extremes [1, infinity) @@ -6747,20 +6747,20 @@ {to} constraint CS = {21} extremes [1, 1] to {...} ( called {...} ) - (hits 0/795) constraint DS = {21} extremes [6, infinity) + (hits 0/800) constraint DS = {21} extremes [6, infinity) {to ...} ( this is the {### function} inverse to {###} ) (hits 16/674) (matched long text) constraint DS = {21} extremes [12, infinity) {to ...} ( this is the {### function} ) (hits 4/717) (matched long text) constraint DS = {21} extremes [9, infinity) {to ...} ( this is {...} ) - (hits 0/758) constraint DS = {21} extremes [7, infinity) + (hits 0/760) constraint DS = {21} extremes [7, infinity) {to ...} - (hits 476/838) (matched long text) constraint DS = {21} extremes [2, infinity) + (hits 476/857) (matched long text) constraint DS = {21} extremes [2, infinity) hits 1/992 nti 22 constraint DS = {22} extremes [3, infinity) English: to now {...} - (hits 1/495) (matched long text) constraint DS = {22} extremes [3, infinity) + (hits 1/492) (matched: 'to now ( cn - condition )') constraint DS = {22} extremes [3, infinity) hits 0/992 nti 23 constraint CS = {23} extremes [2, 2] English: @@ -6770,13 +6770,13 @@ hits 400/1672 nti 24 constraint (none) extremes [1, infinity) English: this is the {... rule} - (hits 29/359) (matched long text) constraint DS = {24} extremes [5, infinity) + (hits 29/360) (matched long text) constraint DS = {24} extremes [5, infinity) this is the rule constraint CS = {24} extremes [4, 4] this is {...} rule - (hits 0/337) constraint DS = {24} extremes [4, infinity) + (hits 0/341) constraint DS = {24} extremes [4, infinity) this is {...} rules - (hits 0/337) constraint DS = {24} extremes [4, infinity) + (hits 0/341) constraint DS = {24} extremes [4, infinity) {...} ( this is the {... rule} ) (hits 281/302) (matched long text) constraint DS = {24} extremes [8, infinity) {...} ( this is the rule ) @@ -6788,139 +6788,123 @@ {...} (hits 90/90) (matched long text) constraint (none) extremes [1, infinity) - hits 0/180 nti 25 constraint DS = {25} extremes [2, infinity) - English: - at - (hits 0/3) constraint DS = {10, 25} extremes [3, 3] - at the time when {...} - (hits 0/43) constraint DS = {25} extremes [5, infinity) - at the time that {...} - (hits 0/43) constraint DS = {25} extremes [5, infinity) - at {...} - (hits 0/53) constraint DS = {25} extremes [2, infinity) - - hits 371/742 nti 28 constraint (none) extremes [1, infinity) + hits 371/742 nti 27 constraint (none) extremes [1, infinity) English: during - (hits 0/312) constraint DS = {28} extremes [3, infinity) + (hits 0/314) constraint DS = {27} extremes [3, infinity) (hits 371/371) (matched long text) constraint (none) extremes [1, infinity) - hits 371/742 nti 27 constraint (none) extremes [1, infinity) + hits 371/742 nti 26 constraint (none) extremes [1, infinity) English: {} {when/while ...} - (hits 23/299) (matched long text) constraint DS = {27} extremes [3, infinity) + (hits 23/296) (matched long text) constraint DS = {26} extremes [3, infinity) {} (hits 348/348) (matched long text) constraint (none) extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - hits 371/750 nti 26 constraint (none) extremes [1, infinity) + hits 371/750 nti 25 constraint (none) extremes [1, infinity) English: {***} (hits 359/371) (matched long text) constraint (none) extremes [1, infinity)
    rule for {***} - (hits 0/12) constraint DS = {26} extremes [4, infinity) + (hits 0/12) constraint DS = {25} extremes [4, infinity)
    rule {***} - (hits 0/12) constraint DS = {26} extremes [3, infinity) + (hits 0/12) constraint DS = {25} extremes [3, infinity) rule for {***} - (hits 0/12) constraint DS = {26} extremes [3, infinity) + (hits 0/12) constraint DS = {25} extremes [3, infinity) rule {***} - (hits 12/12) (matched long text) constraint DS = {26} extremes [2, infinity) + (hits 12/12) (matched long text) constraint DS = {25} extremes [2, infinity) - hits 92/1496 nti 29 constraint DS = {29} extremes [1, infinity) + hits 92/1496 nti 28 constraint DS = {28} extremes [1, infinity) English: of/for {...} - (hits 48/582) (matched long text) constraint DS = {29} extremes [2, infinity) + (hits 48/544) (matched long text) constraint DS = {28} extremes [2, infinity) rule about/for/on {...} - (hits 0/530) constraint DS = {29} extremes [3, infinity) + (hits 0/496) constraint DS = {28} extremes [3, infinity) rule - (hits 44/44) (matched: 'rule') constraint CS = {29} extremes [1, 1] + (hits 44/44) (matched: 'rule') constraint CS = {28} extremes [1, 1] - nti 30 constraint (none) extremes [1, infinity) + nti 29 constraint (none) extremes [1, infinity) English: when {***} - constraint DS = {30} extremes [1, infinity) + constraint DS = {29} extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - hits 3/464 nti 31 constraint DS = {31} extremes [3, infinity) - English: - {...} when/while {...} - (hits 3/83) (matched long text) constraint DS = {31} extremes [3, infinity) - - nti 6 constraint (none) extremes [1, infinity) + nti 30 constraint (none) extremes [1, infinity) English: when the play begins/ends - constraint CS = {6} extremes [4, 4] + constraint CS = {30} extremes [4, 4] {...} constraint (none) extremes [1, infinity) - nti 7 constraint DS = {7} extremes [2, infinity) + nti 31 constraint DS = {31} extremes [2, infinity) English: in the presence of {...} - constraint DS = {7} extremes [5, infinity) + constraint DS = {31} extremes [5, infinity) in {...} - constraint DS = {7} extremes [2, infinity) + constraint DS = {31} extremes [2, infinity) - nti 8 constraint DS = {8} extremes [3, infinity) + nti 6 constraint DS = {6} extremes [3, infinity) English: {...} called {...} {when/while ...} - constraint DS = {8} extremes [5, infinity) + constraint DS = {6} extremes [5, infinity) {...} {when/while *** nothing ***} - constraint DS = {8} extremes [3, infinity) + constraint DS = {6} extremes [3, infinity) {...} {when/while *** nowhere ***} - constraint DS = {8} extremes [3, infinity) + constraint DS = {6} extremes [3, infinity) {...} and {when/while ...} - constraint DS = {8} extremes [4, infinity) + constraint DS = {6} extremes [4, infinity) {...} {when/while ...} - constraint DS = {8} extremes [3, infinity) + constraint DS = {6} extremes [3, infinity) - nti 10 constraint (none) extremes [1, infinity) + nti 8 constraint (none) extremes [1, infinity) English: when/while {...} - constraint DS = {10} extremes [3, infinity) + constraint DS = {8} extremes [3, infinity) constraint (none) extremes [1, infinity) - nti 23 constraint (none) extremes [1, infinity) + nti 22 constraint (none) extremes [1, infinity) English: - constraint DS = {9} extremes [3, infinity) + constraint DS = {7} extremes [3, infinity) constraint (none) extremes [1, infinity) - nti 9 constraint DS = {9} extremes [2, infinity) + nti 7 constraint DS = {7} extremes [2, infinity) English: , _or - constraint DS = {9} extremes [3, infinity) + constraint DS = {7} extremes [3, infinity) _,/or - constraint DS = {9} extremes [2, infinity) + constraint DS = {7} extremes [2, infinity) - nti 24 constraint (none) extremes [1, infinity) + nti 23 constraint (none) extremes [1, infinity) English: {......} constraint (none) extremes [1, infinity) - hits 28/56 nti 13 constraint (none) extremes [1, infinity) + hits 28/56 nti 11 constraint (none) extremes [1, infinity) English: ( {***} ) - (hits 0/3) constraint DS = {13} extremes [2, infinity) + (hits 0/4) constraint DS = {11} extremes [2, infinity) ( {...} ) - (hits 0/2) constraint DS = {13} extremes [4, infinity) + (hits 0/2) constraint DS = {11} extremes [4, infinity) ( {...} ) - (hits 2/2) (matched: 'locale description priority ( a number )') constraint DS = {13} extremes [4, infinity) + (hits 2/2) (matched: 'locale description priority ( a number )') constraint DS = {11} extremes [4, infinity) (hits 12/26) (matched: 'turn stamp') constraint (none) extremes [1, infinity) (hits 14/14) (matched: 'final question wording') constraint (none) extremes [1, infinity) - hits 16/32 nti 12 constraint (none) extremes [1, infinity) + hits 16/32 nti 10 constraint (none) extremes [1, infinity) English:
    (hits 0/9) constraint (none) extremes [1, 1] {topic} - (hits 1/1) (matched: 'topic') constraint CS = {12} extremes [1, 1] + (hits 1/1) (matched: 'topic') constraint CS = {10} extremes [1, 1] {} (hits 0/15) constraint (none) extremes [1, infinity) {} @@ -6928,53 +6912,53 @@ {...} (hits 15/15) (matched: 'final question wording') constraint (none) extremes [1, infinity) - nti 14 constraint DS = {14} extremes [2, infinity) + nti 12 constraint DS = {12} extremes [2, infinity) English: {...} column - constraint DS = {14} extremes [2, infinity) + constraint DS = {12} extremes [2, infinity) - hits 7/14 nti 16 constraint DS = {15} extremes [2, infinity) + hits 7/14 nti 14 constraint DS = {13} extremes [2, infinity) English: ( continued ) - (hits 0/1) constraint DS = {15, 16} extremes [5, infinity) + (hits 0/1) constraint DS = {13, 14} extremes [5, infinity) ( amended ) - (hits 0/1) constraint DS = {15, 16} extremes [5, infinity) + (hits 0/1) constraint DS = {13, 14} extremes [5, infinity) ( replaced ) - (hits 0/1) constraint DS = {15, 16} extremes [5, infinity) + (hits 0/1) constraint DS = {13, 14} extremes [5, infinity) - (hits 7/7) (matched: 'table of final question options') constraint DS = {15} extremes [2, infinity) + (hits 7/7) (matched: 'table of final question options') constraint DS = {13} extremes [2, infinity) - hits 7/14 nti 15 constraint DS = {15} extremes [2, infinity) + hits 7/14 nti 13 constraint DS = {13} extremes [2, infinity) English: table {...} - {...} - (hits 0/7) constraint DS = {15} extremes [4, infinity) + (hits 0/7) constraint DS = {13} extremes [4, infinity) table {###} - constraint DS = {15} extremes [2, 2] + constraint DS = {13} extremes [2, 2] table of {...} - (hits 7/7) (matched: 'table of final question options') constraint DS = {15} extremes [3, infinity) + (hits 7/7) (matched: 'table of final question options') constraint DS = {13} extremes [3, infinity) + table {...} + constraint DS = {13} extremes [2, infinity) + + nti 15 constraint DS = {15} extremes [2, infinity) + English: table {...} constraint DS = {15} extremes [2, infinity) - - nti 17 constraint DS = {17} extremes [2, infinity) - English: - table {...} - constraint DS = {17} extremes [2, infinity) table of {...} - constraint DS = {17} extremes [3, infinity) + constraint DS = {15} extremes [3, infinity) - hits 3/14 nti 18 constraint DS = {18} extremes [4, infinity) + hits 3/14 nti 16 constraint DS = {16} extremes [4, infinity) English: {***} with blank row/rows - (hits 2/7) (matched long text) constraint DS = {18} extremes [4, infinity) + (hits 2/7) (matched long text) constraint DS = {16} extremes [4, infinity) {***} with {...} blank row/rows - (hits 0/5) constraint DS = {18} extremes [4, infinity) + (hits 0/5) constraint DS = {16} extremes [4, infinity) {***} with blank row/rows for each/every {...} - (hits 1/5) (matched long text) constraint DS = {18} extremes [6, infinity) + (hits 1/5) (matched long text) constraint DS = {16} extremes [6, infinity) - hits 164/328 nti 25 constraint (none) extremes [1, infinity) + hits 164/328 nti 24 constraint (none) extremes [1, infinity) English: - (hits 14/14) (matched: '--') constraint CS = {19} extremes [1, 1] + (hits 14/14) (matched: '--') constraint CS = {17} extremes [1, 1] (hits 28/150) (matched: 'a number') constraint (none) extremes [1, infinity) @@ -6988,19 +6972,19 @@ {...} constraint (none) extremes [1, infinity) - hits 14/28 nti 19 constraint CS = {19} extremes [1, 1] + hits 14/28 nti 17 constraint CS = {17} extremes [1, 1] English: -- - (hits 14/14) (matched: '--') constraint CS = {19} extremes [1, 1] + (hits 14/14) (matched: '--') constraint CS = {17} extremes [1, 1] - hits 116/244 nti 20 constraint (none) extremes [1, infinity) + hits 116/244 nti 18 constraint (none) extremes [1, infinity) English: the action of - (hits 0/2) constraint DS = {20} extremes [4, infinity) + (hits 0/4) constraint DS = {18} extremes [4, infinity) (hits 0/122) constraint (none) extremes [1, infinity) the action of - (hits 0/2) constraint DS = {20} extremes [4, infinity) + (hits 0/4) constraint DS = {18} extremes [4, infinity) (hits 0/122) constraint (none) extremes [1, infinity) @@ -7008,82 +6992,82 @@ (hits 116/122) (matched: 'immediately restart the vm rule') constraint (none) extremes [1, infinity) - hits 12/24 nti 21 constraint (none) extremes [1, infinity) + hits 12/24 nti 19 constraint (none) extremes [1, infinity) English: or - (hits 6/6) (matched: '"forecast/weatherman" or "weather forecast/man"') constraint DS = {21} extremes [3, infinity) + (hits 6/6) (matched: '"forecast/weatherman" or "weather forecast/man"') constraint DS = {19} extremes [3, infinity) (hits 6/6) (matched: '"weather forecast/man"') constraint (none) extremes [1, 1] - nti 22 constraint DS = {22} extremes [1, infinity) + nti 20 constraint DS = {20} extremes [1, infinity) English: equation {} - {...} - constraint DS = {22} extremes [4, infinity) + constraint DS = {20} extremes [4, infinity) equation {} - constraint DS = {22} extremes [2, 2] + constraint DS = {20} extremes [2, 2] equation - {...} - constraint DS = {22} extremes [3, infinity) + constraint DS = {20} extremes [3, infinity) equation {***} - constraint DS = {22} extremes [1, infinity) + constraint DS = {20} extremes [1, infinity) - hits 0/8 nti 23 constraint DS = {23} extremes [2, infinity) + hits 0/8 nti 21 constraint DS = {21} extremes [2, infinity) English: {...} , - (hits 0/3) constraint DS = {23} extremes [2, infinity) + (hits 0/3) constraint DS = {21} extremes [2, infinity) - nti 24 constraint DS = {24} extremes [2, infinity) + nti 22 constraint DS = {22} extremes [2, infinity) English: equation {...} - constraint DS = {24} extremes [2, infinity) + constraint DS = {22} extremes [2, infinity) {...} equation - constraint DS = {24} extremes [2, infinity) + constraint DS = {22} extremes [2, infinity) - nti 25 constraint DS = {25} extremes [3, infinity) + nti 23 constraint DS = {23} extremes [3, infinity) English: {...} where {...} - constraint DS = {25} extremes [3, infinity) + constraint DS = {23} extremes [3, infinity) - hits 4/8 nti 26 constraint (none) extremes [1, infinity) + hits 4/8 nti 25 constraint (none) extremes [1, infinity) English: {...} (hits 0/4) constraint (none) extremes [1, infinity) - (hits 0/4) constraint DS = {27} extremes [3, infinity) + (hits 0/4) constraint DS = {25} extremes [3, infinity) (hits 4/4) (matched: 'x is a real number') constraint (none) extremes [1, infinity) - hits 0/32 nti 27 constraint DS = {27} extremes [2, infinity) + hits 0/32 nti 25 constraint DS = {25} extremes [2, infinity) English: , _and - (hits 0/4) constraint DS = {27} extremes [3, infinity) + (hits 0/8) constraint DS = {25} extremes [3, infinity) _,/and - (hits 0/4) constraint DS = {27} extremes [2, infinity) + (hits 0/8) constraint DS = {25} extremes [2, infinity) - hits 4/8 nti 27 constraint (none) extremes [1, infinity) + hits 4/8 nti 26 constraint (none) extremes [1, infinity) English: {...} (hits 0/4) constraint (none) extremes [1, infinity) (hits 4/4) (matched: 'x is a real number') constraint (none) extremes [1, infinity) - hits 4/8 nti 26 constraint (none) extremes [1, infinity) + hits 4/8 nti 24 constraint (none) extremes [1, infinity) English: is/are - (hits 4/4) (matched: 'x is a real number') constraint DS = {26} extremes [3, infinity) + (hits 4/4) (matched: 'x is a real number') constraint DS = {24} extremes [3, infinity) is/are - constraint DS = {26} extremes [3, infinity) + constraint DS = {24} extremes [3, infinity) is/are {...} - constraint DS = {26} extremes [3, infinity) + constraint DS = {24} extremes [3, infinity) = - constraint DS = {26} extremes [3, infinity) + constraint DS = {24} extremes [3, infinity) = - constraint DS = {26} extremes [3, infinity) + constraint DS = {24} extremes [3, infinity) = {...} - constraint DS = {26} extremes [3, infinity) + constraint DS = {24} extremes [3, infinity) constraint (none) extremes [1, infinity) - hits 4/8 nti 28 constraint (none) extremes [1, infinity) + hits 4/8 nti 27 constraint (none) extremes [1, infinity) English: (hits 4/4) (matched: 'x') constraint (none) extremes [1, infinity) @@ -7092,95 +7076,95 @@ {...} constraint (none) extremes [1, infinity) - internal hits 4/8 nti 29 constraint (none) extremes [1, infinity) + internal hits 4/8 nti 28 constraint (none) extremes [1, infinity) - nti 28 constraint CS = {28} extremes [1, 1] + nti 26 constraint CS = {26} extremes [1, 1] English: continue - constraint CS = {28} extremes [1, 1] + constraint CS = {26} extremes [1, 1] - nti 29 constraint (none) extremes [1, infinity) + nti 27 constraint (none) extremes [1, infinity) English: a list of {...} - constraint DS = {29} extremes [4, infinity) + constraint DS = {27} extremes [4, infinity) {...} constraint (none) extremes [1, infinity) - nti 30 constraint (none) extremes [1, infinity) + nti 29 constraint (none) extremes [1, infinity) English: - constraint DS = {31} extremes [3, infinity) + constraint DS = {29} extremes [3, infinity) constraint (none) extremes [1, infinity) - nti 31 constraint DS = {31} extremes [2, infinity) + nti 29 constraint DS = {29} extremes [2, infinity) English: , and/or - constraint DS = {31} extremes [3, infinity) + constraint DS = {29} extremes [3, infinity) ,/and/or - constraint DS = {31} extremes [2, infinity) + constraint DS = {29} extremes [2, infinity) - nti 30 constraint (none) extremes [1, infinity) + nti 28 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) constraint (none) extremes [1, infinity) {...} begins/ends - constraint DS = {30} extremes [2, infinity) + constraint DS = {28} extremes [2, infinity) when/while {***} - constraint DS = {30} extremes [1, infinity) + constraint DS = {28} extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - nti 6 constraint (none) extremes [1, infinity) + nti 30 constraint (none) extremes [1, infinity) English: say {...} - constraint DS = {6} extremes [2, infinity) + constraint DS = {30} extremes [2, infinity) {...} and/or {...} - constraint DS = {6} extremes [3, infinity) + constraint DS = {30} extremes [3, infinity) {...} constraint (none) extremes [1, infinity) - nti 7 constraint (none) extremes [1, infinity) + nti 31 constraint (none) extremes [1, infinity) English: , {...} - constraint DS = {7} extremes [2, infinity) + constraint DS = {31} extremes [2, infinity) unicode {...} - constraint DS = {7} extremes [2, infinity) + constraint DS = {31} extremes [2, infinity) {...} condition - constraint DS = {7} extremes [2, infinity) + constraint DS = {31} extremes [2, infinity) otherwise/else {***} - constraint DS = {7} extremes [1, infinity) + constraint DS = {31} extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - nti 8 constraint (none) extremes [1, infinity) + nti 6 constraint (none) extremes [1, infinity) English: turns - constraint CS = {8} extremes [1, 1] + constraint CS = {6} extremes [1, 1] {...} is/are out of play - constraint DS = {8} extremes [5, infinity) + constraint DS = {6} extremes [5, infinity) unicode {...} - constraint DS = {8} extremes [2, infinity) + constraint DS = {6} extremes [2, infinity) {...} condition - constraint DS = {8} extremes [2, infinity) + constraint DS = {6} extremes [2, infinity) {...} constraint (none) extremes [1, infinity) - nti 31 constraint (none) extremes [1, infinity) + nti 30 constraint (none) extremes [1, infinity) English: {...} ^option constraint (none) extremes [2, infinity) {...} constraint (none) extremes [1, infinity) - nti 9 constraint (none) extremes [1, infinity) + nti 7 constraint (none) extremes [1, infinity) English: {...} of - constraint DS = {9} extremes [2, infinity) + constraint DS = {7} extremes [2, infinity) {...} for - constraint DS = {9} extremes [2, infinity) + constraint DS = {7} extremes [2, infinity) {...} constraint (none) extremes [1, infinity) @@ -7189,9 +7173,9 @@ (hits 171/171) (matched: '100') constraint CS = {r0} extremes [1, 1] minus - (hits 0/1908) constraint DS = {12} extremes [2, 2] + (hits 0/1891) constraint DS = {12} extremes [2, 2] ( ) - (hits 273/815) (matched: '"[current item from the multiple object list]: [run paragraph on]" ( a )') constraint DS = {12} extremes [4, 4] + (hits 273/762) (matched: '"[current item from the multiple object list]: [run paragraph on]" ( a )') constraint DS = {12} extremes [4, 4] (hits 1564/5543) (matched: 'Represents geographical locations, both indoor and outdoor, which are not necessarily areas in a building. A player in one @@ -7200,68 +7184,68 @@ (hits 11/9911) (matched: 'plus infinity') constraint (none) extremes [1, infinity) - (hits 78/315) (matched: 'false') constraint CS = {6} extremes [1, 1] + (hits 78/979) (matched: 'false') constraint CS = {6} extremes [1, 1] - (hits 0/1628) constraint DS = {8} extremes [2, infinity) + (hits 0/1594) constraint DS = {8} extremes [2, infinity) unicode - (hits 0/4223) constraint DS = {12} extremes [2, infinity) + (hits 0/4109) constraint DS = {12} extremes [2, infinity) - (hits 0/1811) constraint DW = {9, 10, 11} extremes [2, 5] + (hits 0/3052) constraint DW = {9, 10, 11} extremes [2, 5] (hits 0/9822) constraint (none) extremes [1, infinity) - internal hits 680/1360 nti 6 constraint (none) extremes [1, 1] + internal hits 680/1360 nti 31 constraint (none) extremes [1, 1] - hits 78/630 nti 6 constraint CS = {6} extremes [1, 1] + hits 78/1958 nti 6 constraint CS = {6} extremes [1, 1] English: false - (hits 29/315) (matched: 'false') constraint CS = {6} extremes [1, 1] + (hits 29/979) (matched: 'false') constraint CS = {6} extremes [1, 1] true - (hits 49/286) (matched: 'true') constraint CS = {6} extremes [1, 1] + (hits 49/950) (matched: 'true') constraint CS = {6} extremes [1, 1] - internal nti 7 constraint (none) extremes [1, infinity) + internal nti 6 constraint (none) extremes [1, infinity) - internal hits 0/19644 nti 8 constraint (none) extremes [1, infinity) + internal hits 0/19644 nti 7 constraint (none) extremes [1, infinity) hits 11/19822 nti 30 constraint (none) extremes [1, infinity) English: _pi - (hits 1/627) (matched: 'pi') constraint CS = {30} extremes [1, 1] + (hits 1/175) (matched: 'pi') constraint CS = {30} extremes [1, 1] _e - (hits 1/626) (matched: 'e') constraint CS = {30} extremes [1, 1] + (hits 1/174) (matched: 'e') constraint CS = {30} extremes [1, 1] plus infinity - (hits 4/140) (matched: 'plus infinity') constraint CS = {30} extremes [2, 2] + (hits 4/8) (matched: 'plus infinity') constraint CS = {30} extremes [2, 2] minus infinity - (hits 4/136) (matched: 'minus infinity') constraint CS = {30} extremes [2, 2] + (hits 4/4) (matched: 'minus infinity') constraint CS = {30} extremes [2, 2] (hits 1/9901) (matched: '0.5') constraint (none) extremes [1, infinity) - internal hits 1/19802 nti 9 constraint (none) extremes [1, infinity) + internal hits 1/19802 nti 8 constraint (none) extremes [1, infinity) - hits 0/3622 nti 11 constraint DW = {9, 10, 11} extremes [2, 5] + hits 0/6104 nti 11 constraint DW = {9, 10, 11} extremes [2, 5] English: minus - (hits 0/282) constraint DS = {9, 11} extremes [3, 5] + (hits 0/865) constraint DS = {9, 11} extremes [3, 5] - (hits 0/1182) constraint DS = {9} extremes [2, 4] + (hits 0/929) constraint DS = {9} extremes [2, 4] - (hits 0/248) constraint DS = {10} extremes [2, 2] + (hits 0/1473) constraint DS = {10} extremes [2, 2] - hits 0/2364 nti 9 constraint DS = {9} extremes [2, 4] + hits 0/1858 nti 9 constraint DS = {9} extremes [2, 4] English: hour/hours - (hits 0/406) constraint DS = {9} extremes [2, 2] + (hits 0/207) constraint DS = {9} extremes [2, 2] minute/minutes - (hits 0/406) constraint DS = {9} extremes [2, 2] + (hits 0/207) constraint DS = {9} extremes [2, 2] hour/hours minute/minutes - (hits 0/377) constraint DS = {9} extremes [4, 4] + (hits 0/386) constraint DS = {9} extremes [4, 4] - hits 0/496 nti 10 constraint DS = {10} extremes [2, 2] + hits 0/2946 nti 9 constraint DS = {10} extremes [2, 2] English: - (hits 0/248) constraint DS = {10} extremes [2, 2] + (hits 0/1473) constraint DS = {10} extremes [2, 2] - (hits 0/248) constraint DS = {10} extremes [2, 2] + (hits 0/1473) constraint DS = {10} extremes [2, 2] nti 10 constraint CS = {10} extremes [1, 1] English: @@ -7270,25 +7254,25 @@ pm constraint CS = {10} extremes [1, 1] - internal hits 0/496 nti 11 constraint (none) extremes [1, 1] + internal hits 0/2946 nti 10 constraint (none) extremes [1, 1] - internal nti 12 constraint (none) extremes [1, 1] + internal nti 11 constraint (none) extremes [1, 1] - nti 13 constraint (none) extremes [1, infinity) + nti 12 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, 1] constraint (none) extremes [1, infinity) - internal nti 14 constraint (none) extremes [1, infinity) + internal nti 13 constraint (none) extremes [1, infinity) - hits 0/3256 nti 8 constraint DS = {8} extremes [2, infinity) + hits 0/3188 nti 8 constraint DS = {8} extremes [2, infinity) English: { } constraint CS = {8} extremes [2, 2] { } - (hits 0/1356) constraint DS = {8} extremes [3, infinity) + (hits 0/1473) constraint DS = {8} extremes [3, infinity) nti 7 constraint (none) extremes [1, infinity) English: @@ -7297,147 +7281,147 @@ constraint (none) extremes [1, infinity) - nti 15 constraint (none) extremes [1, infinity) + nti 14 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) {......} constraint (none) extremes [1, infinity) - internal hits 4/8 nti 16 constraint (none) extremes [1, infinity) + internal hits 4/8 nti 15 constraint (none) extremes [1, infinity) - internal hits 4/16 nti 17 constraint (none) extremes [1, infinity) + internal hits 4/16 nti 16 constraint (none) extremes [1, infinity) - internal hits 3205/8236 nti 18 constraint (none) extremes [1, infinity) + internal hits 3205/8236 nti 17 constraint (none) extremes [1, infinity) - internal hits 1093/2190 nti 19 constraint (none) extremes [1, infinity) + internal hits 1093/2190 nti 18 constraint (none) extremes [1, infinity) - internal hits 4/8 nti 20 constraint (none) extremes [1, infinity) + internal hits 4/8 nti 19 constraint (none) extremes [1, infinity) - internal hits 1962/5224 nti 21 constraint (none) extremes [1, infinity) + internal hits 1962/5224 nti 20 constraint (none) extremes [1, infinity) - internal hits 1272/3058 nti 22 constraint (none) extremes [1, infinity) + internal hits 1272/3058 nti 21 constraint (none) extremes [1, infinity) - internal hits 529/1072 nti 23 constraint (none) extremes [1, infinity) + internal hits 529/1072 nti 22 constraint (none) extremes [1, infinity) - hits 241/1724 nti 24 constraint (none) extremes [1, infinity) + hits 241/1724 nti 23 constraint (none) extremes [1, infinity) English: (hits 189/792) (matched long text) constraint (none) extremes [1, infinity) (hits 52/603) (matched long text) constraint (none) extremes [1, infinity) - internal hits 0/244 nti 25 constraint (none) extremes [1, infinity) + internal hits 0/244 nti 24 constraint (none) extremes [1, infinity) - internal hits 0/244 nti 26 constraint (none) extremes [1, infinity) + internal hits 0/244 nti 25 constraint (none) extremes [1, infinity) - hits 2370/20902 nti 11 constraint (none) extremes [1, infinity) + hits 2370/20902 nti 9 constraint (none) extremes [1, infinity) English: (hits 1797/10451) (matched: '"[current item from the multiple object list]: [run paragraph on]" ( a )') constraint (none) extremes [1, infinity) nothing - (hits 97/306) (matched: 'nothing') constraint CS = {11} extremes [1, 1] + (hits 97/283) (matched: 'nothing') constraint CS = {9} extremes [1, 1] (hits 449/8557) (matched: 'printing the name of a dark room') constraint (none) extremes [1, infinity) outcome - (hits 0/753) constraint DS = {11} extremes [2, infinity) + (hits 0/1420) constraint DS = {9} extremes [2, infinity) option - (hits 26/753) (matched: 'serial comma option') constraint DS = {11} extremes [2, infinity) + (hits 26/1420) (matched: 'serial comma option') constraint DS = {9} extremes [2, infinity) verb - (hits 1/727) (matched: 'verb are') constraint DS = {11} extremes [2, infinity) + (hits 1/1394) (matched: 'verb are') constraint DS = {9} extremes [2, infinity) response ( ) - (hits 0/444) constraint DS = {11} extremes [5, infinity) + (hits 0/728) constraint DS = {9} extremes [5, infinity) - internal hits 449/17114 nti 27 constraint (none) extremes [1, infinity) + internal hits 449/17114 nti 26 constraint (none) extremes [1, infinity) - internal hits 0/244 nti 28 constraint (none) extremes [1, infinity) + internal hits 0/244 nti 27 constraint (none) extremes [1, infinity) - internal nti 29 constraint (none) extremes [1, infinity) + internal nti 28 constraint (none) extremes [1, infinity) - internal hits 26/52 nti 30 constraint (none) extremes [1, infinity) + internal hits 26/52 nti 29 constraint (none) extremes [1, infinity) - internal nti 31 constraint (none) extremes [1, infinity) + internal nti 30 constraint (none) extremes [1, infinity) - internal hits 165/18574 nti 6 constraint (none) extremes [1, infinity) + internal hits 165/18574 nti 31 constraint (none) extremes [1, infinity) - hits 34/1592 nti 7 constraint DS = {10} extremes [2, infinity) + hits 34/1592 nti 6 constraint DS = {8} extremes [2, infinity) English: - (hits 34/34) (matched: 'the property initial appearance') constraint DS = {10} extremes [3, infinity) + (hits 34/34) (matched: 'the property initial appearance') constraint DS = {8} extremes [3, infinity) - (hits 0/16) constraint DS = {10} extremes [2, infinity) + (hits 0/14) constraint DS = {8} extremes [2, infinity) - internal hits 796/21416 nti 8 constraint (none) extremes [1, infinity) + internal hits 796/21416 nti 7 constraint (none) extremes [1, infinity) - hits 651/21866 nti 9 constraint (none) extremes [1, infinity) + hits 651/21866 nti 8 constraint (none) extremes [1, infinity) English: (hits 651/10933) (matched: 'unmarked for listing') constraint (none) extremes [1, infinity) - hits 1442/27538 nti 12 constraint (none) extremes [1, infinity) + hits 1442/27538 nti 10 constraint (none) extremes [1, infinity) English: not - (hits 0/3108) constraint DS = {12} extremes [3, infinity) + (hits 0/2847) constraint DS = {10} extremes [3, infinity) (hits 0/6944) constraint (none) extremes [2, infinity) (hits 1442/13769) (matched: 'marked for listing other') constraint (none) extremes [1, infinity) - hits 1513/29768 nti 11 constraint (none) extremes [1, infinity) + hits 1513/29768 nti 9 constraint (none) extremes [1, infinity) English: not - (hits 12/1676) (matched: 'not lockable') constraint DS = {11} extremes [2, infinity) + (hits 12/3060) (matched: 'not lockable') constraint DS = {9} extremes [2, infinity) (hits 1430/2252) (matched: 'unmarked for listing') constraint CS = {r3} extremes [1, infinity) not - (hits 0/1484) constraint DS = {11} extremes [3, infinity) + (hits 0/2586) constraint DS = {9} extremes [3, infinity) (hits 71/7271) (matched: 'marked for listing other') constraint (none) extremes [2, infinity) internal hits 2217/19100 nti r3 constraint CS = {r3} extremes [1, infinity) - hits 3634/90352 nti 10 constraint (none) extremes [1, infinity) + hits 3634/90352 nti 9 constraint (none) extremes [1, infinity) English: (hits 2599/45176) (matched: 'value of kind k') constraint (none) extremes [1, infinity) (hits 1035/2038) (matched: 'the alfred cralle pool hall') constraint CW = {r2, r4} extremes [1, infinity) - hits 8/864 nti 11 constraint (none) extremes [1, infinity) + hits 8/864 nti 10 constraint (none) extremes [1, infinity) English: (hits 8/432) (matched: 'person') constraint (none) extremes [1, infinity) - hits 133/7892 nti 12 constraint CW = {r2, r4} extremes [1, infinity) + hits 133/7892 nti 11 constraint CW = {r2, r4} extremes [1, infinity) English: (hits 133/332) (matched: 'alfred cralle pool hall') constraint CW = {r2, r4} extremes [1, infinity) - hits 768/5176 nti 13 constraint (none) extremes [1, infinity) + hits 768/5176 nti 12 constraint (none) extremes [1, infinity) English: (hits 768/2588) (matched: 'marked for listing other') constraint (none) extremes [1, infinity) - hits 1652/38798 nti 14 constraint (none) extremes [1, infinity) + hits 1652/38798 nti 13 constraint (none) extremes [1, infinity) English: (hits 1392/19399) (matched long text) constraint (none) extremes [1, infinity) (hits 260/4823) (matched long text) constraint (none) extremes [3, infinity) - hits 256/2104 nti 15 constraint (none) extremes [1, infinity) + hits 256/2104 nti 14 constraint (none) extremes [1, infinity) English: (hits 256/1052) (matched: 'thing ( called the item being printed )') constraint (none) extremes [1, infinity) - hits 1648/40902 nti 13 constraint (none) extremes [1, infinity) + hits 1648/40902 nti 11 constraint (none) extremes [1, infinity) English: ( called ) - (hits 118/1694) (matched long text) constraint DS = {13} extremes [5, infinity) + (hits 118/1624) (matched long text) constraint DS = {11} extremes [5, infinity) (hits 1530/20333) (matched: 'the alfred cralle pool hall') constraint (none) extremes [1, infinity) - hits 1648/40914 nti 16 constraint (none) extremes [1, infinity) + hits 1648/40914 nti 15 constraint (none) extremes [1, infinity) English: (hits 51/10621) (matched: 'at least two stamped envelopes') constraint (none) extremes [2, infinity) @@ -7456,44 +7440,44 @@ (hits 744/19553) (matched: 'marked for listing other people') constraint (none) extremes [1, infinity) - hits 1412/40880 nti 17 constraint (none) extremes [1, infinity) + hits 1412/40880 nti 16 constraint (none) extremes [1, infinity) English: (hits 1028/20440) (matched: 'nancy johnson memorial square') constraint (none) extremes [1, infinity) (hits 384/10192) (matched: 'marked for listing other people') constraint (none) extremes [2, infinity) - hits 2/300 nti 18 constraint (none) extremes [1, infinity) + hits 2/300 nti 17 constraint (none) extremes [1, infinity) English: (hits 2/150) (matched: 'person') constraint (none) extremes [1, infinity) (hits 0/111) constraint (none) extremes [2, infinity) - hits 56/7194 nti 19 constraint (none) extremes [1, infinity) + hits 56/7194 nti 18 constraint (none) extremes [1, infinity) English: (hits 56/129) (matched: 'alfred cralle pool hall') constraint CW = {r2, r4} extremes [1, infinity) (hits 0/1430) constraint (none) extremes [2, infinity) - internal hits 4743/9700 nti 20 constraint (none) extremes [0, 0] + internal hits 4743/9700 nti 19 constraint (none) extremes [0, 0] - hits 102/544 nti 21 constraint (none) extremes [1, infinity) + hits 102/544 nti 20 constraint (none) extremes [1, infinity) English: (hits 102/272) (matched: 'the dark') constraint (none) extremes [1, infinity) (hits 0/170) constraint (none) extremes [1, infinity) - hits 102/544 nti 14 constraint (none) extremes [1, infinity) + hits 102/544 nti 12 constraint (none) extremes [1, infinity) English: ( called ) - (hits 0/66) constraint DS = {14} extremes [5, infinity) + (hits 0/66) constraint DS = {12} extremes [5, infinity) (hits 102/272) (matched: 'the dark') constraint (none) extremes [1, infinity) - hits 102/544 nti 22 constraint (none) extremes [1, infinity) + hits 102/544 nti 21 constraint (none) extremes [1, infinity) English: (hits 8/153) (matched: 'every dvd') constraint (none) extremes [2, infinity) @@ -7512,7 +7496,7 @@ (hits 94/264) (matched: 'the dark') constraint (none) extremes [1, infinity) - hits 102/566 nti 23 constraint (none) extremes [1, infinity) + hits 102/566 nti 22 constraint (none) extremes [1, infinity) English: (hits 101/283) (matched: 'cold comfort') constraint (none) extremes [1, infinity) @@ -7521,30 +7505,30 @@ (hits 1/182) (matched: 'the dark') constraint (none) extremes [1, infinity) - hits 118/236 nti 24 constraint (none) extremes [1, infinity) + hits 118/236 nti 23 constraint (none) extremes [1, infinity) English:
    {...} (hits 83/95) (matched: 'the item being printed') constraint (none) extremes [2, infinity) {...} (hits 35/35) (matched: 'random bystander') constraint (none) extremes [1, infinity) - internal hits 79/21548 nti 25 constraint (none) extremes [1, infinity) + internal hits 79/21548 nti 24 constraint (none) extremes [1, infinity) - internal hits 288/62770 nti 26 constraint (none) extremes [1, infinity) + internal hits 288/62770 nti 25 constraint (none) extremes [1, infinity) - hits 1947/4830 nti 27 constraint (none) extremes [1, infinity) + hits 1947/4830 nti 26 constraint (none) extremes [1, infinity) English:
    (hits 118/398) (matched long text) constraint (none) extremes [2, infinity) (hits 1829/2297) (matched long text) constraint (none) extremes [1, infinity) - hits 3125/7780 nti 21 constraint (none) extremes [1, infinity) + hits 3125/7780 nti 19 constraint (none) extremes [1, infinity) English: variable/variables - (hits 2/488) (matched: 'text variables') constraint DS = {21} extremes [2, infinity) + (hits 2/402) (matched: 'text variables') constraint DS = {19} extremes [2, infinity) that/which vary/varies - (hits 59/375) (matched: 'action name based rule producing nothing that varies') constraint DS = {21} extremes [3, infinity) + (hits 59/322) (matched: 'action name based rule producing nothing that varies') constraint DS = {19} extremes [3, infinity) (hits 2441/3829) (matched long text) constraint (none) extremes [1, infinity) @@ -7561,30 +7545,30 @@ (hits 27/792) (matched long text) constraint (none) extremes [1, infinity) - hits 1252/3018 nti 28 constraint (none) extremes [1, infinity) + hits 1252/3018 nti 27 constraint (none) extremes [1, infinity) English:
    (hits 162/790) (matched: 'an ice cream cone') constraint (none) extremes [2, infinity) (hits 1090/1347) (matched long text) constraint (none) extremes [1, infinity) - hits 1252/3018 nti 29 constraint (none) extremes [1, infinity) + hits 1252/3018 nti 28 constraint (none) extremes [1, infinity) English: (hits 74/1509) (matched: 'unmarked for listing') constraint (none) extremes [1, infinity) (hits 1178/1435) (matched long text) constraint (none) extremes [1, infinity) - hits 61/124 nti 20 constraint (none) extremes [1, infinity) + hits 61/124 nti 18 constraint (none) extremes [1, infinity) English: global - constraint CS = {20} extremes [1, 1] + constraint CS = {18} extremes [1, 1] global - (hits 0/2) constraint DS = {20} extremes [2, infinity) + (hits 0/2) constraint DS = {18} extremes [2, infinity) (hits 61/62) (matched: 'action name based rule producing nothing') constraint (none) extremes [1, infinity) - hits 61/124 nti 30 constraint (none) extremes [1, infinity) + hits 61/124 nti 29 constraint (none) extremes [1, infinity) English: (hits 61/62) (matched: 'action name based rule producing nothing') constraint (none) extremes [1, infinity) @@ -7597,18 +7581,18 @@ (hits 0/1) constraint (none) extremes [1, infinity) - internal hits 8/18428 nti 31 constraint (none) extremes [0, 0] + internal hits 8/18428 nti 30 constraint (none) extremes [0, 0] - internal hits 2/9366 nti 6 constraint (none) extremes [0, 0] + internal hits 2/9366 nti 31 constraint (none) extremes [0, 0] - internal hits 9/18536 nti 7 constraint (none) extremes [0, 0] + internal hits 9/18536 nti 6 constraint (none) extremes [0, 0] - internal hits 0/18536 nti 8 constraint (none) extremes [0, 0] + internal hits 0/18536 nti 7 constraint (none) extremes [0, 0] - hits 8451/18824 nti 17 constraint (none) extremes [1, infinity) + hits 8451/18824 nti 15 constraint (none) extremes [1, infinity) English: ( ) - (hits 0/1767) constraint DS = {17} extremes [3, infinity) + (hits 0/1536) constraint DS = {15} extremes [3, infinity) (hits 144/9412) (matched: 'the person reaching') constraint (none) extremes [1, infinity) @@ -7630,17 +7614,17 @@ (hits 116/9167) (matched: 'a supporter ( called the chaise )') constraint (none) extremes [1, infinity) - (hits 0/2960) constraint DS = {16} extremes [2, infinity) + (hits 0/3608) constraint DS = {14} extremes [2, infinity) member/members of - (hits 0/1739) constraint DS = {17} extremes [3, infinity) + (hits 0/1508) constraint DS = {15} extremes [3, infinity) member/members of - (hits 0/1739) constraint DS = {17} extremes [3, infinity) + (hits 0/1508) constraint DS = {15} extremes [3, infinity) of - (hits 2/1739) (matched: 'the destination of the player') constraint DS = {17} extremes [3, infinity) + (hits 2/1508) (matched: 'the destination of the player') constraint DS = {15} extremes [3, infinity) (hits 0/4683) constraint (none) extremes [2, infinity) entry of/in/from - (hits 0/1248) constraint DS = {17} extremes [4, infinity) + (hits 0/1145) constraint DS = {15} extremes [4, infinity) (hits 0/9049) constraint (none) extremes [1, infinity) @@ -7648,16 +7632,16 @@ (hits 0/9049) constraint (none) extremes [1, infinity) - hits 4/18428 nti 15 constraint (none) extremes [1, infinity) + hits 4/18428 nti 13 constraint (none) extremes [1, infinity) English: where - (hits 4/1167) (matched long text) constraint DS = {15} extremes [3, infinity) + (hits 4/2272) (matched long text) constraint DS = {13} extremes [3, infinity) where - (hits 0/1163) constraint DS = {15} extremes [3, infinity) + (hits 0/2268) constraint DS = {13} extremes [3, infinity) (hits 0/9210) constraint (none) extremes [1, infinity) - hits 5811/24112 nti 9 constraint (none) extremes [1, infinity) + hits 5811/24112 nti 8 constraint (none) extremes [1, infinity) English: (hits 1637/6150) (matched: 'the room back the other way') constraint (none) extremes [2, infinity) @@ -7668,102 +7652,102 @@ (hits 2211/8456) (matched: 'current item from the multiple object list') constraint (none) extremes [1, infinity) - nti 22 constraint (none) extremes [1, infinity) + nti 20 constraint (none) extremes [1, infinity) English: ( ) - constraint DS = {22} extremes [3, infinity) + constraint DS = {20} extremes [3, infinity) constraint (none) extremes [1, infinity) constraint (none) extremes [1, infinity) - hits 173/1130 nti 10 constraint (none) extremes [1, infinity) + hits 173/1130 nti 9 constraint (none) extremes [1, infinity) English: (hits 173/565) (matched: 'the person asked') constraint (none) extremes [1, infinity) - internal hits 1137/27360 nti 11 constraint (none) extremes [1, infinity) + internal hits 1137/27360 nti 10 constraint (none) extremes [1, infinity) - internal hits 897/18706 nti 12 constraint (none) extremes [1, infinity) + internal hits 897/18706 nti 11 constraint (none) extremes [1, infinity) - internal hits 2296/19726 nti 13 constraint (none) extremes [1, infinity) + internal hits 2296/19726 nti 12 constraint (none) extremes [1, infinity) - hits 105/18392 nti 23 constraint DS = {23} extremes [3, infinity) + hits 105/18392 nti 21 constraint DS = {21} extremes [3, infinity) English: of {...} - (hits 105/1462) (matched long text) constraint DS = {23} extremes [3, infinity) + (hits 105/1548) (matched long text) constraint DS = {21} extremes [3, infinity) - internal hits 493/18392 nti 14 constraint (none) extremes [1, infinity) + internal hits 493/18392 nti 13 constraint (none) extremes [1, infinity) - internal hits 477/18098 nti 15 constraint (none) extremes [1, infinity) + internal hits 477/18098 nti 14 constraint (none) extremes [1, infinity) - hits 139/5920 nti 16 constraint DS = {16} extremes [2, infinity) + hits 139/7216 nti 14 constraint DS = {14} extremes [2, infinity) English: entry - (hits 135/2960) (matched: 'a final response rule entry') constraint DS = {16} extremes [2, infinity) + (hits 135/3608) (matched: 'a final response rule entry') constraint DS = {14} extremes [2, infinity) in row of - (hits 0/422) constraint DS = {16} extremes [6, infinity) + (hits 0/430) constraint DS = {14} extremes [6, infinity) listed in - (hits 2/1374) (matched: 'a topic listed in source') constraint DS = {16} extremes [4, infinity) + (hits 2/1435) (matched: 'a topic listed in source') constraint DS = {14} extremes [4, infinity) corresponding to of in - (hits 0/198) constraint DS = {16} extremes [8, infinity) + (hits 0/198) constraint DS = {14} extremes [8, infinity) of in - (hits 2/660) (matched long text) constraint DS = {16} extremes [5, infinity) + (hits 2/693) (matched long text) constraint DS = {14} extremes [5, infinity) - hits 1074/2238 nti 16 constraint (none) extremes [3, infinity) + hits 1074/2238 nti 15 constraint (none) extremes [3, infinity) English: - (hits 0/853) constraint DS = {19} extremes [3, infinity) + (hits 0/358) constraint DS = {19} extremes [3, infinity) (hits 1074/1108) (matched long text) constraint (none) extremes [3, infinity) - hits 11/22 nti 17 constraint FS = {7} extremes [2, infinity) + hits 11/22 nti 16 constraint FS = {7} extremes [2, infinity) English: (hits 11/11) (matched long text) constraint FS = {7} extremes [2, infinity) - hits 2149/6658 nti 18 constraint (none) extremes [2, infinity) + hits 2149/6658 nti 17 constraint (none) extremes [2, infinity) English: - (hits 0/839) constraint DS = {19} & FS = {9} extremes [4, infinity) + (hits 0/748) constraint DS = {17} & FS = {9} extremes [4, infinity) - (hits 224/1635) (matched long text) constraint DS = {14} & FS = {6} extremes [3, infinity) + (hits 224/1842) (matched long text) constraint DS = {14} & FS = {6} extremes [3, infinity) - (hits 1925/2195) (matched long text) constraint FS = {6} extremes [2, infinity) + (hits 1925/2188) (matched long text) constraint FS = {6} extremes [2, infinity) - nti 19 constraint DS = {19} extremes [3, infinity) + nti 17 constraint DS = {17} extremes [3, infinity) English: to - constraint DS = {19} extremes [3, infinity) + constraint DS = {17} extremes [3, infinity) - hits 260/9986 nti 19 constraint (none) extremes [3, infinity) + hits 260/9986 nti 18 constraint (none) extremes [3, infinity) English: - (hits 169/4202) (matched long text) constraint DS = {13} extremes [3, infinity) + (hits 169/4478) (matched long text) constraint DS = {13} extremes [3, infinity) - (hits 91/2748) (matched long text) constraint DS = {30} extremes [4, infinity) + (hits 91/2742) (matched long text) constraint DS = {30} extremes [4, infinity) - hits 448/30942 nti 18 constraint DS = {13} extremes [2, infinity) + hits 448/32048 nti 16 constraint DS = {13} extremes [2, infinity) English: - (hits 447/9222) (matched long text) constraint DS = {13} extremes [2, infinity) + (hits 447/9957) (matched long text) constraint DS = {13} extremes [2, infinity) not - (hits 1/6221) (matched: 'not carried by the person asked') constraint DS = {13, 18} extremes [3, infinity) + (hits 1/3928) (matched: 'not carried by the person asked') constraint DS = {13, 16} extremes [3, infinity) - hits 183/23714 nti 20 constraint DS = {30} extremes [3, infinity) + hits 183/23620 nti 19 constraint DS = {30} extremes [3, infinity) English: - (hits 0/2550) constraint DS = {19, 30} extremes [5, infinity) + (hits 0/2540) constraint DS = {17, 30} extremes [5, infinity) - (hits 32/3677) (matched long text) constraint DS = {14, 30} extremes [4, infinity) + (hits 32/3768) (matched long text) constraint DS = {14, 30} extremes [4, infinity) - (hits 151/5885) (matched: 'which provide the property initial appearance') constraint DS = {30} extremes [3, infinity) + (hits 151/5921) (matched: 'which provide the property initial appearance') constraint DS = {30} extremes [3, infinity) - internal hits 791/18334 nti 21 constraint (none) extremes [1, infinity) + internal hits 791/18334 nti 20 constraint (none) extremes [1, infinity) - internal hits 1217/34624 nti 22 constraint (none) extremes [0, 0] + internal hits 1217/34624 nti 21 constraint (none) extremes [0, 0] - hits 4662/9672 nti 23 constraint (none) extremes [1, infinity) + hits 4662/9672 nti 22 constraint (none) extremes [1, infinity) English: (hits 30/4836) (matched: 'the person asked') constraint (none) extremes [1, infinity) @@ -7772,7 +7756,7 @@ ^ (hits 4602/4776) (matched long text) constraint (none) extremes [1, infinity) - hits 797/2188 nti 24 constraint (none) extremes [1, infinity) + hits 797/2188 nti 23 constraint (none) extremes [1, infinity) English: (hits 143/1094) (matched: 'the person asked') constraint (none) extremes [1, infinity) @@ -7781,10 +7765,10 @@ ^ (hits 552/849) (matched long text) constraint (none) extremes [1, infinity) - hits 2/496 nti 24 constraint (none) extremes [1, infinity) + hits 2/496 nti 22 constraint (none) extremes [1, infinity) English: ( ) - (hits 0/22) constraint DS = {24} extremes [3, infinity) + (hits 0/6) constraint DS = {22} extremes [3, infinity) constraint CS = {r0} extremes [1, 1] @@ -7792,178 +7776,178 @@ (hits 2/248) (matched: 'switched off') constraint (none) extremes [1, infinity) - hits 1071/2634 nti 25 constraint (none) extremes [0, infinity) + hits 1071/2634 nti 24 constraint (none) extremes [0, infinity) English: (hits 1069/1317) (matched long text) constraint (none) extremes [0, infinity) (hits 2/248) (matched: 'switched off') constraint (none) extremes [1, infinity) - hits 1325/3170 nti 7 constraint (none) extremes [0, infinity) + hits 1325/3170 nti 31 constraint (none) extremes [0, infinity) English: ( ) - (hits 0/1310) constraint DS = {7} extremes [3, infinity) + (hits 0/1300) constraint DS = {31} extremes [3, infinity) , and - (hits 0/1203) constraint DS = {7} extremes [4, infinity) + (hits 0/1196) constraint DS = {31} extremes [4, infinity) and - (hits 97/1310) (matched long text) constraint DS = {7} extremes [3, infinity) + (hits 97/1300) (matched long text) constraint DS = {31} extremes [3, infinity) , or - (hits 0/1106) constraint DS = {7} extremes [4, infinity) + (hits 0/1099) constraint DS = {31} extremes [4, infinity) or - (hits 31/1213) (matched long text) constraint DS = {7} extremes [3, infinity) + (hits 31/1203) (matched long text) constraint DS = {31} extremes [3, infinity) (hits 0/1457) constraint (none) extremes [1, infinity) (hits 1197/1457) (matched long text) constraint (none) extremes [0, infinity) - internal hits 0/2914 nti 26 constraint (none) extremes [1, infinity) + internal hits 0/2914 nti 25 constraint (none) extremes [1, infinity) - hits 1197/2914 nti 6 constraint (none) extremes [0, infinity) + hits 1197/2914 nti 30 constraint (none) extremes [0, infinity) English: (hits 1/1457) (matched: 'continuing') constraint (none) extremes [1, infinity) not - (hits 0/1184) constraint DS = {6} extremes [2, infinity) + (hits 0/1178) constraint DS = {30} extremes [2, infinity) (hits 83/1456) (matched long text) constraint (none) extremes [1, infinity) - (hits 0/1077) constraint DS = {27} extremes [3, infinity) + (hits 0/1091) constraint DS = {25} extremes [3, infinity) - (hits 0/765) constraint DS = {28} extremes [4, infinity) + (hits 0/565) constraint DS = {26} extremes [4, infinity) (hits 28/1373) (matched long text) constraint (none) extremes [1, infinity) - (hits 0/1086) constraint DS = {30} extremes [2, infinity) + (hits 0/782) constraint DS = {28} extremes [2, infinity) (hits 1074/1119) (matched long text) constraint (none) extremes [3, infinity) (hits 11/271) (matched long text) constraint (none) extremes [0, infinity) - hits 83/2912 nti 26 constraint (none) extremes [1, infinity) + hits 83/2912 nti 24 constraint (none) extremes [1, infinity) English: - (hits 0/921) constraint DS = {19, 25} extremes [3, infinity) + (hits 0/403) constraint DS = {19, 23} extremes [3, infinity) (hits 83/1445) (matched long text) constraint (none) extremes [1, infinity) not - (hits 0/1063) constraint DS = {26} extremes [2, infinity) + (hits 0/1101) constraint DS = {24} extremes [2, infinity) - hits 11/542 nti 31 constraint (none) extremes [0, infinity) + hits 11/542 nti 29 constraint (none) extremes [0, infinity) English: ^ (hits 0/11) constraint (none) extremes [0, infinity) (hits 11/11) (matched long text) constraint (none) extremes [1, infinity) not - constraint DS = {31} extremes [2, infinity) + constraint DS = {29} extremes [2, infinity) - hits 22/2406 nti 25 constraint DS = {19, 25} extremes [3, infinity) + hits 22/1370 nti 23 constraint DS = {19, 23} extremes [3, infinity) English: is/are {...} - (hits 22/961) (matched long text) constraint DS = {19, 25} extremes [3, infinity) + (hits 22/438) (matched long text) constraint DS = {19, 23} extremes [3, infinity) - internal hits 94/2912 nti 27 constraint (none) extremes [1, infinity) + internal hits 94/2912 nti 26 constraint (none) extremes [1, infinity) - internal hits 1/2914 nti 28 constraint (none) extremes [1, infinity) + internal hits 1/2914 nti 27 constraint (none) extremes [1, infinity) - hits 1374/2748 nti 8 constraint (none) extremes [1, infinity) + hits 1374/2748 nti 6 constraint (none) extremes [1, infinity) English: ( ) - (hits 0/1046) constraint DS = {8} extremes [3, infinity) + (hits 0/1302) constraint DS = {6} extremes [3, infinity) (hits 1374/1374) (matched long text) constraint (none) extremes [1, infinity) - hits 2627/5254 nti 10 constraint (none) extremes [1, infinity) + hits 2627/5254 nti 8 constraint (none) extremes [1, infinity) English: ( ) - (hits 0/388) constraint DS = {10} extremes [3, infinity) + (hits 0/391) constraint DS = {8} extremes [3, infinity) (hits 239/2627) (matched: 'might not appreciate') constraint (none) extremes [1, infinity) (hits 2388/2388) (matched long text) constraint (none) extremes [1, infinity) - hits 239/5254 nti 9 constraint (none) extremes [1, infinity) + hits 239/5254 nti 7 constraint (none) extremes [1, infinity) English: (hits 0/2581) constraint (none) extremes [1, infinity) verb - (hits 0/485) constraint DS = {9} extremes [2, infinity) + (hits 0/465) constraint DS = {7} extremes [2, infinity) adjective - (hits 0/485) constraint DS = {9} extremes [2, infinity) + (hits 0/465) constraint DS = {7} extremes [2, infinity) (hits 210/2581) (matched: 'do not fit') constraint (none) extremes [1, infinity) verb - (hits 0/404) constraint DS = {9} extremes [3, infinity) + (hits 0/384) constraint DS = {7} extremes [3, infinity) (hits 29/855) (matched: 'might not appreciate') constraint (none) extremes [2, infinity) (hits 0/2342) constraint (none) extremes [1, infinity) - internal hits 0/4684 nti 29 constraint (none) extremes [1, infinity) + internal hits 0/4684 nti 28 constraint (none) extremes [1, infinity) - internal hits 1374/2748 nti 30 constraint (none) extremes [1, infinity) + internal hits 1374/2748 nti 29 constraint (none) extremes [1, infinity) - internal hits 2388/4776 nti 31 constraint (none) extremes [1, infinity) + internal hits 2388/4776 nti 30 constraint (none) extremes [1, infinity) internal hits 1168/4912 nti r4 constraint CW = {r2, r4} extremes [1, infinity) - internal hits 4/252 nti 6 constraint (none) extremes [1, infinity) + internal hits 4/252 nti 31 constraint (none) extremes [1, infinity) - nti 7 constraint (none) extremes [0, 0] + nti 6 constraint (none) extremes [0, 0] English: constraint (none) extremes [0, 0] constraint (none) extremes [0, 0] - internal hits 0/172 nti 8 constraint (none) extremes [1, infinity) + internal hits 0/172 nti 7 constraint (none) extremes [1, infinity) - internal hits 4/252 nti 9 constraint (none) extremes [1, infinity) + internal hits 4/252 nti 8 constraint (none) extremes [1, infinity) - nti 10 constraint (none) extremes [1, infinity) + nti 9 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) constraint (none) extremes [1, infinity) - hits 4/292 nti 11 constraint CS = {11} extremes [1, 3] + hits 4/292 nti 9 constraint CS = {9} extremes [1, 3] English: description - (hits 1/6) (matched: 'description') constraint CS = {11} extremes [1, 1] + (hits 1/7) (matched: 'description') constraint CS = {9} extremes [1, 1] specification - (hits 1/5) (matched: 'specification') constraint CS = {11} extremes [1, 1] + (hits 1/6) (matched: 'specification') constraint CS = {9} extremes [1, 1] indefinite appearance text - (hits 1/2) (matched: 'indefinite appearance text') constraint CS = {11} extremes [3, 3] + (hits 1/2) (matched: 'indefinite appearance text') constraint CS = {9} extremes [3, 3] variable initial value - (hits 1/1) (matched: 'variable initial value') constraint CS = {11} extremes [3, 3] + (hits 1/1) (matched: 'variable initial value') constraint CS = {9} extremes [3, 3] - hits 34/100 nti 10 constraint DS = {10} extremes [2, infinity) + hits 34/96 nti 8 constraint DS = {8} extremes [2, infinity) English: property {...} - (hits 34/50) (matched: 'property initial appearance') constraint DS = {10} extremes [2, infinity) + (hits 34/48) (matched: 'property initial appearance') constraint DS = {8} extremes [2, infinity) - internal hits 69/430 nti 11 constraint (none) extremes [1, infinity) + internal hits 69/430 nti 10 constraint (none) extremes [1, infinity) - internal hits 0/44 nti 12 constraint (none) extremes [1, infinity) + internal hits 0/44 nti 11 constraint (none) extremes [1, infinity) - internal hits 127/2212 nti 13 constraint (none) extremes [1, infinity) + internal hits 127/2212 nti 12 constraint (none) extremes [1, infinity) - internal hits 104/392 nti 14 constraint (none) extremes [1, infinity) + internal hits 104/392 nti 13 constraint (none) extremes [1, infinity) - hits 0/292 nti 12 constraint DS = {12} extremes [1, infinity) + hits 0/292 nti 10 constraint DS = {10} extremes [1, infinity) English: {***} of {***} - (hits 0/14) constraint DS = {12} extremes [1, infinity) + (hits 0/9) constraint DS = {10} extremes [1, infinity) - internal nti 15 constraint (none) extremes [1, infinity) + internal nti 14 constraint (none) extremes [1, infinity) - nti 13 constraint DS = {13} extremes [4, infinity) + nti 11 constraint DS = {11} extremes [4, infinity) English: the same {...} as - constraint DS = {13} extremes [4, infinity) + constraint DS = {11} extremes [4, infinity) - hits 22/44 nti 16 constraint (none) extremes [1, infinity) + hits 22/44 nti 15 constraint (none) extremes [1, infinity) English: (hits 0/22) constraint (none) extremes [1, infinity) @@ -7972,86 +7956,86 @@ {...} constraint (none) extremes [1, infinity) - nti 14 constraint DS = {14} extremes [2, infinity) + nti 12 constraint DS = {12} extremes [2, infinity) English: {...} than - constraint DS = {14} extremes [2, infinity) + constraint DS = {12} extremes [2, infinity) - hits 0/82 nti 16 constraint DS = {16} extremes [4, infinity) + hits 0/82 nti 14 constraint DS = {14} extremes [4, infinity) English: {...} is/are not {...} - (hits 0/37) constraint DS = {16} extremes [5, infinity) + (hits 0/37) constraint DS = {14} extremes [5, infinity) {} is/are - (hits 0/37) constraint DS = {16} extremes [4, infinity) + (hits 0/38) constraint DS = {14} extremes [4, infinity) {...} is/are - (hits 0/37) constraint DS = {16} extremes [4, infinity) + (hits 0/38) constraint DS = {14} extremes [4, infinity) - nti 15 constraint (none) extremes [1, infinity) + nti 13 constraint (none) extremes [1, infinity) English: {...} or more - constraint DS = {15} extremes [3, infinity) + constraint DS = {13} extremes [3, infinity) {...} or less - constraint DS = {15} extremes [3, infinity) + constraint DS = {13} extremes [3, infinity) {...} constraint (none) extremes [1, infinity) - hits 10/292 nti 17 constraint CS = {17} extremes [1, 3] + hits 10/292 nti 15 constraint CS = {15} extremes [1, 3] English: indefinite article - (hits 1/2) (matched: 'indefinite article') constraint CS = {17} extremes [2, 2] + (hits 1/2) (matched: 'indefinite article') constraint CS = {15} extremes [2, 2] plural-named - (hits 1/6) (matched: 'plural-named') constraint CS = {17} extremes [1, 1] + (hits 1/6) (matched: 'plural-named') constraint CS = {15} extremes [1, 1] proper-named - (hits 1/5) (matched: 'proper-named') constraint CS = {17} extremes [1, 1] + (hits 1/5) (matched: 'proper-named') constraint CS = {15} extremes [1, 1] printed name - (hits 1/1) (matched: 'printed name') constraint CS = {17} extremes [2, 2] + (hits 1/1) (matched: 'printed name') constraint CS = {15} extremes [2, 2] printed plural name - (hits 1/2) (matched: 'printed plural name') constraint CS = {17} extremes [3, 3] + (hits 1/2) (matched: 'printed plural name') constraint CS = {15} extremes [3, 3] publicly-named - (hits 1/4) (matched: 'publicly-named') constraint CS = {17} extremes [1, 1] + (hits 1/4) (matched: 'publicly-named') constraint CS = {15} extremes [1, 1] privately-named - (hits 1/3) (matched: 'privately-named') constraint CS = {17} extremes [1, 1] + (hits 1/3) (matched: 'privately-named') constraint CS = {15} extremes [1, 1] adaptive text viewpoint - (hits 1/1) (matched: 'adaptive text viewpoint') constraint CS = {17} extremes [3, 3] + (hits 1/1) (matched: 'adaptive text viewpoint') constraint CS = {15} extremes [3, 3] neuter - (hits 1/2) (matched: 'neuter') constraint CS = {17} extremes [1, 1] + (hits 1/2) (matched: 'neuter') constraint CS = {15} extremes [1, 1] female - (hits 1/1) (matched: 'female') constraint CS = {17} extremes [1, 1] + (hits 1/1) (matched: 'female') constraint CS = {15} extremes [1, 1] - hits 1191/2382 nti 18 constraint DS = {18} extremes [2, infinity) + hits 1191/2382 nti 16 constraint DS = {16} extremes [2, infinity) English: {...} rule - (hits 1191/1191) (matched long text) constraint DS = {18} extremes [2, infinity) + (hits 1191/1191) (matched long text) constraint DS = {16} extremes [2, infinity) - internal hits 123/246 nti 17 constraint (none) extremes [1, infinity) + internal hits 123/246 nti 16 constraint (none) extremes [1, infinity) - hits 431/862 nti 19 constraint (none) extremes [1, infinity) + hits 431/862 nti 17 constraint (none) extremes [1, infinity) English: (hits 0/418) constraint (none) extremes [2, infinity) rules/rulebook - (hits 24/193) (matched: 'does the player mean rules') constraint DS = {19} extremes [2, infinity) + (hits 24/164) (matched: 'does the player mean rules') constraint DS = {17} extremes [2, infinity) at {***} - (hits 0/169) constraint DS = {19} extremes [1, infinity) + (hits 0/140) constraint DS = {17} extremes [1, infinity) to {***} - (hits 0/169) constraint DS = {19} extremes [1, infinity) + (hits 0/140) constraint DS = {17} extremes [1, infinity) definition {***} - (hits 0/169) constraint DS = {19} extremes [1, infinity) + (hits 0/140) constraint DS = {17} extremes [1, infinity) {...} (hits 407/407) (matched long text) constraint (none) extremes [1, infinity) - nti 20 constraint DS = {20} extremes [2, infinity) + nti 18 constraint DS = {18} extremes [2, infinity) English: {...} rules - constraint DS = {20} extremes [2, infinity) + constraint DS = {18} extremes [2, infinity) {...} rulebook - constraint DS = {20} extremes [2, infinity) + constraint DS = {18} extremes [2, infinity) - internal hits 82/164 nti 18 constraint (none) extremes [1, infinity) + internal hits 82/164 nti 17 constraint (none) extremes [1, infinity) - internal hits 371/790 nti 19 constraint (none) extremes [1, infinity) + internal hits 371/790 nti 18 constraint (none) extremes [1, infinity) - hits 395/790 nti 20 constraint (none) extremes [1, infinity) + hits 395/790 nti 19 constraint (none) extremes [1, infinity) English: (hits 19/395) (matched: 'a first turn sequence rule') constraint (none) extremes [2, infinity) @@ -8060,180 +8044,180 @@ (hits 373/373) (matched long text) constraint (none) extremes [1, infinity) - hits 395/790 nti 22 constraint (none) extremes [1, infinity) + hits 395/790 nti 20 constraint (none) extremes [1, infinity) English: rule for/about/on - (hits 13/246) (matched long text) constraint DS = {22} extremes [3, infinity) + (hits 13/124) (matched long text) constraint DS = {20} extremes [3, infinity) rule - (hits 0/237) constraint DS = {22} extremes [2, infinity) + (hits 0/115) constraint DS = {20} extremes [2, infinity) first rule - (hits 0/233) constraint DS = {22} extremes [3, infinity) + (hits 0/111) constraint DS = {20} extremes [3, infinity) first - (hits 3/237) (matched: 'first turn sequence rule') constraint DS = {22} extremes [2, infinity) + (hits 3/115) (matched: 'first turn sequence rule') constraint DS = {20} extremes [2, infinity) last rule - (hits 0/230) constraint DS = {22} extremes [3, infinity) + (hits 0/108) constraint DS = {20} extremes [3, infinity) last - (hits 3/234) (matched: 'last turn sequence rule') constraint DS = {22} extremes [2, infinity) + (hits 3/112) (matched: 'last turn sequence rule') constraint DS = {20} extremes [2, infinity) (hits 376/376) (matched long text) constraint (none) extremes [1, infinity) - hits 395/790 nti 21 constraint (none) extremes [1, infinity) + hits 395/790 nti 19 constraint (none) extremes [1, infinity) English: {when ... begins} - (hits 4/123) (matched long text) constraint DS = {21} extremes [3, infinity) + (hits 4/158) (matched long text) constraint DS = {19} extremes [3, infinity) {when ... ends} - (hits 0/119) constraint DS = {21} extremes [3, infinity) + (hits 0/154) constraint DS = {19} extremes [3, infinity) {...} (hits 391/391) (matched long text) constraint (none) extremes [1, infinity) - internal hits 8/1226 nti 21 constraint (none) extremes [1, infinity) + internal hits 8/1226 nti 20 constraint (none) extremes [1, infinity) - hits 7/14 nti 26 constraint (none) extremes [1, infinity) + hits 7/14 nti 24 constraint (none) extremes [1, infinity) English: outcome/outcomes - (hits 7/7) (matched long text) constraint DS = {26} extremes [2, infinity) + (hits 7/7) (matched long text) constraint DS = {24} extremes [2, infinity) default - constraint DS = {26} extremes [2, infinity) + constraint DS = {24} extremes [2, infinity) {...} constraint (none) extremes [1, infinity) - nti 22 constraint (none) extremes [1, infinity) + nti 21 constraint (none) extremes [1, infinity) English: - constraint CS = {23} extremes [1, 2] + constraint CS = {21} extremes [1, 2] {...} constraint (none) extremes [1, infinity) - hits 27/54 nti 23 constraint (none) extremes [1, infinity) + hits 27/54 nti 22 constraint (none) extremes [1, infinity) English: {...} (hits 10/27) (matched long text) constraint (none) extremes [1, infinity) - (hits 10/17) (matched long text) constraint DS = {25} extremes [3, infinity) + (hits 10/17) (matched long text) constraint DS = {23} extremes [3, infinity) (hits 7/7) (matched: 'there is insufficient light ( success )') constraint (none) extremes [1, infinity) - hits 20/170 nti 25 constraint DS = {25} extremes [2, infinity) + hits 20/170 nti 23 constraint DS = {23} extremes [2, infinity) English: , _and/or - (hits 0/71) constraint DS = {25} extremes [3, infinity) + (hits 0/71) constraint DS = {23} extremes [3, infinity) _,/and/or - (hits 20/77) (matched long text) constraint DS = {25} extremes [2, infinity) + (hits 20/77) (matched long text) constraint DS = {23} extremes [2, infinity) - hits 27/54 nti 24 constraint (none) extremes [1, infinity) + hits 27/54 nti 23 constraint (none) extremes [1, infinity) English: {...} (hits 10/27) (matched: 'there is sufficient light ( failure )') constraint (none) extremes [1, infinity) (hits 17/17) (matched: 'there is sufficient light ( failure )') constraint (none) extremes [1, infinity) - hits 17/34 nti 24 constraint (none) extremes [1, infinity) + hits 17/34 nti 22 constraint (none) extremes [1, infinity) English: {...} ( - the default ) - (hits 0/2) constraint DS = {23, 24} extremes [7, infinity) + (hits 0/2) constraint DS = {21, 22} extremes [7, infinity) {...} ( - default ) - (hits 0/3) constraint DS = {23, 24} extremes [6, infinity) + (hits 0/3) constraint DS = {21, 22} extremes [6, infinity) {...} ( ) - (hits 12/12) (matched: 'there is sufficient light ( failure )') constraint DS = {23, 24} extremes [4, infinity) + (hits 12/12) (matched: 'there is sufficient light ( failure )') constraint DS = {21, 22} extremes [4, infinity) {...} ( {...} ) - (hits 0/2) constraint DS = {24} extremes [4, infinity) + constraint DS = {22} extremes [4, infinity) {...} (hits 5/5) (matched: 'it is very likely') constraint (none) extremes [1, infinity) - hits 12/24 nti 23 constraint CS = {23} extremes [1, 2] + hits 12/24 nti 21 constraint CS = {21} extremes [1, 2] English: success - (hits 6/12) (matched: 'success') constraint CS = {23} extremes [1, 1] + (hits 6/12) (matched: 'success') constraint CS = {21} extremes [1, 1] failure - (hits 6/6) (matched: 'failure') constraint CS = {23} extremes [1, 1] + (hits 6/6) (matched: 'failure') constraint CS = {21} extremes [1, 1] no outcome - constraint CS = {23} extremes [2, 2] + constraint CS = {21} extremes [2, 2] - hits 35/70 nti 30 constraint (none) extremes [1, infinity) + hits 35/70 nti 28 constraint (none) extremes [1, infinity) English: ( ) - (hits 32/33) (matched long text) constraint DS = {29, 30} extremes [6, infinity) + (hits 32/33) (matched long text) constraint DS = {27, 28} extremes [6, infinity) -- -- - (hits 1/1) (matched long text) constraint DS = {29, 30} extremes [6, infinity) + (hits 1/1) (matched long text) constraint DS = {27, 28} extremes [6, infinity) (hits 2/2) (matched: 'handling the final question') constraint (none) extremes [1, infinity) - hits 35/70 nti 28 constraint (none) extremes [1, infinity) + hits 35/70 nti 26 constraint (none) extremes [1, infinity) English: ( future action ) - (hits 4/19) (matched long text) constraint DS = {28} extremes [5, infinity) + (hits 4/21) (matched long text) constraint DS = {26} extremes [5, infinity) ( {...} ) - (hits 0/22) constraint DS = {28} extremes [4, infinity) + (hits 0/19) constraint DS = {26} extremes [4, infinity) (hits 31/31) (matched: 'printing a refusal to act in the dark') constraint (none) extremes [1, infinity) - hits 35/70 nti 27 constraint (none) extremes [1, infinity) + hits 35/70 nti 25 constraint (none) extremes [1, infinity) English: {...} of/for something/anything - (hits 14/26) (matched: 'printing the plural name of something') constraint DS = {27} extremes [3, infinity) + (hits 14/30) (matched: 'printing the plural name of something') constraint DS = {25} extremes [3, infinity) {...} something/anything - (hits 5/12) (matched: 'printing a locale paragraph about something') constraint DS = {27} extremes [2, infinity) + (hits 5/16) (matched: 'printing a locale paragraph about something') constraint DS = {25} extremes [2, infinity) {...} (hits 16/16) (matched: 'printing a refusal to act in the dark') constraint (none) extremes [1, infinity) - nti 31 constraint DS = {31} extremes [2, infinity) + nti 29 constraint DS = {29} extremes [2, infinity) English: {...} activity - constraint DS = {31} extremes [2, infinity) + constraint DS = {29} extremes [2, infinity) - nti 6 constraint DS = {6} extremes [2, infinity) + nti 30 constraint DS = {30} extremes [2, infinity) English: before {...} - constraint DS = {6} extremes [2, infinity) + constraint DS = {30} extremes [2, infinity) for {...} - constraint DS = {6} extremes [2, infinity) + constraint DS = {30} extremes [2, infinity) after {...} - constraint DS = {6} extremes [2, infinity) + constraint DS = {30} extremes [2, infinity) - internal hits 1/88 nti 25 constraint (none) extremes [1, infinity) + internal hits 1/88 nti 24 constraint (none) extremes [1, infinity) - hits 432/1426 nti 7 constraint DS = {7} extremes [2, infinity) + hits 432/1426 nti 31 constraint DS = {31} extremes [2, infinity) English: (- {###} - in to only - (hits 16/26) (matched: '(- rtrue; - in to only') constraint DS = {7} extremes [6, 6] + (hits 16/26) (matched: '(- rtrue; - in to only') constraint DS = {31} extremes [6, 6] (- {###} - in to decide if only - (hits 4/12) (matched: '(- rtrue; - in to decide if only') constraint DS = {7} extremes [8, 8] + (hits 4/12) (matched: '(- rtrue; - in to decide if only') constraint DS = {31} extremes [8, 8] (- {###} - in to decide only - (hits 0/7) constraint DS = {7} extremes [7, 7] + (hits 0/7) constraint DS = {31} extremes [7, 7] (- {###} - (hits 412/443) (matched: '(- {-say:val:K} ') constraint DS = {7} extremes [2, 2] + (hits 412/412) (matched: '(- {-say:val:K} ') constraint DS = {31} extremes [2, 2] (- {###} {...} - (hits 0/68) constraint DS = {7} extremes [3, infinity) + (hits 0/66) constraint DS = {31} extremes [3, infinity) - hits 41/82 nti 11 constraint (none) extremes [1, infinity) + hits 41/82 nti 9 constraint (none) extremes [1, infinity) English: not - (hits 1/1) (matched: 'not opening or closing or locking or unlocking') constraint DS = {11} extremes [2, infinity) + (hits 1/21) (matched: 'not opening or closing or locking or unlocking') constraint DS = {9} extremes [2, infinity) (hits 40/40) (matched: 'dropping or throwing or inserting or putting') constraint (none) extremes [1, infinity) - hits 41/82 nti 26 constraint (none) extremes [1, infinity) + hits 41/82 nti 25 constraint (none) extremes [1, infinity) English: {...} (hits 14/41) (matched: 'throwing or inserting or putting') constraint (none) extremes [1, infinity) - (hits 14/14) (matched: 'dropping or throwing or inserting or putting') constraint DS = {10} extremes [3, infinity) + (hits 14/14) (matched: 'dropping or throwing or inserting or putting') constraint DS = {8} extremes [3, infinity) (hits 13/13) (matched: 'an actor smelling') constraint (none) extremes [1, infinity) - hits 28/64 nti 10 constraint DS = {10} extremes [2, infinity) + hits 28/64 nti 8 constraint DS = {8} extremes [2, infinity) English: , _or - (hits 0/20) constraint DS = {10} extremes [3, infinity) + (hits 0/20) constraint DS = {8} extremes [3, infinity) _,/or - (hits 28/32) (matched: 'or throwing or inserting or putting') constraint DS = {10} extremes [2, infinity) + (hits 28/32) (matched: 'or throwing or inserting or putting') constraint DS = {8} extremes [2, infinity) - hits 41/82 nti 9 constraint (none) extremes [1, infinity) + hits 41/82 nti 7 constraint (none) extremes [1, infinity) English: (hits 1/41) (matched: 'listing contents') constraint (none) extremes [1, infinity) of/for - (hits 0/2) constraint DS = {9} extremes [3, infinity) + constraint DS = {7} extremes [3, infinity) (hits 0/12) constraint (none) extremes [2, infinity) ^ {...} @@ -8241,232 +8225,232 @@ (hits 40/40) (matched: 'an actor smelling') constraint (none) extremes [1, infinity) - hits 3/30 nti 8 constraint (none) extremes [1, infinity) + hits 3/30 nti 6 constraint (none) extremes [1, infinity) English: something/anything - constraint CS = {8} extremes [1, 1] + constraint CS = {6} extremes [1, 1] something/anything else - constraint CS = {8} extremes [2, 2] + constraint CS = {6} extremes [2, 2] (hits 3/15) (matched: 'smelling') constraint (none) extremes [1, infinity) - internal hits 80/160 nti 27 constraint (none) extremes [0, 0] + internal hits 80/160 nti 26 constraint (none) extremes [0, 0] - hits 517/1034 nti 14 constraint (none) extremes [1, infinity) + hits 517/1034 nti 12 constraint (none) extremes [1, infinity) English: ( deprecated ) - (hits 1/433) (matched long text) constraint DS = {14} extremes [4, infinity) + (hits 1/425) (matched long text) constraint DS = {12} extremes [4, infinity) - (hits 138/492) (matched long text) constraint DS = {12} extremes [2, infinity) + (hits 138/492) (matched long text) constraint DS = {10} extremes [2, infinity) (hits 378/378) (matched long text) constraint (none) extremes [1, infinity) - hits 400/800 nti 13 constraint (none) extremes [1, infinity) + hits 400/800 nti 11 constraint (none) extremes [1, infinity) English: ( arithmetic operation ) - (hits 16/346) (matched long text) constraint DS = {13} extremes [6, infinity) + (hits 16/345) (matched long text) constraint DS = {11} extremes [6, infinity) ( assignment operation ) - (hits 6/340) (matched long text) constraint DS = {13} extremes [5, infinity) + (hits 6/338) (matched long text) constraint DS = {11} extremes [5, infinity) {let ... be given by ...} - (hits 2/324) (matched long text) constraint DS = {13} extremes [6, infinity) + (hits 2/323) (matched long text) constraint DS = {11} extremes [6, infinity) {let ...} - (hits 4/349) (matched long text) constraint DS = {13} extremes [2, infinity) + (hits 4/349) (matched long text) constraint DS = {11} extremes [2, infinity) {...} -- end - (hits 0/344) constraint DS = {13} extremes [3, infinity) + (hits 0/343) constraint DS = {11} extremes [3, infinity) {...} -- end conditional - (hits 3/338) (matched long text) constraint DS = {13} extremes [4, infinity) + (hits 3/337) (matched long text) constraint DS = {11} extremes [4, infinity) {...} -- end loop - (hits 9/335) (matched long text) constraint DS = {13} extremes [4, infinity) + (hits 9/334) (matched long text) constraint DS = {11} extremes [4, infinity) {...} -- in loop - (hits 2/326) (matched: 'break -- in loop') constraint DS = {13} extremes [4, infinity) + (hits 2/325) (matched: 'break -- in loop') constraint DS = {11} extremes [4, infinity) {...} -- in {###} - (hits 0/324) constraint DS = {13} extremes [4, infinity) + (hits 0/323) constraint DS = {11} extremes [4, infinity) {...} (hits 358/358) (matched long text) constraint (none) extremes [1, infinity) - hits 0/1032 nti 15 constraint DS = {13, 15} extremes [8, infinity) + hits 0/1032 nti 13 constraint DS = {13} extremes [8, infinity) English: ( {......} ) {} ( {......} ) - (hits 0/336) constraint DS = {13, 15} extremes [8, infinity) + (hits 0/338) constraint DS = {13} extremes [8, infinity) - hits 154/1016 nti 12 constraint DS = {12} extremes [2, infinity) + hits 154/1016 nti 10 constraint DS = {10} extremes [2, infinity) English: -- running on - (hits 16/449) (matched long text) constraint DS = {12} extremes [4, infinity) + (hits 16/448) (matched long text) constraint DS = {10} extremes [4, infinity) {say otherwise/else} - (hits 2/3) (matched: 'say otherwise') constraint CS = {12} extremes [2, 2] + (hits 2/4) (matched: 'say otherwise') constraint CS = {10} extremes [2, 2] {say otherwise/else if/unless ...} - (hits 0/433) constraint DS = {12} extremes [4, infinity) + (hits 0/432) constraint DS = {10} extremes [4, infinity) {say if/unless ...} - (hits 2/450) (matched: 'say if ( c - condition )') constraint DS = {12} extremes [3, infinity) + (hits 2/449) (matched: 'say if ( c - condition )') constraint DS = {10} extremes [3, infinity) {say end if/unless} - (hits 2/3) (matched: 'say end if') constraint CS = {12} extremes [3, 3] + (hits 2/4) (matched: 'say end if') constraint CS = {10} extremes [3, 3] {say ...} -- beginning {###} - (hits 2/408) (matched: 'say one of -- beginning say_one_of') constraint DS = {12} extremes [5, infinity) + (hits 2/409) (matched: 'say one of -- beginning say_one_of') constraint DS = {10} extremes [5, infinity) {say ...} -- continuing {###} - (hits 1/406) (matched: 'say or -- continuing say_one_of') constraint DS = {12} extremes [5, infinity) + (hits 1/407) (matched: 'say or -- continuing say_one_of') constraint DS = {10} extremes [5, infinity) {say ...} -- ending {###} with marker {###} - (hits 9/350) (matched long text) constraint DS = {12} extremes [8, infinity) + (hits 9/350) (matched long text) constraint DS = {10} extremes [8, infinity) {say ...} -- ending {###} - (hits 1/396) (matched: 'say only -- ending say_first_time') constraint DS = {12} extremes [5, infinity) + (hits 1/397) (matched: 'say only -- ending say_first_time') constraint DS = {10} extremes [5, infinity) {say ...} - (hits 119/473) (matched long text) constraint DS = {12} extremes [2, infinity) + (hits 119/473) (matched long text) constraint DS = {10} extremes [2, infinity) - hits 516/1032 nti 16 constraint DS = {16} extremes [2, infinity) + hits 516/1032 nti 14 constraint DS = {14} extremes [2, infinity) English: to {decide yes/no} - (hits 2/2) (matched: 'to decide yes') constraint CS = {16} extremes [3, 3] + (hits 2/2) (matched: 'to decide yes') constraint CS = {14} extremes [3, 3] to {decide on ...} - (hits 1/467) (matched: 'to decide on ( something - value )') constraint DS = {16} extremes [4, infinity) + (hits 1/467) (matched: 'to decide on ( something - value )') constraint DS = {14} extremes [4, infinity) to decide whether/if the {...} - (hits 12/453) (matched long text) constraint DS = {16} extremes [5, infinity) + (hits 12/453) (matched long text) constraint DS = {14} extremes [5, infinity) to decide whether/if {...} - (hits 39/454) (matched long text) constraint DS = {16} extremes [4, infinity) + (hits 39/454) (matched long text) constraint DS = {14} extremes [4, infinity) to decide what/which is the {...} - (hits 86/380) (matched long text) constraint DS = {16} extremes [7, infinity) + (hits 86/380) (matched long text) constraint DS = {14} extremes [7, infinity) to decide what/which is {...} - (hits 74/304) (matched long text) constraint DS = {16} extremes [6, infinity) + (hits 74/304) (matched long text) constraint DS = {14} extremes [6, infinity) to {...} - (hits 302/302) (matched long text) constraint DS = {16} extremes [2, infinity) + (hits 302/302) (matched long text) constraint DS = {14} extremes [2, infinity) - hits 160/320 nti 28 constraint (none) extremes [1, infinity) + hits 160/320 nti 27 constraint (none) extremes [1, infinity) English: (hits 160/160) (matched: 'relation of objects') constraint (none) extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - hits 2231/4462 nti 18 constraint (none) extremes [1, infinity) + hits 2231/4462 nti 16 constraint (none) extremes [1, infinity) English: ( ) {***} - (hits 0/1862) constraint DS = {18} extremes [2, infinity) + (hits 0/1699) constraint DS = {16} extremes [2, infinity) ( ) {***} - (hits 579/1770) (matched long text) constraint DS = {18} extremes [3, infinity) + (hits 579/1675) (matched long text) constraint DS = {16} extremes [3, infinity) ( {***} - (hits 0/1321) constraint DS = {18} extremes [1, infinity) + (hits 0/1128) constraint DS = {16} extremes [1, infinity) ) {***} - (hits 0/1321) constraint DS = {18} extremes [1, infinity) + (hits 0/1128) constraint DS = {16} extremes [1, infinity) {###} {***} (hits 1652/1652) (matched long text) constraint (none) extremes [1, infinity) - hits 579/1168 nti 17 constraint (none) extremes [1, infinity) + hits 579/1168 nti 15 constraint (none) extremes [1, infinity) English: {***} ( {***} - {......} - (hits 0/584) constraint DS = {17} extremes [3, infinity) + (hits 0/584) constraint DS = {15} extremes [3, infinity) {......} - a nonexisting variable - (hits 0/193) constraint DS = {17} extremes [5, infinity) + (hits 0/193) constraint DS = {15} extremes [5, infinity) {......} - a nonexisting variable - (hits 0/104) constraint DS = {17} extremes [6, infinity) + (hits 0/104) constraint DS = {15} extremes [6, infinity) {......} - a nonexisting that/which varies - (hits 0/65) constraint DS = {17} extremes [7, infinity) + (hits 0/65) constraint DS = {15} extremes [7, infinity) {......} - nonexisting variable - (hits 4/359) (matched: 't - nonexisting variable') constraint DS = {17} extremes [4, infinity) + (hits 4/359) (matched: 't - nonexisting variable') constraint DS = {15} extremes [4, infinity) {......} - nonexisting variable - (hits 4/193) (matched: 'loopvar - nonexisting k variable') constraint DS = {17} extremes [5, infinity) + (hits 4/193) (matched: 'loopvar - nonexisting k variable') constraint DS = {15} extremes [5, infinity) {......} - nonexisting that/which varies - (hits 0/104) constraint DS = {17} extremes [6, infinity) + (hits 0/104) constraint DS = {15} extremes [6, infinity) {......} - {an existing variable} - (hits 0/189) constraint DS = {17} extremes [5, infinity) + (hits 0/189) constraint DS = {15} extremes [5, infinity) {......} - {an existing variable} - (hits 0/104) constraint DS = {17} extremes [6, infinity) + (hits 0/104) constraint DS = {15} extremes [6, infinity) {......} - {an existing that/which varies} - (hits 0/65) constraint DS = {17} extremes [7, infinity) + (hits 0/65) constraint DS = {15} extremes [7, infinity) {......} - {existing variable} - (hits 2/351) (matched: 't - existing variable') constraint DS = {17} extremes [4, infinity) + (hits 2/351) (matched: 't - existing variable') constraint DS = {15} extremes [4, infinity) {......} - {existing variable} - (hits 0/189) constraint DS = {17} extremes [5, infinity) + (hits 0/189) constraint DS = {15} extremes [5, infinity) {......} - {existing that/which varies} - (hits 0/104) constraint DS = {17} extremes [6, infinity) + (hits 0/104) constraint DS = {15} extremes [6, infinity) {......} - a condition - (hits 0/349) constraint DS = {17} extremes [4, infinity) + (hits 0/349) constraint DS = {15} extremes [4, infinity) {......} - condition - (hits 9/574) (matched: 'c - condition') constraint DS = {17} extremes [3, infinity) + (hits 9/574) (matched: 'c - condition') constraint DS = {15} extremes [3, infinity) {......} - a phrase - (hits 0/349) constraint DS = {17} extremes [4, infinity) + (hits 0/349) constraint DS = {15} extremes [4, infinity) {......} - phrase - (hits 0/565) constraint DS = {17} extremes [3, infinity) + (hits 0/565) constraint DS = {15} extremes [3, infinity) {......} - storage - (hits 4/565) (matched: 's - storage') constraint DS = {17} extremes [3, infinity) + (hits 4/565) (matched: 's - storage') constraint DS = {15} extremes [3, infinity) {......} - a table-reference - (hits 0/349) constraint DS = {17} extremes [4, infinity) + (hits 0/349) constraint DS = {15} extremes [4, infinity) {......} - table-reference - (hits 3/561) (matched: 'tr - table-reference') constraint DS = {17} extremes [3, infinity) + (hits 3/561) (matched: 'tr - table-reference') constraint DS = {15} extremes [3, infinity) {......} - - (hits 529/558) (matched long text) constraint DS = {17} extremes [3, infinity) + (hits 529/558) (matched long text) constraint DS = {15} extremes [3, infinity) {......} - - (hits 2/29) (matched long text) constraint DS = {17} extremes [3, infinity) + (hits 2/29) (matched long text) constraint DS = {15} extremes [3, infinity) {......} - {......} - (hits 0/27) constraint DS = {17} extremes [3, infinity) + (hits 0/27) constraint DS = {15} extremes [3, infinity) (hits 22/27) (matched: 'name of kind of enumerated value k') constraint (none) extremes [1, infinity) {......} (hits 0/5) constraint (none) extremes [1, infinity) - internal hits 24/68 nti 29 constraint (none) extremes [1, infinity) + internal hits 24/68 nti 28 constraint (none) extremes [1, infinity) - hits 65/130 nti 30 constraint (none) extremes [1, infinity) + hits 65/130 nti 29 constraint (none) extremes [1, infinity) English: {...} (hits 20/65) (matched long text) constraint (none) extremes [1, infinity) - (hits 20/21) (matched long text) constraint DS = {19} extremes [3, infinity) + (hits 20/23) (matched long text) constraint DS = {17} extremes [3, infinity) (hits 25/25) (matched: 'printing an abbreviated room description') constraint (none) extremes [1, infinity) - hits 40/154 nti 19 constraint DS = {19} extremes [2, infinity) + hits 40/162 nti 17 constraint DS = {17} extremes [2, infinity) English: , _or - (hits 0/73) constraint DS = {19} extremes [3, infinity) + (hits 0/73) constraint DS = {17} extremes [3, infinity) , and/or - (hits 2/73) (matched: ', and/or capitalized') constraint DS = {19} extremes [3, infinity) + (hits 2/73) (matched: ', and/or capitalized') constraint DS = {17} extremes [3, infinity) _,/or - (hits 38/73) (matched long text) constraint DS = {19} extremes [2, infinity) + (hits 38/75) (matched long text) constraint DS = {17} extremes [2, infinity) and/or - (hits 0/35) constraint DS = {19} extremes [2, infinity) + (hits 0/37) constraint DS = {17} extremes [2, infinity) - hits 65/130 nti 31 constraint (none) extremes [1, infinity) + hits 65/130 nti 30 constraint (none) extremes [1, infinity) English: {...} (hits 20/65) (matched: 'without printing a room description') constraint (none) extremes [1, infinity) {...} (hits 45/45) (matched: 'without printing a room description') constraint (none) extremes [1, infinity) - hits 102/204 nti 6 constraint (none) extremes [1, infinity) + hits 102/204 nti 31 constraint (none) extremes [1, infinity) English: {...} (hits 43/102) (matched long text) constraint (none) extremes [1, infinity) - (hits 43/48) (matched long text) constraint DS = {20} extremes [3, infinity) + (hits 43/47) (matched long text) constraint DS = {18} extremes [3, infinity) (hits 16/16) (matched: 'listing marked items only') constraint (none) extremes [1, infinity) - hits 86/344 nti 20 constraint DS = {20} extremes [2, infinity) + hits 86/330 nti 18 constraint DS = {18} extremes [2, infinity) English: , _and - (hits 0/161) constraint DS = {20} extremes [3, infinity) + (hits 0/157) constraint DS = {18} extremes [3, infinity) _,/and - (hits 86/165) (matched long text) constraint DS = {20} extremes [2, infinity) + (hits 86/160) (matched long text) constraint DS = {18} extremes [2, infinity) - hits 102/204 nti 7 constraint (none) extremes [1, infinity) + hits 102/204 nti 6 constraint (none) extremes [1, infinity) English: (hits 102/102) (matched: 'giving brief inventory information') constraint (none) extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - internal hits 102/3322 nti 8 constraint (none) extremes [1, infinity) + internal hits 102/3322 nti 7 constraint (none) extremes [1, infinity) - hits 209/418 nti 9 constraint (none) extremes [1, infinity) + hits 209/418 nti 8 constraint (none) extremes [1, infinity) English: (hits 14/74) (matched: 'the current working sack') constraint (none) extremes [2, infinity) (hits 195/195) (matched: 'item being printed') constraint (none) extremes [1, infinity) - hits 209/418 nti 21 constraint (none) extremes [1, infinity) + hits 209/418 nti 19 constraint (none) extremes [1, infinity) English: {***} - {***} - constraint DS = {21} extremes [1, infinity) + constraint DS = {19} extremes [1, infinity) (hits 136/209) (matched: 'item being printed') constraint (none) extremes [1, infinity) @@ -8474,17 +8458,17 @@ {...} (hits 73/73) (matched: 'item being printed') constraint (none) extremes [1, infinity) - internal hits 136/418 nti 10 constraint (none) extremes [1, infinity) + internal hits 136/418 nti 9 constraint (none) extremes [1, infinity) - nti 22 constraint DS = {22} extremes [2, infinity) + nti 20 constraint DS = {20} extremes [2, infinity) English: end {...} - constraint DS = {22} extremes [2, infinity) + constraint DS = {20} extremes [2, infinity) - hits 1576/3152 nti 23 constraint (none) extremes [1, infinity) + hits 1576/3152 nti 21 constraint (none) extremes [1, infinity) English: phrase options - (hits 17/17) (matched: 'phrase options') constraint CS = {23} extremes [2, 2] + (hits 17/17) (matched: 'phrase options') constraint CS = {21} extremes [2, 2] (hits 0/1559) constraint (none) extremes [1, infinity) @@ -8492,86 +8476,86 @@ {...} constraint (none) extremes [1, infinity) - internal hits 1559/3118 nti 11 constraint (none) extremes [1, infinity) + internal hits 1559/3118 nti 10 constraint (none) extremes [1, infinity) - hits 44/88 nti 24 constraint CS = {24} extremes [1, 1] + hits 44/88 nti 22 constraint CS = {22} extremes [1, 1] English: definition - (hits 44/44) (matched: 'definition') constraint CS = {24} extremes [1, 1] + (hits 44/44) (matched: 'definition') constraint CS = {22} extremes [1, 1] - hits 44/88 nti 27 constraint DS = {27} extremes [3, infinity) + hits 44/88 nti 25 constraint DS = {25} extremes [3, infinity) English: is/are if {...} - (hits 41/41) (matched long text) constraint DS = {27} extremes [5, infinity) + (hits 41/41) (matched long text) constraint DS = {25} extremes [5, infinity) is/are unless {...} - constraint DS = {27} extremes [5, infinity) + constraint DS = {25} extremes [5, infinity) is/are - (hits 3/3) (matched: 'a room is air-conditioned') constraint DS = {27} extremes [3, infinity) + (hits 3/3) (matched: 'a room is air-conditioned') constraint DS = {25} extremes [3, infinity) - hits 44/88 nti 25 constraint (none) extremes [1, infinity) + hits 44/88 nti 23 constraint (none) extremes [1, infinity) English: {...} ( called the {...} ) - (hits 1/1) (matched: 'a thing ( called the item )') constraint DS = {25} extremes [6, infinity) + (hits 1/1) (matched: 'a thing ( called the item )') constraint DS = {23} extremes [6, infinity) {...} ( called {...} ) - constraint DS = {25} extremes [5, infinity) + constraint DS = {23} extremes [5, infinity) {...} (hits 43/43) (matched: 'a list of values') constraint (none) extremes [1, infinity) - hits 44/88 nti 26 constraint (none) extremes [1, infinity) + hits 44/88 nti 24 constraint (none) extremes [1, infinity) English: {...} rather than {...} - (hits 18/18) (matched: 'even rather than odd') constraint DS = {26} extremes [4, infinity) + (hits 18/18) (matched: 'even rather than odd') constraint DS = {24} extremes [4, infinity) {...} (hits 26/26) (matched: 'going on') constraint (none) extremes [1, infinity) - hits 18/86 nti 28 constraint DS = {28} extremes [8, infinity) + hits 18/86 nti 26 constraint DS = {26} extremes [8, infinity) English: i6 routine {} says so ( {...} ) - (hits 10/24) (matched long text) constraint DS = {28} extremes [8, infinity) + (hits 10/24) (matched long text) constraint DS = {26} extremes [8, infinity) i6 routine {} makes it so ( {...} ) - (hits 8/14) (matched long text) constraint DS = {28} extremes [9, infinity) + (hits 8/14) (matched long text) constraint DS = {26} extremes [9, infinity) - hits 1/80 nti 29 constraint DS = {29} extremes [8, infinity) + hits 1/80 nti 27 constraint DS = {27} extremes [8, infinity) English: i6 condition says so ( {...} ) - (hits 1/24) (matched long text) constraint DS = {29} extremes [8, infinity) + (hits 1/24) (matched long text) constraint DS = {27} extremes [8, infinity) - nti 31 constraint DW = {30, 31} extremes [2, infinity) + nti 29 constraint DW = {28, 29} extremes [2, infinity) English: {} - constraint DS = {30} extremes [2, 3] + constraint DS = {28} extremes [2, 3] {} in {} - constraint DS = {30, 31} extremes [4, 5] + constraint DS = {28, 29} extremes [4, 5] when defining - constraint DS = {31} extremes [3, infinity) + constraint DS = {29} extremes [3, infinity) when defining {...} - constraint DS = {31} extremes [3, infinity) + constraint DS = {29} extremes [3, infinity) before the library - constraint CS = {31} extremes [3, 3] + constraint CS = {29} extremes [3, 3] in the preform grammar - constraint CS = {31} extremes [4, 4] + constraint CS = {29} extremes [4, 4] - nti 30 constraint CS = {30} extremes [1, 2] + nti 28 constraint CS = {28} extremes [1, 2] English: before - constraint CS = {30} extremes [1, 1] + constraint CS = {28} extremes [1, 1] instead of - constraint CS = {30} extremes [2, 2] + constraint CS = {28} extremes [2, 2] after - constraint CS = {30} extremes [1, 1] + constraint CS = {28} extremes [1, 1] - hits 5/30 nti 6 constraint CS = {6} extremes [3, 4] + hits 5/30 nti 30 constraint CS = {30} extremes [3, 4] English: it is very likely - (hits 1/2) (matched: 'it is very likely') constraint CS = {6} extremes [4, 4] + (hits 1/2) (matched: 'it is very likely') constraint CS = {30} extremes [4, 4] it is likely - (hits 1/4) (matched: 'it is likely') constraint CS = {6} extremes [3, 3] + (hits 1/4) (matched: 'it is likely') constraint CS = {30} extremes [3, 3] it is possible - (hits 1/3) (matched: 'it is possible') constraint CS = {6} extremes [3, 3] + (hits 1/3) (matched: 'it is possible') constraint CS = {30} extremes [3, 3] it is unlikely - (hits 1/2) (matched: 'it is unlikely') constraint CS = {6} extremes [3, 3] + (hits 1/2) (matched: 'it is unlikely') constraint CS = {30} extremes [3, 3] it is very unlikely - (hits 1/1) (matched: 'it is very unlikely') constraint CS = {6} extremes [4, 4] + (hits 1/1) (matched: 'it is very unlikely') constraint CS = {30} extremes [4, 4] nti 10 constraint CS = {10} extremes [1, 1] English: @@ -8606,579 +8590,590 @@ pattern constraint CS = {10} extremes [1, 1] - nti 10 constraint (none) extremes [1, infinity) + nti 8 constraint (none) extremes [1, infinity) English: list {...} - constraint DS = {10} extremes [2, infinity) + constraint DS = {8} extremes [2, infinity) constraint (none) extremes [1, infinity) ~~ - constraint DS = {10} extremes [3, infinity) + constraint DS = {8} extremes [3, infinity) {...} constraint (none) extremes [1, infinity) - nti 9 constraint (none) extremes [1, infinity) + nti 7 constraint (none) extremes [1, infinity) English: is {...} - constraint DS = {9} extremes [3, infinity) + constraint DS = {7} extremes [3, infinity) = - constraint DS = {7, 9} extremes [3, infinity) + constraint DS = {7, 31} extremes [3, infinity) constraint (none) extremes [1, infinity) - constraint CS = {7} extremes [1, 1] + constraint CS = {31} extremes [1, 1] experimental {...} - constraint DS = {9} extremes [2, infinity) + constraint DS = {7} extremes [2, infinity) - nti 7 constraint CS = {7} extremes [1, 1] + nti 31 constraint CS = {31} extremes [1, 1] English: r1 - constraint CS = {7} extremes [1, 1] + constraint CS = {31} extremes [1, 1] r2 - constraint CS = {7} extremes [1, 1] + constraint CS = {31} extremes [1, 1] r3 - constraint CS = {7} extremes [1, 1] + constraint CS = {31} extremes [1, 1] r4 - constraint CS = {7} extremes [1, 1] + constraint CS = {31} extremes [1, 1] r5 - constraint CS = {7} extremes [1, 1] + constraint CS = {31} extremes [1, 1] - hits 4/186 nti 11 constraint CS = {11} extremes [1, 2] + hits 4/186 nti 9 constraint CS = {9} extremes [1, 2] English: i6-varying-global - (hits 1/3) (matched: 'i6-varying-global') constraint CS = {11} extremes [1, 1] + (hits 1/3) (matched: 'i6-varying-global') constraint CS = {9} extremes [1, 1] i6-nothing-constant - (hits 1/2) (matched: 'i6-nothing-constant') constraint CS = {11} extremes [1, 1] + (hits 1/2) (matched: 'i6-nothing-constant') constraint CS = {9} extremes [1, 1] command prompt - (hits 1/1) (matched: 'command prompt') constraint CS = {11} extremes [2, 2] + (hits 1/1) (matched: 'command prompt') constraint CS = {9} extremes [2, 2] parameter-object - (hits 1/1) (matched: 'parameter-object') constraint CS = {11} extremes [1, 1] + (hits 1/1) (matched: 'parameter-object') constraint CS = {9} extremes [1, 1] - hits 0/688 nti 12 constraint DS = {12} extremes [1, 2] + hits 0/688 nti 10 constraint DS = {10} extremes [1, 2] English: story - (hits 0/67) constraint DS = {12} extremes [2, 2] + (hits 0/29) constraint DS = {10} extremes [2, 2] this story - constraint CS = {12} extremes [2, 2] + (hits 0/2) constraint CS = {10} extremes [2, 2] story - constraint CS = {12} extremes [1, 1] + (hits 0/1) constraint CS = {10} extremes [1, 1] - nti 13 constraint DS = {13} extremes [2, infinity) + nti 11 constraint DS = {11} extremes [2, infinity) English: episode of - constraint DS = {13} extremes [4, 4] + constraint DS = {11} extremes [4, 4] episode {...} - constraint DS = {13} extremes [2, infinity) + constraint DS = {11} extremes [2, infinity) - hits 7/186 nti 14 constraint CS = {14} extremes [2, 3] + hits 7/186 nti 12 constraint CS = {12} extremes [2, 3] English: story title - (hits 1/10) (matched: 'story title') constraint CS = {14} extremes [2, 2] + (hits 1/7) (matched: 'story title') constraint CS = {12} extremes [2, 2] story author - (hits 1/9) (matched: 'story author') constraint CS = {14} extremes [2, 2] + (hits 1/6) (matched: 'story author') constraint CS = {12} extremes [2, 2] story headline - (hits 1/8) (matched: 'story headline') constraint CS = {14} extremes [2, 2] + (hits 1/5) (matched: 'story headline') constraint CS = {12} extremes [2, 2] story genre - (hits 1/7) (matched: 'story genre') constraint CS = {14} extremes [2, 2] + (hits 1/4) (matched: 'story genre') constraint CS = {12} extremes [2, 2] story description - (hits 1/6) (matched: 'story description') constraint CS = {14} extremes [2, 2] + (hits 1/3) (matched: 'story description') constraint CS = {12} extremes [2, 2] story creation year - (hits 1/1) (matched: 'story creation year') constraint CS = {14} extremes [3, 3] + (hits 1/1) (matched: 'story creation year') constraint CS = {12} extremes [3, 3] release number - (hits 1/5) (matched: 'release number') constraint CS = {14} extremes [2, 2] + (hits 1/2) (matched: 'release number') constraint CS = {12} extremes [2, 2] - nti 17 constraint DW = {15, 16, 17} extremes [1, infinity) + nti 15 constraint DW = {13, 14, 15} extremes [1, infinity) English: - constraint DS = {15, 16} & CW = {15, 16} extremes [2, 3] + constraint DS = {13, 14} & CW = {13, 14} extremes [2, 3] {...} - constraint DS = {15} extremes [2, infinity) + constraint DS = {13} extremes [2, infinity) - constraint CS = {16} extremes [1, 2] + constraint CS = {14} extremes [1, 2] cover art ( ) - constraint DS = {17} extremes [5, 5] + constraint DS = {15} extremes [5, 5] cover art - constraint CS = {17} extremes [2, 2] + constraint CS = {15} extremes [2, 2] existing story file - constraint CS = {17} extremes [3, 3] + constraint CS = {15} extremes [3, 3] existing story file called {} - constraint DS = {17} extremes [5, 5] + constraint DS = {15} extremes [5, 5] file of {} called {} - constraint DS = {17} extremes [5, 5] + constraint DS = {15} extremes [5, 5] file {} in {} - constraint DS = {17} extremes [4, 4] + constraint DS = {15} extremes [4, 4] file {} - constraint DS = {17} extremes [2, 2] + constraint DS = {15} extremes [2, 2] style sheet {} - constraint DS = {17} extremes [3, 3] + constraint DS = {15} extremes [3, 3] javascript {} - constraint DS = {17} extremes [2, 2] + constraint DS = {15} extremes [2, 2] introductory booklet - constraint CS = {17} extremes [2, 2] + constraint CS = {15} extremes [2, 2] introductory postcard - constraint CS = {17} extremes [2, 2] + constraint CS = {15} extremes [2, 2] website - constraint CS = {17} extremes [1, 1] + constraint CS = {15} extremes [1, 1] separate figures - constraint CS = {17} extremes [2, 2] + constraint CS = {15} extremes [2, 2] separate sounds - constraint CS = {17} extremes [2, 2] + constraint CS = {15} extremes [2, 2] {} website - constraint DS = {17} extremes [2, 2] + constraint DS = {15} extremes [2, 2] interpreter - constraint CS = {17} extremes [1, 1] + constraint CS = {15} extremes [1, 1] {} interpreter - constraint DS = {17} extremes [2, 2] + constraint DS = {15} extremes [2, 2] - nti 15 constraint CS = {15} extremes [1, 1] + nti 13 constraint CS = {13} extremes [1, 1] English: private - constraint CS = {15} extremes [1, 1] + constraint CS = {13} extremes [1, 1] public - constraint CS = {15} extremes [1, 1] + constraint CS = {13} extremes [1, 1] - nti 16 constraint CS = {16} extremes [1, 2] + nti 14 constraint CS = {14} extremes [1, 2] English: solution - constraint CS = {16} extremes [1, 1] + constraint CS = {14} extremes [1, 1] source text - constraint CS = {16} extremes [2, 2] + constraint CS = {14} extremes [2, 2] library card - constraint CS = {16} extremes [2, 2] + constraint CS = {14} extremes [2, 2] - hits 12/210 nti 18 constraint CS = {18} extremes [1, 2] + hits 12/210 nti 16 constraint CS = {16} extremes [1, 2] English: room - (hits 2/10) (matched: 'room') constraint CS = {18} extremes [1, 1] + (hits 2/10) (matched: 'room') constraint CS = {16} extremes [1, 1] thing - (hits 2/8) (matched: 'thing') constraint CS = {18} extremes [1, 1] + (hits 2/8) (matched: 'thing') constraint CS = {16} extremes [1, 1] container - (hits 2/6) (matched: 'container') constraint CS = {18} extremes [1, 1] + (hits 2/6) (matched: 'container') constraint CS = {16} extremes [1, 1] supporter - (hits 2/4) (matched: 'supporter') constraint CS = {18} extremes [1, 1] + (hits 2/4) (matched: 'supporter') constraint CS = {16} extremes [1, 1] person - (hits 2/2) (matched: 'person') constraint CS = {18} extremes [1, 1] + (hits 2/2) (matched: 'person') constraint CS = {16} extremes [1, 1] player's holdall - (hits 2/2) (matched: 'player's holdall') constraint CS = {18} extremes [2, 2] + (hits 2/2) (matched: 'player's holdall') constraint CS = {16} extremes [2, 2] - hits 4/292 nti 19 constraint CS = {19} extremes [1, 3] + hits 4/292 nti 17 constraint CS = {17} extremes [1, 3] English: initial appearance - (hits 1/2) (matched: 'initial appearance') constraint CS = {19} extremes [2, 2] + (hits 1/2) (matched: 'initial appearance') constraint CS = {17} extremes [2, 2] wearable - (hits 1/1) (matched: 'wearable') constraint CS = {19} extremes [1, 1] + (hits 1/1) (matched: 'wearable') constraint CS = {17} extremes [1, 1] fixed in place - (hits 1/1) (matched: 'fixed in place') constraint CS = {19} extremes [3, 3] + (hits 1/1) (matched: 'fixed in place') constraint CS = {17} extremes [3, 3] matching key - (hits 1/1) (matched: 'matching key') constraint CS = {19} extremes [2, 2] + (hits 1/1) (matched: 'matching key') constraint CS = {17} extremes [2, 2] - hits 288/61566 nti 20 constraint DS = {20} extremes [1, infinity) + hits 288/61566 nti 18 constraint DS = {18} extremes [1, infinity) English: _something/anything {***} - (hits 207/13452) (matched long text) constraint DS = {20} extremes [1, infinity) + (hits 207/16944) (matched long text) constraint DS = {18} extremes [1, infinity) _somewhere/anywhere {***} - (hits 0/13245) constraint DS = {20} extremes [1, infinity) + (hits 0/16737) constraint DS = {18} extremes [1, infinity) _someone/anyone/somebody/anybody {***} - (hits 57/13245) (matched: 'someone') constraint DS = {20} extremes [1, infinity) + (hits 57/16737) (matched: 'someone') constraint DS = {18} extremes [1, infinity) _everything {***} - (hits 0/13188) constraint DS = {20} extremes [1, infinity) + (hits 0/16680) constraint DS = {18} extremes [1, infinity) _everywhere {***} - (hits 0/13188) constraint DS = {20} extremes [1, infinity) + (hits 0/16680) constraint DS = {18} extremes [1, infinity) _everyone/everybody {***} - (hits 0/13188) constraint DS = {20} extremes [1, infinity) + (hits 0/16680) constraint DS = {18} extremes [1, infinity) _nowhere {***} - (hits 24/13188) (matched: 'nowhere') constraint DS = {20} extremes [1, infinity) + (hits 24/16680) (matched: 'nowhere') constraint DS = {18} extremes [1, infinity) _nobody/no-one {***} - (hits 0/13164) constraint DS = {20} extremes [1, infinity) + (hits 0/16656) constraint DS = {18} extremes [1, infinity) _no _one {***} - (hits 0/12798) constraint DS = {20} extremes [2, infinity) + (hits 0/15676) constraint DS = {18} extremes [2, infinity) - hits 0/2166 nti 21 constraint CS = {21} extremes [1, 1] + hits 0/2166 nti 19 constraint CS = {19} extremes [1, 1] English: nowhere - (hits 0/29) constraint CS = {21} extremes [1, 1] + (hits 0/10) constraint CS = {19} extremes [1, 1] - hits 2/186 nti 22 constraint CS = {22} extremes [1, 3] + hits 2/186 nti 20 constraint CS = {20} extremes [1, 3] English: player - (hits 1/1) (matched: 'player') constraint CS = {22} extremes [1, 1] + (hits 1/1) (matched: 'player') constraint CS = {20} extremes [1, 1] time of day - (hits 1/1) (matched: 'time of day') constraint CS = {22} extremes [3, 3] + (hits 1/1) (matched: 'time of day') constraint CS = {20} extremes [3, 3] - hits 1/334 nti 23 constraint CS = {23} extremes [1, 1] + hits 1/334 nti 21 constraint CS = {21} extremes [1, 1] English: yourself - (hits 1/1) (matched: 'yourself') constraint CS = {23} extremes [1, 1] + (hits 1/1) (matched: 'yourself') constraint CS = {21} extremes [1, 1] - nti 24 constraint CS = {24} extremes [1, 2] + nti 22 constraint CS = {22} extremes [1, 2] English: worn - constraint CS = {24} extremes [1, 1] + constraint CS = {22} extremes [1, 1] carried - constraint CS = {24} extremes [1, 1] + constraint CS = {22} extremes [1, 1] initially carried - constraint CS = {24} extremes [2, 2] + constraint CS = {22} extremes [2, 2] - hits 1/136 nti 25 constraint CS = {25} extremes [1, 1] + hits 1/136 nti 23 constraint CS = {23} extremes [1, 1] English: device - (hits 1/1) (matched: 'device') constraint CS = {25} extremes [1, 1] + (hits 1/1) (matched: 'device') constraint CS = {23} extremes [1, 1] - hits 1/138 nti 26 constraint CS = {26} extremes [1, 1] + hits 1/138 nti 24 constraint CS = {24} extremes [1, 1] English: backdrop - (hits 1/1) (matched: 'backdrop') constraint CS = {26} extremes [1, 1] + (hits 1/1) (matched: 'backdrop') constraint CS = {24} extremes [1, 1] - hits 1/292 nti 27 constraint CS = {27} extremes [1, 1] + hits 1/292 nti 25 constraint CS = {25} extremes [1, 1] English: scenery - (hits 1/1) (matched: 'scenery') constraint CS = {27} extremes [1, 1] + (hits 1/1) (matched: 'scenery') constraint CS = {25} extremes [1, 1] - nti 28 constraint CS = {28} extremes [1, 1] + nti 26 constraint CS = {26} extremes [1, 1] English: everywhere - constraint CS = {28} extremes [1, 1] + constraint CS = {26} extremes [1, 1] - hits 2/190 nti 29 constraint CS = {29} extremes [1, 1] + hits 2/190 nti 27 constraint CS = {27} extremes [1, 1] English: region - (hits 2/3) (matched: 'region') constraint CS = {29} extremes [1, 1] + (hits 2/2) (matched: 'region') constraint CS = {27} extremes [1, 1] - hits 1/292 nti 30 constraint CS = {30} extremes [2, 2] + hits 1/292 nti 28 constraint CS = {28} extremes [2, 2] English: map region - (hits 1/1) (matched: 'map region') constraint CS = {30} extremes [2, 2] + (hits 1/1) (matched: 'map region') constraint CS = {28} extremes [2, 2] - hits 19/2128 nti 31 constraint CS = {31} extremes [1, 1] + hits 19/2128 nti 29 constraint CS = {29} extremes [1, 1] English: direction - (hits 13/23) (matched: 'direction') constraint CS = {31} extremes [1, 1] + (hits 13/19) (matched: 'direction') constraint CS = {29} extremes [1, 1] door - (hits 6/10) (matched: 'door') constraint CS = {31} extremes [1, 1] + (hits 6/6) (matched: 'door') constraint CS = {29} extremes [1, 1] - hits 2/24 nti 6 constraint CS = {6} extremes [1, 1] + hits 2/24 nti 30 constraint CS = {30} extremes [1, 1] English: up - (hits 1/2) (matched: 'up') constraint CS = {6} extremes [1, 1] + (hits 1/2) (matched: 'up') constraint CS = {30} extremes [1, 1] down - (hits 1/1) (matched: 'down') constraint CS = {6} extremes [1, 1] + (hits 1/1) (matched: 'down') constraint CS = {30} extremes [1, 1] - hits 2/292 nti 7 constraint CS = {7} extremes [1, 2] + hits 2/292 nti 31 constraint CS = {31} extremes [1, 2] English: opposite - (hits 1/5) (matched: 'opposite') constraint CS = {7} extremes [1, 1] + (hits 1/1) (matched: 'opposite') constraint CS = {31} extremes [1, 1] other side - (hits 1/1) (matched: 'other side') constraint CS = {7} extremes [2, 2] + (hits 1/1) (matched: 'other side') constraint CS = {31} extremes [2, 2] - hits 0/2166 nti 8 constraint CS = {8} extremes [1, 1] + hits 0/2166 nti 6 constraint CS = {6} extremes [1, 1] English: below - (hits 0/14) constraint CS = {8} extremes [1, 1] + (hits 0/16) constraint CS = {6} extremes [1, 1] above - (hits 0/14) constraint CS = {8} extremes [1, 1] + (hits 0/16) constraint CS = {6} extremes [1, 1] - nti 9 constraint DS = {9} extremes [2, infinity) + nti 7 constraint DS = {7} extremes [2, infinity) English: mapping {...} - constraint DS = {9} extremes [2, infinity) + constraint DS = {7} extremes [2, infinity) - nti 10 constraint DS = {10} extremes [2, infinity) + nti 8 constraint DS = {8} extremes [2, infinity) English: mapped {...} of - constraint DS = {10} extremes [3, infinity) + constraint DS = {8} extremes [3, infinity) mapped {...} - constraint DS = {10} extremes [2, infinity) + constraint DS = {8} extremes [2, infinity) {...} of - constraint DS = {10} extremes [2, infinity) + constraint DS = {8} extremes [2, infinity) {...} from - constraint DS = {10} extremes [2, infinity) + constraint DS = {8} extremes [2, infinity) - hits 2/24 nti 11 constraint CS = {11} extremes [1, 1] + hits 2/24 nti 9 constraint CS = {9} extremes [1, 1] English: inside - (hits 1/2) (matched: 'inside') constraint CS = {11} extremes [1, 1] + (hits 1/2) (matched: 'inside') constraint CS = {9} extremes [1, 1] outside - (hits 1/1) (matched: 'outside') constraint CS = {11} extremes [1, 1] + (hits 1/1) (matched: 'outside') constraint CS = {9} extremes [1, 1] - hits 1/292 nti 12 constraint CS = {12} extremes [1, 1] + hits 0/800 nti 10 constraint DS = {10} extremes [2, infinity) + English: + at + (hits 0/17) constraint DS = {10} extremes [3, 3] + at the time when {...} + (hits 0/180) constraint DS = {10} extremes [5, infinity) + at the time that {...} + (hits 0/180) constraint DS = {10} extremes [5, infinity) + at {...} + (hits 0/216) constraint DS = {10} extremes [2, infinity) + + hits 1/292 nti 11 constraint CS = {11} extremes [1, 1] English: recurring - (hits 1/4) (matched: 'recurring') constraint CS = {12} extremes [1, 1] + (hits 1/5) (matched: 'recurring') constraint CS = {11} extremes [1, 1] - hits 1/2 nti 13 constraint CS = {13} extremes [2, 2] + hits 1/2 nti 12 constraint CS = {12} extremes [2, 2] English: entire game - (hits 1/1) (matched: 'entire game') constraint CS = {13} extremes [2, 2] + (hits 1/1) (matched: 'entire game') constraint CS = {12} extremes [2, 2] - hits 4/8 nti 12 constraint (none) extremes [1, infinity) + hits 4/8 nti 11 constraint (none) extremes [1, infinity) English: (hits 4/4) (matched: 'the entire game') constraint (none) extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - nti 13 constraint (none) extremes [1, infinity) + nti 12 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) - hits 0/4 nti 14 constraint (none) extremes [1, infinity) + hits 0/4 nti 13 constraint (none) extremes [1, infinity) English: (hits 0/1) constraint DS = {15} extremes [5, infinity) play begins - constraint CS = {14} extremes [2, 2] + constraint CS = {13} extremes [2, 2] play ends - constraint CS = {14} extremes [2, 2] + constraint CS = {13} extremes [2, 2] begins - (hits 0/2) constraint DS = {14} extremes [2, infinity) + (hits 0/2) constraint DS = {13} extremes [2, infinity) ends - (hits 0/2) constraint DS = {14} extremes [2, infinity) + (hits 0/2) constraint DS = {13} extremes [2, infinity) ends - (hits 0/2) constraint DS = {14} extremes [3, infinity) + (hits 0/2) constraint DS = {13} extremes [3, infinity) ends {...} - (hits 0/2) constraint DS = {14} extremes [3, infinity) + (hits 0/2) constraint DS = {13} extremes [3, infinity) (hits 0/2) constraint (none) extremes [1, infinity) - hits 4/8 nti 14 constraint (none) extremes [1, infinity) + hits 4/8 nti 13 constraint (none) extremes [1, infinity) English: (hits 4/4) (matched: 'the entire game') constraint (none) extremes [2, infinity) constraint (none) extremes [1, infinity) - hits 4/8 nti 15 constraint (none) extremes [1, infinity) + hits 4/8 nti 14 constraint (none) extremes [1, infinity) English: (hits 4/4) (matched: 'entire game') constraint (none) extremes [1, infinity) - internal nti 16 constraint (none) extremes [1, infinity) + internal nti 15 constraint (none) extremes [1, infinity) - internal nti 17 constraint (none) extremes [1, infinity) + internal nti 16 constraint (none) extremes [1, infinity) - nti 18 constraint (none) extremes [1, infinity) + nti 17 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) - hits 2/186 nti 15 constraint CS = {15} extremes [1, 2] + hits 2/186 nti 14 constraint CS = {14} extremes [1, 2] English: score - (hits 1/2) (matched: 'score') constraint CS = {15} extremes [1, 1] + (hits 1/1) (matched: 'score') constraint CS = {14} extremes [1, 1] maximum score - (hits 1/2) (matched: 'maximum score') constraint CS = {15} extremes [2, 2] + (hits 1/2) (matched: 'maximum score') constraint CS = {14} extremes [2, 2] - hits 0/14 nti 16 constraint CS = {16} extremes [1, 1] + hits 0/14 nti 15 constraint CS = {15} extremes [1, 1] English: rankings - constraint CS = {16} extremes [1, 1] + constraint CS = {15} extremes [1, 1] - hits 1/180 nti 17 constraint CS = {17} extremes [1, 1] + hits 1/180 nti 16 constraint CS = {16} extremes [1, 1] English: waiting - (hits 1/1) (matched: 'waiting') constraint CS = {17} extremes [1, 1] + (hits 1/1) (matched: 'waiting') constraint CS = {16} extremes [1, 1] - hits 90/1036 nti 19 constraint DS = {18} extremes [1, infinity) + hits 90/1036 nti 18 constraint DS = {17} extremes [1, infinity) English: - (hits 90/287) (matched long text) constraint DS = {18} extremes [2, infinity) + (hits 90/269) (matched long text) constraint DS = {17} extremes [2, infinity) - (hits 0/199) constraint DS = {18} extremes [1, infinity) + (hits 0/180) constraint DS = {17} extremes [1, infinity) - hits 90/742 nti 18 constraint DS = {18} extremes [1, infinity) + hits 90/684 nti 17 constraint DS = {17} extremes [1, infinity) English: action - (hits 90/371) (matched long text) constraint DS = {18} extremes [1, infinity) + (hits 90/342) (matched long text) constraint DS = {17} extremes [1, infinity) action - (hits 0/31) constraint CS = {18} extremes [1, 1] + (hits 0/27) constraint CS = {17} extremes [1, 1] - hits 90/182 nti 20 constraint (none) extremes [0, infinity) + hits 90/182 nti 19 constraint (none) extremes [0, infinity) English: ^ (hits 90/91) (matched long text) constraint (none) extremes [0, infinity) - hits 1/182 nti 19 constraint DS = {19} extremes [1, infinity) + hits 1/182 nti 18 constraint DS = {18} extremes [1, infinity) English: {***} that/which vary/varies - (hits 1/91) (matched: 'name based rule producing nothing that varies') constraint DS = {19} extremes [2, infinity) + (hits 1/70) (matched: 'name based rule producing nothing that varies') constraint DS = {18} extremes [2, infinity) {***} variable - (hits 0/90) constraint DS = {19} extremes [1, infinity) + (hits 0/69) constraint DS = {18} extremes [1, infinity) - hits 90/180 nti 21 constraint (none) extremes [1, infinity) + hits 90/180 nti 20 constraint (none) extremes [1, infinity) English: (hits 0/90) constraint (none) extremes [1, infinity) {...} (hits 90/90) (matched: 'switching the story transcript on') constraint (none) extremes [1, infinity) - hits 90/180 nti 22 constraint (none) extremes [1, infinity) + hits 90/180 nti 21 constraint (none) extremes [1, infinity) English: (hits 90/90) (matched long text) constraint (none) extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - hits 128/256 nti 23 constraint (none) extremes [1, infinity) + hits 128/256 nti 22 constraint (none) extremes [1, infinity) English: {...} (hits 19/128) (matched: 'applying to nothing or one thing and') constraint (none) extremes [1, infinity) - (hits 19/109) (matched: 'applying to one visible thing and requiring light') constraint DS = {22} extremes [2, infinity) + (hits 19/109) (matched: 'applying to one visible thing and requiring light') constraint DS = {21} extremes [2, infinity) - (hits 90/90) (matched long text) constraint DS = {22} extremes [1, infinity) + (hits 90/90) (matched long text) constraint DS = {21} extremes [1, infinity) - hits 128/1002 nti 23 constraint DS = {22} extremes [1, infinity) + hits 128/1002 nti 22 constraint DS = {21} extremes [1, infinity) English: , and - (hits 0/270) constraint DS = {22, 23} extremes [3, infinity) + (hits 0/259) constraint DS = {21, 22} extremes [3, infinity) and - (hits 19/302) (matched: 'applying to nothing or one thing and') constraint DS = {22, 23} extremes [2, infinity) + (hits 19/290) (matched: 'applying to nothing or one thing and') constraint DS = {21, 22} extremes [2, infinity) , - (hits 0/283) constraint DS = {22, 23} extremes [2, infinity) + (hits 0/271) constraint DS = {21, 22} extremes [2, infinity) - (hits 109/298) (matched long text) constraint DS = {22} extremes [1, infinity) + (hits 109/284) (matched long text) constraint DS = {21} extremes [1, infinity) - hits 128/702 nti 22 constraint DS = {22} extremes [1, infinity) + hits 128/678 nti 21 constraint DS = {21} extremes [1, infinity) English: out of world - (hits 16/16) (matched: 'out of world') constraint CS = {22} extremes [3, 3] + (hits 16/16) (matched: 'out of world') constraint CS = {21} extremes [3, 3] abbreviable - (hits 2/18) (matched: 'abbreviable') constraint CS = {22} extremes [1, 1] + (hits 2/18) (matched: 'abbreviable') constraint CS = {21} extremes [1, 1] with past participle {...} - (hits 0/153) constraint DS = {22} extremes [4, infinity) + (hits 0/145) constraint DS = {21} extremes [4, infinity) applying to - (hits 104/261) (matched long text) constraint DS = {22} extremes [3, infinity) + (hits 104/252) (matched long text) constraint DS = {21} extremes [3, infinity) requiring light - (hits 6/22) (matched: 'requiring light') constraint CS = {22} extremes [2, 2] + (hits 6/22) (matched: 'requiring light') constraint CS = {21} extremes [2, 2] - hits 104/208 nti 21 constraint (none) extremes [1, infinity) + hits 104/208 nti 20 constraint (none) extremes [1, infinity) English: nothing - (hits 45/45) (matched: 'nothing') constraint CS = {21} extremes [1, 1] + (hits 45/45) (matched: 'nothing') constraint CS = {20} extremes [1, 1] one and one - (hits 11/11) (matched: 'one carried thing and one visible thing') constraint DS = {21} extremes [5, infinity) + (hits 11/11) (matched: 'one carried thing and one visible thing') constraint DS = {20} extremes [5, infinity) one and - (hits 0/2) constraint DS = {21} extremes [4, infinity) + (hits 0/2) constraint DS = {20} extremes [4, infinity) and one - (hits 0/2) constraint DS = {21} extremes [4, infinity) + (hits 0/2) constraint DS = {20} extremes [4, infinity) and - (hits 0/7) constraint DS = {21} extremes [3, infinity) + (hits 0/7) constraint DS = {20} extremes [3, infinity) nothing or one - (hits 2/2) (matched: 'nothing or one thing') constraint DS = {21} extremes [4, infinity) + (hits 2/2) (matched: 'nothing or one thing') constraint DS = {20} extremes [4, infinity) one - (hits 40/46) (matched: 'one visible thing') constraint DS = {21} extremes [2, infinity) + (hits 40/46) (matched: 'one visible thing') constraint DS = {20} extremes [2, infinity) two - (hits 6/6) (matched: 'two things') constraint DS = {21} extremes [2, infinity) + (hits 6/6) (matched: 'two things') constraint DS = {20} extremes [2, infinity) constraint (none) extremes [1, infinity) {...} constraint (none) extremes [1, infinity) - hits 70/140 nti 24 constraint (none) extremes [1, infinity) + hits 70/140 nti 23 constraint (none) extremes [1, infinity) English: (hits 70/70) (matched: 'visible thing') constraint (none) extremes [1, infinity) - hits 70/140 nti 25 constraint (none) extremes [1, infinity) + hits 70/140 nti 24 constraint (none) extremes [1, infinity) English: - (hits 12/12) (matched: 'visible thing') constraint DS = {20} extremes [2, infinity) + (hits 12/12) (matched: 'visible thing') constraint DS = {19} extremes [2, infinity) (hits 58/58) (matched: 'infection color') constraint (none) extremes [1, infinity) - hits 12/24 nti 20 constraint CS = {20} extremes [1, 1] + hits 12/24 nti 19 constraint CS = {19} extremes [1, 1] English: visible - (hits 6/12) (matched: 'visible') constraint CS = {20} extremes [1, 1] + (hits 6/12) (matched: 'visible') constraint CS = {19} extremes [1, 1] touchable - (hits 0/6) constraint CS = {20} extremes [1, 1] + (hits 0/6) constraint CS = {19} extremes [1, 1] carried - (hits 6/6) (matched: 'carried') constraint CS = {20} extremes [1, 1] + (hits 6/6) (matched: 'carried') constraint CS = {19} extremes [1, 1] - hits 13/26 nti 24 constraint (none) extremes [1, infinity) + hits 13/26 nti 23 constraint (none) extremes [1, infinity) English: ( matched as {} ) - (hits 6/6) (matched: 'room gone from ( matched as from )') constraint DS = {24} extremes [6, infinity) + (hits 6/6) (matched: 'room gone from ( matched as from )') constraint DS = {23} extremes [6, infinity) ( {...} ) - constraint DS = {24} extremes [4, infinity) + constraint DS = {23} extremes [4, infinity) (hits 7/7) (matched: 'abbreviated form allowed') constraint (none) extremes [1, infinity) - hits 13/26 nti 26 constraint (none) extremes [1, infinity) + hits 13/26 nti 25 constraint (none) extremes [1, infinity) English: (hits 0/13) constraint (none) extremes [1, infinity) {...} (hits 13/13) (matched: 'room gone from') constraint (none) extremes [1, infinity) - nti 25 constraint DS = {25} extremes [2, infinity) + nti 24 constraint DS = {24} extremes [2, infinity) English: {...} action - constraint DS = {25} extremes [2, infinity) + constraint DS = {24} extremes [2, infinity) - nti 26 constraint DS = {26} extremes [2, infinity) + nti 25 constraint DS = {25} extremes [2, infinity) English: check {...} - constraint DS = {26} extremes [2, infinity) + constraint DS = {25} extremes [2, infinity) carry out {...} - constraint DS = {26} extremes [3, infinity) + constraint DS = {25} extremes [3, infinity) report {...} - constraint DS = {26} extremes [2, infinity) + constraint DS = {25} extremes [2, infinity) - internal hits 227/664 nti 27 constraint (none) extremes [1, infinity) + internal hits 227/664 nti 26 constraint (none) extremes [1, infinity) - hits 378/10710 nti 27 constraint DS = {27} extremes [2, infinity) + hits 378/10710 nti 26 constraint DS = {26} extremes [2, infinity) English: {...} to - (hits 378/1358) (matched: 'giving it to') constraint DS = {27} extremes [2, infinity) + (hits 378/1331) (matched: 'giving it to') constraint DS = {26} extremes [2, infinity) - hits 595/1406 nti 31 constraint (none) extremes [1, infinity) + hits 595/1406 nti 30 constraint (none) extremes [1, infinity) English: doing something/anything other than - (hits 0/98) constraint DS = {31} extremes [5, infinity) + (hits 0/98) constraint DS = {30} extremes [5, infinity) doing something/anything except - (hits 0/134) constraint DS = {31} extremes [4, infinity) + (hits 0/128) constraint DS = {30} extremes [4, infinity) doing something/anything to/with {...} - (hits 0/134) constraint DS = {31} extremes [4, infinity) + (hits 0/128) constraint DS = {30} extremes [4, infinity) doing something/anything - constraint CS = {31} extremes [2, 2] + constraint CS = {30} extremes [2, 2] doing something/anything {...} - (hits 0/276) constraint DS = {31} extremes [3, infinity) + (hits 0/264) constraint DS = {30} extremes [3, infinity) (hits 595/703) (matched long text) constraint (none) extremes [1, infinity) - nti 30 constraint (none) extremes [1, infinity) + nti 29 constraint (none) extremes [1, infinity) English: to/with {} - constraint DS = {30} extremes [3, infinity) + constraint DS = {29} extremes [3, infinity) constraint (none) extremes [1, infinity) - nti 29 constraint (none) extremes [1, infinity) + nti 28 constraint (none) extremes [1, infinity) English: _,/or {...} - constraint DS = {29} extremes [2, infinity) + constraint DS = {28} extremes [2, infinity) {...} to/with {...} - constraint DS = {29} extremes [3, infinity) + constraint DS = {28} extremes [3, infinity) {...} constraint (none) extremes [1, infinity) - hits 595/1406 nti 28 constraint (none) extremes [1, infinity) + hits 595/1406 nti 27 constraint (none) extremes [1, infinity) English: - (hits 0/186) constraint DS = {28} extremes [3, infinity) + (hits 0/194) constraint DS = {27} extremes [3, infinity) (hits 595/703) (matched long text) constraint (none) extremes [1, infinity) - hits 0/1622 nti 28 constraint DS = {28} extremes [2, infinity) + hits 0/1582 nti 27 constraint DS = {27} extremes [2, infinity) English: , _or - (hits 0/414) constraint DS = {28} extremes [3, infinity) + (hits 0/305) constraint DS = {27} extremes [3, infinity) _,/or - (hits 0/537) constraint DS = {28} extremes [2, infinity) + (hits 0/428) constraint DS = {27} extremes [2, infinity) - hits 595/1406 nti 29 constraint (none) extremes [1, infinity) + hits 595/1406 nti 28 constraint (none) extremes [1, infinity) English: (hits 0/703) constraint (none) extremes [1, infinity) @@ -9187,33 +9182,33 @@ (hits 595/703) (matched long text) constraint (none) extremes [1, infinity) - internal hits 0/1406 nti 30 constraint (none) extremes [1, infinity) + internal hits 0/1406 nti 29 constraint (none) extremes [1, infinity) - internal hits 595/1406 nti 31 constraint (none) extremes [1, infinity) + internal hits 595/1406 nti 30 constraint (none) extremes [1, infinity) - hits 7/676 nti 6 constraint CS = {6} extremes [1, 1] + hits 7/676 nti 31 constraint CS = {31} extremes [1, 1] English: is - (hits 7/115) (matched: 'is') constraint CS = {6} extremes [1, 1] + (hits 7/124) (matched: 'is') constraint CS = {31} extremes [1, 1] not - (hits 0/108) constraint CS = {6} extremes [1, 1] + (hits 0/117) constraint CS = {31} extremes [1, 1] - hits 0/662 nti 7 constraint (none) extremes [2, infinity) + hits 0/662 nti 6 constraint (none) extremes [2, infinity) English: _in _the _presence _of {...} - (hits 0/80) constraint DS = {7} extremes [5, infinity) + (hits 0/80) constraint DS = {6} extremes [5, infinity) _in {...} - (hits 0/222) constraint DS = {7} extremes [2, infinity) + (hits 0/235) constraint DS = {6} extremes [2, infinity) {...} (hits 0/331) constraint (none) extremes [2, infinity) - internal hits 0/662 nti 6 constraint (none) extremes [1, infinity) + internal hits 0/662 nti 31 constraint (none) extremes [1, infinity) - internal hits 1197/31612 nti 7 constraint (none) extremes [0, 0] + internal hits 1197/31612 nti 6 constraint (none) extremes [0, 0] - internal hits 1268/2536 nti 8 constraint (none) extremes [0, 0] + internal hits 1268/2536 nti 7 constraint (none) extremes [0, 0] - hits 300/1268 nti 9 constraint (none) extremes [1, infinity) + hits 300/1268 nti 8 constraint (none) extremes [1, infinity) English: ^ (hits 0/634) constraint (none) extremes [1, infinity) @@ -9226,299 +9221,299 @@ (hits 233/567) (matched long text) constraint (none) extremes [1, infinity) - internal hits 3/19982 nti 10 constraint (none) extremes [1, infinity) + internal hits 3/19982 nti 9 constraint (none) extremes [1, infinity) - hits 28/2746 nti 11 constraint (none) extremes [1, infinity) + hits 28/2746 nti 10 constraint (none) extremes [1, infinity) English: (hits 28/1373) (matched long text) constraint (none) extremes [1, infinity) - hits 0/2172 nti 12 constraint DS = {30} extremes [2, infinity) + hits 0/1564 nti 11 constraint DS = {28} extremes [2, infinity) English: - (hits 0/1086) constraint DS = {30} extremes [2, infinity) + (hits 0/782) constraint DS = {28} extremes [2, infinity) - hits 0/2154 nti 13 constraint DS = {27} extremes [3, infinity) + hits 0/2182 nti 12 constraint DS = {25} extremes [3, infinity) English: - (hits 0/1077) constraint DS = {27} extremes [3, infinity) + (hits 0/1091) constraint DS = {25} extremes [3, infinity) - hits 0/1530 nti 14 constraint DS = {28} extremes [4, infinity) + hits 0/1130 nti 13 constraint DS = {26} extremes [4, infinity) English: - (hits 0/765) constraint DS = {28} extremes [4, infinity) + (hits 0/565) constraint DS = {26} extremes [4, infinity) - hits 556/21330 nti 8 constraint (none) extremes [1, infinity) + hits 556/21330 nti 6 constraint (none) extremes [1, infinity) English: asking to try - (hits 0/937) constraint DS = {8} extremes [5, infinity) + (hits 0/1033) constraint DS = {6} extremes [5, infinity) trying - (hits 23/1917) (matched long text) constraint DS = {8} extremes [3, infinity) + (hits 23/2522) (matched long text) constraint DS = {6} extremes [3, infinity) an actor trying - (hits 0/1527) constraint DS = {8} extremes [4, infinity) + (hits 0/1850) constraint DS = {6} extremes [4, infinity) an actor - (hits 408/1894) (matched long text) constraint DS = {8} extremes [3, infinity) + (hits 408/2499) (matched long text) constraint DS = {6} extremes [3, infinity) trying - (hits 0/1713) constraint DS = {8} extremes [2, infinity) + (hits 0/3258) constraint DS = {6} extremes [2, infinity) (hits 60/10234) (matched long text) constraint (none) extremes [1, infinity) (hits 65/5425) (matched long text) constraint (none) extremes [2, infinity) - hits 28/2746 nti 29 constraint (none) extremes [1, infinity) + hits 28/2746 nti 27 constraint (none) extremes [1, infinity) English: we are asking to try - (hits 0/191) constraint DS = {29} extremes [7, infinity) + (hits 0/180) constraint DS = {27} extremes [7, infinity) asking to try - (hits 0/371) constraint DS = {29} extremes [5, infinity) + (hits 0/424) constraint DS = {27} extremes [5, infinity) trying - (hits 0/673) constraint DS = {29} extremes [3, infinity) + (hits 0/733) constraint DS = {27} extremes [3, infinity) an actor trying - (hits 0/645) constraint DS = {29} extremes [4, infinity) + (hits 0/709) constraint DS = {27} extremes [4, infinity) an actor - (hits 3/673) (matched: 'an actor smelling') constraint DS = {29} extremes [3, infinity) + (hits 3/733) (matched: 'an actor smelling') constraint DS = {27} extremes [3, infinity) we are trying - (hits 0/645) constraint DS = {29} extremes [4, infinity) + (hits 0/709) constraint DS = {27} extremes [4, infinity) trying - (hits 0/670) constraint DS = {29} extremes [2, infinity) + (hits 0/730) constraint DS = {27} extremes [2, infinity) we are - (hits 0/670) constraint DS = {29} extremes [3, infinity) + (hits 0/730) constraint DS = {27} extremes [3, infinity) (hits 25/1370) (matched long text) constraint (none) extremes [1, infinity) (hits 0/1120) constraint (none) extremes [2, infinity) - hits 0/2172 nti 30 constraint DS = {30} extremes [2, infinity) + hits 0/1564 nti 28 constraint DS = {28} extremes [2, infinity) English: we are not asking to try - (hits 0/135) constraint DS = {30} extremes [8, infinity) + (hits 0/135) constraint DS = {28} extremes [8, infinity) not asking to try - (hits 0/403) constraint DS = {30} extremes [6, infinity) + (hits 0/329) constraint DS = {28} extremes [6, infinity) not trying - (hits 0/994) constraint DS = {30} extremes [4, infinity) + (hits 0/758) constraint DS = {28} extremes [4, infinity) an actor not trying - (hits 0/622) constraint DS = {30} extremes [5, infinity) + (hits 0/476) constraint DS = {28} extremes [5, infinity) an actor not - (hits 0/994) constraint DS = {30} extremes [4, infinity) + (hits 0/758) constraint DS = {28} extremes [4, infinity) we are not trying - (hits 0/622) constraint DS = {30} extremes [5, infinity) + (hits 0/476) constraint DS = {28} extremes [5, infinity) not trying - (hits 0/1086) constraint DS = {30} extremes [3, infinity) + (hits 0/782) constraint DS = {28} extremes [3, infinity) we are not - (hits 0/994) constraint DS = {30} extremes [4, infinity) + (hits 0/758) constraint DS = {28} extremes [4, infinity) not - (hits 0/1086) constraint DS = {30} extremes [2, infinity) + (hits 0/782) constraint DS = {28} extremes [2, infinity) not - (hits 0/1086) constraint DS = {30} extremes [3, infinity) + (hits 0/782) constraint DS = {28} extremes [3, infinity) - hits 0/2154 nti 27 constraint DS = {27} extremes [3, infinity) + hits 0/2182 nti 25 constraint DS = {25} extremes [3, infinity) English: we have asked to try - (hits 0/231) constraint DS = {27} extremes [7, infinity) + (hits 0/229) constraint DS = {25} extremes [7, infinity) has tried - (hits 0/980) constraint DS = {27} extremes [4, infinity) + (hits 0/986) constraint DS = {25} extremes [4, infinity) an actor has tried - (hits 0/607) constraint DS = {27} extremes [5, infinity) + (hits 0/608) constraint DS = {25} extremes [5, infinity) an actor has - (hits 0/980) constraint DS = {27} extremes [4, infinity) + (hits 0/986) constraint DS = {25} extremes [4, infinity) we have tried - (hits 0/980) constraint DS = {27} extremes [4, infinity) + (hits 0/986) constraint DS = {25} extremes [4, infinity) we have - (hits 0/1077) constraint DS = {27} extremes [3, infinity) + (hits 0/1091) constraint DS = {25} extremes [3, infinity) - hits 0/1530 nti 28 constraint DS = {28} extremes [4, infinity) + hits 0/1130 nti 26 constraint DS = {26} extremes [4, infinity) English: we have not asked to try - (hits 0/136) constraint DS = {28} extremes [8, infinity) + (hits 0/127) constraint DS = {26} extremes [8, infinity) has not tried - (hits 0/474) constraint DS = {28} extremes [5, infinity) + (hits 0/330) constraint DS = {26} extremes [5, infinity) an actor has not tried - (hits 0/327) constraint DS = {28} extremes [6, infinity) + (hits 0/218) constraint DS = {26} extremes [6, infinity) an actor has not - (hits 0/474) constraint DS = {28} extremes [5, infinity) + (hits 0/330) constraint DS = {26} extremes [5, infinity) we have not tried - (hits 0/474) constraint DS = {28} extremes [5, infinity) + (hits 0/330) constraint DS = {26} extremes [5, infinity) we have not - (hits 0/765) constraint DS = {28} extremes [4, infinity) + (hits 0/565) constraint DS = {26} extremes [4, infinity) - internal hits 94/13090 nti 15 constraint (none) extremes [1, infinity) + internal hits 94/13090 nti 14 constraint (none) extremes [1, infinity) - internal hits 584/24264 nti 16 constraint (none) extremes [1, infinity) + internal hits 584/24264 nti 15 constraint (none) extremes [1, infinity) - internal nti 17 constraint (none) extremes [1, infinity) + internal nti 16 constraint (none) extremes [1, infinity) - hits 0/1390 nti 8 constraint CS = {8} extremes [2, 2] + hits 0/1390 nti 7 constraint CS = {7} extremes [2, 2] English: doing it - constraint CS = {8} extremes [2, 2] + constraint CS = {7} extremes [2, 2] - hits 584/1390 nti 9 constraint (none) extremes [1, infinity) + hits 584/1390 nti 8 constraint (none) extremes [1, infinity) English: when/while - (hits 11/169) (matched long text) constraint DS = {9} extremes [3, infinity) + (hits 11/123) (matched long text) constraint DS = {8} extremes [3, infinity) (hits 573/684) (matched long text) constraint (none) extremes [1, infinity) {...} when/while - (hits 0/50) constraint DS = {9} extremes [3, infinity) + (hits 0/37) constraint DS = {8} extremes [3, infinity) {...} when/while {...} - (hits 0/50) constraint DS = {9} extremes [3, infinity) + (hits 0/37) constraint DS = {8} extremes [3, infinity) - internal hits 19/38 nti 18 constraint (none) extremes [1, infinity) + internal hits 19/38 nti 17 constraint (none) extremes [1, infinity) - internal hits 584/1406 nti 19 constraint (none) extremes [1, infinity) + internal hits 584/1406 nti 18 constraint (none) extremes [1, infinity) - hits 200/406 nti 10 constraint (none) extremes [1, infinity) + hits 200/406 nti 9 constraint (none) extremes [1, infinity) English: something/anything - (hits 79/89) (matched: 'something') constraint CS = {10} extremes [1, 1] + (hits 79/79) (matched: 'something') constraint CS = {9} extremes [1, 1] something/anything else - constraint CS = {10} extremes [2, 2] + (hits 0/1) constraint CS = {9} extremes [2, 2] (hits 121/124) (matched long text) constraint (none) extremes [1, infinity) - hits 5/10 nti 11 constraint CS = {11} extremes [1, 1] + hits 5/10 nti 10 constraint CS = {10} extremes [1, 1] English: something/anything - (hits 4/5) (matched: 'something') constraint CS = {11} extremes [1, 1] + (hits 4/5) (matched: 'something') constraint CS = {10} extremes [1, 1] it - (hits 1/1) (matched: 'it') constraint CS = {11} extremes [1, 1] + (hits 1/1) (matched: 'it') constraint CS = {10} extremes [1, 1] - internal hits 0/4000 nti 20 constraint (none) extremes [1, infinity) + internal hits 0/4000 nti 19 constraint (none) extremes [1, infinity) - hits 1/180 nti 12 constraint CS = {12} extremes [1, 1] + hits 1/180 nti 11 constraint CS = {11} extremes [1, 1] English: going - (hits 1/20) (matched: 'going') constraint CS = {12} extremes [1, 1] + (hits 1/1) (matched: 'going') constraint CS = {11} extremes [1, 1] - hits 0/16 nti 13 constraint CS = {13} extremes [1, 1] + hits 0/16 nti 12 constraint CS = {12} extremes [1, 1] English: nowhere - constraint CS = {13} extremes [1, 1] + constraint CS = {12} extremes [1, 1] somewhere - constraint CS = {13} extremes [1, 1] + constraint CS = {12} extremes [1, 1] - hits 21/186 nti 14 constraint DS = {14} extremes [1, infinity) + hits 21/186 nti 13 constraint DS = {13} extremes [1, infinity) English: understood - (hits 16/47) (matched: 'command parser error understood') constraint DS = {14} extremes [2, infinity) + (hits 16/40) (matched: 'command parser error understood') constraint DS = {13} extremes [2, infinity) noun - (hits 1/3) (matched: 'noun') constraint CS = {14} extremes [1, 1] + (hits 1/3) (matched: 'noun') constraint CS = {13} extremes [1, 1] location - (hits 1/2) (matched: 'location') constraint CS = {14} extremes [1, 1] + (hits 1/2) (matched: 'location') constraint CS = {13} extremes [1, 1] actor-location - (hits 1/1) (matched: 'actor-location') constraint CS = {14} extremes [1, 1] + (hits 1/1) (matched: 'actor-location') constraint CS = {13} extremes [1, 1] second noun - (hits 1/8) (matched: 'second noun') constraint CS = {14} extremes [2, 2] + (hits 1/2) (matched: 'second noun') constraint CS = {13} extremes [2, 2] person asked - (hits 1/7) (matched: 'person asked') constraint CS = {14} extremes [2, 2] + (hits 1/1) (matched: 'person asked') constraint CS = {13} extremes [2, 2] - hits 208/416 nti 18 constraint (none) extremes [1, infinity) + hits 208/416 nti 17 constraint (none) extremes [1, infinity) English: nothing - constraint CS = {18} extremes [1, 1] + constraint CS = {17} extremes [1, 1] (hits 1/208) (matched: 'the infection color property') constraint (none) extremes [1, infinity) the command/commands - (hits 40/67) (matched long text) constraint DS = {18} extremes [3, infinity) + (hits 40/67) (matched long text) constraint DS = {17} extremes [3, infinity) the verb/verbs {...} - (hits 0/27) constraint DS = {18} extremes [3, infinity) + (hits 0/27) constraint DS = {17} extremes [3, infinity) (hits 167/167) (matched long text) constraint (none) extremes [1, infinity) - hits 383/766 nti 21 constraint (none) extremes [1, infinity) + hits 383/766 nti 20 constraint (none) extremes [1, infinity) English: {...} (hits 88/383) (matched long text) constraint (none) extremes [1, infinity) - (hits 88/88) (matched long text) constraint DS = {17} extremes [3, infinity) + (hits 88/88) (matched long text) constraint DS = {16} extremes [3, infinity) (hits 207/207) (matched: '"n"') constraint (none) extremes [1, infinity) - hits 176/352 nti 17 constraint DS = {17} extremes [2, infinity) + hits 176/352 nti 16 constraint DS = {16} extremes [2, infinity) English: , _and/or - (hits 0/74) constraint DS = {17} extremes [3, infinity) + (hits 0/74) constraint DS = {16} extremes [3, infinity) _,/and/or - (hits 176/176) (matched long text) constraint DS = {17} extremes [2, infinity) + (hits 176/176) (matched long text) constraint DS = {16} extremes [2, infinity) - hits 383/766 nti 22 constraint (none) extremes [1, infinity) + hits 383/766 nti 21 constraint (none) extremes [1, infinity) English: {...} (hits 383/383) (matched: '"n"') constraint (none) extremes [1, infinity) - hits 52/518 nti 23 constraint (none) extremes [1, infinity) + hits 50/514 nti 22 constraint (none) extremes [1, infinity) English: {...} - (hits 51/259) (matched long text) constraint (none) extremes [1, infinity) + (hits 49/257) (matched long text) constraint (none) extremes [1, infinity) - (hits 0/17) constraint DS = {15, 16} extremes [4, infinity) + (hits 0/24) constraint DS = {14, 15} extremes [4, infinity) - (hits 1/36) (matched: 'the infection color property') constraint DS = {15} extremes [2, infinity) + (hits 1/41) (matched: 'the infection color property') constraint DS = {14} extremes [2, infinity) - hits 51/242 nti 16 constraint DS = {16} extremes [2, infinity) + hits 49/292 nti 15 constraint DS = {15} extremes [2, infinity) English: , _and/or - (hits 0/86) constraint DS = {16} extremes [3, infinity) + (hits 0/98) constraint DS = {15} extremes [3, infinity) _,/and/or - (hits 51/102) (matched long text) constraint DS = {16} extremes [2, infinity) + (hits 49/122) (matched long text) constraint DS = {15} extremes [2, infinity) - hits 1/174 nti 15 constraint DS = {15} extremes [2, infinity) + hits 1/180 nti 14 constraint DS = {14} extremes [2, infinity) English: property - (hits 1/71) (matched: 'the infection color property') constraint DS = {15} extremes [2, infinity) + (hits 1/90) (matched: 'the infection color property') constraint DS = {14} extremes [2, infinity) {...} property - (hits 0/70) constraint DS = {15} extremes [2, infinity) + (hits 0/89) constraint DS = {14} extremes [2, infinity) - hits 167/334 nti 21 constraint (none) extremes [1, infinity) + hits 167/334 nti 20 constraint (none) extremes [1, infinity) English: when/while {...} - (hits 1/26) (matched: 'yourself when the player is not yourself') constraint DS = {21} extremes [3, infinity) + (hits 1/17) (matched: 'yourself when the player is not yourself') constraint DS = {20} extremes [3, infinity) (hits 166/166) (matched: 'giving it to ( with nouns reversed )') constraint (none) extremes [1, infinity) - hits 167/334 nti 24 constraint (none) extremes [1, infinity) + hits 167/334 nti 23 constraint (none) extremes [1, infinity) English: {...} (hits 0/167) constraint (none) extremes [1, infinity) - (hits 0/17) constraint DS = {20} extremes [3, infinity) + (hits 0/26) constraint DS = {19} extremes [3, infinity) (hits 167/167) (matched: 'giving it to ( with nouns reversed )') constraint (none) extremes [1, infinity) - hits 0/92 nti 20 constraint DS = {20} extremes [2, infinity) + hits 0/172 nti 19 constraint DS = {19} extremes [2, infinity) English: , _and/or - (hits 0/9) constraint DS = {20} extremes [3, infinity) + (hits 0/34) constraint DS = {19} extremes [3, infinity) _,/and/or - (hits 0/21) constraint DS = {20} extremes [2, infinity) + (hits 0/60) constraint DS = {19} extremes [2, infinity) - hits 167/334 nti 25 constraint (none) extremes [1, infinity) + hits 167/334 nti 24 constraint (none) extremes [1, infinity) English: (hits 167/167) (matched: 'giving it to ( with nouns reversed )') constraint (none) extremes [1, infinity) - hits 167/334 nti 19 constraint (none) extremes [1, infinity) + hits 167/334 nti 18 constraint (none) extremes [1, infinity) English: {...} (hits 0/167) constraint (none) extremes [1, infinity) a mistake - constraint CS = {19} extremes [2, 2] + constraint CS = {18} extremes [2, 2] a mistake ( ) - (hits 0/3) constraint DS = {19} extremes [5, 5] + (hits 0/3) constraint DS = {18} extremes [5, 5] a mistake {...} - (hits 0/45) constraint DS = {19} extremes [3, infinity) + (hits 0/43) constraint DS = {18} extremes [3, infinity) the plural of - (hits 0/11) constraint DS = {19} extremes [4, infinity) + (hits 0/12) constraint DS = {18} extremes [4, infinity) plural of - (hits 0/45) constraint DS = {19} extremes [3, infinity) + (hits 0/43) constraint DS = {18} extremes [3, infinity) (hits 2/73) (matched: '"[ice cream]"') constraint (none) extremes [1, 1] ( with nouns reversed ) - (hits 6/6) (matched: 'giving it to ( with nouns reversed )') constraint DS = {19} extremes [6, infinity) + (hits 6/6) (matched: 'giving it to ( with nouns reversed )') constraint DS = {18} extremes [6, infinity) (hits 159/159) (matched: 'requesting the story file version') constraint (none) extremes [1, infinity) - hits 165/330 nti 26 constraint (none) extremes [1, infinity) + hits 165/330 nti 25 constraint (none) extremes [1, infinity) English: (hits 150/165) (matched: 'requesting the story file version') constraint (none) extremes [1, infinity) @@ -9529,34 +9524,34 @@ {...} constraint (none) extremes [1, infinity) - hits 40/80 nti 22 constraint (none) extremes [1, infinity) + hits 40/80 nti 21 constraint (none) extremes [1, infinity) English: {...} when/while {...} - constraint DS = {22} extremes [3, infinity) + constraint DS = {21} extremes [3, infinity) something new - (hits 3/3) (matched: 'something new') constraint CS = {22} extremes [2, 2] + (hits 3/3) (matched: 'something new') constraint CS = {21} extremes [2, 2] (hits 37/37) (matched: 'take') constraint (none) extremes [1, 1] {...} constraint (none) extremes [1, infinity) - hits 1/2 nti 24 constraint (none) extremes [1, infinity) + hits 1/2 nti 23 constraint (none) extremes [1, infinity) English: when/while {...} - constraint DS = {24} extremes [3, infinity) + (hits 0/1) constraint DS = {23} extremes [3, infinity) (hits 1/1) (matched: 'referring to an ice cream cone') constraint (none) extremes [1, infinity) - hits 1/2 nti 23 constraint (none) extremes [1, infinity) + hits 1/2 nti 22 constraint (none) extremes [1, infinity) English: referring to - (hits 1/1) (matched: 'referring to an ice cream cone') constraint DS = {23} extremes [3, infinity) + (hits 1/1) (matched: 'referring to an ice cream cone') constraint DS = {22} extremes [3, infinity) describing - constraint DS = {23} extremes [2, infinity) + constraint DS = {22} extremes [2, infinity) {...} constraint (none) extremes [1, infinity) - hits 1/2 nti 27 constraint (none) extremes [1, infinity) + hits 1/2 nti 26 constraint (none) extremes [1, infinity) English: (hits 1/1) (matched: 'an ice cream cone') constraint (none) extremes [1, infinity) @@ -9565,7 +9560,7 @@ {...} constraint (none) extremes [1, infinity) - hits 4/8 nti 28 constraint (none) extremes [1, infinity) + hits 4/8 nti 27 constraint (none) extremes [1, infinity) English: (hits 4/4) (matched: 'the player is not yourself') constraint (none) extremes [1, infinity) @@ -9574,39 +9569,39 @@ {...} constraint (none) extremes [1, infinity) - hits 910/1820 nti 25 constraint (none) extremes [1, infinity) + hits 910/1820 nti 24 constraint (none) extremes [1, infinity) English: {...} , {...} - (hits 340/370) (matched long text) constraint DS = {25} extremes [3, infinity) + (hits 340/370) (matched long text) constraint DS = {24} extremes [3, infinity) (hits 400/526) (matched: 'n') constraint (none) extremes [1, 1] {...} (hits 170/170) (matched: 'a locked lockable thing') constraint (none) extremes [1, infinity) - hits 163/326 nti 27 constraint (none) extremes [1, infinity) + hits 163/326 nti 26 constraint (none) extremes [1, infinity) English: (hits 3/163) (matched: 'flavored ice cream') constraint (none) extremes [1, infinity) any things - constraint CS = {27} extremes [2, 2] + constraint CS = {26} extremes [2, 2] any - (hits 2/28) (matched: 'any room') constraint DS = {27} extremes [2, infinity) + (hits 2/28) (matched: 'any room') constraint DS = {26} extremes [2, infinity) anything - (hits 0/92) constraint CS = {27} extremes [1, 1] + (hits 0/92) constraint CS = {26} extremes [1, 1] anybody - (hits 0/92) constraint CS = {27} extremes [1, 1] + (hits 0/92) constraint CS = {26} extremes [1, 1] anyone - (hits 0/92) constraint CS = {27} extremes [1, 1] + (hits 0/92) constraint CS = {26} extremes [1, 1] anywhere - (hits 0/92) constraint CS = {27} extremes [1, 1] + (hits 0/92) constraint CS = {26} extremes [1, 1] something related by reversed - constraint DS = {27} extremes [5, infinity) + constraint DS = {26} extremes [5, infinity) something related by - (hits 0/2) constraint DS = {27} extremes [4, infinity) + (hits 0/2) constraint DS = {26} extremes [4, infinity) something related by {...} - (hits 0/2) constraint DS = {27} extremes [4, infinity) + (hits 0/2) constraint DS = {26} extremes [4, infinity) - (hits 138/138) (matched: 'something preferably held') constraint CS = {26} extremes [1, 3] + (hits 138/138) (matched: 'something preferably held') constraint CS = {25} extremes [1, 3] (hits 0/13) constraint (none) extremes [2, infinity) @@ -9616,307 +9611,307 @@ {...} constraint (none) extremes [1, infinity) - hits 138/276 nti 26 constraint CS = {26} extremes [1, 3] + hits 138/276 nti 25 constraint CS = {25} extremes [1, 3] English: something - (hits 88/115) (matched: 'something') constraint CS = {26} extremes [1, 1] + (hits 88/115) (matched: 'something') constraint CS = {25} extremes [1, 1] things - (hits 4/27) (matched: 'things') constraint CS = {26} extremes [1, 1] + (hits 4/27) (matched: 'things') constraint CS = {25} extremes [1, 1] things inside - (hits 4/9) (matched: 'things inside') constraint CS = {26} extremes [2, 2] + (hits 4/9) (matched: 'things inside') constraint CS = {25} extremes [2, 2] things preferably held - (hits 3/14) (matched: 'things preferably held') constraint CS = {26} extremes [3, 3] + (hits 3/14) (matched: 'things preferably held') constraint CS = {25} extremes [3, 3] something preferably held - (hits 11/11) (matched: 'something preferably held') constraint CS = {26} extremes [3, 3] + (hits 11/11) (matched: 'something preferably held') constraint CS = {25} extremes [3, 3] other things - (hits 5/5) (matched: 'other things') constraint CS = {26} extremes [2, 2] + (hits 5/5) (matched: 'other things') constraint CS = {25} extremes [2, 2] someone - (hits 15/23) (matched: 'someone') constraint CS = {26} extremes [1, 1] + (hits 15/23) (matched: 'someone') constraint CS = {25} extremes [1, 1] somebody - (hits 0/8) constraint CS = {26} extremes [1, 1] + (hits 0/8) constraint CS = {25} extremes [1, 1] text - (hits 8/8) (matched: 'text') constraint CS = {26} extremes [1, 1] + (hits 8/8) (matched: 'text') constraint CS = {25} extremes [1, 1] topic - constraint CS = {26} extremes [1, 1] + constraint CS = {25} extremes [1, 1] a topic - constraint CS = {26} extremes [2, 2] + constraint CS = {25} extremes [2, 2] object - constraint CS = {26} extremes [1, 1] + constraint CS = {25} extremes [1, 1] an object - constraint CS = {26} extremes [2, 2] + constraint CS = {25} extremes [2, 2] something held - constraint CS = {26} extremes [2, 2] + constraint CS = {25} extremes [2, 2] things held - constraint CS = {26} extremes [2, 2] + constraint CS = {25} extremes [2, 2] - internal hits 3/326 nti 29 constraint (none) extremes [1, infinity) + internal hits 3/326 nti 28 constraint (none) extremes [1, infinity) - hits 1/4 nti 30 constraint DS = {28} extremes [2, infinity) + hits 1/4 nti 29 constraint DS = {27} extremes [2, infinity) English: - (hits 1/1) (matched: 'the file of cover art ( The cover art. )') constraint DS = {28} extremes [3, infinity) + (hits 1/2) (matched: 'the file of cover art ( The cover art. )') constraint DS = {27} extremes [3, infinity) - constraint DS = {28} extremes [2, infinity) + (hits 0/1) constraint DS = {27} extremes [2, infinity) - hits 1/2 nti 28 constraint DS = {28} extremes [2, infinity) + hits 1/4 nti 27 constraint DS = {27} extremes [2, infinity) English: file - (hits 1/1) (matched: 'file of cover art ( The cover art. )') constraint DS = {28} extremes [2, infinity) + (hits 1/2) (matched: 'file of cover art ( The cover art. )') constraint DS = {27} extremes [2, infinity) - hits 2/690 nti 29 constraint DS = {29} extremes [2, infinity) + hits 2/690 nti 28 constraint DS = {28} extremes [2, infinity) English: figure {...} - (hits 2/211) (matched: 'figure of cover') constraint DS = {29} extremes [2, infinity) + (hits 2/225) (matched: 'figure of cover') constraint DS = {28} extremes [2, infinity) - hits 1/2 nti 31 constraint (none) extremes [1, infinity) + hits 1/2 nti 30 constraint (none) extremes [1, infinity) English: ( ) - (hits 1/1) (matched: 'of cover art ( The cover art. )') constraint DS = {31} extremes [4, infinity) + (hits 1/1) (matched: 'of cover art ( The cover art. )') constraint DS = {30} extremes [4, infinity) constraint (none) extremes [1, infinity) - hits 1/2 nti 30 constraint (none) extremes [1, infinity) + hits 1/2 nti 29 constraint (none) extremes [1, infinity) English: of cover art - (hits 1/1) (matched: 'of cover art') constraint CS = {30} extremes [3, 3] + (hits 1/1) (matched: 'of cover art') constraint CS = {29} extremes [3, 3] constraint (none) extremes [1, 1] {...} constraint (none) extremes [1, infinity) - nti 6 constraint CS = {6} extremes [3, 3] + nti 31 constraint CS = {31} extremes [3, 3] English: of cover art - constraint CS = {6} extremes [3, 3] + constraint CS = {31} extremes [3, 3] - hits 0/2 nti 31 constraint DS = {7} extremes [2, infinity) + hits 0/2 nti 30 constraint DS = {6} extremes [2, infinity) English: - constraint DS = {7} extremes [3, infinity) + constraint DS = {6} extremes [3, infinity) - constraint DS = {7} extremes [2, infinity) + constraint DS = {6} extremes [2, infinity) - nti 7 constraint DS = {7} extremes [2, infinity) + nti 6 constraint DS = {6} extremes [2, infinity) English: file - constraint DS = {7} extremes [2, infinity) + constraint DS = {6} extremes [2, infinity) - hits 1/688 nti 8 constraint DS = {8} extremes [2, infinity) + hits 1/688 nti 7 constraint DS = {7} extremes [2, infinity) English: sound {...} - (hits 1/147) (matched: 'sound name understood') constraint DS = {8} extremes [2, infinity) + (hits 1/152) (matched: 'sound name understood') constraint DS = {7} extremes [2, infinity) - nti 9 constraint (none) extremes [1, infinity) + nti 8 constraint (none) extremes [1, infinity) English: ( ) - constraint DS = {9} extremes [4, infinity) + constraint DS = {8} extremes [4, infinity) constraint (none) extremes [1, infinity) - nti 6 constraint (none) extremes [1, infinity) + nti 31 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, 1] {...} constraint (none) extremes [1, infinity) - hits 0/1070 nti 12 constraint (none) extremes [2, infinity) + hits 0/1070 nti 11 constraint (none) extremes [2, infinity) English: (hits 0/509) constraint (none) extremes [2, infinity) text - (hits 0/221) constraint DS = {11, 12} extremes [3, infinity) + (hits 0/321) constraint DS = {10, 11} extremes [3, infinity) binary - (hits 0/221) constraint DS = {11, 12} extremes [3, infinity) + (hits 0/321) constraint DS = {10, 11} extremes [3, infinity) - (hits 0/246) constraint DS = {11} extremes [2, infinity) + (hits 0/362) constraint DS = {10} extremes [2, infinity) - hits 0/492 nti 11 constraint DS = {11} extremes [2, infinity) + hits 0/724 nti 10 constraint DS = {10} extremes [2, infinity) English: {file ...} ( owned by ) - (hits 0/62) constraint DS = {11} extremes [7, infinity) + (hits 0/77) constraint DS = {10} extremes [7, infinity) {file ...} - (hits 0/246) constraint DS = {11} extremes [2, infinity) + (hits 0/362) constraint DS = {10} extremes [2, infinity) - nti 10 constraint (none) extremes [1, infinity) + nti 9 constraint (none) extremes [1, infinity) English: another project - constraint CS = {10} extremes [2, 2] + constraint CS = {9} extremes [2, 2] project {} - constraint DS = {10} extremes [2, 2] + constraint DS = {9} extremes [2, 2] {...} constraint (none) extremes [1, infinity) - nti 7 constraint (none) extremes [1, infinity) + nti 6 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, 1] {...} constraint (none) extremes [1, infinity) - nti 8 constraint DS = {13} extremes [2, infinity) + nti 7 constraint DS = {12} extremes [2, infinity) English: - constraint DS = {13} extremes [3, infinity) + constraint DS = {12} extremes [3, infinity) - constraint DS = {13} extremes [2, infinity) + constraint DS = {12} extremes [2, infinity) - nti 13 constraint DS = {13} extremes [2, infinity) + nti 12 constraint DS = {12} extremes [2, infinity) English: called - constraint DS = {13} extremes [2, infinity) + constraint DS = {12} extremes [2, infinity) - hits 0/688 nti 9 constraint (none) extremes [2, infinity) + hits 0/688 nti 8 constraint (none) extremes [2, infinity) English: (hits 0/330) constraint (none) extremes [2, infinity) - hits 447/3440 nti 14 constraint DS = {14, 29} extremes [6, infinity) + hits 447/2552 nti 13 constraint DS = {13, 27} extremes [6, infinity) English: {...} ( ) - (hits 424/892) (matched long text) constraint DS = {14, 29} extremes [6, infinity) + (hits 424/877) (matched long text) constraint DS = {13, 27} extremes [6, infinity) {...} -- -- - (hits 23/468) (matched long text) constraint DS = {14, 29} extremes [6, infinity) + (hits 23/453) (matched long text) constraint DS = {13, 27} extremes [6, infinity) - hits 480/1188 nti 29 constraint DS = {29} extremes [3, 3] + hits 480/1188 nti 27 constraint DS = {27} extremes [3, 3] English: documented at {###} - (hits 480/505) (matched: 'documented at act_startvm') constraint DS = {29} extremes [3, 3] + (hits 480/494) (matched: 'documented at ph_say') constraint DS = {27} extremes [3, 3] - nti 15 constraint DS = {15} extremes [2, infinity) + nti 14 constraint DS = {14} extremes [2, infinity) English: understood - constraint DS = {15} extremes [2, infinity) + constraint DS = {14} extremes [2, infinity) - nti 17 constraint (none) extremes [1, infinity) + nti 16 constraint (none) extremes [1, infinity) English: {} ( {...} ) - constraint DS = {17} extremes [5, infinity) + constraint DS = {16} extremes [5, infinity) {} ( {...} ) - constraint DS = {17} extremes [4, infinity) + constraint DS = {16} extremes [4, infinity) {} constraint (none) extremes [1, infinity) - nti 16 constraint (none) extremes [1, infinity) + nti 15 constraint (none) extremes [1, infinity) English: {...} - {...} - {...} - constraint DS = {16} extremes [5, infinity) + constraint DS = {15} extremes [5, infinity) {...} - {...} - constraint DS = {16} extremes [3, infinity) + constraint DS = {15} extremes [3, infinity) {...} constraint (none) extremes [1, infinity) - nti 18 constraint (none) extremes [1, 1] + nti 17 constraint (none) extremes [1, 1] English: in - constraint CS = {18} extremes [1, 1] + constraint CS = {17} extremes [1, 1] of - constraint CS = {18} extremes [1, 1] + constraint CS = {17} extremes [1, 1]
    constraint (none) extremes [1, 1] - nti 10 constraint (none) extremes [1, infinity) + nti 9 constraint (none) extremes [1, infinity) English: constraint (none) extremes [1, infinity) - nti 23 constraint (none) extremes [1, infinity) + nti 22 constraint (none) extremes [1, infinity) English: eps file - constraint CS = {23} extremes [2, 2] + constraint CS = {22} extremes [2, 2] mapped as - constraint DS = {23} extremes [4, infinity) + constraint DS = {22} extremes [4, infinity) {...} mapped as {...} - constraint DS = {23} extremes [4, infinity) + constraint DS = {22} extremes [4, infinity) mapped - constraint DS = {19, 23} extremes [4, infinity) + constraint DS = {18, 22} extremes [4, infinity) {...} mapped {...} - constraint DS = {23} extremes [3, infinity) + constraint DS = {22} extremes [3, infinity) set to - constraint DS = {23} extremes [4, infinity) + constraint DS = {22} extremes [4, infinity) set to {...} - constraint DS = {23} extremes [4, infinity) + constraint DS = {22} extremes [4, infinity) {...} set to {...} - constraint DS = {23} extremes [4, infinity) + constraint DS = {22} extremes [4, infinity) rubric {} {***} - constraint DS = {23} extremes [2, infinity) + constraint DS = {22} extremes [2, infinity) {...} constraint (none) extremes [1, infinity) - nti 19 constraint DS = {19} extremes [2, infinity) + nti 18 constraint DS = {18} extremes [2, infinity) English: of/from - constraint DS = {19} extremes [3, infinity) + constraint DS = {18} extremes [3, infinity) above - constraint DS = {19} extremes [2, infinity) + constraint DS = {18} extremes [2, infinity) below - constraint DS = {19} extremes [2, infinity) + constraint DS = {18} extremes [2, infinity) - nti 21 constraint (none) extremes [1, infinity) + nti 20 constraint (none) extremes [1, infinity) English: of - constraint DS = {21} extremes [3, infinity) + constraint DS = {20} extremes [3, infinity) constraint (none) extremes [1, infinity) {...} of - constraint DS = {21} extremes [3, infinity) + constraint DS = {20} extremes [3, infinity) - nti 11 constraint (none) extremes [1, infinity) + nti 10 constraint (none) extremes [1, infinity) English: constraint (none) extremes [2, infinity) constraint (none) extremes [1, infinity) - nti 20 constraint (none) extremes [1, infinity) + nti 19 constraint (none) extremes [1, infinity) English: first room - constraint CS = {20} extremes [2, 2] + constraint CS = {19} extremes [2, 2] level - constraint DS = {20} extremes [2, 2] + constraint DS = {19} extremes [2, 2] constraint (none) extremes [1, infinity) constraint (none) extremes [1, infinity) - internal nti 12 constraint (none) extremes [1, infinity) + internal nti 11 constraint (none) extremes [1, infinity) - nti 13 constraint (none) extremes [1, 1] + nti 12 constraint (none) extremes [1, 1] English: constraint CS = {r0} extremes [1, 1] constraint (none) extremes [1, 1] - constraint CS = {22} extremes [1, 1] + constraint CS = {21} extremes [1, 1] constraint (none) extremes [1, 1] {###} constraint (none) extremes [1, 1] - nti 22 constraint CS = {22} extremes [1, 1] + nti 21 constraint CS = {21} extremes [1, 1] English: on - constraint CS = {22} extremes [1, 1] + constraint CS = {21} extremes [1, 1] off - constraint CS = {22} extremes [1, 1] + constraint CS = {21} extremes [1, 1] - internal nti 14 constraint (none) extremes [1, 1] + internal nti 13 constraint (none) extremes [1, 1] - nti 24 constraint DS = {24} extremes [2, infinity) + nti 23 constraint DS = {23} extremes [2, infinity) English: size {***} - constraint DS = {24} extremes [2, infinity) + constraint DS = {23} extremes [2, infinity) font {} {***} - constraint DS = {24} extremes [2, infinity) + constraint DS = {23} extremes [2, infinity) colour {} {***} - constraint DS = {24} extremes [2, infinity) + constraint DS = {23} extremes [2, infinity) at from {...} - constraint DS = {24} extremes [4, infinity) + constraint DS = {23} extremes [4, infinity) at {***} - constraint DS = {24} extremes [2, infinity) + constraint DS = {23} extremes [2, infinity) - nti 15 constraint (none) extremes [0, 0] + nti 14 constraint (none) extremes [0, 0] - nti 16 constraint (none) extremes [0, 0] + nti 15 constraint (none) extremes [0, 0] diff --git a/inform7/Figures/memory-diagnostics.txt b/inform7/Figures/memory-diagnostics.txt index 87c703a6a..b13172345 100644 --- a/inform7/Figures/memory-diagnostics.txt +++ b/inform7/Figures/memory-diagnostics.txt @@ -1,12 +1,12 @@ -Total memory consumption was 260800K = 255 MB +Total memory consumption was 260801K = 255 MB -62.8% was used for 1340857 objects, in 282597 frames in 205 x 800K = 164000K = 160 MB: +62.8% was used for 1341250 objects, in 282990 frames in 205 x 800K = 164000K = 160 MB: 9.7% inter_tree_node_array 36 x 8192 = 294912 objects, 25953408 bytes 5.4% text_stream_array 2583 x 100 = 258300 objects, 14547456 bytes 3.8% parse_node 129371 objects, 10349680 bytes 2.7% verb_conjugation 160 objects, 7425280 bytes - 2.7% linked_list 13065 objects, 7316400 bytes + 2.7% linked_list 13067 objects, 7317520 bytes 2.5% parse_node_annotation_array 431 x 500 = 215500 objects, 6909792 bytes 2.3% inter_symbol_array 69 x 1024 = 70656 objects, 6219936 bytes 1.2% pcalc_prop_array 24 x 1000 = 24000 objects, 3264768 bytes @@ -19,10 +19,10 @@ Total memory consumption was 260800K = 255 MB 0.3% excerpt_meaning 3098 objects, 966576 bytes 0.3% inter_name_array 20 x 1000 = 20000 objects, 960640 bytes 0.3% inter_package 13227 objects, 952344 bytes - 0.3% production 3887 objects, 901784 bytes - 0.3% phrase 940 objects, 894880 bytes - 0.3% ptoken 8391 objects, 872664 bytes + 0.3% production 3886 objects, 901552 bytes + 0.3% ptoken 8387 objects, 872248 bytes 0.3% grammatical_usage 3610 objects, 866400 bytes + 0.3% phrase 940 objects, 864800 bytes 0.3% individual_form 2560 objects, 860160 bytes 0.3% inter_symbols_table 13227 objects, 846528 bytes 0.3% inter_schema_node 8692 objects, 834432 bytes @@ -43,8 +43,9 @@ Total memory consumption was 260800K = 255 MB ---- linguistic_stock_item 3315 objects, 159120 bytes ---- binary_predicate 321 objects, 156648 bytes ---- stacked_variable_owner_list_array 38 x 100 = 3800 objects, 153216 bytes + ---- rule_family_data 400 objects, 147200 bytes ---- index_lexicon_entry 395 objects, 142200 bytes - ---- nonterminal 761 objects, 140024 bytes + ---- nonterminal 760 objects, 139840 bytes ---- documentation_ref 1275 objects, 112200 bytes ---- inference 1703 objects, 108992 bytes ---- hierarchy_location 730 objects, 105120 bytes @@ -72,12 +73,11 @@ Total memory consumption was 260800K = 255 MB ---- cg_line 230 objects, 47840 bytes ---- table 7 objects, 45528 bytes ---- inter_node_list 750 objects, 42000 bytes - ---- rule_family_data 400 objects, 41600 bytes ---- activity_list_array 1 x 1000 objects, 40032 bytes ---- anl_clause_array 1 x 1000 objects, 40032 bytes + ---- to_family_data 496 objects, 39680 bytes ---- response_message 407 objects, 35816 bytes - ---- to_family_data 496 objects, 35712 bytes - ---- production_list 619 objects, 34664 bytes + ---- production_list 618 objects, 34608 bytes ---- regions_data 670 objects, 32160 bytes ---- HTML_tag_array 1 x 1000 objects, 32032 bytes ---- property_permission 96 objects, 30720 bytes @@ -91,14 +91,15 @@ Total memory consumption was 260800K = 255 MB ---- instance 167 objects, 20040 bytes ---- pcalc_prop_deferral 90 objects, 19440 bytes ---- nonlocal_variable 93 objects, 19344 bytes + ---- timed_rules_rfd_data 400 objects, 19200 bytes ---- property 146 objects, 18688 bytes ---- action_name 90 objects, 18000 bytes ---- parse_node_tree 20 objects, 17280 bytes - ---- method 345 objects, 16560 bytes + ---- method 342 objects, 16416 bytes ---- understanding_reference_array 2 x 100 = 200 objects, 16064 bytes - ---- linked_list_item_array 1 x 1000 objects, 16032 bytes - ---- action_name_list_array 1 x 1000 objects, 16032 bytes ---- match_avinue_array 1 x 1000 objects, 16032 bytes + ---- action_name_list_array 1 x 1000 objects, 16032 bytes + ---- linked_list_item_array 1 x 1000 objects, 16032 bytes ---- to_phrase_request 59 objects, 15576 bytes ---- adjective 137 objects, 14248 bytes ---- booking_list 407 objects, 13024 bytes @@ -130,17 +131,17 @@ Total memory consumption was 260800K = 255 MB ---- command_line_switch 43 objects, 3440 bytes ---- property_setting_bp_data 84 objects, 3360 bytes ---- method_set 104 objects, 3328 bytes - ---- instance_usage_array 1 x 200 objects, 3232 bytes ---- kind_constructor_comparison_schema_array 1 x 100 objects, 3232 bytes - ---- definition 44 objects, 3168 bytes + ---- instance_usage_array 1 x 200 objects, 3232 bytes ---- compatibility_specification 66 objects, 3168 bytes + ---- definition 44 objects, 3168 bytes ---- inform_extension 19 objects, 3040 bytes ---- property_of_value_storage 93 objects, 2976 bytes ---- either_or_property_data 62 objects, 2976 bytes ---- submodule_request 72 objects, 2880 bytes ---- inter_construct 32 objects, 2560 bytes - ---- parentage_inference_data 79 objects, 2528 bytes ---- part_of_inference_data 79 objects, 2528 bytes + ---- parentage_inference_data 79 objects, 2528 bytes ---- kind_constructor_instance_array 1 x 100 objects, 2432 bytes ---- kind_constructor_casting_rule_array 1 x 100 objects, 2432 bytes ---- equation_symbol 30 objects, 2400 bytes @@ -150,14 +151,14 @@ Total memory consumption was 260800K = 255 MB ---- pronoun_usage 42 objects, 1680 bytes ---- activity_crossref_array 1 x 100 objects, 1632 bytes ---- table_contribution_array 1 x 100 objects, 1632 bytes + ---- plugin 25 objects, 1600 bytes ---- kind_interaction 39 objects, 1560 bytes - ---- plugin 24 objects, 1536 bytes ---- inter_annotation_form 37 objects, 1480 bytes ---- pipeline_step 12 objects, 1440 bytes ---- noun_filter_token 22 objects, 1408 bytes ---- special_meaning_holder 33 objects, 1320 bytes - ---- constant_phrase 20 objects, 1280 bytes ---- build_script 40 objects, 1280 bytes + ---- constant_phrase 20 objects, 1280 bytes ---- invocation_options_array 1 x 100 objects, 1224 bytes ---- direction_inference_data 30 objects, 1200 bytes ---- hierarchy_metadatum 15 objects, 1200 bytes @@ -169,15 +170,15 @@ Total memory consumption was 260800K = 255 MB ---- cached_understanding 21 objects, 840 bytes ---- runtime_kind_structure 13 objects, 832 bytes ---- phrase_option_array 1 x 100 objects, 824 bytes - ---- pipeline_stage 17 objects, 816 bytes ---- target_vm 6 objects, 816 bytes + ---- pipeline_stage 17 objects, 816 bytes ---- generated_segment 25 objects, 800 bytes ---- inter_data_type 14 objects, 784 bytes ---- submodule_identity 23 objects, 736 bytes ---- inform_language 6 objects, 672 bytes ---- inter_warehouse_room 10 objects, 640 bytes - ---- relation_guard 5 objects, 640 bytes ---- I6T_intervention 8 objects, 640 bytes + ---- relation_guard 5 objects, 640 bytes ---- nascent_array 7 objects, 616 bytes ---- named_rulebook_outcome 15 objects, 600 bytes ---- inbuild_search_result 15 objects, 600 bytes @@ -205,39 +206,39 @@ Total memory consumption was 260800K = 255 MB ---- inform_pipeline 4 objects, 256 bytes ---- verb_usage_tier 5 objects, 240 bytes ---- adjective_meaning_family 7 objects, 224 bytes - ---- test_scenario 1 object, 208 bytes ---- release_instructions 1 object, 208 bytes - ---- compilation_unit 5 objects, 200 bytes + ---- test_scenario 1 object, 208 bytes ---- build_skill 5 objects, 200 bytes + ---- compilation_unit 5 objects, 200 bytes ---- plural_dictionary_entry 4 objects, 192 bytes ---- kit_dependency 4 objects, 192 bytes ---- inform_project 1 object, 176 bytes ---- link_instruction 4 objects, 160 bytes - ---- imperative_defn_family 4 objects, 160 bytes ---- inter_architecture 4 objects, 160 bytes - ---- inference_subject_family 5 objects, 160 bytes + ---- imperative_defn_family 4 objects, 160 bytes ---- pointer_allocation 2 objects, 160 bytes + ---- inference_subject_family 5 objects, 160 bytes ---- code_generation_target 4 objects, 160 bytes ---- element_activation 4 objects, 128 bytes ---- codegen_pipeline 1 object, 128 bytes ---- inbuild_nest 3 objects, 120 bytes ---- inform_kit_ittt 2 objects, 96 bytes - ---- compile_task_data 1 object, 80 bytes ---- list_together_routine 2 objects, 80 bytes ---- article 2 objects, 80 bytes + ---- compile_task_data 1 object, 80 bytes ---- build_methodology 1 object, 56 bytes ---- inter_warehouse 1 object, 56 bytes + ---- HTML_file_state 1 object, 48 bytes ---- figures_data 1 object, 48 bytes ---- star_invention 1 object, 48 bytes - ---- HTML_file_state 1 object, 48 bytes + ---- parse_name_notice 1 object, 40 bytes ---- by_routine_bp_data 1 object, 40 bytes ---- loop_over_scope 1 object, 40 bytes ---- kind_template_definition 1 object, 40 bytes - ---- parse_name_notice 1 object, 40 bytes 37.1% was used for memory not allocated for objects: - 15.7% text stream storage 42068372 bytes in 264531 claims + 15.7% text stream storage 42068836 bytes in 264534 claims 3.4% dictionary storage 9278976 bytes in 16372 claims ---- sorting 992 bytes in 3 claims 2.6% source text 7200000 bytes in 3 claims @@ -253,5 +254,5 @@ Total memory consumption was 260800K = 255 MB ---- emitter array storage 12320 bytes in 8 claims ---- code generation workspace for objects 9200 bytes in 9 claims -20.5% was overhead - 54964904 bytes = 53676K = 52 MB +20.5% was overhead - 54866064 bytes = 53580K = 52 MB diff --git a/inform7/Figures/preform-summary.txt b/inform7/Figures/preform-summary.txt index abf5b2bb4..14122eda1 100644 --- a/inform7/Figures/preform-summary.txt +++ b/inform7/Figures/preform-summary.txt @@ -3,9 +3,9 @@ (@1)=1 (hits 171/171) (matched: '100') constraint CS = {r0} extremes [1, 1] (@1)minus (@2)=1 - (hits 0/1908) constraint DS = {12} extremes [2, 2] + (hits 0/1891) constraint DS = {12} extremes [2, 2] (@1)=1 (@2)( (@3)=2 (@4)) - (hits 273/815) (matched: '"[current item from the multiple object list]: [run paragraph on]" ( a )') constraint DS = {12} extremes [4, 4] + (hits 273/762) (matched: '"[current item from the multiple object list]: [run paragraph on]" ( a )') constraint DS = {12} extremes [4, 4] (@1)=1 (hits 1564/5543) (matched: 'Represents geographical locations, both indoor and outdoor, which are not necessarily areas in a building. A player in one @@ -14,12 +14,12 @@ =1 (hits 11/9911) (matched: 'plus infinity') constraint (none) extremes [1, infinity) (@1)=1 - (hits 78/315) (matched: 'false') constraint CS = {6} extremes [1, 1] + (hits 78/979) (matched: 'false') constraint CS = {6} extremes [1, 1] =1 - (hits 0/1628) constraint DS = {8} extremes [2, infinity) + (hits 0/1594) constraint DS = {8} extremes [2, infinity) (@1)unicode =1 - (hits 0/4223) constraint DS = {12} extremes [2, infinity) + (hits 0/4109) constraint DS = {12} extremes [2, infinity) =1 - (hits 0/1811) constraint DW = {9, 10, 11} extremes [2, 5] + (hits 0/3052) constraint DW = {9, 10, 11} extremes [2, 5] =1 (hits 0/9822) constraint (none) extremes [1, infinity) diff --git a/inform7/Figures/timings-diagnostics.txt b/inform7/Figures/timings-diagnostics.txt index 79dc0d13e..080515131 100644 --- a/inform7/Figures/timings-diagnostics.txt +++ b/inform7/Figures/timings-diagnostics.txt @@ -1,10 +1,10 @@ 100.0% in inform7 run - 66.6% in compilation to Inter - 25.4% in //ImperativeDefinitions::compile_first_block// - 8.8% in //ImperativeDefinitions::compile_as_needed// - 6.7% in //Strings::compile_responses// + 67.0% in compilation to Inter + 25.8% in //ImperativeDefinitions::compile_first_block// + 8.6% in //ImperativeDefinitions::compile_as_needed// + 6.9% in //Strings::compile_responses// 6.0% in //InferenceSubjects::emit_all// - 4.1% in //MajorNodes::pre_pass// + 4.3% in //MajorNodes::pre_pass// 3.3% in //MajorNodes::pass_1// 2.0% in //RTRules::RulePrintingRule_routine// 1.8% in //RTRules::rulebooks_array_array// @@ -14,14 +14,13 @@ 0.3% in //RTRelations::compile_defined_relations// 0.3% in //RTRules::compile_rulebooks// 0.3% in //World::stage_V// - 0.1% in //RTCommandGrammars::compile_all// 0.1% in //RTKinds::compile_data_type_support_routines// 0.1% in //Task::make_built_in_kind_constructors// - 3.3% not specifically accounted for - 30.9% in running Inter pipeline - 10.0% in step preparation - 9.8% in inter step 2/12: link - 7.1% in inter step 12/12: generate inform6 -> auto.inf + 3.4% not specifically accounted for + 30.5% in running Inter pipeline + 9.9% in inter step 2/12: link + 9.9% in step preparation + 6.9% in inter step 12/12: generate inform6 -> auto.inf 0.3% in inter step 9/12: make-identifiers-unique 0.1% in inter step 10/12: reconcile-verbs 0.1% in inter step 11/12: eliminate-redundant-labels @@ -29,6 +28,6 @@ 0.1% in inter step 6/12: assimilate 0.1% in inter step 7/12: resolve-external-symbols 0.1% in inter step 8/12: inspect-plugs - 2.5% not specifically accounted for + 2.1% not specifically accounted for 2.0% in supervisor 0.4% not specifically accounted for diff --git a/inform7/Tests/Groups/timedrules.testgroup b/inform7/Tests/Groups/timedrules.testgroup new file mode 100644 index 000000000..274631525 --- /dev/null +++ b/inform7/Tests/Groups/timedrules.testgroup @@ -0,0 +1,7 @@ +Chapter7 +Chapter9 +NearMidnight +Resume +PM_AtTimeThat +PM_AtWithoutTime +PM_UnusedTimedEvent diff --git a/inform7/Tests/Test Problems/_Results_Ideal/PM_APWithDisjunction.txt b/inform7/Tests/Test Problems/_Results_Ideal/PM_APWithDisjunction.txt index 08fc61629..d7a1cda98 100644 --- a/inform7/Tests/Test Problems/_Results_Ideal/PM_APWithDisjunction.txt +++ b/inform7/Tests/Test Problems/_Results_Ideal/PM_APWithDisjunction.txt @@ -1,16 +1,17 @@ -Inform 7 build 6L26 has started. +Inform 7 v10.1.0 has started. I've now read your source text, which is 25 words long. -I've also read Standard Rules by Graham Nelson, which is 42597 words long. -I've also read English Language by Graham Nelson, which is 2288 words long. +I've also read Basic Inform by Graham Nelson, which is 7687 words long. +I've also read English Language by Graham Nelson, which is 2328 words long. +I've also read Standard Rules by Graham Nelson, which is 32067 words long. Problem__ PM_APWithDisjunction >--> You wrote 'Instead of pushing Wellington or pushing Orinoco' (source text, line 3), which seems to introduce a rule, but the circumstances ('pushing Wellington or pushing Orinoco') seem to be too general for me to - understand in a single rule. I can understand a choice of of actions, in a + understand in a single rule. I can understand a choice of actions, in a list such as 'taking or dropping the ball', but there can only be one set of noun(s) supplied. So 'taking the ball or taking the bat' is disallowed. You can get around this by using named actions ('Taking the ball is being mischievous. Taking the bat is being mischievous. Instead of being mischievous...'), or it may be less bother just to write more than one rule. -Inform 7 has finished: 19 centiseconds used. +Inform 7 has finished. diff --git a/inform7/Tests/Test Problems/_Results_Ideal/PM_APWithImmiscible.txt b/inform7/Tests/Test Problems/_Results_Ideal/PM_APWithImmiscible.txt index e92d01e27..b7e8a8103 100644 --- a/inform7/Tests/Test Problems/_Results_Ideal/PM_APWithImmiscible.txt +++ b/inform7/Tests/Test Problems/_Results_Ideal/PM_APWithImmiscible.txt @@ -8,9 +8,9 @@ Problem__ PM_APWithDisjunction box' (source text, line 5), which seems to introduce a rule, but the circumstances ('dropping the CD or inserting the CD into the jewel box') seem to be too general for me to understand in a single rule. I can - understand a choice of of actions, in a list such as 'taking or dropping - the ball', but there can only be one set of noun(s) supplied. So 'taking - the ball or taking the bat' is disallowed. You can get around this by using + understand a choice of actions, in a list such as 'taking or dropping the + ball', but there can only be one set of noun(s) supplied. So 'taking the + ball or taking the bat' is disallowed. You can get around this by using named actions ('Taking the ball is being mischievous. Taking the bat is being mischievous. Instead of being mischievous...'), or it may be less bother just to write more than one rule. @@ -19,9 +19,9 @@ Problem__ PM_APWithDisjunction the CD' (source text, line 8), which seems to introduce a rule, but the circumstances ('inserting the CD into the jewel box or dropping the CD') seem to be too general for me to understand in a single rule. I can - understand a choice of of actions, in a list such as 'taking or dropping - the ball', but there can only be one set of noun(s) supplied. So 'taking - the ball or taking the bat' is disallowed. You can get around this by using + understand a choice of actions, in a list such as 'taking or dropping the + ball', but there can only be one set of noun(s) supplied. So 'taking the + ball or taking the bat' is disallowed. You can get around this by using named actions ('Taking the ball is being mischievous. Taking the bat is being mischievous. Instead of being mischievous...'), or it may be less bother just to write more than one rule. diff --git a/inform7/Tests/Test Problems/_Results_Ideal/PM_BadRulePreambleWhen.txt b/inform7/Tests/Test Problems/_Results_Ideal/PM_BadRulePreambleWhen.txt index 65561f94f..dc5216103 100644 --- a/inform7/Tests/Test Problems/_Results_Ideal/PM_BadRulePreambleWhen.txt +++ b/inform7/Tests/Test Problems/_Results_Ideal/PM_BadRulePreambleWhen.txt @@ -1,20 +1,17 @@ -Inform 7 build 6L26 has started. +Inform 7 v10.1.0 has started. I've now read your source text, which is 10 words long. -I've also read Standard Rules by Graham Nelson, which is 42597 words long. -I've also read English Language by Graham Nelson, which is 2288 words long. +I've also read Basic Inform by Graham Nelson, which is 7687 words long. +I've also read English Language by Graham Nelson, which is 2328 words long. +I've also read Standard Rules by Graham Nelson, which is 32067 words long. Problem__ PM_BadRulePreambleWhen >--> The punctuation makes me think 'When the badger runs' (source text, line 3) should be a definition of a phrase or a rule, but it doesn't begin as it should, with either 'To' (e.g. 'To flood the riverplain:'), 'Definition:', a name for a rule (e.g. 'This is the devilishly cunning rule:'), 'At' plus a time (e.g. 'At 11:12 PM:' or 'At the time when the clock chimes:') or the - name of a rulebook. As your rule begins with 'When', it may be worth - noting that in December 2006 the syntax used by Inform for timed events - changed: the old syntax 'When the sky falls in:' to create a named event, - the sky falls in, became 'At the time when the sky falls in:'. This was - changed to avoid confusion with rules relating to when scenes begin or end. - Or perhaps you meant to say that something would only happen when some - condition held. Inform often allows this, but the 'when...' part tends to - be at the end, not up front - for instance, 'Understand "blue" as the deep - crevasse when the location is the South Pole.' -Inform 7 has finished: 19 centiseconds used. + name of a rulebook. Perhaps you meant to say that something would only + happen when some condition held. Inform often allows this, but the + 'when...' part tends to be at the end, not up front - for instance, + 'Understand "blue" as the deep crevasse when the location is the South + Pole.' +Inform 7 has finished. diff --git a/inform7/assertions-module/Chapter 5/Adjectival Definition Family.w b/inform7/assertions-module/Chapter 5/Adjectival Definition Family.w index 6a10be7bf..74ad5ac68 100644 --- a/inform7/assertions-module/Chapter 5/Adjectival Definition Family.w +++ b/inform7/assertions-module/Chapter 5/Adjectival Definition Family.w @@ -2,32 +2,53 @@ Imperative definitions of "Definition: X is Y: ..." adjectives. -@ - -= (early code) -imperative_defn_family *DEFINITIONAL_PHRASE_EFF_family = NULL; /* "Definition: a container is roomy if: ..." */ - -@ +@ This family is used for adjective definitions, whether or not they run on +into substantial amounts of code. = +imperative_defn_family *adjectival_idf = NULL; /* "Definition: a container is roomy if: ..." */ + void AdjectivalDefinitionFamily::create_family(void) { - DEFINITIONAL_PHRASE_EFF_family = ImperativeDefinitionFamilies::new(I"DEFINITIONAL_PHRASE_EFF", FALSE); - METHOD_ADD(DEFINITIONAL_PHRASE_EFF_family, CLAIM_IMP_DEFN_MTID, AdjectivalDefinitionFamily::claim); - METHOD_ADD(DEFINITIONAL_PHRASE_EFF_family, NEW_PHRASE_IMP_DEFN_MTID, AdjectivalDefinitionFamily::new_phrase); - METHOD_ADD(DEFINITIONAL_PHRASE_EFF_family, ALLOWS_EMPTY_IMP_DEFN_MTID, AdjectivalDefinitionFamily::allows_empty); - METHOD_ADD(DEFINITIONAL_PHRASE_EFF_family, TO_PHTD_IMP_DEFN_MTID, AdjectivalDefinitionFamily::to_phtd); - METHOD_ADD(DEFINITIONAL_PHRASE_EFF_family, COMPILE_IMP_DEFN_MTID, AdjectivalDefinitionFamily::compile); + adjectival_idf = ImperativeDefinitionFamilies::new(I"adjectival-idf", FALSE); + METHOD_ADD(adjectival_idf, IDENTIFY_IMP_DEFN_MTID, AdjectivalDefinitionFamily::identify); + METHOD_ADD(adjectival_idf, GIVEN_BODY_IMP_DEFN_MTID, AdjectivalDefinitionFamily::given_body); + METHOD_ADD(adjectival_idf, ALLOWS_EMPTY_IMP_DEFN_MTID, AdjectivalDefinitionFamily::allows_empty); + METHOD_ADD(adjectival_idf, COMPILE_IMP_DEFN_MTID, AdjectivalDefinitionFamily::compile); } +@ Colons are used slightly differently in some adjectival definitions. Consider: += (text as Inform 7) +Definition: A container is roomy if its carrying capacity is greater than 10. +Definition: A container is possessed by the Devil: + if its carrying capacity is 666, decide yes; + decide no. += +To Inform this looks like three consecutive |IMPERATIVE_NT| nodes: += (text as Inform 7) +Definition: + A container is roomy if its carrying capacity is greater than 10. + +Definition: + +A container is possessed by the Devil: + if its carrying capacity is 666, decide yes; + decide no. += +But we want to create just two //imperative_defn// objects, not three. So +when the second |IMPERATIVE_NT| node is identified as belonging to us, we +take the opportunity to change the type of the third node to |DEFN_CONT_NT| +("definition continuation"). That means it will not lead to an //imperative_defn// +of its own. + @ = ::= definition @ = -void AdjectivalDefinitionFamily::claim(imperative_defn_family *self, imperative_defn *id) { +void AdjectivalDefinitionFamily::identify(imperative_defn_family *self, imperative_defn *id) { wording W = Node::get_text(id->at); if ((W)) { - id->family = DEFINITIONAL_PHRASE_EFF_family; + id->family = adjectival_idf; if ((id->at->next) && (id->at->down == NULL) && (Node::get_type(id->at->next) == IMPERATIVE_NT)) { ImperativeSubtrees::accept_body(id->at->next); @@ -37,42 +58,41 @@ void AdjectivalDefinitionFamily::claim(imperative_defn_family *self, imperative_ } } -@ If a phrase defines an adjective, like so: - ->> Definition: A container is capacious if: ... - -we need to make the pronoun "it" a local variable of kind "container" in the -stack frame used to compile the "..." part. If it uses a calling, like so: - ->> Definition: A container (called the sack) is capacious if: ... - -then we also want the name "sack" to refer to this. Here's where we take care -of it: - -= -void AdjectivalDefinitionFamily::new_phrase(imperative_defn_family *self, imperative_defn *id, phrase *new_ph) { - wording CW = EMPTY_WORDING; - kind *K = NULL; - Phrases::Phrasal::define_adjective_by_phrase(id->at, new_ph, &CW, &K); - LocalVariables::add_pronoun(&(new_ph->stack_frame), CW, K); -} - -@ +@ Since the "Definition:" node might have no code under it (because the code +is actually under the continuation node): = int AdjectivalDefinitionFamily::allows_empty(imperative_defn_family *self, imperative_defn *id) { return TRUE; } -void AdjectivalDefinitionFamily::to_phtd(imperative_defn_family *self, imperative_defn *id, ph_type_data *phtd, wording XW, wording *OW) { - Phrases::TypeData::set_mor(phtd, DECIDES_CONDITION_MOR, NULL); +@ The body of code under a definition needs to be set up so that: +(*) The code expects to make a yes/no decision; +(*) The pronoun "it" is a local variable referring to the value being tested, +perhaps also with a calling -- consider the example "Definition: A +container (called the sack) is capacious if...". + += +void AdjectivalDefinitionFamily::given_body(imperative_defn_family *self, imperative_defn *id) { + phrase *body = id->body_of_defn; + + Phrases::TypeData::set_mor(&(body->type_data), DECIDES_CONDITION_MOR, NULL); + + wording CALLW = EMPTY_WORDING; + kind *K = NULL; + Phrases::Phrasal::define_adjective_by_phrase(id->at, body, &CALLW, &K); + LocalVariables::add_pronoun(&(body->stack_frame), CALLW, K); + } +@ The code body for any definition is compiled here: + += void AdjectivalDefinitionFamily::compile(imperative_defn_family *self, int *total_phrases_compiled, int total_phrases_to_compile) { imperative_defn *id; LOOP_OVER(id, imperative_defn) - if (id->family == DEFINITIONAL_PHRASE_EFF_family) + if (id->family == adjectival_idf) Phrases::compile(id->body_of_defn, total_phrases_compiled, total_phrases_to_compile, NULL, NULL, NULL); RTAdjectives::compile_support_code(); diff --git a/inform7/assertions-module/Chapter 5/Imperative Definition Families.w b/inform7/assertions-module/Chapter 5/Imperative Definition Families.w index 5e194db93..a3ec0e8ec 100644 --- a/inform7/assertions-module/Chapter 5/Imperative Definition Families.w +++ b/inform7/assertions-module/Chapter 5/Imperative Definition Families.w @@ -2,8 +2,15 @@ Different categories of imperative definition. -@ There are very few of these, and an Inform source text cannot create more. -The following is called at startup, and then that's the lot: +@h Creation. +See //Imperative Definitions// for what these families are. + +There are very few of them, and an Inform source text cannot create more. +The following is called at startup, and then that's the lot. + +The order of creation is important here, or at least, it's important that +the rule family comes last, because this affects the order of the loop in +//ImperativeDefinitionFamilies::identify// below. = imperative_defn_family *unknown_idf = NULL; /* used only temporarily */ @@ -33,26 +40,31 @@ imperative_defn_family *ImperativeDefinitionFamilies::new(text_stream *name, int return family; } -@ So, then, the rest of this section provides an API, in effect, for different +@h Identification. +So, then, the rest of this section provides an API, in effect, for different users of imperative definitions to get their work done. -|CLAIM_IMP_DEFN_MTID| is for deciding from the syntax of a preamble whether -this definition should belong to the family or not. +|IDENTIFY_IMP_DEFN_MTID| is for deciding from the syntax of a preamble whether +this definition should belong to the family or not. The recipient should set +|id->family| to itself if it wants the definition. -@e CLAIM_IMP_DEFN_MTID +@e IDENTIFY_IMP_DEFN_MTID = -VOID_METHOD_TYPE(CLAIM_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id) +VOID_METHOD_TYPE(IDENTIFY_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id) void ImperativeDefinitionFamilies::identify(imperative_defn *id) { id->family = unknown_idf; imperative_defn_family *f; LOOP_OVER(f, imperative_defn_family) if (id->family == unknown_idf) - VOID_METHOD_CALL(f, CLAIM_IMP_DEFN_MTID, id); + VOID_METHOD_CALL(f, IDENTIFY_IMP_DEFN_MTID, id); } -@ |ASSESS_IMP_DEFN_MTID| is for parsing it in more detail, later on. +@h Assessment. +|ASSESS_IMP_DEFN_MTID| is for parsing the preamble in more detail, later on. +At the start of assessment, this is called on each of the IDs belonging to the +family in turn. @e ASSESS_IMP_DEFN_MTID @@ -63,47 +75,38 @@ void ImperativeDefinitionFamilies::assess(imperative_defn *id) { VOID_METHOD_CALL(id->family, ASSESS_IMP_DEFN_MTID, id); } -@ |REGISTER_IMP_DEFN_MTID| is called on the family when everything has -been assessed. +@ |GIVEN_BODY_IMP_DEFN_MTID| is called on an ID just after |id->body_of_defn| +has finally been created. + +@e GIVEN_BODY_IMP_DEFN_MTID + += +VOID_METHOD_TYPE(GIVEN_BODY_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id) + +void ImperativeDefinitionFamilies::given_body(imperative_defn *id) { + VOID_METHOD_CALL(id->family, GIVEN_BODY_IMP_DEFN_MTID, id); +} + +@ Next, |REGISTER_IMP_DEFN_MTID| is then called on the family when all of the +|ASSESS_IMP_DEFN_MTID| calls have been made, and all the bodies created. @e REGISTER_IMP_DEFN_MTID = -VOID_METHOD_TYPE(REGISTER_IMP_DEFN_MTID, imperative_defn_family *f, int initial_problem_count) +VOID_METHOD_TYPE(REGISTER_IMP_DEFN_MTID, imperative_defn_family *f) -void ImperativeDefinitionFamilies::register(imperative_defn_family *f, int initial_problem_count) { - VOID_METHOD_CALL(f, REGISTER_IMP_DEFN_MTID, initial_problem_count); +void ImperativeDefinitionFamilies::register(imperative_defn_family *f) { + VOID_METHOD_CALL_WITHOUT_ARGUMENTS(f, REGISTER_IMP_DEFN_MTID); } -@ |ASSESSMENT_COMPLETE_IMP_DEFN_MTID| is called on the family when everything has -been assessed. - -@e ASSESSMENT_COMPLETE_IMP_DEFN_MTID - -= -VOID_METHOD_TYPE(ASSESSMENT_COMPLETE_IMP_DEFN_MTID, imperative_defn_family *f, int initial_problem_count) - -void ImperativeDefinitionFamilies::assessment_complete(imperative_defn_family *f, int initial_problem_count) { - VOID_METHOD_CALL(f, ASSESSMENT_COMPLETE_IMP_DEFN_MTID, initial_problem_count); -} - -@ |NEW_PHRASE_IMP_DEFN_MTID| is for ... - -@e NEW_PHRASE_IMP_DEFN_MTID - -= -VOID_METHOD_TYPE(NEW_PHRASE_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id, phrase *new_ph) - -void ImperativeDefinitionFamilies::given_body(imperative_defn *id, phrase *new_ph) { - VOID_METHOD_CALL(id->family, NEW_PHRASE_IMP_DEFN_MTID, id, new_ph); -} - -@ |TO_RCD_IMP_DEFN_MTID| is for... +@ A call to |TO_RCD_IMP_DEFN_MTID| is then made for each ID in turn, asking the +family to give the body its runtime context data. @e TO_RCD_IMP_DEFN_MTID = -VOID_METHOD_TYPE(TO_RCD_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id, ph_runtime_context_data *rcd) +VOID_METHOD_TYPE(TO_RCD_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id, + ph_runtime_context_data *rcd) ph_runtime_context_data ImperativeDefinitionFamilies::to_phrcd(imperative_defn *id) { current_sentence = id->at; @@ -114,23 +117,30 @@ ph_runtime_context_data ImperativeDefinitionFamilies::to_phrcd(imperative_defn * return phrcd; } -@ |TO_PHTD_IMP_DEFN_MTID| is for... +@ Finally, |ASSESSMENT_COMPLETE_IMP_DEFN_MTID| is called on the family when +everything has been assessed. -@e TO_PHTD_IMP_DEFN_MTID +@e ASSESSMENT_COMPLETE_IMP_DEFN_MTID = -VOID_METHOD_TYPE(TO_PHTD_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id, ph_type_data *phtd, wording XW, wording *OW) +VOID_METHOD_TYPE(ASSESSMENT_COMPLETE_IMP_DEFN_MTID, imperative_defn_family *f) -void ImperativeDefinitionFamilies::to_phtd(imperative_defn *id, ph_type_data *phtd, wording XW, wording *OW) { - VOID_METHOD_CALL(id->family, TO_PHTD_IMP_DEFN_MTID, id, phtd, XW, OW); +void ImperativeDefinitionFamilies::assessment_complete(imperative_defn_family *f) { + VOID_METHOD_CALL_WITHOUT_ARGUMENTS(f, ASSESSMENT_COMPLETE_IMP_DEFN_MTID); } -@ Whether phrases which end the current rulebook are allowed in the definition body. +@h What is allowed in the body. +The body of the definition can for the most part be any Inform 7 code, but +there are a few restrictions which depend on what the definition family is. + +|ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID| should reply |TRUE| if phrases +intended to end rules or rulebooks can be used in the body; by default, not. @e ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID = -INT_METHOD_TYPE(ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID, imperative_defn_family *f, imperative_defn *id) +INT_METHOD_TYPE(ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID, imperative_defn_family *f, + imperative_defn *id) int ImperativeDefinitionFamilies::goes_in_rulebooks(imperative_defn *id) { int rv = FALSE; @@ -138,8 +148,9 @@ int ImperativeDefinitionFamilies::goes_in_rulebooks(imperative_defn *id) { return rv; } -@ Whether the definition body can be empty (as when a definition of an adjective -does not go on to contain code). +@ |ALLOWS_EMPTY_IMP_DEFN_MTID| should reply |TRUE| if the body is allowed to +be empty, that is, for there to be no code at all. This happens for some +adjective definitions which wrap up in a single line. The default is no. @e ALLOWS_EMPTY_IMP_DEFN_MTID @@ -152,7 +163,8 @@ int ImperativeDefinitionFamilies::allows_empty(imperative_defn *id) { return rv; } -@ Whether the definition body can be given as |(-| inline |-)| material. +@ |ALLOWS_INLINE_IMP_DEFN_MTID| should reply |TRUE| if the definition body can +be given as |(-| inline |-)| material. The default is no. @e ALLOWS_INLINE_IMP_DEFN_MTID @@ -165,7 +177,10 @@ int ImperativeDefinitionFamilies::allows_inline(imperative_defn *id) { return rv; } -@ |COMPILE_IMP_DEFN_MTID| is for . +@h Compilation and indexing. +|COMPILE_IMP_DEFN_MTID| is called to ask the family to perform its main round +of compilation for any resources it will need -- most obviously, of course, +it may want to turn its definition bodies into Inter functions. @e COMPILE_IMP_DEFN_MTID @@ -179,7 +194,9 @@ void ImperativeDefinitionFamilies::compile(imperative_defn_family *f, total_phrases_compiled, total_phrases_to_compile); } -@ |COMPILE_IMP_DEFN_MTID| is for . +@ |COMPILE_AS_NEEDED_IMP_DEFN_MTID| is then called as an opportunity to +compile any remaining resources, and should pick up anything needed since the +last time it was called: note that it can be called multiple times. @e COMPILE_AS_NEEDED_IMP_DEFN_MTID @@ -193,7 +210,8 @@ void ImperativeDefinitionFamilies::compile_as_needed(imperative_defn_family *f, total_phrases_compiled, total_phrases_to_compile); } -@ |PHRASEBOOK_INDEX_IMP_DEFN_MTID| is for . +@ |PHRASEBOOK_INDEX_IMP_DEFN_MTID| should reply |TRUE| if the definition should +go into the Phrasebook page of the index. @e PHRASEBOOK_INDEX_IMP_DEFN_MTID diff --git a/inform7/assertions-module/Chapter 5/Imperative Definitions.w b/inform7/assertions-module/Chapter 5/Imperative Definitions.w index 6d118ec7e..4cabfacca 100644 --- a/inform7/assertions-module/Chapter 5/Imperative Definitions.w +++ b/inform7/assertions-module/Chapter 5/Imperative Definitions.w @@ -103,7 +103,8 @@ void ImperativeDefinitions::assess_all(void) { } else { phrase *body = Phrases::create_from_preamble(id); id->body_of_defn = body; - ImperativeDefinitionFamilies::given_body(id, body); + ImperativeDefinitionFamilies::given_body(id); + Phrases::prepare_stack_frame(body); } } if (initial_problem_count < problem_count) return; @@ -111,7 +112,7 @@ void ImperativeDefinitions::assess_all(void) { @ = imperative_defn_family *idf; LOOP_OVER(idf, imperative_defn_family) { - ImperativeDefinitionFamilies::register(idf, initial_problem_count); + ImperativeDefinitionFamilies::register(idf); if (initial_problem_count < problem_count) return; } @@ -125,7 +126,7 @@ void ImperativeDefinitions::assess_all(void) { @ = imperative_defn_family *idf; LOOP_OVER(idf, imperative_defn_family) { - ImperativeDefinitionFamilies::assessment_complete(idf, initial_problem_count); + ImperativeDefinitionFamilies::assessment_complete(idf); if (initial_problem_count < problem_count) return; } diff --git a/inform7/assertions-module/Chapter 5/Rule Family.w b/inform7/assertions-module/Chapter 5/Rule Family.w index 163c9588a..21407f12c 100644 --- a/inform7/assertions-module/Chapter 5/Rule Family.w +++ b/inform7/assertions-module/Chapter 5/Rule Family.w @@ -2,55 +2,107 @@ Imperative definitions of rules. -@ +@h Introduction. +This family handles definitions of rules which give explicit Inform 7 +source text to show what they do. (It's also possible to create rules which +are implemented by Inter-level functions only, and those do not fall under +this section, because they have no //imperative_defn//.) For example: += (text as Inform 7) +Every turn: + say "The grandfather clock ticks reprovingly." += +Some rules have names, some do not; some indicate explicitly what rulebook +they belong to, and others are placed in rulebooks with separate sentences. +So there's quite a lot to do. = -imperative_defn_family *RULE_EFF_family = NULL; /* "Before taking a container, ..." */ +imperative_defn_family *rule_idf = NULL; /* "Before taking a container, ..." */ +void RuleFamily::create_family(void) { + rule_idf = ImperativeDefinitionFamilies::new(I"rule-idf", FALSE); + METHOD_ADD(rule_idf, IDENTIFY_IMP_DEFN_MTID, RuleFamily::identify); + METHOD_ADD(rule_idf, ASSESS_IMP_DEFN_MTID, RuleFamily::assess); + METHOD_ADD(rule_idf, ASSESSMENT_COMPLETE_IMP_DEFN_MTID, RuleFamily::assessment_complete); + METHOD_ADD(rule_idf, ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID, RuleFamily::allows_rule_only); + METHOD_ADD(rule_idf, GIVEN_BODY_IMP_DEFN_MTID, RuleFamily::given_body); + METHOD_ADD(rule_idf, TO_RCD_IMP_DEFN_MTID, RuleFamily::to_rcd); + METHOD_ADD(rule_idf, COMPILE_IMP_DEFN_MTID, RuleFamily::compile); +} +@ Each family member gets one of the following. In splitting up preambles, +the "usage preamble" is the part indicating when the rule should happen, and +this is divided up into smaller excerpts of text, as in the following examples: += (text) +rule instead of taking or dropping when Miss Bianca is in the Embassy: +<---------------------------- usage_preamble -----------------------------------> + <- stem ----> <------------------ applicability ------------------> + <- ps -> <- bud -> <--- prewhile ---> <-------- whenwhile --------> + +after examining an open door during the Hurricane (this is the exit hunting rule): +<----------------- usage preamble -----------------> <- const name --> +<---- stem -----> <-- appl --> <- during --> +<- pruned stem -> <-- pw ----> += + += typedef struct rule_family_data { - struct wording reduced_stem; + struct wording usage_preamble; + struct wording pruned_stem; struct wording constant_name; - struct wording pattern; + struct wording prewhile_applicability; + struct wording applicability; + struct wording whenwhile; + struct parse_node *during_spec; /* what scene is currently under way */ + int not_in_rulebook; - int event_time; - struct wording event_name; - struct linked_list *uses_as_event; /* of |use_as_event| */ - struct wording rule_parameter; /* text of object or action parameter */ - struct wording whenwhile; /* when/while for action/activity rulebooks */ - #ifdef IF_MODULE - struct parse_node *during_scene_spec; /* what scene is currently under way */ - #endif + struct rule *defines; struct rulebook *owning_rulebook; /* the primary booking for the phrase will be here */ int owning_rulebook_placement; /* ...and with this placement value: see Rulebooks */ + + void *plugin_rfd[MAX_PLUGINS]; /* storage for plugins to attach, if they want to */ CLASS_DEFINITION } rule_family_data; -@ - -= -void RuleFamily::create_family(void) { - RULE_EFF_family = ImperativeDefinitionFamilies::new(I"RULE_EFF", FALSE); - METHOD_ADD(RULE_EFF_family, CLAIM_IMP_DEFN_MTID, RuleFamily::claim); - METHOD_ADD(RULE_EFF_family, ASSESS_IMP_DEFN_MTID, RuleFamily::assess); - METHOD_ADD(RULE_EFF_family, ASSESSMENT_COMPLETE_IMP_DEFN_MTID, RuleFamily::assessment_complete); - METHOD_ADD(RULE_EFF_family, ALLOWS_RULE_ONLY_PHRASES_IMP_DEFN_MTID, RuleFamily::allows_rule_only_phrases); - METHOD_ADD(RULE_EFF_family, NEW_PHRASE_IMP_DEFN_MTID, RuleFamily::new_phrase); - METHOD_ADD(RULE_EFF_family, TO_RCD_IMP_DEFN_MTID, RuleFamily::to_rcd); - METHOD_ADD(RULE_EFF_family, TO_PHTD_IMP_DEFN_MTID, RuleFamily::to_phtd); - METHOD_ADD(RULE_EFF_family, COMPILE_IMP_DEFN_MTID, RuleFamily::compile); +rule_family_data *RuleFamily::new_data(void) { + rule_family_data *rfd = CREATE(rule_family_data); + rfd->pruned_stem = EMPTY_WORDING; + rfd->constant_name = EMPTY_WORDING; + rfd->usage_preamble = EMPTY_WORDING; + rfd->applicability = EMPTY_WORDING; + rfd->prewhile_applicability = EMPTY_WORDING; + rfd->whenwhile = EMPTY_WORDING; + rfd->during_spec = NULL; + rfd->not_in_rulebook = FALSE; + rfd->defines = NULL; + rfd->owning_rulebook = NULL; + rfd->owning_rulebook_placement = MIDDLE_PLACEMENT; + for (int i=0; iplugin_rfd[i] = NULL; + return rfd; } -@ = +@ These two macros provide access to plugin-specific rule family data: + +@d RFD_PLUGIN_DATA(id, rfd) + ((id##_rfd_data *) rfd->plugin_rfd[id##_plugin->allocation_id]) + +@d CREATE_PLUGIN_RFD_DATA(id, rfd, creator) + (rfd)->plugin_rfd[id##_plugin->allocation_id] = (void *) (creator(rfd)); + +@h Identification. +We are going to claim as our own any definition whose name matches the +following nonterminal -- and because of the last production, this will always +happen. (That's why it is important that we are the last family to claim.) + += ::= - this is the {... rule} | ==> { 1, - } - this is the rule | ==> @ - this is ... rule | ==> @ - this is ... rules | ==> @ - ... ( this is the {... rule} ) | ==> { 2, - } - ... ( this is the rule ) | ==> @ - ... ( this is ... rule ) | ==> @ - ... ( this is ... rules ) | ==> @ - ... ==> { 3, - } + this is the {... rule} | ==> { 1, - } + this is the rule | ==> @ + this is ... rule | ==> @ + this is ... rules | ==> @ + ... ( this is the {... rule} ) | ==> { 2, - } + ... ( this is the rule ) | ==> @ + ... ( this is ... rule ) | ==> @ + ... ( this is ... rules ) | ==> @ + ... ==> { 3, - } @ = StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_NamelessRule), @@ -74,52 +126,15 @@ void RuleFamily::create_family(void) { "contain many rules at once."); ==> { FALSE, - } -@ = - ::= - at | ==> { pass 1 } - at the time when ... | ==> { NO_FIXED_TIME, - } - at the time that ... | ==> @ - at ... ==> @ - -@ = - StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_AtTimeThat), - "this seems to use 'that' where it should use 'when'", - "assuming it's trying to apply a rule to an event. (The convention is " - "that any rule beginning 'At' is a timed one. The time can either be a " - "fixed time, as in 'At 11:10 AM: ...', or the time when some named " - "event takes place, as in 'At the time when the clock chimes: ...'.)"); - -@ = - StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_AtWithoutTime), - "'at' what time? No description of a time is given", - "which means that this rule can never have effect. (The convention is " - "that any rule beginning 'At' is a timed one. The time can either be a " - "fixed time, as in 'At 11:10 AM: ...', or the time when some named " - "event takes place, as in 'At the time when the clock chimes: ...'.)"); - -@ +@ Forms 1 and 2 give a rule name; forms 2 and 3 say which rulebook it goes into. = -void RuleFamily::claim(imperative_defn_family *self, imperative_defn *id) { +void RuleFamily::identify(imperative_defn_family *self, imperative_defn *id) { wording W = Node::get_text(id->at); if ((W)) { int form = <>; - id->family = RULE_EFF_family; - rule_family_data *rfd = CREATE(rule_family_data); - rfd->not_in_rulebook = FALSE; - rfd->constant_name = EMPTY_WORDING; - rfd->pattern = EMPTY_WORDING; - rfd->event_time = NOT_A_TIMED_EVENT; - rfd->event_name = EMPTY_WORDING; - rfd->uses_as_event = NEW_LINKED_LIST(use_as_event); - rfd->rule_parameter = EMPTY_WORDING; - rfd->whenwhile = EMPTY_WORDING; - rfd->reduced_stem = EMPTY_WORDING; - #ifdef IF_MODULE - rfd->during_scene_spec = NULL; - #endif - rfd->owning_rulebook = NULL; - rfd->owning_rulebook_placement = MIDDLE_PLACEMENT; + id->family = rule_idf; + rule_family_data *rfd = RuleFamily::new_data(); if (form == 1) rfd->not_in_rulebook = TRUE; id->family_specific_data = STORE_POINTER_rule_family_data(rfd); @@ -137,52 +152,14 @@ void RuleFamily::claim(imperative_defn_family *self, imperative_defn *id) { Rules::obtain(RW, TRUE); } } - if ((form == 2) || (form == 3)) rfd->pattern = GET_RW(, 1); - if (form == 3) { - if ((W)) { - rfd->pattern = EMPTY_WORDING; - rfd->not_in_rulebook = TRUE; - rfd->event_time = <>; - if (rfd->event_time == NO_FIXED_TIME) - rfd->event_name = GET_RW(, 1); - } - } + if ((form == 2) || (form == 3)) rfd->usage_preamble = GET_RW(, 1); + + PluginCalls::new_rule_defn_notify(id, rfd); } } -@ = -void RuleFamily::assess(imperative_defn_family *self, imperative_defn *id) { - rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); - if (rfd->not_in_rulebook == FALSE) - @; -} - -void RuleFamily::assessment_complete(imperative_defn_family *self, int initial_problem_count) { - RuleBookings::make_automatic_placements(); - if (initial_problem_count < problem_count) return; - - SyntaxTree::traverse(Task::syntax_tree(), RuleFamily::visit_to_parse_placements); -} - -@ - -@e TRAVERSE_FOR_RULE_FILING_SMFT - -= -void RuleFamily::visit_to_parse_placements(parse_node *p) { - if ((Node::get_type(p) == SENTENCE_NT) && - (p->down) && - (Node::get_type(p->down) == VERB_NT)) { - prevailing_mood = Annotations::read_int(p->down, verbal_certainty_ANNOT); - MajorNodes::try_special_meaning(TRAVERSE_FOR_RULE_FILING_SMFT, p->down); - } -} - -int RuleFamily::allows_rule_only_phrases(imperative_defn_family *self, imperative_defn *id) { - return TRUE; -} - -@ Much later on, Inform returns to the definition to look at it in fine detail: +@h Assessment. +Now we take a closer look at the rule preamble. = ::= @@ -206,156 +183,155 @@ int RuleFamily::allows_rule_only_phrases(imperative_defn_family *self, imperativ rule about/for/on ... | ==> { TRUE, - } rule ==> { FALSE, - } -@ That's it for coarse mode. The rest is what happens in fine mode, which -affects rules giving a rulebook and some circumstances: - ->> Instead of taking a container: ... - -Here "Instead of" is the stem and "taking a container" the bud. - -@ = - wording W = rfd->pattern; - (W); - parse_node *during_spec = <>; - int form = <>; - rulebook_match *parsed_rm = Rulebooks::match(); - W = GET_RW(, 1); - if (form == NOT_APPLICABLE) { - (W); - } else { - if (form) rfd->whenwhile = GET_RW(, 2); - #ifdef IF_MODULE - rfd->during_scene_spec = during_spec; - #endif - rfd->owning_rulebook = parsed_rm->matched_rulebook; - if (rfd->owning_rulebook == NULL) internal_error("rulebook stem misparsed"); - rfd->owning_rulebook_placement = parsed_rm->placement_requested; - @; - @; - } - rfd->reduced_stem = W; - -@ The bud is not always present at all, and need not always be at the end -of the stem, so we have to be very careful: - -@ = - wording BUD = GET_RW(, 1); - int b1 = Wordings::first_wn(BUD), b2 = Wordings::last_wn(BUD); - if ((b1 == -1) || (b1 > b2)) { - b1 = parsed_rm->match_from + parsed_rm->advance_words; - b2 = parsed_rm->match_from + parsed_rm->advance_words - 1; - } - b2 -= parsed_rm->tail_words; - wording BW = Wordings::new(b1, b2); - wording CW = EMPTY_WORDING; - - if (parsed_rm->advance_words != parsed_rm->match_length) { - if (!(((BW)) && (<> == FALSE))) { - BW = Wordings::from(BW, parsed_rm->match_from + parsed_rm->match_length); - if ((BW)) { - if (<>) CW = GET_RW(, 1); - } else { - CW = BW; - } - } - } else { - if ((BW)) { - if (<>) CW = GET_RW(, 1); - } else { - CW = BW; - } - } - - if ((BW)) { - if (<>) CW = GET_RW(, 1); - } else if (parsed_rm->advance_words != parsed_rm->match_length) { - BW = Wordings::from(BW, parsed_rm->match_from + parsed_rm->match_length); - if ((BW)) { - if (<>) CW = GET_RW(, 1); - } else { - CW = BW; - } - } else { - CW = BW; - } - - if (Wordings::nonempty(CW)) rfd->rule_parameter = CW; - - if ((rfd->owning_rulebook) && - (Rulebooks::runs_during_activities(rfd->owning_rulebook) == FALSE) && - (Rulebooks::action_focus(rfd->owning_rulebook)) && - (Wordings::nonempty(rfd->rule_parameter)) && - (Wordings::nonempty(rfd->whenwhile))) { - rfd->rule_parameter = - Wordings::new(Wordings::first_wn(rfd->rule_parameter), - Wordings::last_wn(rfd->whenwhile)); - rfd->whenwhile = EMPTY_WORDING; - } - -@ If we can't find a stem, the following chooses which problem to issue: - -= ::= - when *** | ==> @ - ... ==> @ + when *** | ==> @ + ... ==> @ @ = Problems::quote_source(1, current_sentence); StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_BadRulePreambleWhen)); Problems::issue_problem_segment( - "The punctuation makes me think %1 should be a definition " - "of a phrase or a rule, but it doesn't begin as it should, " - "with either 'To' (e.g. 'To flood the riverplain:'), 'Definition:', " - "a name for a rule (e.g. 'This is the devilishly cunning rule:'), " - "'At' plus a time (e.g. 'At 11:12 PM:' or 'At the time when " - "the clock chimes:') or the name of a rulebook. %P" - "As your rule begins with 'When', it may be worth noting that in " - "December 2006 the syntax used by Inform for timed events changed: " - "the old syntax 'When the sky falls in:' to create a named " - "event, the sky falls in, became 'At the time when the sky " - "falls in:'. This was changed to avoid confusion with rules " - "relating to when scenes begin or end. %P" - "Or perhaps you meant to say that something would only happen " - "when some condition held. Inform often allows this, but the " - "'when...' part tends to be at the end, not up front - for " - "instance, 'Understand \"blue\" as the deep crevasse when the " - "location is the South Pole.'"); + "The punctuation makes me think %1 should be a definition of a phrase or a rule, " + "but it doesn't begin as it should, with either 'To' (e.g. 'To flood the riverplain:'), " + "'Definition:', a name for a rule (e.g. 'This is the devilishly cunning rule:'), " + "'At' plus a time (e.g. 'At 11:12 PM:' or 'At the time when the clock chimes:') or " + "the name of a rulebook. %P" + "Perhaps you meant to say that something would only happen when some condition held. " + "Inform often allows this, but the 'when...' part tends to be at the end, not up " + "front - for instance, 'Understand \"blue\" as the deep crevasse when the location " + "is the South Pole.'"); Problems::issue_problem_end(); @ = StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_BadRulePreamble), - "the punctuation here ':' makes me think this should be a definition " - "of a phrase and it doesn't begin as it should", - "with either 'To' (e.g. 'To flood the riverplain:'), 'Definition:', " - "a name for a rule (e.g. 'This is the devilishly cunning rule:'), " - "'At' plus a time (e.g. 'At 11:12 PM:' or 'At the time when " - "the clock chimes') or the name of a rulebook, possibly followed " - "by some description of the action or value to apply to (e.g. " + "the punctuation here ':' makes me think this should be a definition of a phrase " + "and it doesn't begin as it should", + "with either 'To' (e.g. 'To flood the riverplain:'), 'Definition:', a name for a " + "rule (e.g. 'This is the devilishly cunning rule:'), 'At' plus a time (e.g. 'At " + "11:12 PM:' or 'At the time when the clock chimes') or the name of a rulebook, " + "possibly followed by some description of the action or value to apply to (e.g. " "'Instead of taking something:' or 'Every turn:')."); -@ = - if ((parsed_rm->article_used == definite_article) && - (parsed_rm->placement_requested == MIDDLE_PLACEMENT)) - StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_RuleWithDefiniteArticle), - "a rulebook can contain any number of rules", - "so (e.g.) 'the before rule: ...' is disallowed; you should " - "write 'a before rule: ...' instead."); - -@ +@ The crucial nonterminal in the above grammar is , which tries +to make the longest match it can of a rulebook name; if it matches successfully, +then calling |Rulebooks::match| produces a detailed rundown of its findings, +which are too elaborate to pass back in a simple pointer. = -void RuleFamily::new_phrase(imperative_defn_family *self, imperative_defn *id, phrase *new_ph) { +void RuleFamily::assess(imperative_defn_family *self, imperative_defn *id) { rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); - if (rfd->not_in_rulebook) - RuleFamily::to_rule(id); - else - Rules::request_automatic_placement(RuleFamily::to_rule(id)); - new_ph->compile_with_run_time_debugging = TRUE; + if (rfd->not_in_rulebook == FALSE) { + wording W = rfd->usage_preamble; + (W); + parse_node *during_spec = <>; + int has_when = <>; + rulebook_match *parsed_rm = Rulebooks::match(); + W = GET_RW(, 1); + if (has_when == NOT_APPLICABLE) { + (W); + } else { + if (has_when) rfd->whenwhile = GET_RW(, 2); + rfd->during_spec = during_spec; + rfd->owning_rulebook = parsed_rm->matched_rulebook; + rfd->owning_rulebook_placement = parsed_rm->placement_requested; + @; + @; + @; + } + rfd->pruned_stem = W; + } } -@h The late-morning creations. -A little later on, we've made a rule phrase, and it now has a proper PHUD. -If the rule is an anonymous one, such as: +@ This is a super-pedantic problem message, and might cause problems in languages +other than English. + +@ = + if ((parsed_rm->article_used == definite_article) && + (parsed_rm->placement_requested == MIDDLE_PLACEMENT)) + StandardProblems::sentence_problem(Task::syntax_tree(), + _p_(PM_RuleWithDefiniteArticle), + "a rulebook can contain any number of rules", + "so (e.g.) 'the before rule: ...' is disallowed; you should write 'a before " + "rule: ...' instead."); + +@ The bud is not always present at all, and need not always be at the end of the stem, +so we have to be very careful: + +@ = + wording BUDW = GET_RW(, 1); + int b1 = Wordings::first_wn(BUDW), b2 = Wordings::last_wn(BUDW); + if ((b1 == -1) || (b1 > b2)) { + b1 = parsed_rm->match_from + parsed_rm->advance_words; + b2 = parsed_rm->match_from + parsed_rm->advance_words - 1; + } + b2 -= parsed_rm->tail_words; + BUDW = Wordings::new(b1, b2); + + wording APPW = EMPTY_WORDING; + + if (parsed_rm->advance_words != parsed_rm->match_length) { + if (!(((BUDW)) && (<> == FALSE))) { + BUDW = Wordings::from(BUDW, parsed_rm->match_from + parsed_rm->match_length); + if ((BUDW)) { + if (<>) APPW = GET_RW(, 1); + } else { + APPW = BUDW; + } + } + } else { + if ((BUDW)) { + if (<>) APPW = GET_RW(, 1); + } else { + APPW = BUDW; + } + } + + if ((BUDW)) { + if (<>) APPW = GET_RW(, 1); + } else if (parsed_rm->advance_words != parsed_rm->match_length) { + BUDW = Wordings::from(BUDW, parsed_rm->match_from + parsed_rm->match_length); + if ((BUDW)) { + if (<>) APPW = GET_RW(, 1); + } else { + APPW = BUDW; + } + } else { + APPW = BUDW; + } + + if (Wordings::nonempty(APPW)) { + rfd->applicability = APPW; + rfd->prewhile_applicability = APPW; + } + +@ This unobvious manoeuvre puts the when/while text back again, so that: += (text) +rule instead of taking or dropping when Miss Bianca is in the Embassy: + <----- appl -----> <---------- whenwhile -----------> + || +\||/ +rule instead of taking or dropping when Miss Bianca is in the Embassy: + <----- appl ----------------------------------------> += +This is done only where we now know that the stem specified a rulebook based +on actions, and the reason it's done is that action applicabilities are parsed +with a grammar much more sensitive to ambiguities, and in which "when..." +clauses are therefore better recognised. + +@ = + if ((rfd->owning_rulebook) && + (Rulebooks::runs_during_activities(rfd->owning_rulebook) == FALSE) && + (Rulebooks::action_focus(rfd->owning_rulebook)) && + (Wordings::nonempty(rfd->applicability)) && + (Wordings::nonempty(rfd->whenwhile))) { + rfd->applicability = + Wordings::new(Wordings::first_wn(rfd->applicability), + Wordings::last_wn(rfd->whenwhile)); + rfd->whenwhile = EMPTY_WORDING; + } + +@ Every rule corresponds to a |rule| structure. If the rule is an anonymous +one, such as: >> Instead of jumping: say "Don't." @@ -368,35 +344,31 @@ then we have a predeclared rule called "avoid water rule" already, so we connect this existing one to the phrase. = -rule *RuleFamily::to_rule(imperative_defn *id) { +void RuleFamily::given_body(imperative_defn_family *self, imperative_defn *id) { + rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); + rule *R = NULL; + @; + rfd->defines = R; +// if (rfd->not_in_rulebook == FALSE) Rules::request_automatic_placement(R); + + id->body_of_defn->compile_with_run_time_debugging = TRUE; + Phrases::TypeData::set_mor(&(id->body_of_defn->type_data), + DECIDES_NOTHING_AND_RETURNS_MOR, NULL); +} + +@ = rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); wording W = EMPTY_WORDING; int explicitly = FALSE; - @; - - rule *R = NULL; - if (Wordings::nonempty(W)) R = Rules::by_name(W); - if (R) @ - else R = Rules::obtain(W, explicitly); - if (Wordings::empty(W)) - Hierarchy::markup_wording(R->compilation_data.rule_package, RULE_NAME_HMD, Node::get_text(id->at)); - Rules::set_imperative_definition(R, id); - phrase *ph = id->body_of_defn; - package_request *P = RTRules::package(R); - ph->ph_iname = Hierarchy::make_localised_iname_in(RULE_FN_HL, P, ph->owning_module); - - @; - - return R; -} - -@ = - if (Wordings::nonempty(rfd->event_name)) { - W = Articles::remove_the(rfd->event_name); - } else if (Wordings::nonempty(rfd->constant_name)) { + if (Wordings::nonempty(rfd->constant_name)) { W = Articles::remove_the(rfd->constant_name); explicitly = TRUE; } + if (Wordings::nonempty(W)) R = Rules::by_name(W); + if (R) @ + else R = Rules::obtain(W, explicitly); + Rules::set_imperative_definition(R, id); + @; @ = imperative_defn *existing_id = Rules::get_imperative_definition(R); @@ -410,157 +382,109 @@ rule *RuleFamily::to_rule(imperative_defn *id) { Problems::issue_problem_end(); } -@ This is simply to make the rule's entry in the Index more helpful. - -@ = - wording IX = rfd->rule_parameter; +@ = + wording IX = rfd->applicability; if (Wordings::nonempty(rfd->whenwhile)) { - if (Wordings::first_wn(rfd->whenwhile) == Wordings::last_wn(rfd->rule_parameter) + 1) { - IX = Wordings::new(Wordings::first_wn(rfd->rule_parameter), Wordings::last_wn(rfd->whenwhile)); + if (Wordings::first_wn(rfd->whenwhile) == Wordings::last_wn(rfd->applicability) + 1) { + IX = Wordings::new(Wordings::first_wn(rfd->applicability), + Wordings::last_wn(rfd->whenwhile)); } else { IX = rfd->whenwhile; } } IXRules::set_italicised_index_text(R, IX); -@ = -int RuleFamily::get_timing_of_event(imperative_defn *id) { - if (id->family != RULE_EFF_family) return NOT_A_TIMED_EVENT; - rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); - return rfd->event_time; -} +@ At the end of the assessment process, we can finally put the rules into their +rulebooks. We make "automatic placements" first -- i.e., those where the usage +preamble specified which rulebook the rule belonged to; and then we make manual +placements, which may move or remove rules already place. See //Rule Placement Requests// +for how sentences specifying this are parsed. -@ For example, for the rule - ->> Instead of taking the box while the skylight is open: ... - -this returns "taking the box". +@e TRAVERSE_FOR_RULE_FILING_SMFT = -wording RuleFamily::get_prewhile_text(imperative_defn *id) { - if (id->family != RULE_EFF_family) return EMPTY_WORDING; - rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); - if (Wordings::nonempty(rfd->rule_parameter)) { - wording E = rfd->rule_parameter; - if ((E)) E = GET_RW(, 1); - return E; +void RuleFamily::assessment_complete(imperative_defn_family *self) { + imperative_defn *id; + LOOP_OVER(id, imperative_defn) + if (id->family == rule_idf) { + rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); + if (rfd->not_in_rulebook == FALSE) Rules::request_automatic_placement(rfd->defines); + } + + int initial_problem_count = problem_count; + RuleBookings::make_automatic_placements(); + if (initial_problem_count < problem_count) return; + + SyntaxTree::traverse(Task::syntax_tree(), RuleFamily::visit_to_parse_placements); +} + +void RuleFamily::visit_to_parse_placements(parse_node *p) { + if ((Node::get_type(p) == SENTENCE_NT) && + (p->down) && + (Node::get_type(p->down) == VERB_NT)) { + prevailing_mood = Annotations::read_int(p->down, verbal_certainty_ANNOT); + MajorNodes::try_special_meaning(TRAVERSE_FOR_RULE_FILING_SMFT, p->down); } - return EMPTY_WORDING; } -@ = - ::= - ... when/while ... - -@h Miscellaneous. -Some access routines. +@h Runtime context data. = -int RuleFamily::get_rulebook_placement(imperative_defn *id) { - if (id->family != RULE_EFF_family) return MIDDLE_PLACEMENT; - rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); - return rfd->owning_rulebook_placement; -} - -rulebook *RuleFamily::get_rulebook(imperative_defn *id) { - if (id->family != RULE_EFF_family) return NULL; - rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); - return rfd->owning_rulebook; -} - -void RuleFamily::set_rulebook(imperative_defn *id, rulebook *rb) { - if (id->family != RULE_EFF_family) internal_error("cannot set rulebook: not a rule"); - rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); - rfd->owning_rulebook = rb; -} - -linked_list *RuleFamily::get_uses_as_event(imperative_defn *id) { - if (id->family != RULE_EFF_family) return NULL; - rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); - return rfd->uses_as_event; -} - int NAP_problem_explained = FALSE; /* pertains to Named Action Patterns */ int issuing_ANL_problem = FALSE; /* pertains to Action Name Lists */ -void RuleFamily::to_rcd(imperative_defn_family *self, imperative_defn *id, ph_runtime_context_data *rcd) { +void RuleFamily::to_rcd(imperative_defn_family *self, imperative_defn *id, + ph_runtime_context_data *rcd) { rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); - if (rfd->not_in_rulebook) + if (rfd->not_in_rulebook) { rcd->permit_all_outcomes = TRUE; - else - @; + } else { + if (Wordings::nonempty(rfd->applicability)) + @; + if (Wordings::nonempty(rfd->whenwhile)) + rcd->activity_context = + Wordings::from(rfd->whenwhile, Wordings::first_wn(rfd->whenwhile) + 1); + if (rfd->during_spec) rcd->during_scene = rfd->during_spec; + } } -@ All of this is just dumb copying... +@ Here we try the text first without its when clause, then with, and accept +whichever way works. -@ = - - rcd->compile_for_rulebook = &(rfd->owning_rulebook); - - if (Wordings::nonempty(rfd->rule_parameter)) @; - - if (Wordings::nonempty(rfd->whenwhile)) { - rcd->activity_context = - Wordings::new( - Wordings::first_wn(rfd->whenwhile) + 1, - Wordings::last_wn(rfd->whenwhile)); - rcd->activity_where = current_sentence; - } - - #ifdef IF_MODULE - if (rfd->during_scene_spec) rcd->during_scene = rfd->during_scene_spec; - #endif - -@ ...except for this: - -@ = - #ifdef IF_MODULE +@ = if (Rulebooks::action_focus(rfd->owning_rulebook)) { - int saved = ParseActionPatterns::enter_mode(PERMIT_TRYING_OMISSION); - if (Rules::all_action_processing_variables()) - Frames::set_stvol( - Frames::current_stack_frame(), Rules::all_action_processing_variables()); - if ((rfd->rule_parameter)) rcd->ap = <>; - Frames::remove_nonphrase_stack_frame(); - ParseActionPatterns::restore_mode(saved); - - if (rcd->ap == NULL) - @; + rcd->ap = ActionPatterns::parse_action_based(rfd->applicability); + if (rcd->ap == NULL) @; } else { kind *pk = Rulebooks::get_focus_kind(rfd->owning_rulebook); - rcd->ap = ActionPatterns::parse_parametric(rfd->rule_parameter, pk); + rcd->ap = ActionPatterns::parse_parametric(rfd->applicability, pk); if (rcd->ap == NULL) { if (Wordings::nonempty(rfd->whenwhile)) { - wording F = Wordings::up_to(rfd->rule_parameter, Wordings::last_wn(rfd->whenwhile)); + wording F = Wordings::up_to(rfd->applicability, Wordings::last_wn(rfd->whenwhile)); rcd->ap = ActionPatterns::parse_parametric(F, pk); if (rcd->ap) { - rfd->rule_parameter = F; + rfd->applicability = F; rfd->whenwhile = EMPTY_WORDING; } } } if (rcd->ap == NULL) @; } - #endif - #ifndef IF_MODULE - kind *pk = Rulebooks::get_focus_kind(rfd->owning_rulebook); - @; - #endif -@ All that's left is to issue a "good" problem message, but this is quite -a large undertaking, because the situation as we currently know it is just -that something's wrong with the rule preamble -- which covers an enormous -range of different faults. +@ All that's left is to issue a "good" problem message, but this is quite a +large undertaking, because the situation as we currently know it is just that +something's wrong with the rule preamble -- which covers an enormous range of +different faults. -The "PAP failure reason" is a sort of error code set by the action pattern +The |pap_failure_reason| is a sort of error code set by the action pattern parser, recording how it most recently failed. @ = LOG("Bad action pattern: %W = $A\nPAP failure reason: %d\n", - rfd->rule_parameter, rcd->ap, pap_failure_reason); + rfd->applicability, rcd->ap, pap_failure_reason); Problems::quote_source(1, current_sentence); - Problems::quote_wording(2, rfd->rule_parameter); - if ((rfd->rule_parameter) == FALSE) + Problems::quote_wording(2, rfd->applicability); + if ((rfd->applicability) == FALSE) switch(pap_failure_reason) { case MIXEDNOUNS_PAPF: @; break; case NOPARTICIPLE_PAPF: @; break; @@ -572,47 +496,42 @@ parser, recording how it most recently failed. @ = StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_APWithDisjunction)); Problems::issue_problem_segment( - "You wrote %1, which seems to introduce a rule, but the " - "circumstances ('%2') seem to be too general for me to " - "understand in a single rule. I can understand a choice of " - "of actions, in a list such as 'taking or dropping the ball', " - "but there can only be one set of noun(s) supplied. So 'taking " - "the ball or taking the bat' is disallowed. You can get around " - "this by using named actions ('Taking the ball is being " - "mischievous. Taking the bat is being mischievous. Instead of " - "being mischievous...'), or it may be less bother just to " - "write more than one rule."); + "You wrote %1, which seems to introduce a rule, but the circumstances ('%2') seem " + "to be too general for me to understand in a single rule. I can understand a " + "choice of actions, in a list such as 'taking or dropping the ball', but there " + "can only be one set of noun(s) supplied. So 'taking the ball or taking the bat' " + "is disallowed. You can get around this by using named actions ('Taking the ball " + "is being mischievous. Taking the bat is being mischievous. Instead of being " + "mischievous...'), or it may be less bother just to write more than one rule."); Problems::issue_problem_end(); @ = StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_APWithNoParticiple)); Problems::issue_problem_segment( - "You wrote %1, which seems to introduce a rule taking effect " - "only '%2'. But this does not look like an action, since " - "there is no sign of a participle ending '-ing' (as in " - "'taking the brick', say) - which makes me think I have " - "badly misunderstood what you intended."); + "You wrote %1, which seems to introduce a rule taking effect only '%2'. But this " + "does not look like an action, since there is no sign of a participle ending '-ing' " + "(as in 'taking the brick', say) - which makes me think I have badly misunderstood " + "what you intended."); Problems::issue_problem_end(); @ = StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_APWithImmiscible)); Problems::issue_problem_segment( - "You wrote %1, which seems to introduce a rule taking effect " - "only '%2'. But this is a combination of actions which cannot " - "be mixed. The only alternatives where 'or' is allowed are " - "cases where a choice of actions is given but applying to " - "the same objects in each case. (So 'taking or dropping the " - "CD' is allowed, but 'dropping the CD or inserting the CD " - "into the jewel box' is not, because the alternatives there " - "would make different use of objects from each other.)"); + "You wrote %1, which seems to introduce a rule taking effect only '%2'. But this " + "is a combination of actions which cannot be mixed. The only alternatives where " + "'or' is allowed are cases where a choice of actions is given but applying to " + "the same objects in each case. (So 'taking or dropping the CD' is allowed, but " + "'dropping the CD or inserting the CD into the jewel box' is not, because the " + "alternatives there would make different use of objects from each other.)"); Problems::issue_problem_end(); @ = StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_APWithBadWhen)); - wording Q = rfd->rule_parameter; + wording Q = rfd->applicability; int diagnosis = 0; if ((Q)) { - Q = Wordings::new(<>, <>); + if (<> == 1) Q = GET_RW(, 3); + else Q = GET_RW(, 2); diagnosis = <>; } Problems::quote_wording(2, Q); @@ -628,30 +547,30 @@ parser, recording how it most recently failed. "(Whereas 'no room' is usually allowed.)"); } Problems::issue_problem_segment( - "You wrote %1, which seems to introduce a rule taking effect " - "only '%2'. But this condition did not make sense, %3"); + "You wrote %1, which seems to introduce a rule taking effect only '%2'. But this " + "condition did not make sense, %3"); if (diagnosis == 1) Problems::issue_problem_segment( "%PIt might be worth mentioning that a 'when' condition tacked on to " "an action like this is not allowed to mention or use 'called' values."); if (diagnosis == 4) Problems::issue_problem_segment( - "%PThe problem might be that 'and' has been followed by 'when' or " - "'while'. For example, to make a rule with two conditions, this is " - "okay: 'Instead of jumping when Peter is happy and Peter is in the " - "location'; but the same thing with '...and when Peter is...' is not allowed."); + "%PThe problem might be that 'and' has been followed by 'when' or 'while'. " + "For example, to make a rule with two conditions, this is okay: 'Instead of " + "jumping when Peter is happy and Peter is in the location'; but the same thing " + "with '...and when Peter is...' is not allowed."); Problems::issue_problem_end(); @ = - Problems::quote_wording(2, rfd->rule_parameter); + Problems::quote_wording(2, rfd->applicability); if (pap_failure_reason == WHENOKAY_PAPF) Problems::quote_text(3, "The part after 'when' (or 'while') was fine, but the earlier words"); else Problems::quote_text(3, "But that"); StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_APUnknown)); Problems::issue_problem_segment( - "You wrote %1, which seems to introduce a rule taking effect only if the " - "action is '%2'. %3 did not make sense as a description of an action."); + "You wrote %1, which seems to introduce a rule taking effect only if the action " + "is '%2'. %3 did not make sense as a description of an action."); @; @; @; @@ -662,44 +581,42 @@ parser, recording how it most recently failed. @ = action_name *an; LOOP_OVER(an, action_name) - if ((Wordings::length(rfd->rule_parameter) < Wordings::length(ActionNameNames::tensed(an, IS_TENSE))) && - (Wordings::match(rfd->rule_parameter, - Wordings::truncate(ActionNameNames::tensed(an, IS_TENSE), Wordings::length(rfd->rule_parameter))))) { + if ((Wordings::length(rfd->applicability) < + Wordings::length(ActionNameNames::tensed(an, IS_TENSE))) && + (Wordings::match(rfd->applicability, + Wordings::truncate(ActionNameNames::tensed(an, IS_TENSE), + Wordings::length(rfd->applicability))))) { Problems::quote_wording(3, ActionNameNames::tensed(an, IS_TENSE)); Problems::issue_problem_segment( - " I notice that there's an action called '%3', though: perhaps " - "this is what you meant?"); + " I notice that there's an action called '%3', though: perhaps this is " + "what you meant?"); break; } @ = if (pap_failure_reason == WHENOKAY_PAPF) { - time_period *duration = Occurrence::parse(rfd->reduced_stem); + time_period *duration = Occurrence::parse(rfd->pruned_stem); if (duration) { Problems::quote_wording(3, Occurrence::used_wording(duration)); Problems::issue_problem_segment( - " (I wonder if this might be because '%3', which looks like a " - "condition on the timing, is the wrong side of the 'when...' " - "clause?)"); + " (I wonder if this might be because '%3', which looks like a condition " + "on the timing, is the wrong side of the 'when...' clause?)"); } } -@ If the action pattern contains what looks like a list of action names, as -for example - ->> Instead of taking or dropping the magnet: ... - -then the anl-diagnosis grammar will parse this and return N equal to 2, the -apparent number of action names. We then run the grammar again, but this time -allowing it to print comments on each apparent action name it sees. +@ If the action pattern contains what looks like a list of action names, as for example +"Instead of taking or dropping the magnet: ..." then the grammar will + parse this and return N equal to 2, the apparent number of action names. We then + run the grammar again, but this time allowing it to print comments on each apparent + action name it sees. @ = issuing_ANL_problem = FALSE; NAP_problem_explained = FALSE; - (rfd->rule_parameter); + (rfd->applicability); int N = <>; if (N > 1) { int positive = TRUE; - ActionNameLists::parse(rfd->rule_parameter, IS_TENSE, &positive); + ActionNameLists::parse(rfd->applicability, IS_TENSE, &positive); if (positive == FALSE) Problems::issue_problem_segment( " This looks like a list of actions to avoid: "); @@ -707,7 +624,7 @@ allowing it to print comments on each apparent action name it sees. Problems::issue_problem_segment( " Looking at this as a list of alternative actions: "); issuing_ANL_problem = TRUE; NAP_problem_explained = FALSE; - (rfd->rule_parameter); + (rfd->applicability); Problems::issue_problem_segment(" so"); } @@ -716,9 +633,9 @@ the only possible problem is that the value was wrong. @ = Problems::quote_source(1, current_sentence); - Problems::quote_wording(2, rfd->rule_parameter); + Problems::quote_wording(2, rfd->applicability); Problems::quote_kind(3, pk); - (rfd->reduced_stem); + (rfd->pruned_stem); @ And that is the end of the code as such, but we still have to define the three diagnosis grammars we needed. @@ -729,21 +646,20 @@ is used to choose a problem message if the value makes no sense. = ::= when the play begins/ends | ==> @ - ... ==> @ + ... ==> @ @ = StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_WhenThePlay), "there's no scene called 'the play'", - "so I think you need to remove 'the' - Inform has two " - "special rulebooks, 'When play begins' and 'When play ends', " - "and I think you probably mean to refer to one of those."); + "so I think you need to remove 'the' - Inform has two special rulebooks, 'When " + "play begins' and 'When play ends', and I think you probably mean to refer to " + "one of those."); @ = StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_BadParameter)); Problems::issue_problem_segment( - "You wrote %1, but the description of the thing(s) to which the rule " - "applies ('%2') did not make sense. This is %3 based rulebook, so " - "that should have described %3."); + "You wrote %1, but the description of the thing(s) to which the rule applies ('%2') " + "did not make sense. This is %3 based rulebook, so that should have described %3."); Problems::issue_problem_end(); @ And here we choose a problem message if a rule applying to an action is used, @@ -752,30 +668,26 @@ but the action isn't one we recognise. = ::= in the presence of ... | ==> @ - in ... ==> @ + in ... ==> @ @ = StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_NonActionInPresenceOf)); Problems::issue_problem_segment( - "You wrote %1, but 'in the presence of...' is a clause which can " - "only be used to talk about an action: so, for instance, 'waiting " - "in the presence of...' is needed. " - "This problem arises especially with 'every turn' rules, where " - "'every turn in the presence of...' looks plausible but doesn't " - "work. This could be fixed by writing 'Every turn doing something " - "in the presence of...', but a neater solution talks about the " - "current situation instead: 'Every turn when the player can " - "see...'."); + "You wrote %1, but 'in the presence of...' is a clause which can only be used to " + "talk about an action: so, for instance, 'waiting in the presence of...' is needed. " + "This problem arises especially with 'every turn' rules, where 'every turn in the " + "presence of...' looks plausible but doesn't work. This could be fixed by writing " + "'Every turn doing something in the presence of...', but a neater solution talks " + "about the current situation instead: 'Every turn when the player can see...'."); Problems::issue_problem_end(); @ = StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_NonActionIn)); Problems::issue_problem_segment( - "You wrote %1, but 'in...' used in this way should really belong " - "to an action: for instance, 'Before waiting in the Library'. " - "Rules like 'Every turn in the Library' don't work, because " - "'every turn' is not an action; what's wanted is 'Every turn " + "You wrote %1, but 'in...' used in this way should really belong to an action: for " + "instance, 'Before waiting in the Library'. Rules like 'Every turn in the Library' " + "don't work, because 'every turn' is not an action; what's wanted is 'Every turn " "when in the Library'."); Problems::issue_problem_end(); @@ -786,13 +698,12 @@ might have gone wrong. = ::= - ... called ... {when/while ...} | ==> { 1, -, <> = Wordings::first_wn(WR[3]), <> = Wordings::last_wn(WR[3]) } - ... {when/while *** nothing ***} | ==> { 2, -, <> = Wordings::first_wn(WR[2]), <> = Wordings::last_wn(WR[2]) } - ... {when/while *** nowhere ***} | ==> { 3, -, <> = Wordings::first_wn(WR[2]), <> = Wordings::last_wn(WR[2]) } - ... and {when/while ...} | ==> { 4, -, <> = Wordings::first_wn(WR[2]), <> = Wordings::last_wn(WR[2]) } - ... {when/while ...} ==> { 5, -, <> = Wordings::first_wn(WR[2]), <> = Wordings::last_wn(WR[2]) } + ... called ... {when/while ...} | ==> { 1, - } + ... {when/while *** nothing ***} | ==> { 2, - } + ... {when/while *** nowhere ***} | ==> { 3, - } + ... and {when/while ...} | ==> { 4, - } + ... {when/while ...} ==> { 5, - } -@ = ::= when/while ... | ==> { pass 1 } ==> { pass 1 } @@ -806,12 +717,11 @@ might have gone wrong. _,/or ==> { pass 1 } ::= - ...... ==> @ + ...... ==> @ @ = if ((issuing_ANL_problem) && (!preform_lookahead_mode)) { Problems::quote_wording(4, W); - #ifdef IF_MODULE if ((W) == FALSE) { Problems::issue_problem_segment("'%4' did not make sense; "); return TRUE; @@ -848,18 +758,16 @@ might have gone wrong. "which isn't allowed in a list like this; "); return TRUE; } - #endif Problems::issue_problem_segment("'%4' was okay; "); } ==> { 1, - }; -@ +@h Compilation. +We compile these in rulebook order first, and then pick up any rules not in +rulebooks. This is really just to make the Inter output tidily arranged; +any order would have done just as well. = -void RuleFamily::to_phtd(imperative_defn_family *self, imperative_defn *id, ph_type_data *phtd, wording XW, wording *OW) { - Phrases::TypeData::set_mor(phtd, DECIDES_NOTHING_AND_RETURNS_MOR, NULL); -} - void RuleFamily::compile(imperative_defn_family *self, int *total_phrases_compiled, int total_phrases_to_compile) { rulebook *rb; @@ -871,3 +779,34 @@ void RuleFamily::compile(imperative_defn_family *self, RTRules::compile_definition(R, total_phrases_compiled, total_phrases_to_compile); } + +@h Miscellaneous access functions. + += +wording RuleFamily::get_prewhile_text(imperative_defn *id) { + if (id->family != rule_idf) return EMPTY_WORDING; + rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); + return rfd->prewhile_applicability; +} + +int RuleFamily::get_rulebook_placement(imperative_defn *id) { + if (id->family != rule_idf) return MIDDLE_PLACEMENT; + rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); + return rfd->owning_rulebook_placement; +} + +rulebook *RuleFamily::get_rulebook(imperative_defn *id) { + if (id->family != rule_idf) return NULL; + rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); + return rfd->owning_rulebook; +} + +void RuleFamily::set_rulebook(imperative_defn *id, rulebook *rb) { + if (id->family != rule_idf) internal_error("cannot set rulebook: not a rule"); + rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); + rfd->owning_rulebook = rb; +} + +int RuleFamily::allows_rule_only(imperative_defn_family *self, imperative_defn *id) { + return TRUE; +} diff --git a/inform7/assertions-module/Chapter 5/To Phrase Family.w b/inform7/assertions-module/Chapter 5/To Phrase Family.w index d1fa4a375..2b07eee39 100644 --- a/inform7/assertions-module/Chapter 5/To Phrase Family.w +++ b/inform7/assertions-module/Chapter 5/To Phrase Family.w @@ -14,6 +14,7 @@ typedef struct to_family_data { struct wording pattern; struct wording prototype_text; struct wording constant_name; + struct wording ph_documentation_symbol; /* the documentation reference, if any */ struct constant_phrase *constant_phrase_holder; int explicit_name_used_in_maths; /* if so, this flag means it's like |log()| or |sin()| */ struct wording explicit_name_for_inverse; /* e.g. |exp| for |log| */ @@ -26,12 +27,11 @@ typedef struct to_family_data { = void ToPhraseFamily::create_family(void) { TO_PHRASE_EFF_family = ImperativeDefinitionFamilies::new(I"TO_PHRASE_EFF", TRUE); - METHOD_ADD(TO_PHRASE_EFF_family, CLAIM_IMP_DEFN_MTID, ToPhraseFamily::claim); + METHOD_ADD(TO_PHRASE_EFF_family, IDENTIFY_IMP_DEFN_MTID, ToPhraseFamily::claim); METHOD_ADD(TO_PHRASE_EFF_family, ASSESS_IMP_DEFN_MTID, ToPhraseFamily::assess); METHOD_ADD(TO_PHRASE_EFF_family, REGISTER_IMP_DEFN_MTID, ToPhraseFamily::register); - METHOD_ADD(TO_PHRASE_EFF_family, NEW_PHRASE_IMP_DEFN_MTID, ToPhraseFamily::new_phrase); + METHOD_ADD(TO_PHRASE_EFF_family, GIVEN_BODY_IMP_DEFN_MTID, ToPhraseFamily::given_body); METHOD_ADD(TO_PHRASE_EFF_family, ALLOWS_INLINE_IMP_DEFN_MTID, ToPhraseFamily::allows_inline); - METHOD_ADD(TO_PHRASE_EFF_family, TO_PHTD_IMP_DEFN_MTID, ToPhraseFamily::to_phtd); METHOD_ADD(TO_PHRASE_EFF_family, COMPILE_IMP_DEFN_MTID, ToPhraseFamily::compile); METHOD_ADD(TO_PHRASE_EFF_family, COMPILE_AS_NEEDED_IMP_DEFN_MTID, ToPhraseFamily::compile_as_needed); METHOD_ADD(TO_PHRASE_EFF_family, PHRASEBOOK_INDEX_IMP_DEFN_MTID, ToPhraseFamily::include_in_Phrasebook_index); @@ -83,13 +83,15 @@ void ToPhraseFamily::claim(imperative_defn_family *self, imperative_defn *id) { "because it already has a meaning."); } else { tfd->constant_name = RW; - if (Phrases::Constants::parse(RW) == NULL) - Phrases::Constants::create(RW, GET_RW(, 1)); + if (ToPhraseFamily::parse_constant(RW) == NULL) + ToPhraseFamily::create_constant(RW, GET_RW(, 1)); } if ((form == 1) || (form == 2)) tfd->explicit_name_used_in_maths = TRUE; if (form == 1) tfd->explicit_name_for_inverse = Wordings::first_word(GET_RW(, 3)); } - tfd->prototype_text = GET_RW(, 1); + wording PW = GET_RW(, 1); + tfd->ph_documentation_symbol = Index::DocReferences::position_of_symbol(&PW); + tfd->prototype_text = PW; } } @@ -136,9 +138,9 @@ mode, we can get that value back again if we look it up by name. @ = wording NW = tfd->constant_name; - constant_phrase *cphr = Phrases::Constants::parse(NW); + constant_phrase *cphr = ToPhraseFamily::parse_constant(NW); if (Kinds::Behaviour::definite(cphr->cphr_kind) == FALSE) { - phrase *ph = Phrases::Constants::as_phrase(cphr); + phrase *ph = ToPhraseFamily::body_of_constant(cphr); if (ph) current_sentence = Phrases::declaration_node(ph); Problems::quote_source(1, Diagrams::new_UNPARSED_NOUN(Nouns::nominative_singular(cphr->name))); Problems::quote_wording(2, Nouns::nominative_singular(cphr->name)); @@ -158,24 +160,26 @@ mode, we can get that value back again if we look it up by name. @ = -void ToPhraseFamily::register(imperative_defn_family *self, int initial_problem_count) { +void ToPhraseFamily::register(imperative_defn_family *self) { Routines::ToPhrases::register_all(); } -void ToPhraseFamily::new_phrase(imperative_defn_family *self, imperative_defn *id, phrase *new_ph) { +void ToPhraseFamily::given_body(imperative_defn_family *self, imperative_defn *id) { to_family_data *tfd = RETRIEVE_POINTER_to_family_data(id->family_specific_data); - if (tfd->to_begin) new_ph->to_begin = TRUE; - Routines::ToPhrases::new(new_ph); + if (tfd->to_begin) id->body_of_defn->to_begin = TRUE; + + wording XW = ToPhraseFamily::get_prototype_text(id); + wording OW = EMPTY_WORDING; + Phrases::TypeData::Textual::parse(&(id->body_of_defn->type_data), XW, &OW); + Phrases::Options::parse_declared_options(&(id->body_of_defn->options_data), OW); + + Routines::ToPhrases::new(id->body_of_defn); } int ToPhraseFamily::allows_inline(imperative_defn_family *self, imperative_defn *id) { return TRUE; } -void ToPhraseFamily::to_phtd(imperative_defn_family *self, imperative_defn *id, ph_type_data *phtd, wording XW, wording *OW) { - Phrases::TypeData::Textual::parse(phtd, XW, OW); -} - int ToPhraseFamily::include_in_Phrasebook_index(imperative_defn_family *self, imperative_defn *id) { return TRUE; } @@ -224,6 +228,12 @@ wording ToPhraseFamily::get_equation_form(imperative_defn *id) { return EMPTY_WORDING; } +wording ToPhraseFamily::doc_ref(imperative_defn *id) { + if (id->family != TO_PHRASE_EFF_family) return EMPTY_WORDING; + to_family_data *tfd = RETRIEVE_POINTER_to_family_data(id->family_specific_data); + return tfd->ph_documentation_symbol; +} + @h Extracting the stem. A couple of routines to read but not really parse the stem and the bud. @@ -369,3 +379,85 @@ void ToPhraseFamily::compile_as_needed(imperative_defn_family *self, repeat = TRUE; } } + +@ A few "To..." phrases have names, and can therefore be used as values in their +own right, a functional-programming sort of device. For example: + +>> To decide what number is double (N - a number) (this is doubling): + +has the name "doubling". Such a name is recorded here: + += +typedef struct constant_phrase { + struct noun *name; + struct phrase *phrase_meant; /* if known at this point */ + struct kind *cphr_kind; /* ditto */ + struct inter_name *cphr_iname; + struct wording associated_preamble_text; + CLASS_DEFINITION +} constant_phrase; + +@ Here we create a new named phrase ("doubling", say): + += +constant_phrase *ToPhraseFamily::create_constant(wording NW, wording RW) { + constant_phrase *cphr = CREATE(constant_phrase); + cphr->phrase_meant = NULL; /* we won't know until later */ + cphr->cphr_kind = NULL; /* nor this */ + cphr->associated_preamble_text = RW; + cphr->name = Nouns::new_proper_noun(NW, NEUTER_GENDER, ADD_TO_LEXICON_NTOPT, + PHRASE_CONSTANT_MC, Rvalues::from_constant_phrase(cphr), Task::language_of_syntax()); + cphr->cphr_iname = NULL; + return cphr; +} + +@ ...and parse for an existing one: + += +constant_phrase *ToPhraseFamily::parse_constant(wording NW) { + if ((NW)) { + parse_node *spec = <>; + if (Rvalues::is_CONSTANT_construction(spec, CON_phrase)) { + constant_phrase *cphr = Rvalues::to_constant_phrase(spec); + ToPhraseFamily::kind(cphr); + return cphr; + } + } + return NULL; +} + +@ As often happens with Inform constants, the kind of a constant phrase can't +be known when its name first comes up, and must be filled in later. (In +particular, before the second traverse many kinds do not yet exist.) So +the following takes a patch-it-later approach. + += +kind *ToPhraseFamily::kind(constant_phrase *cphr) { + if (cphr == NULL) return NULL; + if (global_pass_state.pass < 2) return Kinds::binary_con(CON_phrase, K_value, K_value); + if (cphr->cphr_kind == NULL) { + wording OW = EMPTY_WORDING; + ph_type_data phtd = Phrases::TypeData::new(); + Phrases::TypeData::Textual::parse(&phtd, + cphr->associated_preamble_text, &OW); + cphr->cphr_kind = Phrases::TypeData::kind(&phtd); + } + return cphr->cphr_kind; +} + +@ And similarly for the |phrase| structure this name corresponds to. + += +phrase *ToPhraseFamily::body_of_constant(constant_phrase *cphr) { + if (cphr == NULL) internal_error("null cphr"); + if (cphr->phrase_meant == NULL) { + imperative_defn *id; + LOOP_OVER(id, imperative_defn) { + if (ToPhraseFamily::constant_phrase(id) == cphr) { + cphr->phrase_meant = id->body_of_defn; + break; + } + } + } + return cphr->phrase_meant; +} diff --git a/inform7/core-module/Chapter 1/Class Predeclarations.w b/inform7/core-module/Chapter 1/Class Predeclarations.w index e134b0182..0e99201fd 100644 --- a/inform7/core-module/Chapter 1/Class Predeclarations.w +++ b/inform7/core-module/Chapter 1/Class Predeclarations.w @@ -22,6 +22,7 @@ DECLARE_CLASS(compile_task_data) @e adjective_meaning_family_CLASS @e application_CLASS @e by_routine_bp_data_CLASS +@e constant_phrase_CLASS @e equivalence_bp_data_CLASS @e explicit_bp_data_CLASS @e generalisation_CLASS @@ -41,6 +42,7 @@ DECLARE_CLASS(compile_task_data) DECLARE_CLASS(adjective_meaning) DECLARE_CLASS(adjective_meaning_family) DECLARE_CLASS_ALLOCATED_IN_ARRAYS(application, 100) +DECLARE_CLASS(constant_phrase) DECLARE_CLASS(generalisation) DECLARE_CLASS(by_routine_bp_data) DECLARE_CLASS(equivalence_bp_data) @@ -159,7 +161,6 @@ DECLARE_CLASS(value_property_data) @ //imperative// -- -@e constant_phrase_CLASS @e invocation_options_CLASS @e local_variable_CLASS @e past_tense_action_record_CLASS @@ -170,10 +171,8 @@ DECLARE_CLASS(value_property_data) @e phrase_option_CLASS @e pointer_allocation_CLASS @e to_phrase_request_CLASS -@e use_as_event_CLASS = -DECLARE_CLASS(constant_phrase) DECLARE_CLASS_ALLOCATED_IN_ARRAYS(invocation_options, 100) DECLARE_CLASS_ALLOCATED_IN_ARRAYS(local_variable, 100) DECLARE_CLASS(past_tense_action_record) @@ -184,7 +183,6 @@ DECLARE_CLASS(phrase) DECLARE_CLASS_ALLOCATED_IN_ARRAYS(phrase_option, 100) DECLARE_CLASS(pointer_allocation) DECLARE_CLASS(to_phrase_request) -DECLARE_CLASS(use_as_event) @ //runtime// -- @@ -276,6 +274,7 @@ DECLARE_CLASS(rubric_holder) @e release_instructions_CLASS @e scene_CLASS @e spatial_data_CLASS +@e timed_rules_rfd_data_CLASS @e anl_clause_CLASS @e anl_entry_CLASS @@ -310,6 +309,7 @@ DECLARE_CLASS(regions_data) DECLARE_CLASS(release_instructions) DECLARE_CLASS(scene) DECLARE_CLASS(spatial_data) +DECLARE_CLASS(timed_rules_rfd_data) DECLARE_CLASS_ALLOCATED_IN_ARRAYS(anl_clause, 1000) DECLARE_CLASS_ALLOCATED_IN_ARRAYS(anl_entry, 1000) diff --git a/inform7/core-module/Chapter 1/How To Compile.w b/inform7/core-module/Chapter 1/How To Compile.w index 125b03aea..cc9e0211e 100644 --- a/inform7/core-module/Chapter 1/How To Compile.w +++ b/inform7/core-module/Chapter 1/How To Compile.w @@ -243,9 +243,6 @@ so on. Those absolute basics are made here. BENCH(Phrases::Constants::compile_closures) BENCH(RTKinds::compile_structures) BENCH(Rules::check_response_usages) - BENCH(Phrases::Timed::check_for_unused) - BENCH(Phrases::Timed::TimedEventsTable) - BENCH(Phrases::Timed::TimedEventTimesTable) BENCH(RTUseOptions::configure_template) BENCH(RTBibliographicData::IFID_text); diff --git a/inform7/core-module/Chapter 3/Plugin Calls.w b/inform7/core-module/Chapter 3/Plugin Calls.w index f8fc7db34..2f178330f 100644 --- a/inform7/core-module/Chapter 3/Plugin Calls.w +++ b/inform7/core-module/Chapter 3/Plugin Calls.w @@ -196,6 +196,16 @@ int PluginCalls::variable_set_warning(nonlocal_variable *q, parse_node *val) { PLUGINS_CALL(VARIABLE_VALUE_NOTIFY_PLUG, q, val); } +@ Called from //assertions: Rule Family// to warn plugins that a new rule +definition has been found in the source text. + +@e NEW_RULE_DEFN_NOTIFY_PLUG + += +int PluginCalls::new_rule_defn_notify(imperative_defn *id, rule_family_data *rfd) { + PLUGINS_CALL(NEW_RULE_DEFN_NOTIFY_PLUG, id, rfd); +} + @h Influencing values. Called from //values: Rvalues// to allow plugins to help decide whether values of the same kind would be equal if evaluated at runtime. For example, the @@ -466,6 +476,17 @@ int PluginCalls::compile_test_tail(phrase *ph, rule *R) { PLUGINS_CALL(COMPILE_TEST_TAIL_PLUG, ph, R); } +@ Called from //imperative: Compile Invocations Inline//, but only when an +annotation arises which the regular machinery doesn't know how to handle. +This is currently only used by //if: Timed Rules//. + +@e INLINE_ANNOTATION_PLUG + += +int PluginCalls::nonstandard_inline_annotation(int annot, parse_node *supplied) { + PLUGINS_CALL(INLINE_ANNOTATION_PLUG, annot, supplied); +} + @h Influencing the actions plugin. We now have a whole run of functions called only by the actions plugin, and therefore only when it is active. diff --git a/inform7/if-module/Chapter 1/IF Module.w b/inform7/if-module/Chapter 1/IF Module.w index 55c3915d6..93926176d 100644 --- a/inform7/if-module/Chapter 1/IF Module.w +++ b/inform7/if-module/Chapter 1/IF Module.w @@ -79,7 +79,7 @@ plugin *actions_plugin, *going_plugin, *backdrops_plugin, *bibliographic_plugin, *chronology_plugin, *devices_plugin, *map_plugin, *parsing_plugin, *persons_plugin, *player_plugin, *regions_plugin, *scenes_plugin, *scoring_plugin, *showme_plugin, *spatial_plugin, - *times_plugin; + *timed_rules_plugin, *times_plugin; @ = void IFModule::create_plugins(void) { @@ -98,6 +98,7 @@ void IFModule::create_plugins(void) { regions_plugin = PluginManager::new(&Regions::start, I"regions", ifp); scenes_plugin = PluginManager::new(&Scenes::start, I"scenes", ifp); scoring_plugin = PluginManager::new(&TheScore::start, I"scoring", ifp); + timed_rules_plugin = PluginManager::new(TimedRules::start, I"timed rules", ifp); times_plugin = PluginManager::new(TimesOfDay::start, I"times of day", ifp); actions_plugin = PluginManager::new(&ActionsPlugin::start, I"actions", ifp); diff --git a/inform7/if-module/Chapter 3/Timed Rules.w b/inform7/if-module/Chapter 3/Timed Rules.w new file mode 100644 index 000000000..e025df2cd --- /dev/null +++ b/inform7/if-module/Chapter 3/Timed Rules.w @@ -0,0 +1,171 @@ +[TimedRules::] Timed Rules. + +A plugin to support rules like "At 12:03AM: ...". + +@ This plugin makes a special set of rules for timed events; the |:timedrules| +test group may be useful in testing it. + +Each such rule has a time at which it should spontaneously happen. This is +ordinarily a time of day, such as "At 9:00 AM: ...", represented by a number +from 0 to 1439, measuring minutes since midnight. These negative values have +special significance: + +@d NOT_A_TIMED_EVENT -1 /* as for the vast majority of rules */ +@d NO_FIXED_TIME -2 /* for phrases like "When the clock strikes: ..." */ +@d NOT_AN_EVENT -3 /* not even syntactically */ + += +void TimedRules::start(void) { + PluginManager::plug(NEW_RULE_DEFN_NOTIFY_PLUG, TimedRules::new_rule_defn_notify); + PluginManager::plug(INLINE_ANNOTATION_PLUG, TimedRules::inline_annotation); + PluginManager::plug(PRODUCTION_LINE_PLUG, TimedRules::production_line); +} + +int TimedRules::production_line(int stage, int debugging, stopwatch_timer *sequence_timer) { + if (stage == INTER5_CSEQ) { + BENCH(TimedRules::check_for_unused) + BENCH(RTTimedRules::TimedEventsTable) + BENCH(RTTimedRules::TimedEventTimesTable) + } + return FALSE; +} + +@ Event rules are recognised by the initial word "At": + += + ::= + at | ==> { pass 1 } + at the time when ... | ==> { NO_FIXED_TIME, - } + at the time that ... | ==> @ + at ... ==> @ + +@ = + StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_AtTimeThat), + "this seems to use 'that' where it should use 'when'", + "assuming it's trying to apply a rule to an event. (The convention is that any " + "rule beginning 'At' is a timed one. The time can either be a fixed time, as in " + "'At 11:10 AM: ...', or the time when some named event takes place, as in 'At the " + "time when the clock chimes: ...'.)"); + +@ = + StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_AtWithoutTime), + "'at' what time? No description of a time is given", + "which means that this rule can never have effect. (The convention is that any " + "rule beginning 'At' is a timed one. The time can either be a fixed time, as in " + "'At 11:10 AM: ...', or the time when some named event takes place, as in 'At the " + "time when the clock chimes: ...'.)"); + +@ = +int TimedRules::new_rule_defn_notify(imperative_defn *id, rule_family_data *rfd) { + CREATE_PLUGIN_RFD_DATA(timed_rules, rfd, TimedRules::new_rfd_data); + wording W = rfd->usage_preamble; + if ((W)) { + int t = <>; + rfd->usage_preamble = EMPTY_WORDING; + rfd->not_in_rulebook = TRUE; + RFD_PLUGIN_DATA(timed_rules, rfd)->event_time = t; + if (t == NO_FIXED_TIME) { + wording EW = GET_RW(, 1); + EW = Articles::remove_the(EW); + RFD_PLUGIN_DATA(timed_rules, rfd)->event_name = EW; + rfd->constant_name = EW; + } + } + return FALSE; +} + +@ The above therefore attaches one of these to each set of rule data: + += +typedef struct timed_rules_rfd_data { + int event_time; /* 0 to 1339, or one of the special values above */ + struct wording event_name; /* if one is given */ + struct linked_list *uses_as_event; /* of |parse_node| */ + CLASS_DEFINITION +} timed_rules_rfd_data; + +timed_rules_rfd_data *TimedRules::new_rfd_data(rule_family_data *rfd) { + timed_rules_rfd_data *trfd = CREATE(timed_rules_rfd_data); + trfd->event_time = NOT_A_TIMED_EVENT; + trfd->event_name = EMPTY_WORDING; + trfd->uses_as_event = NEW_LINKED_LIST(parse_node); + return trfd; +} + +@ And that data can be read back with: + += +linked_list *TimedRules::get_uses_as_event(imperative_defn *id) { + if (id->family != rule_idf) return NULL; + rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); + return RFD_PLUGIN_DATA(timed_rules, rfd)->uses_as_event; +} + +int TimedRules::get_timing_of_event(imperative_defn *id) { + if (id->family != rule_idf) return NOT_A_TIMED_EVENT; + rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); + return RFD_PLUGIN_DATA(timed_rules, rfd)->event_time; +} + +wording TimedRules::get_wording_of_event(imperative_defn *id) { + if (id->family != rule_idf) return EMPTY_WORDING; + rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); + return RFD_PLUGIN_DATA(timed_rules, rfd)->event_name; +} + +@ When a rule has no explicit timing, it needs to be triggered by a phrase +like "spawn fresh zombies in 4 turns from now". Here, "spawn fresh zombies" +is the name of the rule. But this has the same kind as any other rule, so +the Dash typechecker is not able to make sure "spawn fresh zombies" is indeed +timed, and not some other rule. + +We fix this by defining the trigger phrase to use the inline annotation +|{-mark-event-used:R}| on the rule |R|. That in turn results in the following +being called: + += +int TimedRules::inline_annotation(int annot, parse_node *supplied) { + if (annot == mark_event_used_ISINC) { + if (Rvalues::is_CONSTANT_construction(supplied, CON_rule)) { + rule *R = Rvalues::to_rule(supplied); + imperative_defn *id = Rules::get_imperative_definition(R); + if (id) { + int t = TimedRules::get_timing_of_event(id); + if (t == NO_FIXED_TIME) { + linked_list *L = TimedRules::get_uses_as_event(id); + ADD_TO_LINKED_LIST(current_sentence, parse_node, L); + } else @; + } else @; + } else @; + return TRUE; + } + return FALSE; +} + +@ = + Problems::quote_source(1, current_sentence); + Problems::quote_wording(2, Node::get_text(supplied)); + StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_NonconstantEvent)); + Problems::issue_problem_segment( + "You wrote %1, but '%2' isn't the name of any timed event that I know of. " + "(These need to be set up in a special way, like so - 'At the time when stuff " + "happens: ...' creates a timed event called 'stuff happens'.)"); + Problems::issue_problem_end(); + +@ An interesting case where the Problem is arguably only a warning and arguably +shouldn't block compilation. Then again... + += +void TimedRules::check_for_unused(void) { + imperative_defn *id; + LOOP_OVER(id, imperative_defn) + if (TimedRules::get_timing_of_event(id) == NO_FIXED_TIME) + if (LinkedLists::len(TimedRules::get_uses_as_event(id)) == 0) { + current_sentence = id->at; + StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_UnusedTimedEvent), + "this sets up a timed event which is never used", + "since you never use any of the phrases which could cause it. (A timed " + "event is just a name, and it needs other instructions elsewhere before " + "it can have any effect.)"); + } +} diff --git a/inform7/if-module/Chapter 4/Action Patterns.w b/inform7/if-module/Chapter 4/Action Patterns.w index 353e09e87..2be150290 100644 --- a/inform7/if-module/Chapter 4/Action Patterns.w +++ b/inform7/if-module/Chapter 4/Action Patterns.w @@ -94,10 +94,21 @@ void ActionPatterns::write(OUTPUT_STREAM, action_pattern *ap) { } } -@ This simple parser converts text to a parametric AP of kind |K|. The parser -for action-based APs is very much more complicated: see //Parse Action Patterns//. +@ These functions are used when parsing rule applicability: = +action_pattern *ActionPatterns::parse_action_based(wording W) { + action_pattern *ap = NULL; + int saved = ParseActionPatterns::enter_mode(PERMIT_TRYING_OMISSION); + if (Rules::all_action_processing_variables()) + Frames::set_stvol( + Frames::current_stack_frame(), Rules::all_action_processing_variables()); + if ((W)) ap = <>; + Frames::remove_nonphrase_stack_frame(); + ParseActionPatterns::restore_mode(saved); + return ap; +} + action_pattern *ActionPatterns::parse_parametric(wording W, kind *K) { parse_node *spec = NULL; if ((W)) spec = <>; diff --git a/inform7/if-module/Contents.w b/inform7/if-module/Contents.w index f604e0c97..8ecaae3af 100644 --- a/inform7/if-module/Contents.w +++ b/inform7/if-module/Contents.w @@ -30,6 +30,7 @@ Chapter 3: Space and Time Regions The Map Map Connection Relations + Timed Rules Scenes The Score diff --git a/inform7/imperative-module/Chapter 2/Rules.w b/inform7/imperative-module/Chapter 2/Rules.w index 6533ef4a0..3bce34095 100644 --- a/inform7/imperative-module/Chapter 2/Rules.w +++ b/inform7/imperative-module/Chapter 2/Rules.w @@ -225,6 +225,7 @@ of a //phrase// as follows: = void Rules::set_imperative_definition(rule *R, imperative_defn *id) { R->defn_as_I7_source = id; + RTRules::prepare_rule(id, R); } imperative_defn *Rules::get_imperative_definition(rule *R) { diff --git a/inform7/imperative-module/Chapter 3/Describing Phrase Type Data.w b/inform7/imperative-module/Chapter 3/Describing Phrase Type Data.w index 0bb0e0460..4453d7bc6 100644 --- a/inform7/imperative-module/Chapter 3/Describing Phrase Type Data.w +++ b/inform7/imperative-module/Chapter 3/Describing Phrase Type Data.w @@ -206,9 +206,9 @@ void Phrases::TypeData::Textual::inv_write_HTML_representation(OUTPUT_STREAM, pa phrase *ph = Node::get_phrase_invoked(inv); if (ph) { ph_type_data *phtd = &(ph->type_data); - if (Wordings::nonempty(ph->ph_documentation_symbol)) { + if (Wordings::nonempty(ToPhraseFamily::doc_ref(ph->from))) { TEMPORARY_TEXT(pds) - WRITE_TO(pds, "%+W", Wordings::one_word(Wordings::first_wn(ph->ph_documentation_symbol))); + WRITE_TO(pds, "%+W", Wordings::one_word(Wordings::first_wn(ToPhraseFamily::doc_ref(ph->from)))); Index::DocReferences::link_to(OUT, pds, -1); DISCARD_TEXT(pds) } else @@ -275,10 +275,10 @@ void Phrases::TypeData::Textual::write_reveal_box(OUTPUT_STREAM, ph_type_data *p of course. @ = - if (Wordings::nonempty(ph->ph_documentation_symbol)) { + if (Wordings::nonempty(ToPhraseFamily::doc_ref(ph->from))) { HTML_CLOSE("p"); TEMPORARY_TEXT(pds) - WRITE_TO(pds, "%+W", Wordings::one_word(Wordings::first_wn(ph->ph_documentation_symbol))); + WRITE_TO(pds, "%+W", Wordings::one_word(Wordings::first_wn(ToPhraseFamily::doc_ref(ph->from)))); Index::DocReferences::doc_fragment(OUT, pds); HTML_OPEN("p"); WRITE("See "); Index::DocReferences::fully_link(OUT, pds); diff --git a/inform7/imperative-module/Chapter 3/Phrase Options.w b/inform7/imperative-module/Chapter 3/Phrase Options.w index 93a270285..3bf40267d 100644 --- a/inform7/imperative-module/Chapter 3/Phrase Options.w +++ b/inform7/imperative-module/Chapter 3/Phrase Options.w @@ -91,14 +91,13 @@ void Phrases::Options::index(OUTPUT_STREAM, ph_options_data *phod) { ph_options_data *phod_being_parsed = NULL; phrase *ph_being_parsed = NULL; -ph_options_data Phrases::Options::parse_declared_options(wording W) { - ph_options_data phod = Phrases::Options::new(W); +void Phrases::Options::parse_declared_options(ph_options_data *phod, wording W) { if (Wordings::nonempty(W)) { - phod_being_parsed = &phod; + phod->options_declaration = W; + phod_being_parsed = phod; (W); - if (<>) phod.multiple_options_permitted = TRUE; + if (<>) phod->multiple_options_permitted = TRUE; } - return phod; } @ I have to say that I regret the syntax for phrase options, which makes diff --git a/inform7/imperative-module/Chapter 3/Phrase Runtime Context Data.w b/inform7/imperative-module/Chapter 3/Phrase Runtime Context Data.w index 96a28d555..ceea28f5f 100644 --- a/inform7/imperative-module/Chapter 3/Phrase Runtime Context Data.w +++ b/inform7/imperative-module/Chapter 3/Phrase Runtime Context Data.w @@ -20,7 +20,6 @@ rulebooks reach them. = typedef struct ph_runtime_context_data { struct wording activity_context; /* happens only while any activities go on? */ - struct parse_node *activity_where; /* and who says? */ struct activity_list *avl; #ifdef IF_MODULE struct parse_node *during_scene; /* ...happens only during a scene matching this? */ @@ -29,7 +28,6 @@ typedef struct ph_runtime_context_data { int never_test_actor; /* ...for instance, for a parametrised rather than action rulebook */ int marked_for_anyone; /* any actor is allowed to perform this action */ #endif - struct rulebook **compile_for_rulebook; /* ...used for the default outcome */ int permit_all_outcomes; /* waive the usual restrictions on rule outcomes */ } ph_runtime_context_data; @@ -89,7 +87,6 @@ the following only blanks out a PHRCD structure ready for that to happen. ph_runtime_context_data Phrases::Context::new(void) { ph_runtime_context_data phrcd; phrcd.activity_context = EMPTY_WORDING; - phrcd.activity_where = NULL; phrcd.avl = NULL; #ifdef IF_MODULE phrcd.during_scene = NULL; @@ -99,7 +96,6 @@ ph_runtime_context_data Phrases::Context::new(void) { phrcd.marked_for_anyone = FALSE; #endif phrcd.permit_all_outcomes = FALSE; - phrcd.compile_for_rulebook = NULL; return phrcd; } @@ -321,7 +317,7 @@ void Phrases::Context::ensure_avl(rule *R) { ph_runtime_context_data *rcd = &(ph->runtime_context_data); if (Wordings::nonempty(rcd->activity_context)) { parse_node *save_cs = current_sentence; - current_sentence = rcd->activity_where; + current_sentence = id->at; ph_stack_frame *phsf = &(ph->stack_frame); Frames::make_current(phsf); @@ -414,13 +410,10 @@ with the default outcome return (see above). void Phrases::Context::compile_test_tail(phrase *ph, rule *R) { inter_name *identifier = Phrases::iname(ph); ph_runtime_context_data *phrcd = &(ph->runtime_context_data); - - if (phrcd->compile_for_rulebook) { - rulebook *rb = *(phrcd->compile_for_rulebook); - if (rb) RTRules::compile_default_outcome(Rulebooks::get_outcomes(rb)); - } - - if (Wordings::nonempty(phrcd->activity_context)) @; + rulebook *rb = RuleFamily::get_rulebook(ph->from); + if (rb) RTRules::compile_default_outcome(Rulebooks::get_outcomes(rb)); + if (Wordings::nonempty(phrcd->activity_context)) + @; if (PluginCalls::compile_test_tail(ph, R) == FALSE) { if (phrcd->ap) @; } diff --git a/inform7/imperative-module/Chapter 3/Phrases.w b/inform7/imperative-module/Chapter 3/Phrases.w index cce8d69ba..c85ac8cd8 100644 --- a/inform7/imperative-module/Chapter 3/Phrases.w +++ b/inform7/imperative-module/Chapter 3/Phrases.w @@ -36,7 +36,6 @@ typedef struct phrase { struct inter_schema *inter_tail_defn; /* inline definition translated to inter, if possible */ int inter_defn_converted; /* has this been tried yet? */ int inline_mor; /* manner of return for inline I6 definition, or |UNKNOWN_NT| */ - struct wording ph_documentation_symbol; /* cross-reference with documentation */ struct compilation_unit *owning_module; struct package_request *requests_package; @@ -75,8 +74,6 @@ phrase *Phrases::create_from_preamble(imperative_defn *id) { internal_error("a phrase preamble should be at a IMPERATIVE_NT node"); int inline_wn = -1; /* the word number of an inline I6 definition if any */ int mor = DONT_KNOW_MOR; /* and its manner of return */ - wording OW = EMPTY_WORDING; /* the text of the phrase options, if any */ - wording documentation_W = EMPTY_WORDING; /* the documentation reference, if any */ @; @@ -88,8 +85,8 @@ phrase *Phrases::create_from_preamble(imperative_defn *id) { if ((inline_wn >= 0) && (ImperativeDefinitionFamilies::allows_inline(id) == FALSE)) @; - @; @; + @; @; @; @@ -108,15 +105,12 @@ phrase *Phrases::create_from_preamble(imperative_defn *id) { @; } +@ = + phod = Phrases::Options::new(EMPTY_WORDING); + @ = - wording XW = ToPhraseFamily::get_prototype_text(id); - documentation_W = Index::DocReferences::position_of_symbol(&XW); phtd = Phrases::TypeData::new(); if (inline_wn >= 0) Phrases::TypeData::make_inline(&phtd); - ImperativeDefinitionFamilies::to_phtd(id, &phtd, XW, &OW); - -@ = - phod = Phrases::Options::parse_declared_options(OW); @ The stack frame needs to know the kind of this phrase -- something like = (text as Inform 6) @@ -129,10 +123,6 @@ inline definitions. @ = phsf = Frames::new(); - Phrases::TypeData::into_stack_frame(&phsf, &phtd, - Phrases::TypeData::kind(&phtd), TRUE); - if (Phrases::Options::allows_options(&phod)) - LocalVariables::options_parameter_is_needed(&phsf); @ = phrcd = Phrases::Context::new(); @@ -168,8 +158,6 @@ inline definitions. new_ph->next_in_logical_order = NULL; new_ph->sequence_count = -1; - new_ph->ph_documentation_symbol = documentation_W; - @ That just leaves two problem messages about inline definitions: @ = @@ -218,6 +206,16 @@ void Phrases::parse_possible_inline_defn(wording W, int *wn, int *mor) { if ((W)) { *wn = <>; *mor = <>; } } +@ + += +void Phrases::prepare_stack_frame(phrase *body) { + Phrases::TypeData::into_stack_frame(&(body->stack_frame), &(body->type_data), + Phrases::TypeData::kind(&(body->type_data)), TRUE); + if (Phrases::Options::allows_options(&(body->options_data))) + LocalVariables::options_parameter_is_needed(&(body->stack_frame)); +} + @h Miscellaneous. That completes the process of creation. Here's how we log them: diff --git a/inform7/imperative-module/Chapter 3/Timed Phrases.w b/inform7/imperative-module/Chapter 3/Timed Phrases.w deleted file mode 100644 index 21c3e5986..000000000 --- a/inform7/imperative-module/Chapter 3/Timed Phrases.w +++ /dev/null @@ -1,158 +0,0 @@ -[Phrases::Timed::] Timed Phrases. - -Another way phrases can be invoked is as timed events, which need -no special Inform data structure and are simply compiled into a pair of -timetable I6 arrays to be processed at run-time. - -@ The timing of an event records the time at which a phrase should -spontaneously happen. This is ordinarily a time value, in minutes from 12 -midnight, for a phrase happening at a specific time -- for instance, one -defined as "At 9:00 AM: ..." But two values are special: - -@d NOT_A_TIMED_EVENT -1 /* as for the vast majority of phrases */ -@d NO_FIXED_TIME -2 /* for phrases like "When the clock strikes: ..." */ -@d NOT_AN_EVENT -3 /* not even syntactically */ - -@ And here we record where events are used: - -= -typedef struct use_as_event { - struct parse_node *where_triggered; /* sentence which specifies when this occurs */ - struct use_as_event *next; - CLASS_DEFINITION -} use_as_event; - -@ Timed events are stored in two simple arrays, processed by run-time code. - -= -void Phrases::Timed::TimedEventsTable(void) { - inter_name *iname = Hierarchy::find(TIMEDEVENTSTABLE_HL); - packaging_state save = Emit::named_table_array_begin(iname, K_value); - int when_count = 0; - phrase *ph; - LOOP_OVER(ph, phrase) { - int t = RuleFamily::get_timing_of_event(ph->from); - if (t == NOT_A_TIMED_EVENT) continue; - if (t == NO_FIXED_TIME) when_count++; - else Emit::array_iname_entry(Phrases::iname(ph)); - } - - for (int i=0; ifrom); - if (t == NOT_A_TIMED_EVENT) continue; - if (t == NO_FIXED_TIME) when_count++; - else Emit::array_numeric_entry((inter_ti) t); - } - - for (int i=0; ifrom); - if (t == NO_FIXED_TIME) { - use_as_event *uae = CREATE(use_as_event); - uae->where_triggered = at; - uae->next = NULL; - linked_list *L = RuleFamily::get_uses_as_event(ph->from); - if (L) ADD_TO_LINKED_LIST(uae, use_as_event, L); - } -} - -@ An interesting case where the Problem is arguably only a warning and -arguably shouldn't block compilation. Then again... - -= -void Phrases::Timed::check_for_unused(void) { - phrase *ph; - LOOP_OVER(ph, phrase) - if (RuleFamily::get_timing_of_event(ph->from) == NO_FIXED_TIME) { - linked_list *L = RuleFamily::get_uses_as_event(ph->from); - if (LinkedLists::len(L) == 0) { - current_sentence = ph->from->at; - StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_UnusedTimedEvent), - "this sets up a timed event which is never used", - "since you never use any of the phrases which could cause it. " - "(A timed event is just a name, and it needs other instructions " - "elsewhere before it can have any effect.)"); - } - } -} - -@ And here's the actual index segment. - -= -void Phrases::Timed::index(OUTPUT_STREAM) { - int when_count = 0, tt_count = 0; - @; - @; - if ((when_count == 0) && (tt_count == 0)) { - HTML_OPEN("p"); WRITE("None."); HTML_CLOSE("p"); - } -} - -@ = - phrase *ph; - LOOP_OVER(ph, phrase) { - int t = RuleFamily::get_timing_of_event(ph->from); - if (t == NO_FIXED_TIME) { - if (when_count == 0) { - HTML_OPEN("p"); - WRITE("Events with no specific time"); - HTML_CLOSE("p"); - } - when_count++; - HTML_OPEN_WITH("p", "class=\"tightin2\""); - ImperativeDefinitions::index_preamble(OUT, ph->from); - if ((ph->from->at) && - (Wordings::nonempty(Node::get_text(ph->from->at)))) - Index::link(OUT, Wordings::first_wn(Node::get_text(ph->from->at))); - WRITE(" (where triggered: "); - linked_list *L = RuleFamily::get_uses_as_event(ph->from); - use_as_event *uae; - LOOP_OVER_LINKED_LIST(uae, use_as_event, L) - Index::link(OUT, Wordings::first_wn(Node::get_text(uae->where_triggered))); - WRITE(")"); - HTML_CLOSE("p"); - } - } - -@ = - phrase *ph; - LOOP_OVER(ph, phrase) { - int t = RuleFamily::get_timing_of_event(ph->from); - if (t >= 0) { /* i.e., an actual time of day in minutes since midnight */ - if (tt_count == 0) { - HTML_OPEN("p"); - WRITE("Timetable"); - HTML_CLOSE("p"); - } - tt_count++; - HTML_OPEN_WITH("p", "class=\"in2\""); - ImperativeDefinitions::index_preamble(OUT, ph->from); - if ((ph->from->at) && - (Wordings::nonempty(Node::get_text(ph->from->at)))) - Index::link(OUT, Wordings::first_wn(Node::get_text(ph->from->at))); - HTML_CLOSE("p"); - } - } diff --git a/inform7/imperative-module/Chapter 6/Compile Invocations Inline.w b/inform7/imperative-module/Chapter 6/Compile Invocations Inline.w index 2ceff3f1c..5de94d0ed 100644 --- a/inform7/imperative-module/Chapter 6/Compile Invocations Inline.w +++ b/inform7/imperative-module/Chapter 6/Compile Invocations Inline.w @@ -855,34 +855,10 @@ token, because that would be "property name". Instead: } return; -@ This little annotation is used for the phrases about timed rule firing: - ->> To (R - rule) in (t - number) turn/turns from now: ... - -has the inline definition: -= (text) - SetTimedEvent({-mark-event-used:R}, {t}+1, 0); -= -The annotation makes no difference to how R is compiled, except that it -sneaks in a sanity check (R must be explicitly named and must be an event -rule), and also makes a note for indexing purposes. +@ This little annotation is used in //if: Timed Rules//. @ = - if (Rvalues::is_CONSTANT_construction(supplied, CON_rule)) { - rule *R = Rvalues::to_rule(supplied); - imperative_defn *id = Rules::get_imperative_definition(R); - if (id) Phrases::Timed::note_usage(id->body_of_defn, current_sentence); - } else { - Problems::quote_source(1, current_sentence); - Problems::quote_wording(2, Node::get_text(supplied)); - StandardProblems::handmade_problem(Task::syntax_tree(), _p_(PM_NonconstantEvent)); - Problems::issue_problem_segment( - "You wrote %1, but '%2' isn't the name of any timed event that " - "I know of. (These need to be set up in a special way, like so - " - "'At the time when stuff happens: ...' creates a timed event " - "called 'stuff happens'.)"); - Problems::issue_problem_end(); - } + PluginCalls::nonstandard_inline_annotation(sche->inline_command, supplied); valid_annotation = TRUE; @ = diff --git a/inform7/imperative-module/Contents.w b/inform7/imperative-module/Contents.w index ef46a2dc8..9256a5d8c 100644 --- a/inform7/imperative-module/Contents.w +++ b/inform7/imperative-module/Contents.w @@ -31,9 +31,7 @@ being compiled as a great mass of Inform 6 routines and arrays." Phrase Type Data Describing Phrase Type Data Phrase Options - Phrases as Values To Phrases - Timed Phrases Chapter 4: Compilation Context "Preparing a context at run-time in which code can be executed." diff --git a/inform7/index-module/Chapter 2/Index File Services.w b/inform7/index-module/Chapter 2/Index File Services.w index e30071c8a..26a0e597d 100644 --- a/inform7/index-module/Chapter 2/Index File Services.w +++ b/inform7/index-module/Chapter 2/Index File Services.w @@ -649,7 +649,7 @@ void Index::index_actual_element(OUTPUT_STREAM, text_stream *elt) { return; } if (Str::eq_wide_string(elt, L"Ev")) { - Phrases::Timed::index(OUT); /* rules which happen at set times of day */ + IXRules::index_timed_rules(OUT); /* rules which happen at set times of day */ return; } if (Str::eq_wide_string(elt, L"RS")) { diff --git a/inform7/index-module/Chapter 2/Phrasebook Index.w b/inform7/index-module/Chapter 2/Phrasebook Index.w index 713435008..d6c118e9b 100644 --- a/inform7/index-module/Chapter 2/Phrasebook Index.w +++ b/inform7/index-module/Chapter 2/Phrasebook Index.w @@ -187,10 +187,10 @@ a single shared reveal-box: = int Phrases::Index::ph_same_doc(phrase *p1, phrase *p2) { if ((p1 == NULL) || (p2 == NULL) || - (Wordings::empty(p1->ph_documentation_symbol)) || - (Wordings::empty(p2->ph_documentation_symbol))) + (Wordings::empty(ToPhraseFamily::doc_ref(p1->from))) || + (Wordings::empty(ToPhraseFamily::doc_ref(p2->from)))) return FALSE; - if (Wordings::match(p1->ph_documentation_symbol, p2->ph_documentation_symbol)) + if (Wordings::match(ToPhraseFamily::doc_ref(p1->from), ToPhraseFamily::doc_ref(p2->from))) return TRUE; return FALSE; } diff --git a/inform7/index-module/Chapter 2/Rules.w b/inform7/index-module/Chapter 2/Rules.w index e0f25353b..d77bb0204 100644 --- a/inform7/index-module/Chapter 2/Rules.w +++ b/inform7/index-module/Chapter 2/Rules.w @@ -640,3 +640,61 @@ void IXRules::index_outcomes(OUTPUT_STREAM, outcomes *outs, int suppress_outcome HTML_CLOSE("p"); } } + +@ + += +void IXRules::index_timed_rules(OUTPUT_STREAM) { + int when_count = 0, tt_count = 0; + @; + @; + if ((when_count == 0) && (tt_count == 0)) { + HTML_OPEN("p"); WRITE("None."); HTML_CLOSE("p"); + } +} + +@ = + phrase *ph; + LOOP_OVER(ph, phrase) { + int t = TimedRules::get_timing_of_event(ph->from); + if (t == NO_FIXED_TIME) { + if (when_count == 0) { + HTML_OPEN("p"); + WRITE("Events with no specific time"); + HTML_CLOSE("p"); + } + when_count++; + HTML_OPEN_WITH("p", "class=\"tightin2\""); + ImperativeDefinitions::index_preamble(OUT, ph->from); + if ((ph->from->at) && + (Wordings::nonempty(Node::get_text(ph->from->at)))) + Index::link(OUT, Wordings::first_wn(Node::get_text(ph->from->at))); + WRITE(" (where triggered: "); + linked_list *L = TimedRules::get_uses_as_event(ph->from); + parse_node *p; + LOOP_OVER_LINKED_LIST(p, parse_node, L) + Index::link(OUT, Wordings::first_wn(Node::get_text(p))); + WRITE(")"); + HTML_CLOSE("p"); + } + } + +@ = + phrase *ph; + LOOP_OVER(ph, phrase) { + int t = TimedRules::get_timing_of_event(ph->from); + if (t >= 0) { /* i.e., an actual time of day in minutes since midnight */ + if (tt_count == 0) { + HTML_OPEN("p"); + WRITE("Timetable"); + HTML_CLOSE("p"); + } + tt_count++; + HTML_OPEN_WITH("p", "class=\"in2\""); + ImperativeDefinitions::index_preamble(OUT, ph->from); + if ((ph->from->at) && + (Wordings::nonempty(Node::get_text(ph->from->at)))) + Index::link(OUT, Wordings::first_wn(Node::get_text(ph->from->at))); + HTML_CLOSE("p"); + } + } diff --git a/inform7/imperative-module/Chapter 3/Phrases as Values.w b/inform7/runtime-module/Chapter 4/Closures.w similarity index 62% rename from inform7/imperative-module/Chapter 3/Phrases as Values.w rename to inform7/runtime-module/Chapter 4/Closures.w index ec4329c85..66dd7521a 100644 --- a/inform7/imperative-module/Chapter 3/Phrases as Values.w +++ b/inform7/runtime-module/Chapter 4/Closures.w @@ -2,105 +2,23 @@ To provide the names of phrases as first-class values. -@ A few "To..." phrases have names, and can therefore be used as values in their -own right, a functional-programming sort of device. For example: - ->> To decide what number is double (N - a number) (this is doubling): - -has the name "doubling". Such a name is recorded here: - -= -typedef struct constant_phrase { - struct noun *name; - struct phrase *phrase_meant; /* if known at this point */ - struct kind *cphr_kind; /* ditto */ - struct inter_name *cphr_iname; - struct wording associated_preamble_text; - CLASS_DEFINITION -} constant_phrase; - -@ Here we create a new named phrase ("doubling", say): - -= -constant_phrase *Phrases::Constants::create(wording NW, wording RW) { - constant_phrase *cphr = CREATE(constant_phrase); - cphr->phrase_meant = NULL; /* we won't know until later */ - cphr->cphr_kind = NULL; /* nor this */ - cphr->associated_preamble_text = RW; - cphr->name = Nouns::new_proper_noun(NW, NEUTER_GENDER, ADD_TO_LEXICON_NTOPT, - PHRASE_CONSTANT_MC, Rvalues::from_constant_phrase(cphr), Task::language_of_syntax()); - cphr->cphr_iname = NULL; - return cphr; -} - -@ ...and parse for an existing one: - -= -constant_phrase *Phrases::Constants::parse(wording NW) { - if ((NW)) { - parse_node *spec = <>; - if (Rvalues::is_CONSTANT_construction(spec, CON_phrase)) { - constant_phrase *cphr = Rvalues::to_constant_phrase(spec); - Phrases::Constants::kind(cphr); - return cphr; - } - } - return NULL; -} - -@ As often happens with Inform constants, the kind of a constant phrase can't -be known when its name first comes up, and must be filled in later. (In -particular, before the second traverse many kinds do not yet exist.) So -the following takes a patch-it-later approach. - -= -kind *Phrases::Constants::kind(constant_phrase *cphr) { - if (cphr == NULL) return NULL; - if (global_pass_state.pass < 2) return Kinds::binary_con(CON_phrase, K_value, K_value); - if (cphr->cphr_kind == NULL) { - wording OW = EMPTY_WORDING; - ph_type_data phtd = Phrases::TypeData::new(); - Phrases::TypeData::Textual::parse(&phtd, - cphr->associated_preamble_text, &OW); - cphr->cphr_kind = Phrases::TypeData::kind(&phtd); - } - return cphr->cphr_kind; -} - -@ And similarly for the |phrase| structure this name corresponds to. - -= -phrase *Phrases::Constants::as_phrase(constant_phrase *cphr) { - if (cphr == NULL) internal_error("null cphr"); - if (cphr->phrase_meant == NULL) { - imperative_defn *id; - LOOP_OVER(id, imperative_defn) { - if (ToPhraseFamily::constant_phrase(id) == cphr) { - cphr->phrase_meant = id->body_of_defn; - break; - } - } - } - return cphr->phrase_meant; -} - @ So much for setting up constant phrases. Now we come to compilation, and a surprise. It might be expected that a constant phrase compiles simply to an I6 routine name, but no: it compiles to a small array called a "closure". = inter_name *Phrases::Constants::compile(constant_phrase *cphr) { - phrase *ph = Phrases::Constants::as_phrase(cphr); + phrase *ph = ToPhraseFamily::body_of_constant(cphr); if (ph == NULL) internal_error("cannot reconstruct phrase from cphr"); if (Phrases::compiled_inline(ph) == FALSE) Routines::ToPhrases::make_request(ph, - Phrases::Constants::kind(cphr), NULL, EMPTY_WORDING); + ToPhraseFamily::kind(cphr), NULL, EMPTY_WORDING); return Phrases::Constants::iname(cphr); } inter_name *Phrases::Constants::iname(constant_phrase *cphr) { if (cphr->cphr_iname == NULL) { - phrase *ph = Phrases::Constants::as_phrase(cphr); + phrase *ph = ToPhraseFamily::body_of_constant(cphr); if (ph == NULL) internal_error("cannot reconstruct phrase from cphr"); package_request *P = Hierarchy::package_within(CLOSURES_HAP, ph->requests_package); cphr->cphr_iname = Hierarchy::make_iname_in(CLOSURE_DATA_HL, P); @@ -114,9 +32,9 @@ inter_name *Phrases::Constants::iname(constant_phrase *cphr) { void Phrases::Constants::compile_closures(void) { constant_phrase *cphr; LOOP_OVER(cphr, constant_phrase) { - phrase *ph = Phrases::Constants::as_phrase(cphr); + phrase *ph = ToPhraseFamily::body_of_constant(cphr); if (ph == NULL) internal_error("cannot reconstruct phrase from cphr"); - Phrases::Constants::kind(cphr); + ToPhraseFamily::kind(cphr); @; } } @@ -134,7 +52,7 @@ case the phrase occurs as a constant but is never explicitly invoked. RTKinds::emit_strong_id(cphr->cphr_kind); inter_name *RS = Routines::ToPhrases::make_iname(ph, - Phrases::Constants::kind(cphr)); + ToPhraseFamily::kind(cphr)); Emit::array_iname_entry(RS); TEMPORARY_TEXT(name) diff --git a/inform7/runtime-module/Chapter 4/Rules.w b/inform7/runtime-module/Chapter 4/Rules.w index 0a38669c8..6d06406a2 100644 --- a/inform7/runtime-module/Chapter 4/Rules.w +++ b/inform7/runtime-module/Chapter 4/Rules.w @@ -39,6 +39,14 @@ ph_stack_frame *RTRules::stack_frame(rule *R) { return &(R->defn_as_I7_source->body_of_defn->stack_frame); } +void RTRules::prepare_rule(imperative_defn *id, rule *R) { + rule_family_data *rfd = RETRIEVE_POINTER_rule_family_data(id->family_specific_data); + package_request *P = RTRules::package(R); + if (Wordings::empty(rfd->constant_name)) + Hierarchy::markup_wording(P, RULE_NAME_HMD, Node::get_text(id->at)); + id->body_of_defn->ph_iname = Hierarchy::make_localised_iname_in(RULE_FN_HL, P, id->body_of_defn->owning_module); +} + package_request *RTRules::package(rule *R) { return R->compilation_data.rule_package; } diff --git a/inform7/runtime-module/Chapter 5/Timed Rules.w b/inform7/runtime-module/Chapter 5/Timed Rules.w new file mode 100644 index 000000000..3b1115be9 --- /dev/null +++ b/inform7/runtime-module/Chapter 5/Timed Rules.w @@ -0,0 +1,46 @@ +[RTTimedRules::] Timed Rules. + +Code to support rules like "At 12:03AM: ...". + +@ Timed events are stored in two simple arrays, processed by run-time code. + += +void RTTimedRules::TimedEventsTable(void) { + inter_name *iname = Hierarchy::find(TIMEDEVENTSTABLE_HL); + packaging_state save = Emit::named_table_array_begin(iname, K_value); + int when_count = 0; + phrase *ph; + LOOP_OVER(ph, phrase) { + int t = TimedRules::get_timing_of_event(ph->from); + if (t == NOT_A_TIMED_EVENT) continue; + if (t == NO_FIXED_TIME) when_count++; + else Emit::array_iname_entry(Phrases::iname(ph)); + } + + for (int i=0; ifrom); + if (t == NOT_A_TIMED_EVENT) continue; + if (t == NO_FIXED_TIME) when_count++; + else Emit::array_numeric_entry((inter_ti) t); + } + + for (int i=0; iph_documentation_symbol; + wording NW = ToPhraseFamily::doc_ref(ph->from); if (Wordings::nonempty(NW)) { TEMPORARY_TEXT(pds) WRITE_TO(pds, "%+W", Wordings::one_word(Wordings::first_wn(NW))); diff --git a/inform7/values-module/Chapter 2/Rvalues.w b/inform7/values-module/Chapter 2/Rvalues.w index a8560a97e..2a488ec50 100644 --- a/inform7/values-module/Chapter 2/Rvalues.w +++ b/inform7/values-module/Chapter 2/Rvalues.w @@ -530,7 +530,7 @@ kind *Rvalues::to_kind(parse_node *spec) { assertion traverse: @ = - return Phrases::Constants::kind(Rvalues::to_constant_phrase(spec)); + return ToPhraseFamily::kind(Rvalues::to_constant_phrase(spec)); @ This too is tricky. Some phrases to decide values are unambiguous. If they say they are "To decide a rule: ...", then clearly the return value diff --git a/services/lexicon-module/Figures/excerpts-diagnostics.txt b/services/lexicon-module/Figures/excerpts-diagnostics.txt index f8660e01b..88941950d 100644 --- a/services/lexicon-module/Figures/excerpts-diagnostics.txt +++ b/services/lexicon-module/Figures/excerpts-diagnostics.txt @@ -1,5 +1,5 @@ Size of lexicon: 3098 excerpt meanings - Stored among 840 words out of total vocabulary of 10562 + Stored among 840 words out of total vocabulary of 10561 710 words have a start list: longest belongs to report (with 293 meanings) 15 words have an end list: longest belongs to case (with 6 meanings) 29 words have a middle list: longest belongs to to (with 4 meanings)