-
Notifications
You must be signed in to change notification settings - Fork 19
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
Sometimes type signatures are not defined inline in the main code but are defined in a separate RBI file with the same name.
For example: a file called mod.rb, which itself has a # typed: strict comment, might not actually have any type signatures stored inline but instead may have it in mod.rbi that sits alongside.
To Reproduce
Create a mod.rb with the following contents:
# typed: strict
module TestModule
def self.some_method(arg)
puts arg
end
endThen create a mod.rbi with the following contents:
# typed: strict
module TestModule
include Kernel
sig { params(arg: String).void }
def self.some_method(arg); end
endNote that srb tc will pass without errors here - it picks up the RBI and merges the type signatures into the main file.
Expected behavior
The Parlour conflict resolver handles this without errors.
Actual behavior
Parlour debug: Class: Registered
Parlour debug: conflict resolver: ├─ Resolving conflicts for <anonymous namespace>...
Parlour debug: conflict resolver: │ ├─ Checking children named TestModule...
Parlour debug: conflict resolver: │ │ ├─ Possible conflict between 2 objects
Parlour debug: conflict resolver: │ │ └─ Children are all mergeable; resolving automatically
Parlour debug: conflict resolver: │ ├─ Resolving children...
Parlour debug: conflict resolver: │ ├─ Resolving conflicts for TestModule...
Parlour debug: conflict resolver: │ │ ├─ Checking children named some_method...
Parlour debug: conflict resolver: │ │ │ ├─ Possible conflict between 2 objects
Parlour debug: conflict resolver: │ │ │ └─ Unable to resolve automatically; requesting manual resolution
Additional information
Parlour 6.0.0
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working