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

Method meet

chapter09/src/main/java/com/seaofnodes/simple/type/Type.java:90–99  ·  view source on GitHub ↗
(Type t)

Source from the content-addressed store, hash-verified

88
89 // ----------------------------------------------------------
90 public final Type meet(Type t) {
91 // Shortcut for the self case
92 if( t == this ) return this;
93 // Same-type is always safe in the subclasses
94 if( _type==t._type ) return xmeet(t);
95 // Reverse; xmeet 2nd arg is never "is_simple" and never equal to "this".
96 if( is_simple() ) return this.xmeet(t );
97 if( t.is_simple() ) return t .xmeet(this);
98 return xmeet(t); // Mixing 2 unrelated types
99 }
100
101 // Compute meet right now. Overridden in subclasses.
102 // Handle cases where 'this.is_simple()' and unequal to 't'.

Callers 13

testMeetMethod · 0.95
isaMethod · 0.95
computeMethod · 0.95
computeMethod · 0.95
xmeetMethod · 0.45
joinMethod · 0.45
computeMethod · 0.45
computeMethod · 0.45
computeMethod · 0.45
computeMethod · 0.45
computeMethod · 0.45
computeMethod · 0.45

Calls 2

xmeetMethod · 0.95
is_simpleMethod · 0.95

Tested by 1

testMeetMethod · 0.76