Commit graph

187 commits

Author SHA1 Message Date
jberg
a925bfc31e measure image if we don't have node attributes to use (#811)
* measure image if we don't have node attributes to use

* return image, allow for x/y to be specificied without w/h
2019-11-30 13:42:53 -08:00
jberg
d6f9ce8351 tweak 2 arg operatores and coercion (#810) 2019-11-30 13:42:53 -08:00
Jordan Eldredge
005629f9e9 Abstract how we handle two argument operators.
Some don't work. I wonder why.
2019-11-30 13:42:53 -08:00
Jordan Eldredge
3798934615 Don't log the "done" promise 2019-11-30 13:42:53 -08:00
Jordan Eldredge
05362da4a3 Be consistent with ordering of a and b, even when it does not matter
Interestingly this changes the order of << but tests still pass
2019-11-30 13:42:53 -08:00
Jordan Eldredge
5a7489db4e Commands only have a single argument 2019-11-30 13:42:53 -08:00
jberg
e015c15625 fix tests, sprinkle more async/await (#809) 2019-11-30 13:42:53 -08:00
jberg
f56d44cbb8 remove integer checking (#808) 2019-11-30 13:42:53 -08:00
Jordan Eldredge
fb14ae9a00 Run prettier 2019-11-30 13:42:53 -08:00
jberg
4c06a38d46 add simple function tests, run wa5 tests (#806)
* add simple function tests

* add simple functions to test suite

* add popTo/callGlobal definitions

* use interpret for callGlobal, pass stack to interpret

* type check and cast to int when setting variables

* need to await interpret calls

* get wa5 tests running

* add some comments
2019-11-30 13:42:53 -08:00
Jordan Eldredge
0187838132 Reference correct skin in utils test 2019-11-30 13:42:53 -08:00
jberg
e8e49103a9 simplify type coercion / fix destructuring related error (#807) 2019-11-30 13:42:53 -08:00
jberg
9007b1c4ee More basic tests (#805)
* add more basic tests

* add/update passing test strings

* only coerce if int is on LHS
2019-11-30 13:42:53 -08:00
jberg
1146ce4758 implement more operators and coerce types (#804)
* implement more operators and coerce types

* add remaining operators
2019-11-30 13:42:53 -08:00
Jordan Eldredge
8e0f50a2e6 Fix initial paused state 2019-11-30 13:42:53 -08:00
Jordan Eldredge
66c3a5c058 Improve debugging 2019-11-30 13:42:53 -08:00
Jordan Eldredge
cf2e8992af Use a reducer to update state 2019-11-30 13:42:53 -08:00
jberg
6b1301cef9 check type on modulo (#803) 2019-11-30 13:42:53 -08:00
Jordan Eldredge
dcbcd20a65 Implement more operators and add debugger 2019-11-30 13:42:53 -08:00
Jordan Eldredge
c02b59219c Inject logger 2019-11-30 13:42:53 -08:00
Jordan Eldredge
6ce7193bc0 Reenable tests 2019-11-30 13:42:53 -08:00
Jordan Eldredge
0abccdd211 Allow parser.js to run in the browserFor some reason object destructuing makes someone assume we should be using es6 exports 2019-11-30 13:42:53 -08:00
Jordan Eldredge
736a922cba Compensate for the upcoming i++ 2019-11-30 13:42:53 -08:00
Jordan Eldredge
5c4c82f4d8 Start running basic test 2019-11-30 13:42:53 -08:00
Jordan Eldredge
deb8289d6a Add missing opcodes
the basicTest.m file, compiled by the Winamp3 compiler (and perhaps others) output these opcodes which are unknown to the decompiler. I _think_ this is what they are supposed to be.
2019-11-30 13:42:53 -08:00
Jordan Eldredge
f94fcf2579 Consolidate line 2019-11-30 13:42:53 -08:00
jberg
cf9c58c31b add basic maki operator tests (#802) 2019-11-30 13:42:53 -08:00
Jordan Eldredge
ec25acfc1e Extract version info 2019-11-30 13:42:53 -08:00
Jordan Eldredge
44fb10d776 Inline calculating position 2019-11-30 13:42:53 -08:00
Jordan Eldredge
ec754cfbce Pull local functions into their own thing 2019-11-30 13:42:53 -08:00
Jordan Eldredge
53c06ab7c4 Move binding logic into Variable 2019-11-30 13:42:53 -08:00
Jordan Eldredge
d52129c5d9 Improve error message for missing classes 2019-11-30 13:42:53 -08:00
Jordan Eldredge
27aba0b826 Add commented version of interpreting maki 2019-11-30 13:42:53 -08:00
Jordan Eldredge
39bad700e9 Handle unknown objects better 2019-11-30 13:42:53 -08:00
Jordan Eldredge
ff26800905 Split out function for formatting ids 2019-11-30 13:42:53 -08:00
Jordan Eldredge
0711ac4bbf Use the name "data" 2019-11-30 13:42:53 -08:00
Jordan Eldredge
8806b78c0a Don't use buffer when parsing maki 2019-11-30 13:42:53 -08:00
Jordan Eldredge
256e24d83d Move the maki-interpreter experiment into the modern experiment
We're getting to a place where it's going to be feasible to test the
Maki interpreter in the browser, so it makes sense to merge the two
experiments.
2019-11-30 13:42:53 -08:00
jberg
7db826ffba add simple skin (#801) 2019-11-30 13:42:53 -08:00
Jordan Eldredge
2337fa93e7 Homonyms, how do they work? 2019-11-30 13:42:53 -08:00
Jordan Eldredge
0f35f71737 Get rid of props 2019-11-30 13:42:53 -08:00
Jordan Eldredge
4a15cde301 Start writing MakiFile to use a Uint8Array under the hood
For now we do both and assert that they behave the same
2019-11-30 13:42:53 -08:00
Jordan Eldredge
26009a7cd1 Error on invalid arg type 2019-11-30 13:42:53 -08:00
Jordan Eldredge
9117b0572a Don't use Buffer outside of MakiFile 2019-11-30 13:42:53 -08:00
Jordan Eldredge
94aaa2eb7b Setup multi version test 2019-11-30 13:42:53 -08:00
Jordan Eldredge
b2eedf67fd Don't share subscriptions between instances 2019-11-30 13:42:53 -08:00
Jordan Eldredge
afb3b7851a Add first integration test 2019-11-30 13:42:53 -08:00
Jordan Eldredge
9116793fb9 Pass values to functions, not variables. 2019-11-30 13:42:53 -08:00
Jordan Eldredge
502dade90a Fix typo 2019-11-30 13:42:53 -08:00
Jordan Eldredge
3804621603 Allow cli to be executed directly 2019-11-30 13:42:53 -08:00