[m-rev.] diff: enable goal_contains_reconstruction

Peter Wang novalazy at gmail.com
Tue Jan 29 12:03:05 AEDT 2008


Branches: main

compiler/goal_util.m:
	`goal_contains_reconstruction' was disabled on the main branch
	because, previously, structure reuse was only implemented on a branch
	and so it would never succeed.  This is no longer true so enable it.

Index: compiler/goal_util.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/goal_util.m,v
retrieving revision 1.154
diff -u -r1.154 goal_util.m
--- compiler/goal_util.m	22 Jan 2008 15:06:09 -0000	1.154
+++ compiler/goal_util.m	29 Jan 2008 00:54:00 -0000
@@ -173,7 +173,7 @@
     = list(pred_proc_id).

     % Test whether the goal contains a reconstruction
-    % (a construction where the `cell_to_reuse' field is `yes(_)').
+    % (a construction where the `construct_how' field is `cell_to_reuse(_)').
     %
 :- pred goal_contains_reconstruction(hlds_goal::in) is semidet.

@@ -1043,10 +1043,8 @@

 %-----------------------------------------------------------------------------%

-goal_contains_reconstruction(_) :-
-    % This will only succeed on the alias branch with structure reuse.
-    semidet_fail.
-    % goal_expr_contains_reconstruction(GoalExpr).
+goal_contains_reconstruction(hlds_goal(GoalExpr, _)) :-
+    goal_expr_contains_reconstruction(GoalExpr).

 :- pred goal_expr_contains_reconstruction(hlds_goal_expr::in) is semidet.
--------------------------------------------------------------------------
mercury-reviews mailing list
Post messages to:       mercury-reviews at csse.unimelb.edu.au
Administrative Queries: owner-mercury-reviews at csse.unimelb.edu.au
Subscriptions:          mercury-reviews-request at csse.unimelb.edu.au
--------------------------------------------------------------------------



More information about the reviews mailing list