Commit Graph

14 Commits

Author SHA1 Message Date
Julien Fischer
6faef40e9e Fix spelling.
extras/moose/check.m:
    As above.
2023-04-03 21:09:24 +10:00
Julien Fischer
d7a606af4c Update moose to conform to stdlib changes.
extras/moose/check.m:
extras/moose/grammar.m:
extras/moose/mercury_syntax.m:
     As above.
2022-12-14 01:28:34 +11:00
Julien Fischer
4099cca890 Minor cleanups for moose.
extras/moose/*.m:
    As above.
2022-04-18 00:00:09 +10:00
Zoltan Somogyi
031c7194cd Bring moose's programming style up to date. 2020-05-17 22:59:13 +10:00
Julien Fischer
2dc59fefbe Fix compilation errors in samples, extras and benchmarks.
benchmarks/progs/quicksort/qs_always_par.m:
benchmarks/progs/quicksort/qs_utils.m:
extras/moose/check.m:
extras/posix/samples/mdprof_cgid.m:
extras/xml/parsing.m:
samples/muz/zparser.m:
samples/muz/ztype_op.m:
    As above -- the compiler now rejects determinism declarations on
    non-predmode predicate declarations.

    Replace a call to bitmap.new with bitmap.init.
2016-01-13 14:16:24 +11:00
Julien Fischer
2a8be7bbf6 Replace '__' as module qualifier in rest of the extras.
extras/*/*.m:
	Replace the use of '__' as a module qualifier in the rest of
	the extras.

	s/io\.state/io/ in the extras.

	Use '=' instead of is/2 in a spot.
2014-12-29 16:48:17 +11:00
Julien Fischer
9f68c330f0 Change the argument order of many of the predicates in the map, bimap, and
Branches: main

Change the argument order of many of the predicates in the map, bimap, and
multi_map modules so they are more conducive to the use of state variable
notation, i.e. make the order the same as in the sv* modules.

Prepare for the deprecation of the sv{bimap,map,multi_map} modules by
removing their use throughout the system.

library/bimap.m:
library/map.m:
library/multi_map.m:
	As above.
NEWS:
	Announce the change.

	Separate out the "highlights" from the "detailed listing" for
	the post-11.01 NEWS.

	Reorganise the announcement of the Unicode support.

benchmarks/*/*.m:
browser/*.m:
compiler/*.m:
deep_profiler/*.m:
extras/*/*.m:
mdbcomp/*.m:
profiler/*.m:
tests/*/*.m:
ssdb/*.m:
samples/*/*.m
slice/*.m:
	Conform to the above change.

	Remove any dependencies on the sv{bimap,map,multi_map} modules.
2011-05-03 04:35:04 +00:00
Julien Fischer
144145573e Don't use "cute" operator overloadings in moose - this allows us to compile it
Branches: main, 11.01

Don't use "cute" operator overloadings in moose - this allows us to compile it
with the non-C backends, some of which don't currently do the name mangling
which would otherwise be required.

Make the moose samples work again.

extras/moose/misc.m:
	Delete this module -- overloading operators in this way was
	never a particuarly good idea, especially as several of the
	overloaded operators (now) mean other things in Mercury.

extras/moose/check.m:
extras/moose/grammar.m:
extras/moose/lalr.m:
extras/moose/mercury_syntax.m:
extras/moose/moose.m:
extras/moose/tables.m:
	Conform to the above changes.

	Import each module on its own line.

extras/moose/options.m:
	As above.

	Use the "multi" form of the option_ops type.

extras/moose/samples/try_alpha.m:
extras/moose/samples/try_expr.m:
	Make these examples work again -- as written the typeclass
	instance they contain does not satisfy the current restrictions
	on the form of instance arguments.

	Syntax and formatting cleanups.
2011-01-18 13:03:59 +00:00
Paul Bone
326e5c640d Corrected a bug in moose whereby it failed to return a non-zero exit code when
Estimated hours taken: 1

Corrected a bug in moose whereby it failed to return a non-zero exit code when
a critical error occured.

Converted moose to modern syntax with regard to DCGs and State Variables and
module delimters such as '__' vs '.'.  Converted some indentation to four
spaces.

extras/moose/check.m:
extras/moose/grammar.m:
extras/moose/lalr.m:
extras/moose/mercury_syntax.m:
extras/moose/misc.m:
extras/moose/moose.m:
extras/moose/options.m:
extras/moose/tables.m:
	As above.

extras/moose/BUGS
	Noted a new bug.

extras/moose/TODO
	Corrected a spelling mistake.
2009-02-21 11:27:54 +00:00
Julien Fischer
beb5c107a8 Import solutions rather than std_util.
Estimated hours taken: 0
Branches: main, release

extras/moose/check.m:
	Import solutions rather than std_util.
2006-04-21 04:03:21 +00:00
Julien Fischer
1afe830f57 Allow moose to parse conditional goals written using the if - then - else
Estimated hours taken: 1.
Branches: main.

Allow moose to parse conditional goals written using the if - then - else
notation.  This makes the code generated by moose less ugly when the `.moo'
file contains these type of goals.

extras/moose/mercury_syntax.m:
	Handle if-then-elses so that the generated code is less ugly.
	Fix some indentation.
	Fix some type declarations.
	Delete some dead code.

extras/moose/check.m:
extras/moose/grammar.m:
	Add some module qualifiers.

extras/moose/samples/alpha.moo:
	Use the alternative if-then-else notation.
2003-07-24 05:38:08 +00:00
Julien Fischer
d4aec6ecc4 This change doesn't alter any functionality.
Estimated hours taken 5:
Branches: main.

This change doesn't alter any functionality.  It just cleans up some
notation and (hopefully) makes things a little easier to modify in the
future.

The changes are:
	- Remove instances of `:' as a module qualifier.
	- Add more module qualifiers.
	- Use state variables for threading the IO state.
	- Use state variables for accumulators.
	- Remove some unused predicates.

extras/moose/check.m:
extras/moose/lalr.m:
extras/moose/mercury_syntax.m:
extras/moose/moose.m:
extras/moose/options.m:
extras/moose/tables.m:
	Changes to notation as listed above.

extras/moose/grammar.m:
	Replace calls to predicate grammar.foldl/4 with calls to
	function array.foldl/3 from standard library.  Delete grammar.foldl/4.
	Other changes as above.

extras/moose/misc.m:
	Remove predicate between/3 since it isn't used anywhere.
	Other changes as above.
2003-07-16 07:16:03 +00:00
Julien Fischer
a9d249407b Fix moose so that it compiles successfully with intermodule-optimization
Estimated hours taken: 0.5
Branches: main

Fix moose so that it compiles successfully with intermodule-optimization
enabled.

extras/moose/check.m:
extras/moose/grammar.m:
extras/moose/lalr.m:
extras/moose/moose.m:
	Module qualify some predicate names to resolve type ambiguities.
	Add underscores to a couple of variables that are not used.
2003-07-09 07:43:38 +00:00
Tyson Dowd
2a81aec951 Moose, the Mercury parser generator.
Estimated hours taken: 5 (+ unknown hours by Tom, + unknown hours by fjh)

Moose, the Mercury parser generator.

extras/moose/Mmakefile:
extras/moose/check.m:
extras/moose/grammar.m:
extras/moose/lalr.m:
extras/moose/mercury.m:
extras/moose/misc.m:
extras/moose/moose.m:
extras/moose/options.m:
extras/moose/tables.m:

extras/moose/BUGS:
	A list of known bugs.

extras/moose/TODO:
	Things that still need to be done.

extras/moose/README:
	Documentation for moose (thanks to fjh).

extras/moose/samples/Mmakefile:
extras/moose/samples/README:
extras/moose/samples/alpha.input:
extras/moose/samples/alpha.moo:
extras/moose/samples/cgram.moo:
extras/moose/samples/expr.input:
extras/moose/samples/expr.moo:
extras/moose/samples/small.moo:
extras/moose/samples/try_alpha.m:
extras/moose/samples/try_expr.m:
	Some samples.
2000-05-22 05:22:18 +00:00