1
0
Fork 0
mirror of https://github.com/ganelson/inform.git synced 2024-06-30 22:14:58 +03:00

Fix and test cases for Mantis bug 1974

This commit is contained in:
Graham Nelson 2022-04-10 21:33:38 +01:00
parent fd2a34fe4c
commit a903453116
10 changed files with 338 additions and 295 deletions

View file

@ -1,6 +1,6 @@
Total memory consumption was 126308K = 123 MB
---- was used for 2008022 objects, in 360797 frames in 0 x 800K = 0K = 0 MB:
---- was used for 2008028 objects, in 360803 frames in 0 x 800K = 0K = 0 MB:
32.3% inter_tree_node_array 58 x 8192 = 475136 objects, 41813824 bytes
18.9% text_stream_array 4342 x 100 = 434200 objects, 24454144 bytes
@ -26,8 +26,8 @@ Total memory consumption was 126308K = 123 MB
0.8% id_body 941 objects, 1076504 bytes
0.7% adjective_meaning 202 objects, 1000304 bytes
0.7% excerpt_meaning 3100 objects, 967200 bytes
0.6% production 3874 objects, 898768 bytes
0.6% ptoken 8385 objects, 872040 bytes
0.6% production 3875 objects, 899000 bytes
0.6% ptoken 8390 objects, 872560 bytes
0.6% grammatical_usage 3611 objects, 866640 bytes
0.6% individual_form 2561 objects, 860496 bytes
0.6% inter_schema_node 8897 objects, 854112 bytes
@ -255,5 +255,5 @@ Total memory consumption was 126308K = 123 MB
---- code generation workspace for objects 1336 bytes in 4 claims
0.2% emitter array storage 279776 bytes in 1995 claims
-140.-5% was overhead - -181849392 bytes = -177587K = -173 MB
-140.-5% was overhead - -181850144 bytes = -177588K = -173 MB

View file

@ -1,9 +1,9 @@
100.0% in inform7 run
68.1% in compilation to Inter
47.9% in //Sequence::undertake_queued_tasks//
68.6% in compilation to Inter
48.2% in //Sequence::undertake_queued_tasks//
4.5% in //MajorNodes::pre_pass//
3.1% in //MajorNodes::pass_1//
2.4% in //RTPhrasebook::compile_entries//
3.2% in //MajorNodes::pass_1//
2.3% in //RTPhrasebook::compile_entries//
1.8% in //ImperativeDefinitions::assess_all//
1.5% in //RTKindConstructors::compile//
1.0% in //Sequence::lint_inter//
@ -18,20 +18,20 @@
0.1% in //Task::make_built_in_kind_constructors//
0.1% in //Understand::traverse//
0.1% in //World::stages_II_and_III//
2.0% not specifically accounted for
29.2% in running Inter pipeline
10.3% in step 14/15: generate inform6 -> auto.inf
2.3% not specifically accounted for
28.8% in running Inter pipeline
10.0% in step 14/15: generate inform6 -> auto.inf
7.6% in step 5/15: load-binary-kits
6.7% in step 6/15: make-synoptic-module
6.5% in step 6/15: make-synoptic-module
1.5% in step 9/15: make-identifiers-unique
0.5% in step 4/15: compile-splats
0.4% in step 12/15: eliminate-redundant-operations
0.4% in step 4/15: compile-splats
0.4% in step 7/15: shorten-wiring
0.3% in step 11/15: eliminate-redundant-labels
0.3% in step 8/15: detect-indirect-calls
0.2% in step 11/15: eliminate-redundant-labels
0.1% in step 10/15: reconcile-verbs
0.1% in step 2/15: parse-insertions
0.1% in step 3/15: resolve-conditional-compilation
0.5% not specifically accounted for
2.2% in supervisor
0.4% not specifically accounted for
0.6% not specifically accounted for
2.3% in supervisor
0.3% not specifically accounted for

File diff suppressed because it is too large Load diff

View file

@ -1,3 +1,3 @@
There is room.
Nothing is in the box.
Nothing is greater than the player.

View file

@ -0,0 +1,3 @@
Foo is a room.
Quog is a room that varies.
Quog is in the player.

View file

@ -0,0 +1,3 @@
Foo is a room.
Quog is a room that varies.
The player is in Quog.

View file

@ -1,11 +1,12 @@
Inform 7 build 6L26 has started.
I've now read your source text, which is 8 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.
Inform 7 v10.1.0 has started.
I've now read your source text, which is 9 words long.
I've also read Basic Inform by Graham Nelson, which is 7691 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 32092 words long.
Problem__ PM_RelationFailedOnNothing
>--> You wrote 'Nothing is in the box' (source text, line 3): but that is an
assertion which involves 'nothing', which looks as if it might be trying to
give me negative rather than positive information. There's no need to tell
me something like 'Nothing is in the box.': just don't put anything in the
box, and then nothing will be in it.
Inform 7 has finished: 16 centiseconds used.
>--> You wrote 'Nothing is greater than the player' (source text, line 3):
but that is an assertion which involves 'nothing', which looks as if it
might be trying to give me negative rather than positive information.
There's no need to tell me something like 'Nothing is in the box.': just
don't put anything in the box, and then nothing will be in it.
Inform 7 has finished.

View file

@ -0,0 +1,11 @@
Inform 7 v10.1.0 has started.
I've now read your source text, which is 15 words long.
I've also read Basic Inform by Graham Nelson, which is 7691 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 32092 words long.
Problem__ PM_UndefinedContainment
>--> You wrote 'Quog is in the player' (source text, line 3): but this asks
to put something whose identity I don't know inside something else, and the
reason I don't know that identity is that it isn't either a name of a room
or thing, or of a constant or variable set to a room or thing.
Inform 7 has finished.

View file

@ -0,0 +1,11 @@
Inform 7 v10.1.0 has started.
I've now read your source text, which is 15 words long.
I've also read Basic Inform by Graham Nelson, which is 7691 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 32092 words long.
Problem__ PM_UndefinedContainment2
>--> You wrote 'The player is in Quog' (source text, line 3): but this asks
to put something inside something else whose identity I don't know, and the
reason I don't know that identity is that it isn't either a name of a room
or thing, or of a constant or variable set to a room or thing.
Inform 7 has finished.

View file

@ -196,6 +196,20 @@ int SpatialRelations::assert(bp_family *self, binary_predicate *bp,
@<Assert the worn and wearable properties@>;
return TRUE;
}
if (I1 == NULL) {
StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_UndefinedContainment),
"this asks to put something whose identity I don't know inside something else",
"and the reason I don't know that identity is that it isn't either a name "
"of a room or thing, or of a constant or variable set to a room or thing.");
return TRUE;
}
if (I0 == NULL) {
StandardProblems::sentence_problem(Task::syntax_tree(), _p_(PM_UndefinedContainment2),
"this asks to put something inside something else whose identity I don't know",
"and the reason I don't know that identity is that it isn't either a name "
"of a room or thing, or of a constant or variable set to a room or thing.");
return TRUE;
}
return FALSE;
}