[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Humor in unusal places
- From: Paige DePol <lual@...>
- Date: Sat, 13 Jan 2018 08:58:17 -0600
steve donovan <steve.j.donovan@gmail.com> wrote:
> This is probably true for any hard thing, like an organ player reading
> left hand, right hand
> _and_ foot pedals. The question is, what is more maintainable for
> normal people who can only read one line of music at a time?
I can play a clarinet, but forget a piano and nevermind foot pedals!
Well... if I tried playing one now I'd probably sound terrible! ;)
However, my point still stands... sure at first you may have an issue
with reading multiple lines of music, or keeping time over long rests
in the music, or any other analogy, but in time you should get better!
> The Rust flavour of regexp works like that, nice design. Adds more
> than 400kb to "hello world" though and some crates have deliberately
> dropped it as a "too heavy" dependency. So I wrapped the 400 lines
> (!) core of Lua pattern matching as a little crate, lua-patterns.
The /x modifier really was a great help when I was learning the finer
details of regular expressions... but I can see why it would be deemed
to be "too heavy" for many applications. I added regular expression
support to my hard fork of Lua for shell scripting mostly.
Learning how Lua works internally and adding things via direct patching
has been a really nice learning experience! Adding regular expression
support was just another journey that ended in success!
> Fun fact: the PCRE implementation is rather larger (390K) than Lua 5.2
> (195K) on my system.
Yes, I know that PCRE is quite a bit larger than Lua itself, however, if
you need regular expressions (or just want them) then they can be used!
I will definitely look into Lua patterns though, it does seem that they
could be quite useful for the simpler data-extraction cases. However, I
think regular expressions, in all their line-noise glory, will always be
special to me! ;)
~Paige