mirror of
https://github.com/Mercury-Language/mercury.git
synced 2026-04-16 01:43:35 +00:00
Use spaces, not tabs, in the Java and C# runtimes.
Add modelines to keep it that way. Fix formatting, and english in comments.
This commit is contained in:
@@ -1,52 +1,45 @@
|
||||
// vim: ts=4 sw=4 expandtab ft=java
|
||||
//
|
||||
// Copyright (C) 2001-2003 The University of Melbourne.
|
||||
// Copyright (C) 2018 The Mercury team.
|
||||
// This file is distributed under the terms specified in COPYING.LIB.
|
||||
//
|
||||
|
||||
|
||||
package jmercury.runtime;
|
||||
|
||||
public class TypeLayout implements java.io.Serializable {
|
||||
// This should hold a value of one of the types
|
||||
// accessible by the access functions that follow.
|
||||
public java.lang.Object layout_init;
|
||||
// This should hold a value of one of the types
|
||||
// accessible by the access functions that follow.
|
||||
public java.lang.Object layout_init;
|
||||
|
||||
//
|
||||
// In runtime/mercury_type_info.h:
|
||||
// typedef MR_DuPtagLayout *MR_DuTypeLayout;
|
||||
// so here we just use DuPtagLayout[]
|
||||
//
|
||||
public DuPtagLayout[] layout_du() {
|
||||
return (DuPtagLayout[]) layout_init;
|
||||
}
|
||||
// In runtime/mercury_type_info.h:
|
||||
// typedef MR_DuPtagLayout *MR_DuTypeLayout;
|
||||
// so here we just use DuPtagLayout[].
|
||||
public DuPtagLayout[] layout_du() {
|
||||
return (DuPtagLayout[]) layout_init;
|
||||
}
|
||||
|
||||
//
|
||||
// In runtime/mercury_type_info.h:
|
||||
// typedef MR_EnumFunctorDesc **EnumTypeLayout;
|
||||
// so here we just use EnumFunctorDesc[][]
|
||||
//
|
||||
public EnumFunctorDesc[] layout_enum() {
|
||||
return (EnumFunctorDesc[]) layout_init;
|
||||
}
|
||||
// In runtime/mercury_type_info.h:
|
||||
// typedef MR_EnumFunctorDesc **EnumTypeLayout;
|
||||
// so here we just use EnumFunctorDesc[][]
|
||||
public EnumFunctorDesc[] layout_enum() {
|
||||
return (EnumFunctorDesc[]) layout_init;
|
||||
}
|
||||
|
||||
//
|
||||
// In runtime/mercury_type_info.h:
|
||||
// typedef MR_NotagFunctorDesc *MR_NotagTypeLayout;
|
||||
// so here we just us NotagFunctorDesc[]
|
||||
//
|
||||
public NotagFunctorDesc[] layout_notag() {
|
||||
return (NotagFunctorDesc[]) layout_init;
|
||||
}
|
||||
//
|
||||
// In runtime/mercury_type_info.h:
|
||||
// typedef MR_PseudoTypeInfo MR_EquivType;
|
||||
// so here we just use MR_PseudoTypeInfo
|
||||
//
|
||||
public PseudoTypeInfo layout_equiv() {
|
||||
return (PseudoTypeInfo) layout_init;
|
||||
}
|
||||
// In runtime/mercury_type_info.h:
|
||||
// typedef MR_NotagFunctorDesc *MR_NotagTypeLayout;
|
||||
// so here we just us NotagFunctorDesc[]
|
||||
public NotagFunctorDesc[] layout_notag() {
|
||||
return (NotagFunctorDesc[]) layout_init;
|
||||
}
|
||||
// In runtime/mercury_type_info.h:
|
||||
// typedef MR_PseudoTypeInfo MR_EquivType;
|
||||
// so here we just use MR_PseudoTypeInfo
|
||||
public PseudoTypeInfo layout_equiv() {
|
||||
return (PseudoTypeInfo) layout_init;
|
||||
}
|
||||
|
||||
public TypeLayout(java.lang.Object init) {
|
||||
layout_init = init;
|
||||
}
|
||||
public TypeLayout(java.lang.Object init) {
|
||||
layout_init = init;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user