Open
Description
With #106 we introduced RBS Inline types annotations.
It would be great if we could also use Sorbet to typecheck the codebase. Right now we are blocked because RBS aliases are not supported yet:
$ bundle exec srb tc
lib/herb/errors.rb:21: RBS aliases are not supported https://srb.help/3551
21 | #: () -> serialized_error
^^^^^^^^^^^^^^^^
Another detail I noticed is that Sorbet doesn't support the inline type signatures for attr_reader
, i.e this doesn't work:
module Herb
class Position
attr_reader :line #: Integer
attr_reader :column #: Integer
end
end
but this does:
module Herb
class Position
#: Integer
attr_reader :line
#: Integer
attr_reader :column
end
end