From 5c377ef565db2c4641068e5f04742831378e48c7 Mon Sep 17 00:00:00 2001 From: Charles Oliver Nutter Date: Thu, 12 Jan 2023 14:32:35 -0600 Subject: Remove unused yaml argument --- ext/java/org/jruby/ext/psych/PsychParser.java | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/ext/java/org/jruby/ext/psych/PsychParser.java b/ext/java/org/jruby/ext/psych/PsychParser.java index 8bc7ee2..0f7b79e 100644 --- a/ext/java/org/jruby/ext/psych/PsychParser.java +++ b/ext/java/org/jruby/ext/psych/PsychParser.java @@ -229,7 +229,7 @@ public class PsychParser extends RubyObject { } } catch (ParserException pe) { parser = null; - raiseParserException(context, yaml, pe, path); + raiseParserException(context, pe, path); } catch (ScannerException se) { parser = null; @@ -237,18 +237,18 @@ public class PsychParser extends RubyObject { if (se.getProblemMark() != null) { message.append(se.getProblemMark().toString()); } - raiseParserException(context, yaml, se, path); + raiseParserException(context, se, path); } catch (ReaderException re) { parser = null; - raiseParserException(context, yaml, re, path); + raiseParserException(context, re, path); } catch (YAMLException ye) { Throwable cause = ye.getCause(); if (cause instanceof MalformedInputException) { // failure due to improperly encoded input - raiseParserException(context, yaml, (MalformedInputException) cause, path); + raiseParserException(context, (MalformedInputException) cause, path); } throw ye; @@ -317,7 +317,7 @@ public class PsychParser extends RubyObject { invoke(context, handler, "start_sequence", anchor, tag, implicit, style); } - private static void raiseParserException(ThreadContext context, IRubyObject yaml, ReaderException re, IRubyObject rbPath) { + private static void raiseParserException(ThreadContext context, ReaderException re, IRubyObject rbPath) { Ruby runtime; RubyClass se; IRubyObject exception; @@ -339,7 +339,7 @@ public class PsychParser extends RubyObject { RubyKernel.raise(context, runtime.getKernel(), new IRubyObject[] { exception }, Block.NULL_BLOCK); } - private static void raiseParserException(ThreadContext context, IRubyObject yaml, MarkedYAMLException mye, IRubyObject rbPath) { + private static void raiseParserException(ThreadContext context, MarkedYAMLException mye, IRubyObject rbPath) { Ruby runtime; Mark mark; RubyClass se; @@ -364,9 +364,8 @@ public class PsychParser extends RubyObject { RubyKernel.raise(context, runtime.getKernel(), new IRubyObject[] { exception }, Block.NULL_BLOCK); } - private static void raiseParserException(ThreadContext context, IRubyObject yaml, MalformedInputException mie, IRubyObject rbPath) { - Ruby runtime; - Mark mark; + private static void raiseParserException(ThreadContext context, MalformedInputException mie, IRubyObject rbPath) { + Ruby runtime;; RubyClass se; IRubyObject exception; -- cgit v1.2.1