[Libre-soc-bugs] [Bug 1094] insndb instruction database visitor-walker is needed

bugzilla-daemon at libre-soc.org bugzilla-daemon at libre-soc.org
Fri Jun 9 23:11:17 BST 2023


--- Comment #74 from Luke Kenneth Casson Leighton <lkcl at lkcl.net> ---
ahhh... this may have been a misunderstanding


  class ListVisitor(Visitor):
    def __call__(self, node):
        if isinstance(node, Record):
        yield node

below is much better and readable, and it is a really beneficial
part of the API


  class ListVisitor(Visitor):
    def Record(self, node):
        yield node

was there a technical reason to make this change?

when i was referring to use of isinstance, i was referring to the
(now decoupled) database-walking-function, not the visitors.
(now called Dataclass.walk)

You are receiving this mail because:
You are on the CC list for the bug.

More information about the libre-soc-bugs mailing list