public override Yarn.Type VisitExpMultDivMod(YarnSpinnerParser.ExpMultDivModContext context) { var expressions = context.expression(); // *, /, % all support numbers only return(CheckOperation(context, expressions, context.op.Text, Yarn.Type.Number)); }
public override Yarn.IType VisitExpMultDivMod(YarnSpinnerParser.ExpMultDivModContext context) { var expressions = context.expression(); var @operator = CodeGenerationVisitor.TokensToOperators[context.op.Type]; // *, /, % all support numbers only Yarn.IType type = CheckOperation(context, expressions, @operator, context.op.Text); context.Type = type; return(type); }
// * / % public override int VisitExpMultDivMod(YarnSpinnerParser.ExpMultDivModContext context) { genericExpVisitor(context.expression(0), context.expression(1), context.op.Type); return(0); }
// * / % public override int VisitExpMultDivMod(YarnSpinnerParser.ExpMultDivModContext context) { this.GenerateCodeForOperation(TokensToOperators[context.op.Type], context.op, context.Type, context.expression(0), context.expression(1)); return(0); }
/// <summary> /// Visit a parse tree produced by the <c>expMultDivMod</c> /// labeled alternative in <see cref="YarnSpinnerParser.expression"/>. /// <para> /// The default implementation returns the result of calling <see cref="AbstractParseTreeVisitor{Result}.VisitChildren(IRuleNode)"/> /// on <paramref name="context"/>. /// </para> /// </summary> /// <param name="context">The parse tree.</param> /// <return>The visitor result.</return> public virtual Result VisitExpMultDivMod([NotNull] YarnSpinnerParser.ExpMultDivModContext context) { return(VisitChildren(context)); }
/// <summary> /// Exit a parse tree produced by the <c>expMultDivMod</c> /// labeled alternative in <see cref="YarnSpinnerParser.expression"/>. /// <para>The default implementation does nothing.</para> /// </summary> /// <param name="context">The parse tree.</param> public virtual void ExitExpMultDivMod([NotNull] YarnSpinnerParser.ExpMultDivModContext context) { }