[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

can s-exprs represent a graph without eval?



Many extensions to Scheme support this, and I imagine they probably
obtained their notation from (Common?) Lisp.  In Chez Scheme, PLT
Scheme and others, you can write programs such as this:

  > (define v '#0=(a . #0#))

so that

  > (car v)
  a
  > (cadr v)
  a
  > (caddr v)
  a

and

  > (cdr v)
  #0=(a . #0#)

In general, #n= binds while #n# refers.

Shriram