From e3193575d99b58759a64468ebde386c0fa1e748c Mon Sep 17 00:00:00 2001 From: Alex Rocha Date: Fri, 10 Jan 2025 11:09:41 -0800 Subject: [PATCH] wip test annotation output --- lib/tapioca/commands/annotations.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/tapioca/commands/annotations.rb b/lib/tapioca/commands/annotations.rb index 9da9d4c9d..21925a6a8 100644 --- a/lib/tapioca/commands/annotations.rb +++ b/lib/tapioca/commands/annotations.rb @@ -238,8 +238,9 @@ def merge_files(gem_name, contents) return if contents.empty? rewriter = RBI::Rewriters::Merge.new(keep: RBI::Rewriters::Merge::Keep::NONE) - + content2 = T.let(nil, T.untyped) contents.each do |content| + content2 = content rbi = RBI::Parser.parse_string(content) rewriter.merge(rbi) end @@ -257,6 +258,7 @@ def merge_files(gem_name, contents) rescue RBI::ParseError => e say_error("\n\n Can't import RBI file for `#{gem_name}` as it contains errors:", :yellow) say_error(" Error: #{e.message} (#{e.location})") + say_error(content2) nil end