mirror of
https://github.com/Mercury-Language/mercury.git
synced 2025-12-15 05:44:58 +00:00
Estimated hours taken: 10. Classes used by the Java backend, particularly in the implementation of RTTI. java/Compare.java: java/Unify.java: New files. Java classes for implementation of wrapper classes around the builtin `unify'and `compare' predicates. java/JavaInternal.java: New file. Java class for storing runtime information such as command line arguments. java/DuExistInfo.java: java/DuExistLocn.java: java/DuFunctorDesc.java: java/DuPtagLayout.java: java/EnumFunctorDesc.java: java/NotagFunctorDesc.java: java/ProcAddr.java: java/PseudoTypeInfo.java: java/Sectag_Locn.java: java/TypeCtorInfo_Struct.java java/TypeCtorRep.java: java/TypeFunctors.java: java/TypeLayout.java: New files. Java classes for implementing Mercury RTTI. java/UnreachableDefault.java: New file. Runtime exception that signals that unreachable default case in a switch statement has been reached. runtime/mercury_type_info.h: Update comments to mention that Java runtime classes will need to be altered if structures in this file are.
57 lines
2.1 KiB
Java
57 lines
2.1 KiB
Java
//
|
|
// Copyright (C) 2001 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.
|
|
//
|
|
|
|
package mercury.runtime;
|
|
|
|
public class TypeCtorRep {
|
|
|
|
// Constants
|
|
|
|
public static final int MR_TYPECTOR_REP_ENUM = 0;
|
|
public static final int MR_TYPECTOR_REP_ENUM_USEREQ = 1;
|
|
public static final int MR_TYPECTOR_REP_DU = 2;
|
|
public static final int MR_TYPECTOR_REP_DU_USEREQ = 3;
|
|
public static final int MR_TYPECTOR_REP_NOTAG = 4;
|
|
public static final int MR_TYPECTOR_REP_NOTAG_USEREQ = 5;
|
|
public static final int MR_TYPECTOR_REP_EQUIV = 6;
|
|
public static final int MR_TYPECTOR_REP_EQUIV_VAR = 7;
|
|
public static final int MR_TYPECTOR_REP_INT = 8;
|
|
public static final int MR_TYPECTOR_REP_CHAR = 9;
|
|
public static final int MR_TYPECTOR_REP_FLOAT = 10;
|
|
public static final int MR_TYPECTOR_REP_STRING = 11;
|
|
public static final int MR_TYPECTOR_REP_PRED = 12;
|
|
public static final int MR_TYPECTOR_REP_UNIV = 13;
|
|
public static final int MR_TYPECTOR_REP_VOID = 14;
|
|
public static final int MR_TYPECTOR_REP_C_POINTER = 15;
|
|
public static final int MR_TYPECTOR_REP_TYPEINFO = 16;
|
|
public static final int MR_TYPECTOR_REP_TYPECLASSINFO = 17;
|
|
public static final int MR_TYPECTOR_REP_ARRAY = 18;
|
|
public static final int MR_TYPECTOR_REP_SUCCIP = 19;
|
|
public static final int MR_TYPECTOR_REP_HP = 20;
|
|
public static final int MR_TYPECTOR_REP_CURFR = 21;
|
|
public static final int MR_TYPECTOR_REP_MAXFR = 22;
|
|
public static final int MR_TYPECTOR_REP_REDOFR = 23;
|
|
public static final int MR_TYPECTOR_REP_REDOIP = 24;
|
|
public static final int MR_TYPECTOR_REP_TRAIL_PTR = 25;
|
|
public static final int MR_TYPECTOR_REP_TICKET = 26;
|
|
public static final int MR_TYPECTOR_REP_NOTAG_GROUND = 27;
|
|
public static final int MR_TYPECTOR_REP_NOTAG_GROUND_USEREQ = 28;
|
|
public static final int MR_TYPECTOR_REP_EQUIV_GROUND = 29;
|
|
public static final int MR_TYPECTOR_REP_TUPLE = 30;
|
|
public static final int MR_TYPECTOR_REP_UNKNOWN = 31;
|
|
|
|
// Instance variable for TypeCtorRep objects.
|
|
|
|
public int value;
|
|
|
|
// Constructor
|
|
|
|
public TypeCtorRep(int arg) {
|
|
this.value = arg;
|
|
}
|
|
}
|
|
|