diff options
| Commit | 370d2afe025f899caab7829407363a37a37093b2 (patch) | |
|---|---|---|
| Author | 2018-10-14 18:09:45 +0300 | |
| Committer | 2018-10-14 18:09:45 +0300 | |
| Files | c9cf14183738b92052879009babdad16d0f7dfad /JSImpl/src/Expression.cpp | |
| IPL-370d2afe025f899caab7829407363a37a37093b2.tar IPL-370d2afe025f899caab7829407363a37a37093b2.tar.gz IPL-370d2afe025f899caab7829407363a37a37093b2.zip | ||
| Parent | a24ea4d6be0a92f9d2d8e937d08f6ea5575021ef (diff) | |
Split literls in different classes and remove all handwritten code.
1 files changed, 0 insertions, 29 deletions
| -rw-r--r-- | JSImpl/src/Expression.cpp | 29 |
diff --git a/JSImpl/src/Expression.cpp b/JSImpl/src/Expression.cpp index b8044e1..7153b3f 100644 --- a/JSImpl/src/Expression.cpp +++ b/JSImpl/src/Expression.cpp @@ -1,33 +1,4 @@ #include "Expression.h" #include <assert.h> -LiteralExpression::LiteralExpression(double v) - :m_Type(LiteralType::Number) - , m_NumValue(v) -{} -LiteralExpression::LiteralExpression(IPLString& v) - : m_Type(LiteralType::String) - , m_StringValue(v) -{} - -LiteralExpression::LiteralExpression(bool v) - : m_Type(LiteralType::Boolean) - , m_BooleanValue(v) -{} - -LiteralExpression::LiteralExpression(TokenType type) -{ - if (type == TokenType::Null) - { - m_Type = LiteralType::Null; - } - else if (type == TokenType::Undefined) - { - m_Type = LiteralType::Undefined; - } - else - { - assert(false); - } -} |
