Skip to content

fix(host): report an unreadable argument on any stacked host decorator - #611

Merged
Brooooooklyn merged 1 commit into
mainfrom
fix/stacked-host-lone-surrogate
Oct 22, 2026
Merged

Brooooooklyn merged 1 commit into
mainfrom
fix/stacked-host-lone-surrogate

Conversation

@Brooooooklyn

Copy link
Copy Markdown
Member

Follow-up to #601. That PR compiles every stacked @HostListener / @HostBinding on a member, but lone_surrogate_host_error still checked only the first one. A lone surrogate ('\uD800') in a later decorator got past the check, and a fallback was compiled silently:

Member Before Now
@HostBinding('title') @HostBinding('\uD800') v ɵɵdomProperty("title", ctx.v)("v", ctx.v), a binding named after the member @HostBinding's argument must be a string …
@HostListener('click') @HostListener('\uD800') a() the 2nd listener is dropped @HostListener's event name argument must be a string …
@HostListener('click') @HostListener('x', ['\uD800']) a(x) "x" listener with its args dropped Failed to resolve @HostListener.args at position 0 …

The check now goes over every matching decorator, the same set the extractors compile. A lone surrogate on the first or only decorator was already reported this way.

Found by Codex on #601 (thread).

Tests

  • tests/stacked_host_decorators_test.rs: one new test with the three cases above. It fails without the change.
  • cargo test -p oxc_angular_compiler --all-features: 3496 passed.
  • Conformance: 1264/1264.
  • pnpm compare --fixtures: 1162 fixtures, 0 mismatches.
  • pnpm test: 376 passed.

🤖 Generated with Claude Code

Every stacked `@HostListener` / `@HostBinding` is compiled now, so the
lone-surrogate check looks at every one too. A bad argument on a later
decorator is reported instead of compiling a fallback (the member name,
no listener, no args).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@Brooooooklyn

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-22T12:10:50.886032Z eec956b Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Another round soon, please!

Reviewed commit: eec956bf7e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@Brooooooklyn
Brooooooklyn merged commit 43e870b into main Oct 22, 2026
10 checks passed
@Brooooooklyn
Brooooooklyn deleted the fix/stacked-host-lone-surrogate branch October 22, 2026 12:34
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.

1 participant