mirror of
https://github.com/Mercury-Language/mercury.git
synced 2026-04-18 02:43:40 +00:00
Replace __ with . as the module qualifier symbol. Replace references to io.state with just io. Replace DCGs with state variables. Replace (C->T;E) syntax for if-then-elses with (if C then T else E) syntax. Replace if-then-elses with switches when possible and where this does not affect what is being tested. Replace separate pred and mode declarations with predmode declarations. Put predicate and function declarations just before the definition of the predicate or function. Delete unneeded module qualifications on predicate and function declarations and definitions. Update .exp files (and if needed, .inp files) for the line number changes that result from the above. For tests that have more than one .exp file and where one of those files is affected by the above, add a section to the source file header that says which .exp file is for what grade, with XXXs for the (as yet) unknown parts.
51 lines
2.0 KiB
Plaintext
51 lines
2.0 KiB
Plaintext
E1: C1 CALL pred interpreter.main/2-0 (det) interpreter.m:48
|
|
mdb> echo on
|
|
Command echo enabled.
|
|
mdb> context none
|
|
Contexts will not be printed.
|
|
mdb> register --quiet
|
|
mdb> b consult
|
|
0: + stop interface pred interpreter.consult/5-0 (det)
|
|
mdb> c
|
|
Pure Prolog Interpreter.
|
|
|
|
E2: C2 CALL pred interpreter.consult/5-0 (det)
|
|
mdb> delete 0
|
|
0: E stop interface pred interpreter.consult/5-0 (det)
|
|
mdb> vars
|
|
1 File (arg 1)
|
|
2 Database0 (arg 2)
|
|
mdb> print *
|
|
File (arg 1) "interpreter.m"
|
|
Database0 (arg 2) []
|
|
mdb> b database_assert_clause
|
|
0: + stop interface pred interpreter.database_assert_clause/4-0 (det)
|
|
mdb> c
|
|
Consulting file `interpreter.m'...
|
|
E3: C3 CALL pred interpreter.database_assert_clause/4-0 (det)
|
|
mdb> delete 0
|
|
0: E stop interface pred interpreter.database_assert_clause/4-0 (det)
|
|
mdb> finish
|
|
E4: C3 EXIT pred interpreter.database_assert_clause/4-0 (det)
|
|
mdb> print *
|
|
VarSet (arg 1) varset(var_supply(0), empty, empty)
|
|
Term (arg 2) functor(atom(":-"), [functor(atom/1, [|]/2, context/2)], context("interpreter.m", 29))
|
|
Database (arg 3) []
|
|
HeadVar__4 [clause(varset(var_supply/1, empty, empty), functor(atom/1, [|]/2, context/2), functor(atom/1, [], context/2))]
|
|
mdb> finish -a
|
|
This command is a no-op from this port.
|
|
mdb> print *
|
|
VarSet (arg 1) varset(var_supply(0), empty, empty)
|
|
Term (arg 2) functor(atom(":-"), [functor(atom/1, [|]/2, context/2)], context("interpreter.m", 29))
|
|
Database (arg 3) []
|
|
HeadVar__4 [clause(varset(var_supply/1, empty, empty), functor(atom/1, [|]/2, context/2), functor(atom/1, [], context/2))]
|
|
mdb>
|
|
E5: C4 CALL pred interpreter.consult_until_eof/4-0 (det)
|
|
mdb> finish -n
|
|
E6: C4 EXIT pred interpreter.consult_until_eof/4-0 (det)
|
|
mdb>
|
|
E7: C5 EXIT pred interpreter.consult_until_eof_2/5-0 (det)
|
|
mdb>
|
|
E8: C6 EXIT pred interpreter.consult_until_eof/4-0 (det)
|
|
mdb> continue
|
|
?- |