[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: odd thing
- From: "Kelmar K. Firesun" <kfiresun@...>
- Date: Thu, 5 Sep 2002 23:55:11 -0500
----- Original Message -----
From: "Srivatsan Raghavan" <email@example.com>
To: "Multiple recipients of list" <firstname.lastname@example.org>
Sent: Thursday, September 05, 2002 8:51 PM
Subject: odd thing
> but i'm wondering why lua's string handling functions use a strange
> pseudo-regex syntax as
> opposed to the well-known syntax that's used by everyone else?
This is really just a guess, but I would beleive this is because the
full blown regular expression functions are not part of the ANSI C
standard. Many platforms/compilers do not have the regex() and co.
I have looked at the source for these functions, and they are quite
large; so I think the simplified version was selected becuase it
would more easily fit in embeded systems.
> on that note, i'm considering writing a wrapper for pcre ( www.pcre.org
> ) to lua ..
> can anyone give any suggestions on where i can start learning the lua C
> api ?
The reference manual that comes with Lua explains the API quite nicely
(IMHO) and is rather easy to use. Wraping regex() or other such functions
into a Lua module should be a snap.
Kelmar K. Firesun (IRL: Bryce Simonds)