Skip to content

Add defined? type inference support#106

Merged
dak2 merged 1 commit intomainfrom
feature/v020-defined
Apr 5, 2026
Merged

Add defined? type inference support#106
dak2 merged 1 commit intomainfrom
feature/v020-defined

Conversation

@dak2
Copy link
Copy Markdown
Owner

@dak2 dak2 commented Apr 5, 2026

Motivation

defined? expressions were silently ignored by the analyzer, producing no type information. This could cause downstream type errors to go undetected.

Changes

  • Handle DefinedNode in dispatch_simple to return String | nil without evaluating the child expression
  • Add Ruby integration tests for defined? type inference

Checked

  • cargo test --lib
  • bundle exec rake test

🤖 Generated with Claude Code

DefinedNode was silently ignored, meaning defined? expressions produced
no type information. This adds handling that returns String | nil
without evaluating the child expression.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@dak2 dak2 merged commit 9e50157 into main Apr 5, 2026
4 checks passed
@dak2 dak2 deleted the feature/v020-defined branch April 5, 2026 01:53
@dak2 dak2 added this to the v0.2.0 milestone Apr 5, 2026
@dak2 dak2 mentioned this pull request Apr 5, 2026
4 tasks
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