Skip to content

Fix issue #204 (asdf/core metadata order in the tree)#209

Merged
embray merged 2 commits into
asdf-format:mainfrom
embray:issue-204
Jun 25, 2026
Merged

Fix issue #204 (asdf/core metadata order in the tree)#209
embray merged 2 commits into
asdf-format:mainfrom
embray:issue-204

Conversation

@embray

@embray embray commented Jun 25, 2026

Copy link
Copy Markdown
Collaborator

Mainly resolves #204 .

Found it useful to be able to reverse iterate mapping, so also added new APIs asdf_mapping_reverse_iter_init, asdf_mapping_sequence_iter_init, and asdf_mapping_container_iter_init. No other new iter functions are needed; the iteration order is stored on the iterator handle.

embray added 2 commits June 25, 2026 13:36
Reverse iterators for mappings needed for asdf-formatgh-204, but add for
sequences and generic container iterators as well.
Could have probably done this a number of different ways, but simplest
overall change was to keep using asdf_mapping_update but add _ex version
that prepends new keys at the beginning of the mapping rather than
appending them, so asdf_mapping_reverse_iter is needed to prepend keys
while keeping their original order.

asdf-formatgh-204
@embray embray merged commit 78f094c into asdf-format:main Jun 25, 2026
12 checks passed
@embray embray deleted the issue-204 branch June 25, 2026 12:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

asdf core metadata not inserted at beginning of tree

1 participant