mirror of
https://github.com/Mercury-Language/mercury.git
synced 2026-04-23 21:33:49 +00:00
Fix a bug by distinguishing the type_ctor_reps of type_infos and
Estimated hours taken: 12 Branches: main Fix a bug by distinguishing the type_ctor_reps of type_infos and type_ctor_infos. The type_ctor_infos of types with nonzero arity cannot be printed, copied etc like type_infos; any attempt to do so causes a core dump. For similar reasons, add a separate type_ctor_rep for base_typeclass_infos separate from typeclass_infos. runtime/mercury_type_info.h: runtime/mercury_mcpp.h: compiler/mlds_to_gcc.m: library/rtti_implementation.m: java/TypeCtorRep.java: Add new type_ctor_reps for type_ctor_infos and base_typeclass_infos. library/private_builtin.m: runtime/mercury.c: Use the new type_ctor_reps in the type_ctor_infos of the builtin types type_ctor_info and base_typeclass_info. runtime/mercury_type_info.[ch]: Add a function for comparing type_ctor_infos. Move some interface documentation from the source file to the header file. runtime/mercury_deep_copy_body.h: Add code to handle the new type_ctor_reps. Simplify some code. Make the whole file use 4-space indentation. library/std_util.m: runtime/mercury_ml_expand_body.h: runtime/mercury_unify_compare_body.h: runtime/mercury_ho_call.c: runtime/mercury_tabling.c: Add code to handle the new type_ctor_reps.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// Copyright (C) 2001 The University of Melbourne.
|
||||
// Copyright (C) 2001-2002 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.
|
||||
//
|
||||
@@ -41,7 +41,11 @@ public class TypeCtorRep {
|
||||
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;
|
||||
public static final int MR_TYPECTOR_REP_RESERVED_ADDR = 31;
|
||||
public static final int MR_TYPECTOR_REP_RESERVED_ADDR_USEREQ = 32;
|
||||
public static final int MR_TYPECTOR_REP_TYPECTORINFO = 33;
|
||||
public static final int MR_TYPECTOR_REP_BASETYPECLASSINFO = 34;
|
||||
public static final int MR_TYPECTOR_REP_UNKNOWN = 35;
|
||||
|
||||
// Instance variable for TypeCtorRep objects.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user