Skip to content

chore: Zig master compatibility for main library#64

Closed
adoerr wants to merge 2 commits into
ianprime0509:mainfrom
adoerr:array-list-fix
Closed

chore: Zig master compatibility for main library#64
adoerr wants to merge 2 commits into
ianprime0509:mainfrom
adoerr:array-list-fix

Conversation

@adoerr

@adoerr adoerr commented Mar 14, 2026

Copy link
Copy Markdown

Fix std.ArrayList field initialization for Reader and Writer .

With this PR deprecated default values for std.ArrayList have been removed.

We are affected by this, because the (also deprecated) std.ArrayListUnmanaged is an aliased std.ArrayList. I haven't changed std.ArrayListUnamagned to std.ArrayList in order to keep changes for this PR minimal.

Signed-off-by: adoerr <0xad@gmx.net>
Copilot AI review requested due to automatic review settings March 14, 2026 07:48

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR standardizes initialization of internal container fields in the XML Reader and Writer to use the explicit .empty initializer, improving clarity around “empty but valid” container state at construction.

Changes:

  • Update Writer.init to initialize strings, element_names, and ns_prefixes with .empty.
  • Update Reader.init to initialize spans, attributes, strings, element_names, and ns_prefixes with .empty.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
src/Writer.zig Uses .empty for empty container initialization in Writer.init.
src/Reader.zig Uses .empty for empty container initialization in Reader.init.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

@ianprime0509

Copy link
Copy Markdown
Owner

Sorry, just noticed this PR now, and after resolving conflicts, it looks like #65 took care of this. Thank you, though!

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.

3 participants