HLE: read manifest fields past inline XML comments #487
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/487"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from Marvisak/VIctory. Originally posted by Quat3rnion on 2026-11-24T03:57:57Z.
What
elements()read a field's text up to the next<. A manifest generatorthat writes
<TitleId><!-- generated -->639AA8DD</TitleId>thereforeproduced an empty TitleId, giving the title id 0 and the wrong save
namespace. The same affected StoreId and storage size. Field text now skips
comments instead of stopping at them; other markup still ends the field.
An AI tool wrote part of this change.
Tested
cargo test --workspace: 165 passed, 0 failed, 3 ignored. The existing manifest test still passes; a new regression puts inline comments inside TitleId, StoreId and SizeMB and checks all three values.cargo check --target x86_64-pc-windows-gnu --workspace --testspasses. No Windows host here.cargo xtask policypasses (150 files ok). No game files or data from them were added.Checklist
cargo xtask policypasses. No game files or data from them were added.Imported from Marvisak/VIctory. Originally posted by mercuryVM on 2026-11-24T08:40:52Z.
Review: APPROVED
Tested
be484a1on Windows 11, RTX 5070, MSVC:cargo test --workspace --no-fail-fastpasses (248 passed, 0 failed; older base), includinginline_comments_do_not_truncate_a_field.field_textkeeps the old rule that any other markup ends the text, and only steps over<!-- … -->. Entities are still decoded afterwards on the joined text (the9&<!-- -->Ccase shows that). An unterminated comment stops at the text read so far rather than swallowing the rest. It also merges cleanly with #359 (quoted>in attributes), which is in our fork: together they handle both directions of this parser's edge cases.No issues found.
AI-assisted (Claude Code).
Imported from Marvisak/VIctory. Originally posted by jeremygold02 on 2026-11-24T17:40:28Z.
Focused verification on current head
ca362a42473bb0f8f9a83377091287a621e94527:cargo test --locked -p victory-hle --lib inline_comments_do_not_truncate_a_field -- --test-threads=1passed (1 passed, 0 failed). This exercises manifest parsing throughTitle::from_manifest: inline comments are skipped beforeTitleIdand storage size values, and9&<!-- keep -->Cbecomes9&C. The earlier review cites a workspace run onbe484a1; this result is specifically for the current SHA above.This verification was AI-assisted.