Replies: 2 comments 15 replies
-
|
Hahahaha I really enjoyed watching you fight with an AI and get nowhere. Thanks for sharing that! I don't actually parse regex, I depend on an existing parser. The code you see here is just executing parsed patterns. As to how the code works, think of it as evolving the pattern over time! If the pattern to match is That's the easy part, but say the pattern is |
Beta Was this translation helpful? Give feedback.
-
|
@jcbhmr I picked up the playground code and dusted it off. I had it working well at one point, but then the architecture changed some more and my focus shifted to other projects. At the moment what it needs is some d3.js work to render state the way the engine is currently storing it. Would you be interested in helping with that work? My theory is that if I can help people understand how the code works (by just showing them how it works), then I can attract the maintenance attention needed to build some other features I've been neglecting -- most importantly unicode support. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello @conartist6! 👋
Thanks for making this awesome project! I especially appreciate the way you publicly post on the GitHub Issue tracker with your current progress; 😆 I do the same thing and thought it was funny.
I got a playground example working, and it made me think... How the heck does this code actually work?
I tried to have a conversation with ChatGPT about it, but that didn't get me very far. https://sharegpt.com/c/nf0YXQn I also tried reading through the article that was linked in the README https://jasonhpriestley.com/regex and (I'll be honest) didn't completely understand it.
What I guess I'm asking is: how did you make this incredible magic machine? It seems to implement a custom regex parser. How did you do that? What happens to my
/hello/gpattern when it goes into theEngine? How do you know when bytes are safe to discard from the stream (this is my big question)? Is there an architectural reason whyexec()andexecGlobal()are two separate functions (some parser quirk?)?I'd be interested in learning more about how this project works. No particular purpose, I'm just curious. 🤓
Sidenote: How does this @iter-tools/regex package compare to something like https://oxism.com/works/stream-snitch/ ?
Beta Was this translation helpful? Give feedback.
All reactions