[m-dev.] for review: changes to MLDS

Julien Fischer juliensf at students.cs.mu.oz.au
Wed Jan 31 16:33:15 AEDT 2001


Re: ml_initial_cont, there was already a comment to the effect that
if `--nondet-copy-out' is not enabled it should take empty lists as 
arguments in the interface.  I've put another one in the implementation
anyway.  

I've changed the comment about the unknown_types.

Julien

Here is a relative diff:
--- compiler/ml_code_util.m
+++ compiler/ml_code_util.m
@@ -248 +247,0 @@
-	%
@@ -1571,0 +1571,4 @@
+	%
+	% We expect OutputVarlvals0 OutputVarTypes0 to be empty if
+	% `--nondet-copy-out' is not enabled.
+	%
--- compiler/ml_type_gen.m
+++ compiler/ml_type_gen.m
@@ -53 +53 @@
-	% from normal members in that their finality is final.
+	% from normal members in that their finality is `final'.
--- compiler/ml_unify_gen.m
+++ compiler/ml_unify_gen.m
@@ -310,2 +310,2 @@
-		% XXX This is probably wrong when `--high-level-data' is 
-		%     enabled.
+		% XXX Using mdls__array_type(mlds__generic_type) is probably 
+		% wrong when `--high-level-data' is enabled.
@@ -1021,2 +1021,2 @@
-		% XXX This is probably wrong when `--high-level-data'
-		%     is enabled.
+		% XXX Using mdls__array_type(mlds__generic_type) is probably 
+		% wrong when `--high-level-data' is enabled.
--- compiler/ml_util.m	2001/01/31 01:41:58
+++ compiler/ml_util.m	2001/01/11 14:25:39	1.5
@@ -68,8 +68,8 @@
 :- pred defn_is_public(mlds__defn).
 :- mode defn_is_public(in) is semidet.
 
+%-----------------------------------------------------------------------------%
 
-%-----------------------------------------------------------------------------%
 :- implementation.
 
 :- import_module rtti.
--- compiler/mlds.m
+++ compiler/mlds.m
@@ -553,4 +553,5 @@
-		% mark variables whose type is yet to be generated.  This
-		% occurs once in ml_code_util.m where env_ptr's are created,
-		% but their type remains unknown until the ml_elim_nested.m
-		% pass.  
+		% for references to variables that have yet to be
+		% declared.  This occurs once in ml_code_util.m where
+		% references to env_ptr's are generated but the declaration
+		% of these env_ptr's does not occur until the ml_elim_nested
+		% pass.
--- compiler/mlds_to_c.m
+++ compiler/mlds_to_c.m
@@ -636 +636,2 @@
-	{ error("mlds_to_c.m: prefix has unknown type") }. 
+	{ unexpected(this_file, 
+		"mlds_output_pragma_export_type: unknown_type") }. 
@@ -1711 +1712,2 @@
-	{ error("mlds_to_c.m: suffix has unknown type") }.
+	{ unexpected(this_file,
+		"mlds_output_type_suffix: unknown_type") }.
--- compiler/mlds_to_il.m
+++ compiler/mlds_to_il.m
@@ -1818,2 +1818 @@
-	 error("mlds_to_il.m: unknown type").	
-
+	unexpected(this_file, "mlds_type_to_ilds_type: unknown_type").
--- compiler/rtti_to_mlds.m	2001/01/16 03:24:39	1.11
+++ compiler/rtti_to_mlds.m	2001/01/31 05:17:51
@@ -564,7 +564,11 @@
 gen_init_builtin_const(Name) = init_obj(Rval) :-
         mercury_private_builtin_module(PrivateBuiltin),
 	MLDS_Module = mercury_module_name_to_mlds(PrivateBuiltin),
-	Rval = lval(var(qual(MLDS_Module, Name))).
+	% XXX These are actually enumeration constants.
+	% Perhaps we should be using an enumeration type here,
+	% rather than `mlds__native_int_type'.
+	Type = mlds__native_int_type,
+	Rval = lval(var(qual(MLDS_Module, Name), Type)).
 
 %-----------------------------------------------------------------------------%
 %


--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to:       mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions:          mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------



More information about the developers mailing list