Skip to content

Do not associate a RBS comment to a node after a blank line#780

Merged
Morriar merged 1 commit into
mainfrom
at-fix-type-alias
Aug 4, 2025
Merged

Do not associate a RBS comment to a node after a blank line#780
Morriar merged 1 commit into
mainfrom
at-fix-type-alias

Conversation

@Morriar

@Morriar Morriar commented Jul 21, 2025

Copy link
Copy Markdown
Contributor

Before this PR, the following example would fail because we tried to use the type alias as the generic signature of the class:

#: type foo = Integer

class Bar; end

@Morriar Morriar self-assigned this Jul 21, 2025
@Morriar Morriar requested a review from a team as a code owner July 21, 2025 20:39
@Morriar Morriar added the bugfix Fix a bug label Jul 21, 2025
Comment thread lib/spoom/rbs.rb Outdated
Comment on lines +85 to +87
if comment_line < last_line - 1
break
end

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit

Suggested change
if comment_line < last_line - 1
break
end
break if comment_line < last_line - 1

Signed-off-by: Alexandre Terrasa <alexandre.terrasa@shopify.com>
@Morriar Morriar force-pushed the at-fix-type-alias branch from a9d8e00 to 07db4aa Compare August 4, 2025 15:17
@Morriar Morriar enabled auto-merge August 4, 2025 15:17
@Morriar Morriar merged commit ccd8867 into main Aug 4, 2025
8 checks passed
@Morriar Morriar deleted the at-fix-type-alias branch August 4, 2025 15:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugfix Fix a bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants