[Pharo-project] learning rewrite rules

Lukas Renggli renggli at gmail.com
Thu Nov 4 17:50:32 CET 2010


> ok I added the files this is better.

Yes, I could read the french article now.

I am not quite convinced with the explanation of the back-tick though:

"Un schéma peut contenir des variables en utilisant le backquote ou
accent grave. Ainsi, `key représente n’importe quelle variable, mais
pas une expression."

"`key" is a *meta-variable*, not necessarily a variable in the matched
tree. Depending on the context it can also be a selector, e.g. "foo
`key" matches all unary selectors sent to a variable called 'foo'.

Ok, my french might not be that good :-)

Also check page 42--43 of my PhD
(http://scg.unibe.ch/archive/phd/renggli-phd.pdf): 4.1.1 Tree Pattern
Matching. It is a bit dense and doesn't explain everything, but the
basic matching is described and was successfully tested on students.

Lukas

-- 
Lukas Renggli
www.lukas-renggli.ch




More information about the Pharo-project mailing list