MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / iter_fields

Function iter_fields

tools/python-3.11.9-amd64/Lib/ast.py:255–264  ·  view source on GitHub ↗

Yield a tuple of ``(fieldname, value)`` for each field in ``node._fields`` that is present on *node*.

(node)

Source from the content-addressed store, hash-verified

253
254
255def iter_fields(node):
256 """
257 Yield a tuple of ``(fieldname, value)`` for each field in ``node._fields``
258 that is present on *node*.
259 """
260 for field in node._fields:
261 try:
262 yield field, getattr(node, field)
263 except AttributeError:
264 pass
265
266
267def iter_child_nodes(node):

Callers 3

iter_child_nodesFunction · 0.70
generic_visitMethod · 0.70
generic_visitMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected