deSubgraphKit bug: unscope can specify temps (please confirm)
Kevin Reid <[email protected]>
| Newsgroups | gmane.comp.lang.e.general |
|---|---|
| Message-ID | <[email protected]> |
If the provided unscope contains an integer, it is interpreted as specifying a temp in the graph being serialized. This seems like a POLA violation to me, as well as an undesirable type-unsafety. ? def deSubgraphKit := <elib:serial.deSubgraphKit> # value: <deSubgraphKit> ? deSubgraphKit \ > .makeRecognizer(null, ["a" => 0, __makeList => "__makeList"]) \ > .recognize([["foo", "foo"], "a"], > deSubgraphKit.makeBuilder([=> __makeList])) # value: [["foo", "foo"], <***CYCLE***>] Note that in the general case, the unscope can designate objects it does not itself have access to. If it is agreed that this is a bug, I will revise generate(obj) in deSubgraphKit to throw if the unscope value is not a string. -- Kevin Reid <http://homepage.mac.com/kpreid/>