Comments (6)
I also had a need for this, and recently released https://github.com/robertothais/ohm-cli.
It currently only supports validating grammars and recognizing inputs. I'd like to add support for semantic actions soon. Any feedback is welcome.
from ohm.
I'm going to close this as we now have an "official" CLI tool.
from ohm.
Hi Blake,
I think that's worth a shot and we could put something like that in bin
. There currently is a script in this directory - es5bench
- that does something similar: Parse dist/ohm.js
against the ES5 grammar and compile it to JS code (using examples/ecmascript/compile.js
). It's not a semantics but I don't see why it couldn't be.
from ohm.
I agree that it would be useful to have something like this!
On Thu, Mar 3, 2016 at 2:47 PM, mroeder [email protected] wrote:
Hi Blake,
I think that's worth a shot and we could put something like that in bin
http://../blob/master/bin. There currently is a script in this
directory - es5bench http://../blob/master/bin/es5bench - that does
something similar: Parse dist/ohm.js against the ES5 grammar and compile
it to JS code (using examples/ecmascript/compile.js
http://../blob/master/examples/ecmascript/compile.js). It's not a
semantics but I don't see why it couldn't be.—
Reply to this email directly or view it on GitHub
#71 (comment).
from ohm.
It looks like this was done.
$ npm install ohm-js -g
$ ohm-js $opts
from ohm.
No, it actually is still in the pipeline (something that takes grammar, semantics, operation/attribute name and input and processes it).
from ohm.
Related Issues (20)
- Type definitions for parameterized rules are inconsistent with behavior HOT 1
- Semantic action '[...]' has the wrong arity: expected 3, got 0 HOT 5
- Semantic actions for comments defined under the space rule HOT 1
- Add ability to type operation parameters & return values HOT 11
- CLI: Line endings in generated files vary across systems and platforms HOT 1
- cli.js is reading incorrect package.json file for version HOT 2
- Typescript example causes error HOT 1
- space with applySyntactic causes failure
- `toAST` incorrectly makes some nodes intermediate nodes HOT 1
- Indentation-sensitive grammar forgets consumed dedents HOT 1
- Syntax error handling? HOT 2
- Indentation-sensitive parsing: dedent not working? HOT 3
- Typescript example fails to compile HOT 1
- "Built-in Rules" section of syntax reference docs are incorrectly formatted
- No indication of stack size exceeded
- Do we get comments from ohm? HOT 6
- Idiomatic way to do partial (prefix) parses
- NPM release behind latest commit
- Partially parse grammar
- Odd behavior: Alternation fails instead of trying second alternative
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ohm.