Jimka <firstname.lastname@example.org> wrote:
| By the say, parsing EDIF is more than just calling read.
| There is the problem of case to consider. The keywords
| of EDIF itself are apparently case independent, but the
| design data it is trying to represent is very case sensitive.
| Any type of walker of the data must remember to match
| keywords in a case fold manner, but to respect case
| of other data.
In the small amount of EDIF post-processing I've done recently,
I've found that (setf (readtable-case *readtable*) :invert) helps
a lot with the design data, without screwing up the rest of my
If you're only dealing with EDIFs from one design tool, then the case
of the keywords tends to be constant -- camelcased, with the tools I've
been dealing with [e.g. "edifVersion", "viewRef", "cellRef"]:
(edifVersion 2 0 0)
(keywordMap (keywordLevel 0))
(timeStamp 2005 05 23 23 05 04)
(program "CAPTURE.EXE" (Version "10.3.0.p001"))
(comment "Original data from OrCAD/CAPTURE schematic"))
(comment "Wednesday, March 02, 2005")
But if you're mixing various EDIF-generating tools [i.e., dealing
with EDIFs from various tools], then I suspect you're correct that
you need to do case-independent matching on the keywords.
| Another problem is that each keyword can only appear
| in certain contexts defined by some state machine. The
| state machine is explained in a 500 page EDIF manual
| but there is no program available to do operations on the
| data structure with correctness maintained.
My needs so far have been minimal; I've been able to extract
the data I needed with very simple CL tree-walking functions.
Rob Warnock <email@example.com>
627 26th Avenue <URL:http://rpw3.org/>
San Mateo, CA 94403 (650)572-2607