[ruby/yarp] Use node kind for Ruby types
* For example in ProgramNode: # attr_reader statements: Node => # attr_reader statements: StatementsNode https://github.com/ruby/yarp/commit/ffed35238c
This commit is contained in:
parent
725ca2f9d8
commit
55f930aa7e
@ -23,6 +23,10 @@ module KindTypes
|
||||
end
|
||||
end
|
||||
|
||||
def ruby_type
|
||||
options[:kind] || "Node"
|
||||
end
|
||||
|
||||
def java_type
|
||||
options[:kind] || "Node"
|
||||
end
|
||||
@ -42,7 +46,7 @@ class NodeParam < Param
|
||||
include KindTypes
|
||||
|
||||
def rbs_class
|
||||
"Node"
|
||||
ruby_type
|
||||
end
|
||||
end
|
||||
|
||||
@ -52,7 +56,7 @@ class OptionalNodeParam < Param
|
||||
include KindTypes
|
||||
|
||||
def rbs_class
|
||||
"Node?"
|
||||
"#{ruby_type}?"
|
||||
end
|
||||
end
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user