From 34e68548d43175c5d496b533dec280e935a8d2d5 Mon Sep 17 00:00:00 2001 From: Kevin Newton Date: Wed, 11 Dec 2024 14:09:17 -0500 Subject: [PATCH] [ruby/prism] Bump typechecking deps https://github.com/ruby/prism/commit/230c8b8a48 --- lib/prism/parse_result.rb | 4 ++-- lib/prism/parse_result/errors.rb | 2 +- lib/prism/relocation.rb | 2 +- prism/templates/lib/prism/node.rb.erb | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/prism/parse_result.rb b/lib/prism/parse_result.rb index 46bd33d1db..7aee20c9de 100644 --- a/lib/prism/parse_result.rb +++ b/lib/prism/parse_result.rb @@ -204,8 +204,8 @@ module Prism LengthCounter.new(source, encoding) end - @cache = {} - @offsets = [] + @cache = {} #: Hash[Integer, Integer] + @offsets = [] #: Array[Integer] end # Retrieve the code units offset from the given byte offset. diff --git a/lib/prism/parse_result/errors.rb b/lib/prism/parse_result/errors.rb index 847a8442fe..eb4f317248 100644 --- a/lib/prism/parse_result/errors.rb +++ b/lib/prism/parse_result/errors.rb @@ -17,7 +17,7 @@ module Prism # Formats the errors in a human-readable way and return them as a string. def format - error_lines = {} + error_lines = {} #: Hash[Integer, Array[ParseError]] parse_result.errors.each do |error| location = error.location (location.start_line..location.end_line).each do |line| diff --git a/lib/prism/relocation.rb b/lib/prism/relocation.rb index ad914396f6..163d2012c5 100644 --- a/lib/prism/relocation.rb +++ b/lib/prism/relocation.rb @@ -465,7 +465,7 @@ module Prism while (node = queue.shift) @entries[node.node_id].each do |field_name, entry| value = node.public_send(field_name) - values = {} + values = {} #: Hash[Symbol, untyped] fields.each_value do |field| values.merge!(field.fields(value)) diff --git a/prism/templates/lib/prism/node.rb.erb b/prism/templates/lib/prism/node.rb.erb index 72245cd30d..e4ca185719 100644 --- a/prism/templates/lib/prism/node.rb.erb +++ b/prism/templates/lib/prism/node.rb.erb @@ -182,7 +182,7 @@ module Prism # bytes, as opposed to characters or code units. def tunnel(line, column) queue = [self] #: Array[Prism::node] - result = [] + result = [] #: Array[Prism::node] while (node = queue.shift) result << node