/[svn]/linuxsampler/trunk/src/scriptvm/tree.h
ViewVC logotype

Diff of /linuxsampler/trunk/src/scriptvm/tree.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3575 by schoenebeck, Wed Aug 28 11:12:04 2019 UTC revision 3576 by schoenebeck, Wed Aug 28 12:56:38 2019 UTC
# Line 678  public: Line 678  public:
678  };  };
679  typedef Ref<SyncBlock,Node> SyncBlockRef;  typedef Ref<SyncBlock,Node> SyncBlockRef;
680    
681  class Neg FINAL : public IntExpr {  class Neg FINAL : virtual public IntExpr, virtual public RealExpr {
682      IntExprRef expr;      ScalarNumberExprRef expr;
683  public:  public:
684      Neg(IntExprRef expr) : expr(expr) { }      Neg(ScalarNumberExprRef expr) : expr(expr) { }
685      vmint evalInt() OVERRIDE { return (expr) ? -expr->evalInt() : 0; }      ExprType_t exprType() const OVERRIDE { return expr->exprType(); }
686        vmint evalInt() OVERRIDE { return (expr) ? -(expr->asInt()->evalInt()) : 0; }
687        vmfloat evalReal() OVERRIDE { return (expr) ? -(expr->asReal()->evalReal()) : vmfloat(0); }
688        String evalCastToStr() OVERRIDE;
689      void dump(int level = 0) OVERRIDE;      void dump(int level = 0) OVERRIDE;
690      bool isConstExpr() const OVERRIDE { return expr->isConstExpr(); }      bool isConstExpr() const OVERRIDE { return expr->isConstExpr(); }
691      bool isPolyphonic() const OVERRIDE { return expr->isPolyphonic(); }      bool isPolyphonic() const OVERRIDE { return expr->isPolyphonic(); }

Legend:
Removed from v.3575  
changed lines
  Added in v.3576

  ViewVC Help
Powered by ViewVC