Skip to content

Align ARGS_NOEXCEPT completion behavior with throwing mode#174

Merged
Taywee merged 1 commit into
Taywee:masterfrom
jmestwa-coder:noexcept-completion-behavior
May 26, 2026
Merged

Align ARGS_NOEXCEPT completion behavior with throwing mode#174
Taywee merged 1 commit into
Taywee:masterfrom
jmestwa-coder:noexcept-completion-behavior

Conversation

@jmestwa-coder
Copy link
Copy Markdown
Contributor

Summary

This fixes an inconsistency between throwing mode and ARGS_NOEXCEPT during shell completion parsing.

In throwing mode, recursive parsing of partial completion input suppresses ordinary parse failures and returns empty completion output. ARGS_NOEXCEPT did not mirror that behavior and could leak Error::Parse state for unknown commands during completion.

Changes

  • Restore Error::Completion state after recursive completion parsing in ARGS_NOEXCEPT
  • Clear leaked parse error messages from inner completion parsing
  • Add focused regression coverage for unknown-command completion in noexcept mode

Result

ARGS_NOEXCEPT completion behavior now matches the existing throwing-mode semantics for partial/unknown command completion input.

@Taywee
Copy link
Copy Markdown
Owner

Taywee commented May 26, 2026

Makes sense to me. The nothrow code has had a lot of issues being consistent with the throw code. It's a fairly half-baked feature.

Thanks for the PR.

@Taywee Taywee merged commit e172c63 into Taywee:master May 26, 2026
7 checks passed
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.

2 participants