This repository has been archived by the owner on May 11, 2020. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
wast: first import of a wast format scanner+parser
- `tokens.go`: Defines the Token type generated by the scanner and several utility functions around it - `test.wast`: A .wast test file extracted from [wasm's spec tests](https://github.com/WebAssembly/spec/blob/master/test/core/names.wast) - `scanner.go`: Implements the actual scanner and utilty functions regarding runes - `scanner_test.go`: A dead simple test case against the `test.wast` file. It doesn't verify correctness yet. - Added several new token kind constants to list different typed instructions such as `i64.reinterpret/f64` or `i32.add` - Implemented the `(*Scanner).scanTypedReserved()` method to identify well and ill-formed typed instructions - Better Scanner test interface, the test suite now takes a `-wast-file` flag that must point to the `.wast` file to Scan and test against. In order to test: - Create (or use a [`spec/test/core`](https://github.com/WebAssembly/spec/tree/master/test/core) ) wast file Updates #34.
- Loading branch information