You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
WIP: config/schema: collect annotations in :pairs()
Sometimes we need to know somethings about parent nodes during
processing of a current node.
The ideal solution would be pre-process schema in `schema.new()` and
saturate schema nodes with extra information. For example, we can add a
`parent` field. Or merge annotations from the root node down to the
current one and store in the current node.
However, we have shared schema nodes between instance_config and
cluster_config. I'm in a doubt whether the copying in appropriate places
would be error-prone.
The next commit needs the annotations from the parent nodes in
`<schema>:pairs()`, so this functionality is added to this particular
method.
TBD: Consider the alternative approach with precomputing on
`schema.new()` and a copying function for a schema.
TBD: Add a test.
TBD: Part of #xxxx
NO_DOC=the schema module is internal, at least now
NO_CHANGELOG=see NO_DOC
0 commit comments