MCPcopy Create free account
hub / github.com/SeaOfNodes/Simple / gather

Method gather

chapter21/src/main/java/com/seaofnodes/simple/type/Type.java:61–82  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

59 public static final Type NIL = new Type( TNIL ).intern(); // low null of all flavors
60 public static final Type XNIL = new Type( TXNIL ).intern(); // high or choice null
61 public static Type[] gather() {
62 ArrayList<Type> ts = new ArrayList<>();
63 ts.add(BOTTOM);
64 ts.add(CONTROL);
65 ts.add(NIL);
66 ts.add(XNIL);
67 TypeNil.gather(ts);
68 TypePtr.gather(ts);
69 TypeInteger.gather(ts);
70 TypeFloat.gather(ts);
71 TypeMemPtr.gather(ts);
72 TypeFunPtr.gather(ts);
73 TypeMem.gather(ts);
74 Field.gather(ts);
75 TypeStruct.gather(ts);
76 TypeTuple.gather(ts);
77 TypeRPC.gather(ts);
78 int sz = ts.size();
79 for( int i = 0; i < sz; i++ )
80 ts.add(ts.get(i).dual());
81 return ts.toArray(new Type[ts.size()]);
82 }
83
84 // Is high or on the lattice centerline.
85 public boolean isHigh () { return _type==TTOP || _type==TXCTRL || _type==TXNIL; }

Callers 1

testLatticeTheoryMethod · 0.95

Calls 15

gatherMethod · 0.95
gatherMethod · 0.95
gatherMethod · 0.95
gatherMethod · 0.95
gatherMethod · 0.95
gatherMethod · 0.95
gatherMethod · 0.95
gatherMethod · 0.95
gatherMethod · 0.95
gatherMethod · 0.95
gatherMethod · 0.95
addMethod · 0.45

Tested by 1

testLatticeTheoryMethod · 0.76