
Visitor:
Just Do It
Didier Verna
Introduction
C++
LISP
Step 1: plain LIS P
Step 2: brute force
Step 3: first class
Step 4: mapping
Step 5: generic map
State
Step 6: objects
Step 7: closures
step 8: visit schemes
Conclusion
Patterns descriptions / organizations
GOF: Creational, Structural, Behavioral
usage-oriented
POSA: Architectural, Design, Idioms
abstraction-oriented
Idioms according to POSA
An idiom is a low-level pattern specific to a
programming language. An idiom describes how to
implement particular aspects of components or the
relationships between them using the features of
the given language. [. . . ] They address aspects of
both design and implementation.
GOF’s design patterns are closer to POSA’s idioms
5/25