Location<?> rhsDecl = rightChild.getLocation(var);
Type type = Type.Union(lhsDecl.getType(), rhsDecl.getType());
if (type.equals(origDecl.getType())) {
result.environment.put(var, origDecl.getIndex());
} else {
<BUG>Nominal nominal = Nominal.construct(type, type);
int newDecl = result.createAlias(nominal, var, Collections.EMPTY_LIST);</BUG>
result.environment.put(var, newDecl);
}
}

Location<?> rhsDecl = rightChild.getLocation(var);
Type type = Type.Union(lhsDecl.getType(), rhsDecl.getType());
if (type.equals(origDecl.getType())) {
result.environment.put(var, origDecl.getIndex());
} else {
Nominal nominal = Nominal.construct(type);
int newDecl = result.createAlias(nominal, var, Collections.EMPTY_LIST);
result.environment.put(var, newDecl);
