Ann: Plex 1.0 - Lexical analysis module

Greg Ewing greg at cosc.canterbury.ac.nz
Wed Mar 8 23:27:57 EST 2000


Well, I've got as far as putting in everything I promised
to do before 1.0, so here it is:

http://www.cosc.canterbury.ac.nz/~greg/python/Plex

Changes since Version 0.5

   1.Range() constructor for patterns which match
     contiguous ranges of characters. 
   2.Support for traditional regular expression
     syntax. 
   3.Building a Lexicon is about 4 times faster. 
   4.The assumption of 8-bit character codes has
     been removed. It should be Unicode-ready now.
   5.The scanner is unfortunately a whisker slower.
     Not quite sure why - seems to be a consequence
     of change (4). Sorry about that! Hope to do a C
     version soon, though. 

Abstract:

Plex is a Python module for constructing lexical
analysers, or scanners. Plex scanners have almost all
the capabilities of the scanners generated by GNU
Flex, and are specified in a very similar way. Tokens
are defined by regular expressions, and each token
has an associated action, which may be to return a
literal value, or to call an arbitrary function. 

-- 
Greg Ewing, Computer Science Dept,
+--------------------------------------+
University of Canterbury,	   | A citizen of NewZealandCorp, a	  |
Christchurch, New Zealand	   | wholly-owned subsidiary of USA Inc.  |
greg at cosc.canterbury.ac.nz	   +--------------------------------------+



More information about the Python-list mailing list