Git Product home page Git Product logo

Comments (3)

c272 avatar c272 commented on June 18, 2024 1

@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.

skerit avatar skerit commented on June 18, 2024

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.

skerit avatar skerit commented on June 18, 2024

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)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.