Giter VIP home page Giter VIP logo

Comments (9)

andgineer avatar andgineer commented on August 16, 2024

@Alexey-T could you fix that? and add tests for re like '[[ab]', '[]ab]'?

from tregexpr.

Alexey-T avatar Alexey-T commented on August 16, 2024

Will try it

from tregexpr.

Alexey-T avatar Alexey-T commented on August 16, 2024

Line 1010 is in the func RegExprSubExpressions, so the issue is in this func? Or it’s everywhere? Repro steps?

from tregexpr.

andgineer avatar andgineer commented on August 16, 2024

It checks for “]” as first char inside [] and in this case includes it into the char set.
But also it have to check also for “[” so we can use re “[[ab]*” to find string like “a[b”

To chech that we need tests with re like “[[ab]” and “[]ab]”

from tregexpr.

andgineer avatar andgineer commented on August 16, 2024

May be I found wrong line - it shoud be inside re parser

from tregexpr.

Alexey-T avatar Alexey-T commented on August 16, 2024

What wrong line, sorry ?

from tregexpr.

andgineer avatar andgineer commented on August 16, 2024

Line 1010
As I see it should be

'[':

but we have to support this syntax in RegExprSubExpressions too

from tregexpr.

Alexey-T avatar Alexey-T commented on August 16, 2024

Pull request, with test 38

from tregexpr.

andgineer avatar andgineer commented on August 16, 2024

silly me - we do not need to check for '[' because user class ("[]") includes just any char but ']'.
so we should check only for ']' at first position.

from tregexpr.

Related Issues (20)

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.