[m-dev.] Re: Making the IL backend work (maybe)

Jonathan Morgan jonmmorgan at gmail.com
Tue Sep 12 00:30:38 AEST 2006


On 21/08/06, Jonathan Morgan <jonmmorgan at gmail.com> wrote:
> I have looked at the IL backend again, and the problem breaking it is
> to do with dummy types.  The code it objects to is the following line
> in io.init_state:
>     io.set_op_table(ops.init_mercury_op_table, !IO)

The following diff makes everything work perfectly again.  However (as
of yet) I have been unable to figure out where to change the compiler
to get this result.  I'll look at again after the 0.13 release.

Jon

--- tmp_dir/library/io.il	Tue Sep 12 00:04:48 2006
+++ io.il	Tue Sep 12 00:26:32 2006
@@ -24185,7 +24185,8 @@
 		int32 'V_61_61',
 		class ['mercury']'mercury'.'io'.'stream_mode_0' 'V_62_62',
 		class ['mercury']'mercury'.'io'.'stream_content_0' 'V_63_63',
-		class ['mercury']'mercury'.'io'.'stream_source_0' 'V_64_64'
+		class ['mercury']'mercury'.'io'.'stream_source_0' 'V_64_64',
+          	class [mercury]mercury.ops.mercury_op_table_0 V_Op
 	)

 	
@@ -24289,10 +24290,8 @@
 	.line 34 'ops.opt'
 	newobj	instance void
 		['mercury']'mercury'.'ops'.'mercury_op_table_0'::.ctor()

-	stsfld	class ['mercury']'mercury'.'ops'.'mercury_op_table_0'
-		['mercury']'mercury'.'private_builtin__csharp_code'.'mercury_code'::'dummy_var'
+	stloc V_Op
	
 	.line 4708 'io.m'
 	ldloc	'Globals_5'
 	call	void
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to:       mercury-developers at csse.unimelb.edu.au
Administrative Queries: owner-mercury-developers at csse.unimelb.edu.au
Subscriptions:          mercury-developers-request at csse.unimelb.edu.au
--------------------------------------------------------------------------



More information about the developers mailing list