Skip to content

Commit

Permalink
Fix DSL generation for Protobuf::Struct
Browse files Browse the repository at this point in the history
`type_of(descriptor)` is returning `nil` for `Google::Protobuf::Struct`
methods in `sorbet/rbi/dsl/google/protobuf/struct.rbi` in version
3.23.0.
  • Loading branch information
dirceu committed May 11, 2023
1 parent 6448e34 commit 977bbe5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/tapioca/dsl/compilers/protobuf.rb
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ def type_of(descriptor)
# > field, even if it was not defined in the enum.
"T.any(Symbol, Integer)"
when :message
descriptor.subtype.msgclass.name
descriptor.subtype.msgclass.name || "T.untyped"
when :int32, :int64, :uint32, :uint64
"Integer"
when :double, :float
Expand Down

0 comments on commit 977bbe5

Please sign in to comment.