mirror of
https://github.com/Mercury-Language/mercury.git
synced 2025-12-14 05:12:33 +00:00
Branches: main
Make Java classes corresponding to Mercury types automatically serialisable.
java/runtime/MercuryType.java:
Make MercuryType extend java.io.Serializable.
compiler/mlds_to_java.m:
java/runtime/MercuryEnum.java:
Add a MercuryEnum interface which is implemented by classes
corresponding to Mercury enumerations. Previously enumerations
didn't implement MercuryType.
compiler/ml_type_gen.m:
Make enumeration classes implement MercuryType and MercuryEnum.
library/builtin.m:
Make builtin.copy check for MercuryEnum instead of relying on
enumeration classes not to implement MercuryType. This is not
strictly necessary but avoids copying instances of enumeration
classes.
14 lines
424 B
Java
14 lines
424 B
Java
//
|
|
// Copyright (C) 2009 The University of Melbourne.
|
|
// This file may only be copied under the terms of the GNU Library General
|
|
// Public License - see the file COPYING.LIB in the Mercury distribution.
|
|
//
|
|
// This interface is implemented by all classes generated by the Java back-end
|
|
// which correspond to Mercury-defined types.
|
|
//
|
|
|
|
package jmercury.runtime;
|
|
|
|
public interface MercuryType extends java.io.Serializable {
|
|
}
|