1 |
/* |
/* |
2 |
* Copyright (c) 2014-2019 Christian Schoenebeck |
* Copyright (c) 2014-2020 Christian Schoenebeck |
3 |
* |
* |
4 |
* http://www.linuxsampler.org |
* http://www.linuxsampler.org |
5 |
* |
* |
44 |
StmtFlags_t flags; ///< general completion status (i.e. success or failure) of the function call |
StmtFlags_t flags; ///< general completion status (i.e. success or failure) of the function call |
45 |
vmint value; ///< result value of the function call |
vmint value; ///< result value of the function call |
46 |
vmfloat unitPrefixFactor; ///< unit factor of result value of the function call |
vmfloat unitPrefixFactor; ///< unit factor of result value of the function call |
47 |
|
StdUnit_t unitBaseType; ///< fundamental standard measuring unit type (e.g. seconds), this is ALWAYS and ONLY set (to the actual unit type) by @c FunctionCall class for performance reasons. |
48 |
|
|
49 |
VMIntResult() : flags(STMT_SUCCESS), value(0), unitPrefixFactor(VM_NO_FACTOR) {} |
VMIntResult(); |
50 |
vmint evalInt() OVERRIDE { return value; } |
vmint evalInt() OVERRIDE { return value; } |
51 |
VMExpr* resultValue() OVERRIDE { return this; } |
VMExpr* resultValue() OVERRIDE { return this; } |
52 |
StmtFlags_t resultFlags() OVERRIDE { return flags; } |
StmtFlags_t resultFlags() OVERRIDE { return flags; } |
53 |
bool isConstExpr() const OVERRIDE { return false; } |
bool isConstExpr() const OVERRIDE { return false; } |
54 |
vmfloat unitFactor() const OVERRIDE { return unitPrefixFactor; } |
vmfloat unitFactor() const OVERRIDE { return unitPrefixFactor; } |
55 |
StdUnit_t unitType() const OVERRIDE { return VM_NO_UNIT; } // actually never called, VMFunction::returnUnitType() is always used instead |
StdUnit_t unitType() const OVERRIDE { return unitBaseType; } |
56 |
bool isFinal() const OVERRIDE { return false; } // actually never called, VMFunction::returnsFinal() is always used instead |
bool isFinal() const OVERRIDE { return false; } // actually never called, VMFunction::returnsFinal() is always used instead |
57 |
}; |
}; |
58 |
|
|
65 |
StmtFlags_t flags; ///< general completion status (i.e. success or failure) of the function call |
StmtFlags_t flags; ///< general completion status (i.e. success or failure) of the function call |
66 |
vmfloat value; ///< result value of the function call |
vmfloat value; ///< result value of the function call |
67 |
vmfloat unitPrefixFactor; ///< unit factor of result value of the function call |
vmfloat unitPrefixFactor; ///< unit factor of result value of the function call |
68 |
|
StdUnit_t unitBaseType; ///< fundamental standard measuring unit type (e.g. seconds), this is ALWAYS and ONLY set (to the actual unit type) by @c FunctionCall class for performance reasons. |
69 |
|
|
70 |
VMRealResult() : flags(STMT_SUCCESS), value(0), unitPrefixFactor(VM_NO_FACTOR) {} |
VMRealResult(); |
71 |
vmfloat evalReal() OVERRIDE { return value; } |
vmfloat evalReal() OVERRIDE { return value; } |
72 |
VMExpr* resultValue() OVERRIDE { return this; } |
VMExpr* resultValue() OVERRIDE { return this; } |
73 |
StmtFlags_t resultFlags() OVERRIDE { return flags; } |
StmtFlags_t resultFlags() OVERRIDE { return flags; } |
74 |
bool isConstExpr() const OVERRIDE { return false; } |
bool isConstExpr() const OVERRIDE { return false; } |
75 |
vmfloat unitFactor() const OVERRIDE { return unitPrefixFactor; } |
vmfloat unitFactor() const OVERRIDE { return unitPrefixFactor; } |
76 |
StdUnit_t unitType() const OVERRIDE { return VM_NO_UNIT; } // actually never called, VMFunction::returnUnitType() is always used instead |
StdUnit_t unitType() const OVERRIDE { return unitBaseType; } |
77 |
bool isFinal() const OVERRIDE { return false; } // actually never called, VMFunction::returnsFinal() is always used instead |
bool isFinal() const OVERRIDE { return false; } // actually never called, VMFunction::returnsFinal() is always used instead |
78 |
}; |
}; |
79 |
|
|