Estimated hours taken: 14
Branches: main
Change the compiler and tools so that `.' and not `:' is now used as the
module separator in all output.
Infix `.' now has associativity yfx and priority 10.
NEWS:
Report the change.
configure.in:
Amend the test for an up-to-date Mercury compiler to check whether
it recognises `.' as a module qualifier.
compiler/code_gen.m:
compiler/error_util.m:
compiler/hlds_out.m:
compiler/prog_out.m:
compiler/prog_util.m:
compiler/rl_exprn.m:
compiler/rl_gen.m:
compiler/source_file_map.m:
compiler/unused_args.m:
library/io.m:
library/rtti_implementation.m:
library/type_desc.m:
runtime/mercury_debug.c:
runtime/mercury_deconstruct.c:
runtime/mercury_stack_trace.c:
Change `:' to `.' as module separator for output.
compiler/mercury_to_mercury.m:
compiler/prog_io_typeclass.m:
As above.
Fixed a bug where `.' was not being recognised as a module separator.
doc/reference_manual.texi:
Report the change.
library/term_io.m:
Ensure that infix `.' is written without surrounding spaces.
tests/hard_coded/dot_separator.m:
tests/hard_coded/dot_separator.exp:
tests/hard_coded/Mmakefile:
Test case added.
Estimated hours taken: 10
Branches: main
Improve variable naming in the debugger. Where possible, use
the user's argument names rather than `HeadVar__N'.
compiler/clause_to_proc.m:
Use the user's names for the arguments of
`:- pragma foreign_proc' procedures.
compiler/simplify.m:
When performing excess assignment elimination with `--trace deep',
don't replace a variable with a meaningful name with `HeadVar__N'
or an unnamed variable.
compiler/trace_params.m:
Add a predicate `trace_level_needs_meaningful_var_names'
for use by simplify.m.
compiler/typecheck.m:
For predicates with a single clause, attempt to replace the
`HeadVar__N' variables with the user's original head variables.
trace/mercury_trace_declarative.c:
trace/mercury_trace_vars.c:
Don't assume head variables have names of the form `HeadVar__N'.
Print the argument number when printing the names of
head variables.
tests/debugger/browser_test.inp:
tests/debugger/completion.inp:
Change names of variables in `print' commands.
tests/debugger/*.exp:
tests/debugger/*.exp2:
tests/debugger/declarative/dependency.exp:
tests/invalid/aditi_errors.err_exp:
tests/invalid/mode_inf.err_exp:
tests/invalid/record_syntax_errors.err_exp:
Update expected output.
Estimated hours taken: 0.1
Branches: main
tests/debugger/existential_type_classes.exp2:
tests/debugger/multi_parameter.exp2:
Update these expected outputs for my change to the class method naming
scheme.
Estimated hours taken: 0.5
Fix a problem where one of the debugger test cases
was failing due to a change to library/io.m affecting
the line numbers in the debugger output.
tests/debugger/Mmakefile:
Pipe the output of several test cases through sed,
so we can avoid hard-coding the line numbers of code
in the standard library in the expected output for
those test cases.
tests/debugger/browser_test.exp2:
tests/debugger/multi_parameter.exp2:
tests/debugger/existential_type_classes.exp2:
Replace hard-coded line numbers with "NNNN".
Estimated hours taken: 1
Compile the files in the library directory with --trace minimum by default,
which has no effect in non-debugging grades and causes the library to be
shallow traced, not deep traced, in debugging grades.
This is probably what most users want, and it makes it much easier to
maintain the expected output of the debugging test cases in debugging grades.
library/Mmakefile:
Add --trace minimum to MCG.
tests/*/*:
Update the test cases both for this change and for my previous change,
the addition of line numbers.
Estimated hours taken: 0.5
tests/debugger/*.exp2:
Adjust the whitespace in the *.exp2 files to match
what the debugger actually outputs. In particular,
use spaces rather than tabs.
Estimated hours taken: 0.5
tests/debugger/*.exp2:
Adjust the whitespace in the *.exp2 files to match
what the debugger actually outputs, in line with zs's
changes to the *.exp files on 1999/05/27.
Estimated hours taken: 2
trace/mercury_trace_internal.c:
GNU readline always echos the inputs, so if readline support is
enabled, then ignore the MR_echo_commands variable,
and report an error if the user tries to use `echo off'.
Also, if we're not using readline, then echo the `echo on' command,
so that the output will be the same as with readline.
tests/debugger/*.inp:
Ensure that `echo on' is always the first command.
tests/debugger/*.exp:
tests/debugger/*.exp2:
Update to reflect the changes to *.inp,
and to include the echo of the `echo on' command.
(Also delete the mdb intro banners from *_lib.exp*,
because mdb is invoked with MERCURY_SUPPRESS_MDB_BANNER=yes.
The *_lib* files are in fact currently not used, so they should
probably be just deleted, I think. But I'll do that as
a separate change.)
Estimated hours taken: 4.5
Implement demangling for instance declarations (i.e. base_typeclass_infos).
compiler/base_typeclass_info.m:
compiler/llds_out.m:
Change the way name mangling for base_typeclass_infos is done
to ensure that they can be unambiguously demangled.
util/mdemangle.c:
profiler/demangle.m:
Add code to demangle base_typeclass_infos.
util/mdemangle.c:
Fix a bug: if it got part way through demangling a symbol
before noticing that it had the wrong format, then it would
sometimes print out a partially demangled version of the
symbol rather than printing out the original symbol unchanged.
tests/debugger/*.exp*:
Update the expected output to reflect the new mangling scheme.
(Really the debugger ought to demangle the names, but
currently it doesn't.)
Estimated hours taken: 2.75
Change the mdb `print' command so that it invokes the non-interactive
version of the term browser, and change the way the browser is invoked
so that the browser state is preserved across multiple invocations
of `print' or `browse' in a single mdb session.
browser/browse.m:
Make `browser_state' an abstract type.
Add new predicate `browse__init_state' to initialize that ADT.
Change the interface to `browse__browse' so that it takes and
returns the old and new browser_states.
Add a new predicate `browse__print' to replace the old
`browse__portray_root' predicate; this is the non-interactive
version of the browser. It calls io__write_univ if the term
is small enough, and browse__portray (with flat format) otherwise.
Export the `browse__print' and `browse__init_state' predicates to C.
Delete the predicates for formatting terms as strings, since that
code was a potential double-maintenance problem and was not needed.
library/io.m:
Export `io__write_univ', for use by browser/browse.m.
trace/mercury_trace_browse.h:
trace/mercury_trace_browse.c:
New files. These provide an interface to the browser
which preserves the browser state in a C static variable.
trace/Mmakefile:
Add the new files mercury_trace_browse.{h,c} to the appropriate
file lists.
trace/mercury_trace_internal.c:
Change the `browse' and `print' mdb commands to use the new
functions defined in mercury_trace_browse.{h,c} rather than
calling browser__browse and io__print (respectively), and don't
print a newline afterwards, since the browser does that itself.
Delete the old hack to avoid printing out HLDS and ModuleInfo,
since it's not necessary any more.
doc/user_guide.texi:
Update the documentation for the `browse' and `print' commands
to reflect these changes.
tests/debugger/*.exp:
tests/debugger/*.exp2:
Update the expected output from the debugger to reflect these changes.
Estimated hours taken: 0.5
Fix some spurious test cases failures for the debugging test cases.
tests/debugger/*.exp2:
Add alternative expected outputs for the test cases that
produce different results when built in debug grades (i.e.
when linked with a library was built with debugging enabled).