Skip to content

Warn for unknown catchpoint classes - #996

Open
OskarEichler wants to merge 1 commit into
deivid-rodriguez:mainfrom
OskarEichler:codex/warn-unknown-catchpoint-class
Open

OskarEichler wants to merge 1 commit into
deivid-rodriguez:mainfrom
OskarEichler:codex/warn-unknown-catchpoint-class

Conversation

@OskarEichler

Copy link
Copy Markdown

Summary:

  • evaluate the requested constant and inspect the resulting object
  • warn unless it resolves to a Class
  • avoid testing whether the textual boolean result itself is a Class

Why:
The current code evaluates exception.is_a?(Class).to_s through warning_eval, then calls is_a?(Class) on that evaluator result. The condition does not represent the requested constant and valid/invalid class warnings are inverted or lost.

Verification:

  • focused known-class and unknown/non-class catchpoint models pass
  • current full-suite failure count is unchanged from baseline
  • gem build and syntax checks pass

Compatibility:
Catchpoint registration remains unchanged; diagnostics now reflect the evaluated constant.

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