[squeak-dev] Question about VB-Regex

John Pfersich smalltalker2 at mac.com
Mon Mar 30 04:53:38 UTC 2020


I know it’s a little old-fashioned to recommend a book, but you might learn a thing or two about regexes from Mastering Regular Expressions by Friedl. It’s an OReilly book. Mine’s copyright 2002, second edition, about 430 pages deep. Still on my reference shelf after 20 years.

/————————————————————/
For encrypted mail use jgpfersich at protonmail.com
Get a free account at ProtonMail.com
Web: https://objectnets.net and https://objectnets.org
https://datascilv.com https://datascilv.org


> On Mar 29, 2020, at 11:42, Thiede, Christoph <Christoph.Thiede at student.hpi.uni-potsdam.de> wrote:
> 
> 
> Hi Regex friend :-)
> 
> 
> 
> I assume you are referring to Regex-Core (thanks for the clarification, Levente!).
> 
> 
> 
> Yes, regexes are indeed very nerdy fun, though I recommend to use them rarely in production stuff, they just don't provide a really good readability. I don't know how experienced you are with regex in general, but I can recommend you regex101.com if you did not know it yet. I'm not sure what you are looking for in detail, but if you're interested in further examples, here are a few ones:
> 
> 
> 
> http://forum.world.st/The-Inbox-Tests-ct-429-mcz-td5113665.html#:~:text=allRangesOfRegexMatches (see #testUndefinedVariable and #testUnusedVariable).
> 
> 
> 
> In Regex-Core-ct.55 f., I extended the implementation of lookaround expressions in Smalltalk.
> 
> (This is a small piece of art:
> 
> '(?<=(?<!n''t\s+)l[o]ve\s+)\w+' asRegex matchesIn: 'I love Squeak. I don''t love C++. I love Smalltalk.'.
> :-))
> 
> And in as near as possible future, I will commit support for \x and \p as described here. Stay tuned!
> 
> 
> Best,
> 
> Christoph
> 
> Von: Squeak-dev <squeak-dev-bounces at lists.squeakfoundation.org> im Auftrag von Chris Cunnington <brasspen at gmail.com>
> Gesendet: Sonntag, 29. März 2020 18:08:44
> An: The general-purpose Squeak developers list
> Betreff: Re: [squeak-dev] Question about VB-Regex
>  
> You posted an #asRegex example in talking to Eliot about inlining recently. I’ve printed it out and plan to play with it next week. 
> If you have any more thoughts or examples using the VB-Regex package, I hope you’ll post some here. I’m very interested in this stuff. 
> 
> Chris 
> 
>> On Mar 29, 2020, at 9:44 AM, Thiede, Christoph <Christoph.Thiede at student.hpi.uni-potsdam.de> wrote:
>> 
>> Hi all,
>> 
>> as you may have noticed, I have proposed some new features for Regex-Core in recent past, and I found a lot of fun in working with this clean architecture for which I still see a lot of potential for expansion (for example, I'm currently having basic support for Unicode matches in my pipeline, this is currently blocked by this thread. For the future, I also would like to consider named groups & depending features). But before I will invest unnecessary time into the Regex-Core package, I have one question:
>> 
>> Recently I stumbled upon VB-Regex, which looks very similar to Regex-Core. Has this been a predecessor of Regex-Core, is it a successor or are they two independent forks? I could not find any information about this topic on the web.
>> Is my assumption correct that Regex-Core is the regex "state of the art" within Squeak?
>> 
>> Best,
>> Christoph
> 
> 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20200329/cc032675/attachment.html>


More information about the Squeak-dev mailing list