-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e4ff7de
commit e04a7ac
Showing
14 changed files
with
303 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#pragma once | ||
|
||
namespace Vaev::Script { | ||
|
||
struct Expression {}; | ||
|
||
} // namespace Vaev::Script |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#pragma once | ||
|
||
namespace Vaev::Script { | ||
|
||
struct Identifier {}; | ||
|
||
} // namespace Vaev::Script |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#pragma once | ||
|
||
namespace Vaev::Script { | ||
|
||
struct Module {}; | ||
|
||
} // namespace Vaev::Script |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#pragma once | ||
|
||
namespace Vaev::Script { | ||
|
||
struct Script {}; | ||
|
||
} // namespace Vaev::Script |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#pragma once | ||
|
||
namespace Vaev::Script { | ||
|
||
struct Statement {}; | ||
|
||
} // namespace Vaev::Script |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
#include <karm-math/funcs.h> | ||
|
||
#include "value.h" | ||
|
||
namespace Vaev::Script { | ||
|
||
// MARK: Numeric Types --------------------------------------------------------- | ||
// https://tc39.es/ecma262/#sec-ecmascript-language-types-number-type | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-unaryMinus | ||
Number Number::unaryMinus() { | ||
if (Math::isNan(_val)) | ||
return Math::NAN; | ||
return -_val; | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-bitwiseNOT | ||
Number Number::bitwiseNot() { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-exponentiate | ||
Number Number::exponentiate(Number exp) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-multiply | ||
Number Number::multiply(Number multiplicand) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-divide | ||
Number Number::divide(Number divisor) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-remainder | ||
Number Number::remainder(Number divisor) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-add | ||
Number Number::add(Number augend) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-subtract | ||
Number Number::subtract(Number subtrahend) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-leftShift | ||
Number Number::leftShift(Number shiftCount) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-signedRightShift | ||
Number Number::signedRightShift(Number shiftCount) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-unsignedRightShift | ||
Number Number::unsignedRightShift(Number shiftCount) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-lessThan | ||
Boolean Number::lessThan(Number y) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-equal | ||
Boolean Number::equal(Number y) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-sameValue | ||
Boolean Number::sameValue(Number y) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-sameValueZero | ||
Boolean Number::sameValueZero(Number y) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numberbitwiseop | ||
Number Number::bitwiseOp(Number y, f64 op) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-bitwiseAND | ||
Number Number::bitwiseAnd(Number y) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-bitwiseXOR | ||
Number Number::bitwiseXor(Number y) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-bitwiseOR | ||
Number Number::bitwiseOr(Number y) { | ||
} | ||
|
||
// https://tc39.es/ecma262/#sec-numeric-types-number-tostring | ||
String Number::toString() { | ||
} | ||
|
||
} // namespace Vaev::Script |
Oops, something went wrong.