Comments (3)
@skerit Lookbehinds are not permitted in normal Iro because the lowest-common-denominator Javascript regex parsers do not support them. However, there is no such limitation at the moment for you compiling with lookbehinds using iro4cli
, just note that it might break Atom and Rouge compatibility, and there's no guarantee of them working with certain regex parsers.
The file will likely be generated fine, it might just not work in some contexts.
I will add a warning in iro4cli
that lets you know that lookbehinds are not fully supported in Iro. 😃
Also sorry, I don't have any detailed examples of Iro grammar files on hand, but I can point you to the file I used in my toy language a while ago, which you can find here. Not exactly complex I know, sorry. 😅
from iro4cli.
I decided to give it another go and create an HTML Iro syntax from scratch, and to not focus too much on how Sublime or existing tmlanguage files implement it.
It's still a WIP, but I'm getting there.
from iro4cli.
Ah, unfortunately Iro does not support lookbehinds... So even though parsing HTML is doable, JavaScript is not because you need lookbehinds for literal regular expressions.
from iro4cli.
Related Issues (15)
- Make missing scopes for Ace and Rouge inherit from Textmate and Pygments. HOT 1
- Supporting ANTLR 4 or Langium grammars HOT 4
- Add support for tmLanguage json schema HOT 1
- Rename flag --vscode to avoid confusions
- Add option to suppress warnings
- hex color codes error HOT 4
- Grammar railroad diagram
- Please tag a new release
- Seems to register regex look-ahead as a capture group HOT 1
- License HOT 2
- VS Code Extension HOT 2
- Using Iro's CLI verison HOT 1
- Any plans on adding Sublime3 support? HOT 3
- `iro4cli` crashes on a seemingly correct grammar HOT 3
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 iro4cli.