[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: can s-exprs represent a graph without eval?
>>>>> "James" == James McCartney <asynth@io.com> writes:
James> S-exprs can represent trees of data easily. I am wondering
James> if s-exprs, or some other syntax, can be used to represent
James> a graph just on reading, without eval.
James> I assume something simple could be done where you have a
James> syntax to bind symbols, and then access their bindings.
James> Does Lisp do this already? or is graph data just written
James> as Lisp code and eval'ed?
Some lisps have ways of representing circular list structure; that
might be what you want. See
http://download.plt-scheme.org/doc/mzscheme/mzscheme-Z-H-14.html#node_sec_14.5,
for one example.
--
People studying literature rarely say anything that would be of the
slightest use to those producing it.
-- Paul Graham