[m-rev.] for review: document high-level-data for IL parameter passing

Peter Ross peter.ross at miscrit.be
Fri Dec 7 02:03:59 AEDT 2001


Hi,


===================================================================


Estimated hours taken: 0.25
Branches: main

doc/reference_manual.texi:
    Document the distinction between high and low level data when
    interfacing with IL.

Index: reference_manual.texi
===================================================================
RCS file: /home/mercury1/repository/mercury/doc/reference_manual.texi,v
retrieving revision 1.231
diff -u -r1.231 reference_manual.texi
--- reference_manual.texi	6 Dec 2001 13:24:19 -0000	1.231
+++ reference_manual.texi	6 Dec 2001 15:01:51 -0000
@@ -5095,9 +5095,27 @@
 @code{System.Int32}, @code{System.Double}, @code{System.Char} and
 @code{System.String} respectively.
 
-Mercury variables which are polymorphically typed (e.g. whose type is a 
-type variables) will be passed as @code{System.Object} while all other
-Mercury variables are passed as @code{System.Object[]}.
+ at c XXX Is this true for --high-level-data
+Mercury variables whose type is a type variable will be passed as
+ at code{System.Object}.
+Mercury array types are mapped to CLR array types.
+When compiling with --no-high-level-data, all other Mercury variables
+are passed as @code{System.Object[]}.
+When compiling with --high-level-data,
+Mercury variables whose type is a Mercury discriminated union type
+will be passed as a CLR type whose type name is determined from
+the Mercury type name (ignoring any type parameters) followed by
+an underscore and then the type arity,
+expressed as a decimal integer.
+Mercury module qualifiers are converted to CLR namespace qualifiers.
+Note an extra namespace qualifier, `mercury', will be appended to the
+beginning of names residing in the Mercury standard library.
+For example the Mercury type `foo__bar__baz/1' will be passed as the CLR
+type `foo.bar.baz_1'.
+Mercury variables variables whose type is a Mercury equivalence type
+will be passed as the representation of the right hand side of the
+equivalence type.
+
 This mapping is subject to change and you should try to avoid writing
 code that relies heavily upon a particular representation of Mercury
 terms.

--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list