/** * Creates a new complete constructor {@code ALetBeStExp} node with the given nodes as children. * @deprecated This method should not be used, use AstFactory instead. * The basic child nodes are removed from their previous parents. * @param bind_ the {@link PMultipleBind} node for the {@code bind} child of this {@link ALetBeStExp} node * @param suchThat_ the {@link PExp} node for the {@code suchThat} child of this {@link ALetBeStExp} node * @param value_ the {@link PExp} node for the {@code value} child of this {@link ALetBeStExp} node * @param def_ the {@link AMultiBindListDefinition} node for the {@code def} child of this {@link ALetBeStExp} node */ public ALetBeStExp(PType type_, ILexLocation location_, PMultipleBind bind_, PExp suchThat_, PExp value_, AMultiBindListDefinition def_) { super(type_,location_); this.setBind(bind_); this.setSuchThat(suchThat_); this.setValue(value_); this.setDef(def_); }
/** * Creates a new tree field only constructor {@code ALetBeStExp TAG=letBeSt} node with the given nodes as children. * @deprecated This method should not be used, use AstFactory instead. * The basic child nodes are removed from their previous parents. * @param bind_ the {@link PMultipleBind} node for the {@code bind} child of this {@link ALetBeStExp} node * @param suchThat_ the {@link PExp} node for the {@code suchThat} child of this {@link ALetBeStExp} node * @param value_ the {@link PExp} node for the {@code value} child of this {@link ALetBeStExp} node * @param def_ the {@link AMultiBindListDefinition} node for the {@code def} child of this {@link ALetBeStExp} node */ public ALetBeStExp(ILexLocation location_, PMultipleBind bind_, PExp suchThat_, PExp value_, AMultiBindListDefinition def_) { super(null,location_); this.setBind(bind_); this.setSuchThat(suchThat_); this.setValue(value_); this.setDef(def_); }
@Override public PType caseALetBeStExp(ALetBeStExp node, TypeCheckInfo question) throws AnalysisException { Entry<PType, AMultiBindListDefinition> res = typecheckLetBeSt(node, node.getLocation(), node.getBind(), node.getSuchThat(), node.getValue(), question); node.setDef(res.getValue()); node.setType(res.getKey()); return node.getType(); }