diff --git a/.github/workflows/rspec.yml b/.github/workflows/tests.yml
similarity index 78%
rename from .github/workflows/rspec.yml
rename to .github/workflows/tests.yml
index 66b3233..632cb9d 100644
--- a/.github/workflows/rspec.yml
+++ b/.github/workflows/tests.yml
@@ -1,4 +1,4 @@
-name: Run RSpec tests
+name: Run tests
on:
push:
branches:
@@ -15,6 +15,9 @@ jobs:
ruby-version: 3.3.3
# runs 'bundle install' and caches installed gems automatically
bundler-cache: true
- - name: Run tests
+ - name: Run sorbet typechecks
+ run: |
+ bundle exec srb
+ - name: Run rspec tests
run: |
bundle exec rspec
diff --git a/bin/tapioca b/bin/tapioca
new file mode 100755
index 0000000..a6ae757
--- /dev/null
+++ b/bin/tapioca
@@ -0,0 +1,27 @@
+#!/usr/bin/env ruby
+# frozen_string_literal: true
+
+#
+# This file was generated by Bundler.
+#
+# The application 'tapioca' is installed as part of a gem, and
+# this file is here to facilitate running it.
+#
+
+ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__)
+
+bundle_binstub = File.expand_path("bundle", __dir__)
+
+if File.file?(bundle_binstub)
+ if File.read(bundle_binstub, 300).include?("This file was generated by Bundler")
+ load(bundle_binstub)
+ else
+ abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
+Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.")
+ end
+end
+
+require "rubygems"
+require "bundler/setup"
+
+load Gem.bin_path("tapioca", "tapioca")
diff --git a/lib/schema_registry/rbi_generator.rb b/lib/schema_registry/rbi_generator.rb
index 7afd8f7..15e7afc 100644
--- a/lib/schema_registry/rbi_generator.rb
+++ b/lib/schema_registry/rbi_generator.rb
@@ -1,4 +1,4 @@
-# typed: false
+# typed: true
require 'rbi'
diff --git a/sorbet/rbi/annotations/.gitattributes b/sorbet/rbi/annotations/.gitattributes
new file mode 100644
index 0000000..d2eacd2
--- /dev/null
+++ b/sorbet/rbi/annotations/.gitattributes
@@ -0,0 +1 @@
+**/*.rbi linguist-vendored=true
diff --git a/sorbet/rbi/annotations/activesupport.rbi b/sorbet/rbi/annotations/activesupport.rbi
new file mode 100644
index 0000000..716210d
--- /dev/null
+++ b/sorbet/rbi/annotations/activesupport.rbi
@@ -0,0 +1,452 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This file was pulled from a central RBI files repository.
+# Please run `bin/tapioca annotations` to update it.
+
+module ActiveSupport::Testing::Declarative
+ sig { params(name: String, block: T.proc.bind(T.untyped).void).void }
+ def test(name, &block); end
+end
+
+class ActiveSupport::EnvironmentInquirer
+ sig { returns(T::Boolean) }
+ def development?; end
+
+ sig { returns(T::Boolean) }
+ def production?; end
+
+ sig { returns(T::Boolean) }
+ def test?; end
+
+ # @method_missing: delegated to String through ActiveSupport::StringInquirer
+ sig { returns(T::Boolean) }
+ def staging?; end
+end
+
+module ActiveSupport::Testing::SetupAndTeardown::ClassMethods
+ sig { params(args: T.untyped, block: T.nilable(T.proc.bind(T.untyped).void)).void }
+ def setup(*args, &block); end
+
+ sig { params(args: T.untyped, block: T.nilable(T.proc.bind(T.untyped).void)).void }
+ def teardown(*args, &block); end
+end
+
+class ActiveSupport::TestCase
+ sig { params(args: T.untyped, block: T.nilable(T.proc.bind(T.attached_class).void)).void }
+ def self.setup(*args, &block); end
+
+ sig { params(args: T.untyped, block: T.nilable(T.proc.bind(T.attached_class).void)).void }
+ def self.teardown(*args, &block); end
+
+ sig { params(name: String, block: T.proc.bind(T.attached_class).void).void }
+ def self.test(name, &block); end
+end
+
+class ActiveSupport::TimeWithZone
+ # @shim: Methods on ActiveSupport::TimeWithZone are delegated to `Time` using `method_missing
+ include ::DateAndTime::Zones
+
+ # @shim: Methods on ActiveSupport::TimeWithZone are delegated to `Time` using `method_missing
+ include ::DateAndTime::Calculations
+
+ sig { returns(FalseClass) }
+ def blank?; end
+
+ # @shim: since `present?` is always true, `presence` always returns `self`
+ sig { returns(T.self_type) }
+ def presence; end
+
+ # @shim: since `blank?` is always false, `present?` always returns `true`
+ sig { returns(TrueClass) }
+ def present?; end
+end
+
+class Object
+ sig { returns(T::Boolean) }
+ def blank?; end
+
+ sig { returns(FalseClass) }
+ def html_safe?; end
+
+ sig { returns(T.nilable(T.self_type)) }
+ def presence; end
+
+ sig { params(another_object: T.untyped).returns(T.nilable(T.self_type)) }
+ def presence_in(another_object); end
+
+ sig { returns(T::Boolean) }
+ def present?; end
+end
+
+class Hash
+ sig { returns(T::Boolean) }
+ def blank?; end
+
+ sig { returns(T::Boolean) }
+ def present?; end
+
+ sig { returns(T::Boolean) }
+ def extractable_options?; end
+end
+
+class Array
+ sig { returns(T::Boolean) }
+ def blank?; end
+
+ sig { returns(T::Boolean) }
+ def present?; end
+
+ sig { params(position: Integer).returns(T.self_type) }
+ def from(position); end
+
+ sig { params(position: Integer).returns(T.self_type) }
+ def to(position); end
+
+ sig { params(elements: T.untyped).returns(T::Array[T.untyped]) }
+ def including(*elements); end
+
+ sig { params(elements: T.untyped).returns(T.self_type) }
+ def excluding(*elements); end
+
+ sig { params(elements: T.untyped).returns(T.self_type) }
+ def without(*elements); end
+
+ sig { returns(T.nilable(Elem)) }
+ def second; end
+
+ sig { returns(T.nilable(Elem)) }
+ def third; end
+
+ sig { returns(T.nilable(Elem)) }
+ def fourth; end
+
+ sig { returns(T.nilable(Elem)) }
+ def fifth; end
+
+ sig { returns(T.nilable(Elem)) }
+ def forty_two; end
+
+ sig { returns(T.nilable(Elem)) }
+ def third_to_last; end
+
+ sig { returns(T.nilable(Elem)) }
+ def second_to_last; end
+
+ sig { params(options: T::Hash[T.untyped, T.untyped]).returns(String) }
+ def to_sentence(options = {}); end
+
+ sig { params(format: Symbol).returns(String) }
+ def to_fs(format = :default); end
+
+ sig { params(format: Symbol).returns(String) }
+ def to_formatted_s(format = :default); end
+
+ sig { returns(String) }
+ def to_xml; end
+
+ sig { returns(T::Hash[T.untyped, T.untyped]) }
+ def extract_options!; end
+
+ sig { type_parameters(:FillType).params(number: Integer, fill_with: T.type_parameter(:FillType), block: T.nilable(T.proc.params(group: T::Array[T.any(Elem, T.type_parameter(:FillType))]).void)).returns(T::Array[T::Array[T.any(Elem, T.type_parameter(:FillType))]]) }
+ def in_groups(number, fill_with = T.unsafe(nil), &block); end
+
+ sig { type_parameters(:FillType).params(number: Integer, fill_with: T.type_parameter(:FillType), block: T.nilable(T.proc.params(group: T::Array[T.any(Elem, T.type_parameter(:FillType))]).void)).returns(T::Array[T::Array[T.any(Elem, T.type_parameter(:FillType))]]) }
+ def in_groups_of(number, fill_with = T.unsafe(nil), &block); end
+
+ sig { params(value: T.untyped, block: T.nilable(T.proc.params(element: Elem).returns(T.untyped))).returns(T::Array[T::Array[Elem]]) }
+ def split(value = nil, &block); end
+
+ sig { params(block: T.nilable(T.proc.params(element: Elem).returns(T.untyped))).returns(T.any(T::Array[Elem], T::Enumerator[Elem])) }
+ def extract!(&block); end
+
+ sig { returns(ActiveSupport::ArrayInquirer) }
+ def inquiry; end
+
+ sig { params(object: T.untyped).returns(T::Array[T.untyped]) }
+ def self.wrap(object); end
+end
+
+class Date
+ sig { returns(FalseClass) }
+ def blank?; end
+
+ # @shim: since `present?` is always true, `presence` always returns `self`
+ sig { returns(T.self_type) }
+ def presence; end
+
+ # @shim: since `blank?` is always false, `present?` always returns `true`
+ sig { returns(TrueClass) }
+ def present?; end
+end
+
+class DateTime
+ sig { returns(FalseClass) }
+ def blank?; end
+
+ # @shim: since `present?` is always true, `presence` always returns `self`
+ sig { returns(T.self_type) }
+ def presence; end
+
+ # @shim: since `blank?` is always false, `present?` always returns `true`
+ sig { returns(TrueClass) }
+ def present?; end
+end
+
+class NilClass
+ sig { returns(TrueClass) }
+ def blank?; end
+
+ # @shim: since `present?` is always false, `presence` always returns `nil`
+ sig { returns(NilClass) }
+ def presence; end
+
+ # @shim: since `blank?` is always true, `present?` always returns `false`
+ sig { returns(FalseClass) }
+ def present?; end
+end
+
+class FalseClass
+ sig { returns(TrueClass) }
+ def blank?; end
+
+ # @shim: since `present?` is always false, `presence` always returns `nil`
+ sig { returns(NilClass) }
+ def presence; end
+
+ # @shim: since `blank?` is always true, `present?` always returns `false`
+ sig { returns(FalseClass) }
+ def present?; end
+end
+
+class TrueClass
+ sig { returns(FalseClass) }
+ def blank?; end
+
+ # @shim: since `present?` is always true, `presence` always returns `self`
+ sig { returns(T.self_type) }
+ def presence; end
+
+ # @shim: since `blank?` is always false, `present?` always returns `true`
+ sig { returns(TrueClass) }
+ def present?; end
+end
+
+class Numeric
+ sig { returns(FalseClass) }
+ def blank?; end
+
+ sig { returns(TrueClass) }
+ def html_safe?; end
+
+ # @shim: since `present?` is always true, `presence` always returns `self`
+ sig { returns(T.self_type) }
+ def presence; end
+
+ # @shim: since `blank?` is always false, `present?` always returns `true`
+ sig { returns(TrueClass) }
+ def present?; end
+end
+
+class Time
+ sig { returns(FalseClass) }
+ def blank?; end
+
+ # @shim: since `present?` is always true, `presence` always returns `self`
+ sig { returns(T.self_type) }
+ def presence; end
+
+ # @shim: since `blank?` is always false, `present?` always returns `true`
+ sig { returns(TrueClass) }
+ def present?; end
+
+ sig { returns(ActiveSupport::TimeZone) }
+ def self.zone; end
+
+ sig { returns(T.any(ActiveSupport::TimeWithZone, ::Time)) }
+ def self.current; end
+end
+
+class Symbol
+ sig { returns(T::Boolean) }
+ def blank?; end
+
+ sig { returns(T::Boolean) }
+ def present?; end
+
+ # alias for `#start_with?`
+ sig { params(string_or_regexp: T.any(String, Regexp)).returns(T::Boolean) }
+ def starts_with?(*string_or_regexp); end
+
+ # alias for `#end_with?`
+ sig { params(string_or_regexp: T.any(String, Regexp)).returns(T::Boolean) }
+ def ends_with?(*string_or_regexp); end
+end
+
+class String
+ sig { returns(TrueClass) }
+ def acts_like_string?; end
+
+ sig { params(position: Integer).returns(T.nilable(String)) }
+ sig { params(position: T.any(T::Range[Integer], Regexp)).returns(T.nilable(String)) }
+ sig { params(position: String).returns(T.nilable(String)) }
+ def at(position); end
+
+ sig { returns(String) }
+ def as_json; end
+
+ sig { returns(T::Boolean) }
+ def blank?; end
+
+ sig { params(first_letter: Symbol).returns(String) }
+ def camelcase(first_letter = :upper); end
+
+ sig { params(first_letter: Symbol).returns(String) }
+ def camelize(first_letter = :upper); end
+
+ sig { returns(String) }
+ def classify; end
+
+ sig { returns(T.untyped) }
+ def constantize; end
+
+ sig { returns(String) }
+ def dasherize; end
+
+ sig { returns(String) }
+ def deconstantize; end
+
+ sig { returns(String) }
+ def demodulize; end
+
+ # alias for `#end_with?`
+ sig { params(string_or_regexp: T.any(String, Regexp)).returns(T::Boolean) }
+ def ends_with?(*string_or_regexp); end
+
+ sig { returns(String) }
+ def downcase_first; end
+
+ sig { params(string: String).returns(T::Boolean) }
+ def exclude?(string); end
+
+ sig { params(limit: Integer).returns(String) }
+ def first(limit = 1); end
+
+ sig { params(separate_class_name_and_id_with_underscore: T::Boolean).returns(String) }
+ def foreign_key(separate_class_name_and_id_with_underscore = true); end
+
+ sig { params(position: Integer).returns(String) }
+ def from(position); end
+
+ sig { returns(ActiveSupport::SafeBuffer) }
+ def html_safe; end
+
+ sig { params(capitalize: T::Boolean, keep_id_suffix: T::Boolean).returns(String) }
+ def humanize(capitalize: true, keep_id_suffix: false); end
+
+ sig { params(zone: T.nilable(T.any(ActiveSupport::TimeZone, String))).returns(T.any(ActiveSupport::TimeWithZone, Time)) }
+ def in_time_zone(zone = ::Time.zone); end
+
+ sig { params(amount: Integer, indent_string: T.nilable(String), indent_empty_lines: T::Boolean).returns(String) }
+ def indent(amount, indent_string = nil, indent_empty_lines = false); end
+
+ sig { params(amount: Integer, indent_string: T.nilable(String), indent_empty_lines: T::Boolean).returns(T.nilable(String)) }
+ def indent!(amount, indent_string = nil, indent_empty_lines = false); end
+
+ sig { returns(ActiveSupport::StringInquirer) }
+ def inquiry; end
+
+ sig { returns(T::Boolean) }
+ def is_utf8?; end
+
+ sig { params(limit: Integer).returns(String) }
+ def last(limit = 1); end
+
+ sig { returns(ActiveSupport::Multibyte::Chars) }
+ def mb_chars; end
+
+ sig { params(separator: String, preserve_case: T::Boolean, locale: T.nilable(Symbol)).returns(String) }
+ def parameterize(separator: "-", preserve_case: false, locale: nil); end
+
+ sig { params(count: T.nilable(T.any(Integer, Symbol)), locale: T.nilable(Symbol)).returns(String) }
+ def pluralize(count = nil, locale = :en); end
+
+ sig { returns(T::Boolean) }
+ def present?; end
+
+ sig { params(patterns: T.any(String, Regexp)).returns(String) }
+ def remove(*patterns); end
+
+ sig { params(patterns: T.any(String, Regexp)).returns(String) }
+ def remove!(*patterns); end
+
+ sig { returns(T.untyped) }
+ def safe_constantize; end
+
+ sig { params(locale: Symbol).returns(String) }
+ def singularize(locale = :en); end
+
+ sig { returns(String) }
+ def squish; end
+
+ sig { returns(String) }
+ def squish!; end
+
+ # alias for `#start_with?`
+ sig { params(string_or_regexp: T.any(String, Regexp)).returns(T::Boolean) }
+ def starts_with?(*string_or_regexp); end
+
+ sig { returns(String) }
+ def strip_heredoc; end
+
+ sig { returns(String) }
+ def tableize; end
+
+ sig { params(keep_id_suffix: T::Boolean).returns(String) }
+ def titlecase(keep_id_suffix: false); end
+
+ sig { params(keep_id_suffix: T::Boolean).returns(String) }
+ def titleize(keep_id_suffix: false); end
+
+ sig { params(position: Integer).returns(String) }
+ def to(position); end
+
+ sig { returns(::Date) }
+ def to_date; end
+
+ sig { returns(::DateTime) }
+ def to_datetime; end
+
+ sig { params(form: T.nilable(Symbol)).returns(T.nilable(Time)) }
+ def to_time(form = :local); end
+
+ sig { params(truncate_to: Integer, options: T::Hash[Symbol, T.anything]).returns(String) }
+ def truncate(truncate_to, options = {}); end
+
+ sig { params(truncate_to: Integer, omission: T.nilable(String)).returns(String) }
+ def truncate_bytes(truncate_to, omission: "…"); end
+
+ sig { params(words_count: Integer, options: T::Hash[Symbol, T.anything]).returns(String) }
+ def truncate_words(words_count, options = {}); end
+
+ sig { returns(String) }
+ def underscore; end
+
+ sig { returns(String) }
+ def upcase_first; end
+end
+
+class ActiveSupport::ErrorReporter
+ sig { type_parameters(:Block, :Fallback).params(error_classes: T.class_of(Exception), severity: T.nilable(Symbol), context: T.nilable(T::Hash[Symbol, T.untyped]), fallback: T.nilable(T.proc.returns(T.type_parameter(:Fallback))), source: T.nilable(String), blk: T.proc.returns(T.type_parameter(:Block))).returns(T.any(T.type_parameter(:Block), T.type_parameter(:Fallback))) }
+ def handle(*error_classes, severity: T.unsafe(nil), context: T.unsafe(nil), fallback: T.unsafe(nil), source: T.unsafe(nil), &blk); end
+
+ sig { type_parameters(:Block).params(error_classes: T.class_of(Exception), severity: T.nilable(Symbol), context: T.nilable(T::Hash[Symbol, T.untyped]), source: T.nilable(String), blk: T.proc.returns(T.type_parameter(:Block))).returns(T.type_parameter(:Block)) }
+ def record(*error_classes, severity: T.unsafe(nil), context: T.unsafe(nil), source: T.unsafe(nil), &blk); end
+
+ sig { params(error: Exception, handled: T::Boolean, severity: T.nilable(Symbol), context: T::Hash[Symbol, T.untyped], source: T.nilable(String)).void }
+ def report(error, handled: true, severity: T.unsafe(nil), context: T.unsafe(nil), source: T.unsafe(nil)); end
+
+ # @version >= 7.2.0.beta1
+ sig { params(error: T.any(Exception, String), severity: T.nilable(Symbol), context: T::Hash[Symbol, T.untyped], source: T.nilable(String)).void }
+ def unexpected(error, severity: T.unsafe(nil), context: T.unsafe(nil), source: T.unsafe(nil)); end
+end
diff --git a/sorbet/rbi/annotations/minitest.rbi b/sorbet/rbi/annotations/minitest.rbi
new file mode 100644
index 0000000..64a8928
--- /dev/null
+++ b/sorbet/rbi/annotations/minitest.rbi
@@ -0,0 +1,119 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This file was pulled from a central RBI files repository.
+# Please run `bin/tapioca annotations` to update it.
+
+module Minitest::Assertions
+ sig { params(test: T.anything, msg: T.anything).returns(TrueClass) }
+ def assert(test, msg = nil); end
+
+ sig { params(obj: T.anything, msg: T.anything).returns(TrueClass) }
+ def assert_empty(obj, msg = nil); end
+
+ sig { params(exp: T.anything, act: T.anything, msg: T.anything).returns(TrueClass) }
+ def assert_equal(exp, act, msg = nil); end
+
+ sig { params(exp: T.anything, act: T.anything, delta: Numeric, msg: T.anything).returns(TrueClass) }
+ def assert_in_delta(exp, act, delta = T.unsafe(nil), msg = nil); end
+
+ sig { params(a: T.anything, b: T.anything, epsilon: Numeric, msg: T.anything).returns(TrueClass) }
+ def assert_in_epsilon(a, b, epsilon = T.unsafe(nil), msg = nil); end
+
+ sig { params(collection: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) }
+ def assert_includes(collection, obj, msg = nil); end
+
+ sig { params(cls: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) }
+ def assert_instance_of(cls, obj, msg = nil); end
+
+ sig { params(cls: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) }
+ def assert_kind_of(cls, obj, msg = nil); end
+
+ sig { params(matcher: T.any(String, Regexp), obj: T.anything, msg: T.anything).returns(MatchData) }
+ def assert_match(matcher, obj, msg = nil); end
+
+ sig { params(obj: T.anything, msg: T.anything).returns(TrueClass) }
+ def assert_nil(obj, msg = nil); end
+
+ sig { params(o1: T.anything, op: T.any(Symbol, String), o2: T.anything, msg: T.anything).returns(TrueClass) }
+ def assert_operator(o1, op, o2 = T.unsafe(nil), msg = nil); end
+
+ sig { params(stdout: T.nilable(T.any(String, Regexp)), stderr: T.nilable(T.any(String, Regexp)), block: T.proc.void).returns(T::Boolean) }
+ def assert_output(stdout = nil, stderr = nil, &block); end
+
+ sig { params(path: T.any(String, Pathname), msg: T.anything).returns(TrueClass) }
+ def assert_path_exists(path, msg = nil); end
+
+ sig { params(block: T.proc.void).returns(TrueClass) }
+ def assert_pattern(&block); end
+
+ sig { params(o1: T.anything, op: T.any(String, Symbol), msg: T.anything).returns(TrueClass) }
+ def assert_predicate(o1, op, msg = nil); end
+
+ sig { params(exp: NilClass, block: T.proc.void).returns(StandardError) }
+ sig { type_parameters(:T).params(exp: T.any(T::Class[T.type_parameter(:T)], Regexp, String), block: T.proc.void).returns(T.type_parameter(:T)) }
+ def assert_raises(*exp, &block); end
+
+ sig { params(obj: T.anything, meth: T.any(String, Symbol), msg: T.anything, include_all: T::Boolean).returns(TrueClass) }
+ def assert_respond_to(obj, meth, msg = nil, include_all: false); end
+
+ sig { params(exp: T.anything, act: T.anything, msg: T.anything).returns(TrueClass) }
+ def assert_same(exp, act, msg = nil); end
+
+ sig { params(send_ary: T::Array[T.anything], m: T.anything).returns(T::Boolean) }
+ def assert_send(send_ary, m = nil); end
+
+ sig { params(block: T.proc.void).returns(T::Boolean) }
+ def assert_silent(&block); end
+
+ sig { params(sym: Symbol, msg: T.anything, block: T.proc.void).returns(T.anything) }
+ def assert_throws(sym, msg = nil, &block); end
+
+ sig { params(test: T.anything, msg: T.anything).returns(TrueClass) }
+ def refute(test, msg = nil); end
+
+ sig { params(obj: T.anything, msg: T.anything).returns(TrueClass) }
+ def refute_empty(obj, msg = nil); end
+
+ sig { params(exp: T.anything, act: T.anything, msg: T.anything).returns(TrueClass) }
+ def refute_equal(exp, act, msg = nil); end
+
+ sig { params(exp: T.anything, act: T.anything, delta: Numeric, msg: T.anything).returns(TrueClass) }
+ def refute_in_delta(exp, act, delta = T.unsafe(nil), msg = nil); end
+
+ sig { params(a: T.anything, b: T.anything, epsilon: Numeric, msg: T.anything).returns(TrueClass) }
+ def refute_in_epsilon(a, b, epsilon = T.unsafe(nil), msg = nil); end
+
+ sig { params(collection: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) }
+ def refute_includes(collection, obj, msg = nil); end
+
+ sig { params(cls: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) }
+ def refute_instance_of(cls, obj, msg = nil); end
+
+ sig { params(cls: T.anything, obj: T.anything, msg: T.anything).returns(TrueClass) }
+ def refute_kind_of(cls, obj, msg = nil); end
+
+ sig { params(matcher: T.any(String, Regexp), obj: T.anything, msg: T.anything).returns(TrueClass) }
+ def refute_match(matcher, obj, msg = nil); end
+
+ sig { params(obj: T.anything, msg: T.anything).returns(TrueClass) }
+ def refute_nil(obj, msg = nil); end
+
+ sig { params(block: T.proc.void).returns(TrueClass) }
+ def refute_pattern(&block); end
+
+ sig { params(o1: T.anything, op: T.any(Symbol, String), o2: T.anything, msg: T.anything).returns(TrueClass) }
+ def refute_operator(o1, op, o2 = T.unsafe(nil), msg = nil); end
+
+ sig { params(path: T.any(String, Pathname), msg: T.anything).returns(TrueClass) }
+ def refute_path_exists(path, msg = nil); end
+
+ sig { params(o1: T.anything, op: T.any(String, Symbol), msg: T.anything).returns(TrueClass) }
+ def refute_predicate(o1, op, msg = nil); end
+
+ sig { params(obj: T.anything, meth: T.any(String, Symbol), msg: T.anything, include_all: T::Boolean).returns(TrueClass) }
+ def refute_respond_to(obj, meth, msg = nil, include_all: false); end
+
+ sig { params(exp: T.anything, act: T.anything, msg: T.anything).returns(TrueClass) }
+ def refute_same(exp, act, msg = nil); end
+end
diff --git a/sorbet/rbi/gems/.gitattributes b/sorbet/rbi/gems/.gitattributes
new file mode 100644
index 0000000..d9bb82a
--- /dev/null
+++ b/sorbet/rbi/gems/.gitattributes
@@ -0,0 +1 @@
+**/*.rbi linguist-generated=true
diff --git a/sorbet/rbi/gems/activesupport@7.2.0.rbi b/sorbet/rbi/gems/activesupport@7.2.0.rbi
new file mode 100644
index 0000000..055a7b2
--- /dev/null
+++ b/sorbet/rbi/gems/activesupport@7.2.0.rbi
@@ -0,0 +1,11 @@
+# typed: false
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `activesupport` gem.
+# Please instead update this file by running `bin/tapioca gem activesupport`.
+
+
+class NameError < ::StandardError
+ include ::ErrorHighlight::CoreExt
+ include ::DidYouMean::Correctable
+end
diff --git a/sorbet/rbi/gems/base64@0.2.0.rbi b/sorbet/rbi/gems/base64@0.2.0.rbi
new file mode 100644
index 0000000..7f733b0
--- /dev/null
+++ b/sorbet/rbi/gems/base64@0.2.0.rbi
@@ -0,0 +1,9 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `base64` gem.
+# Please instead update this file by running `bin/tapioca gem base64`.
+
+
+# THIS IS AN EMPTY RBI FILE.
+# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem
diff --git a/sorbet/rbi/gems/bigdecimal@3.1.8.rbi b/sorbet/rbi/gems/bigdecimal@3.1.8.rbi
new file mode 100644
index 0000000..c52d9ff
--- /dev/null
+++ b/sorbet/rbi/gems/bigdecimal@3.1.8.rbi
@@ -0,0 +1,9 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `bigdecimal` gem.
+# Please instead update this file by running `bin/tapioca gem bigdecimal`.
+
+
+# THIS IS AN EMPTY RBI FILE.
+# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem
diff --git a/sorbet/rbi/gems/concurrent-ruby@1.3.4.rbi b/sorbet/rbi/gems/concurrent-ruby@1.3.4.rbi
new file mode 100644
index 0000000..11d0bfb
--- /dev/null
+++ b/sorbet/rbi/gems/concurrent-ruby@1.3.4.rbi
@@ -0,0 +1,9 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `concurrent-ruby` gem.
+# Please instead update this file by running `bin/tapioca gem concurrent-ruby`.
+
+
+# THIS IS AN EMPTY RBI FILE.
+# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem
diff --git a/sorbet/rbi/gems/connection_pool@2.4.1.rbi b/sorbet/rbi/gems/connection_pool@2.4.1.rbi
new file mode 100644
index 0000000..3d9f595
--- /dev/null
+++ b/sorbet/rbi/gems/connection_pool@2.4.1.rbi
@@ -0,0 +1,9 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `connection_pool` gem.
+# Please instead update this file by running `bin/tapioca gem connection_pool`.
+
+
+# THIS IS AN EMPTY RBI FILE.
+# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem
diff --git a/sorbet/rbi/gems/diff-lcs@1.5.1.rbi b/sorbet/rbi/gems/diff-lcs@1.5.1.rbi
new file mode 100644
index 0000000..aa5aa3c
--- /dev/null
+++ b/sorbet/rbi/gems/diff-lcs@1.5.1.rbi
@@ -0,0 +1,1131 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `diff-lcs` gem.
+# Please instead update this file by running `bin/tapioca gem diff-lcs`.
+
+
+# source://diff-lcs//lib/diff/lcs.rb#3
+module Diff; end
+
+# == How Diff Works (by Mark-Jason Dominus)
+#
+# I once read an article written by the authors of +diff+; they said that they
+# hard worked very hard on the algorithm until they found the right one.
+#
+# I think what they ended up using (and I hope someone will correct me, because
+# I am not very confident about this) was the `longest common subsequence'
+# method. In the LCS problem, you have two sequences of items:
+#
+# a b c d f g h j q z
+# a b c d e f g i j k r x y z
+#
+# and you want to find the longest sequence of items that is present in both
+# original sequences in the same order. That is, you want to find a new
+# sequence *S* which can be obtained from the first sequence by deleting some
+# items, and from the second sequence by deleting other items. You also want
+# *S* to be as long as possible. In this case *S* is:
+#
+# a b c d f g j z
+#
+# From there it's only a small step to get diff-like output:
+#
+# e h i k q r x y
+# + - + + - + + +
+#
+# This module solves the LCS problem. It also includes a canned function to
+# generate +diff+-like output.
+#
+# It might seem from the example above that the LCS of two sequences is always
+# pretty obvious, but that's not always the case, especially when the two
+# sequences have many repeated elements. For example, consider
+#
+# a x b y c z p d q
+# a b c a x b y c z
+#
+# A naive approach might start by matching up the +a+ and +b+ that appear at
+# the beginning of each sequence, like this:
+#
+# a x b y c z p d q
+# a b c a b y c z
+#
+# This finds the common subsequence +a b c z+. But actually, the LCS is +a x b
+# y c z+:
+#
+# a x b y c z p d q
+# a b c a x b y c z
+#
+# source://diff-lcs//lib/diff/lcs.rb#51
+module Diff::LCS
+ # Returns the difference set between +self+ and +other+. See Diff::LCS#diff.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#75
+ def diff(other, callbacks = T.unsafe(nil), &block); end
+
+ # Returns an Array containing the longest common subsequence(s) between
+ # +self+ and +other+. See Diff::LCS#lcs.
+ #
+ # lcs = seq1.lcs(seq2)
+ #
+ # A note when using objects: Diff::LCS only works properly when each object
+ # can be used as a key in a Hash, which typically means that the objects must
+ # implement Object#eql? in a way that two identical values compare
+ # identically for key purposes. That is:
+ #
+ # O.new('a').eql?(O.new('a')) == true
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#70
+ def lcs(other, &block); end
+
+ # Attempts to patch +self+ with the provided +patchset+. A new sequence based
+ # on +self+ and the +patchset+ will be created. See Diff::LCS#patch. Attempts
+ # to autodiscover the direction of the patch.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#101
+ def patch(patchset); end
+
+ # Attempts to patch +self+ with the provided +patchset+. A new sequence based
+ # on +self+ and the +patchset+ will be created. See Diff::LCS#patch. Does no
+ # patch direction autodiscovery.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#109
+ def patch!(patchset); end
+
+ # Attempts to patch +self+ with the provided +patchset+, using #patch!. If
+ # the sequence this is used on supports #replace, the value of +self+ will be
+ # replaced. See Diff::LCS#patch. Does no patch direction autodiscovery.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#123
+ def patch_me(patchset); end
+
+ # Returns the balanced ("side-by-side") difference set between +self+ and
+ # +other+. See Diff::LCS#sdiff.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#81
+ def sdiff(other, callbacks = T.unsafe(nil), &block); end
+
+ # Traverses the discovered longest common subsequences between +self+ and
+ # +other+ using the alternate, balanced algorithm. See
+ # Diff::LCS#traverse_balanced.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#94
+ def traverse_balanced(other, callbacks = T.unsafe(nil), &block); end
+
+ # Traverses the discovered longest common subsequences between +self+ and
+ # +other+. See Diff::LCS#traverse_sequences.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#87
+ def traverse_sequences(other, callbacks = T.unsafe(nil), &block); end
+
+ # Attempts to patch +self+ with the provided +patchset+. A new sequence based
+ # on +self+ and the +patchset+ will be created. See Diff::LCS#patch. Attempts
+ # to autodiscover the direction of the patch.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#101
+ def unpatch(patchset); end
+
+ # Attempts to unpatch +self+ with the provided +patchset+. A new sequence
+ # based on +self+ and the +patchset+ will be created. See Diff::LCS#unpatch.
+ # Does no patch direction autodiscovery.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#116
+ def unpatch!(patchset); end
+
+ # Attempts to unpatch +self+ with the provided +patchset+, using #unpatch!.
+ # If the sequence this is used on supports #replace, the value of +self+ will
+ # be replaced. See Diff::LCS#unpatch. Does no patch direction autodiscovery.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#134
+ def unpatch_me(patchset); end
+
+ class << self
+ # :yields: seq1[i] for each matched
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#144
+ def LCS(seq1, seq2, &block); end
+
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#52
+ def callbacks_for(callbacks); end
+
+ # #diff computes the smallest set of additions and deletions necessary to
+ # turn the first sequence into the second, and returns a description of these
+ # changes.
+ #
+ # See Diff::LCS::DiffCallbacks for the default behaviour. An alternate
+ # behaviour may be implemented with Diff::LCS::ContextDiffCallbacks. If a
+ # Class argument is provided for +callbacks+, #diff will attempt to
+ # initialise it. If the +callbacks+ object (possibly initialised) responds to
+ # #finish, it will be called.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#168
+ def diff(seq1, seq2, callbacks = T.unsafe(nil), &block); end
+
+ # :yields: seq1[i] for each matched
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#144
+ def lcs(seq1, seq2, &block); end
+
+ # Applies a +patchset+ to the sequence +src+ according to the +direction+
+ # (:patch or :unpatch), producing a new sequence.
+ #
+ # If the +direction+ is not specified, Diff::LCS::patch will attempt to
+ # discover the direction of the +patchset+.
+ #
+ # A +patchset+ can be considered to apply forward (:patch) if the
+ # following expression is true:
+ #
+ # patch(s1, diff(s1, s2)) -> s2
+ #
+ # A +patchset+ can be considered to apply backward (:unpatch) if the
+ # following expression is true:
+ #
+ # patch(s2, diff(s1, s2)) -> s1
+ #
+ # If the +patchset+ contains no changes, the +src+ value will be returned as
+ # either src.dup or +src+. A +patchset+ can be deemed as having no
+ # changes if the following predicate returns true:
+ #
+ # patchset.empty? or
+ # patchset.flatten(1).all? { |change| change.unchanged? }
+ #
+ # === Patchsets
+ #
+ # A +patchset+ is always an enumerable sequence of changes, hunks of changes,
+ # or a mix of the two. A hunk of changes is an enumerable sequence of
+ # changes:
+ #
+ # [ # patchset
+ # # change
+ # [ # hunk
+ # # change
+ # ]
+ # ]
+ #
+ # The +patch+ method accepts patchsets that are enumerable sequences
+ # containing either Diff::LCS::Change objects (or a subclass) or the array
+ # representations of those objects. Prior to application, array
+ # representations of Diff::LCS::Change objects will be reified.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#626
+ def patch(src, patchset, direction = T.unsafe(nil)); end
+
+ # Given a set of patchset, convert the current version to the next version.
+ # Does no auto-discovery.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#736
+ def patch!(src, patchset); end
+
+ # #sdiff computes all necessary components to show two sequences and their
+ # minimized differences side by side, just like the Unix utility
+ # sdiff does:
+ #
+ # old < -
+ # same same
+ # before | after
+ # - > new
+ #
+ # See Diff::LCS::SDiffCallbacks for the default behaviour. An alternate
+ # behaviour may be implemented with Diff::LCS::ContextDiffCallbacks. If a
+ # Class argument is provided for +callbacks+, #diff will attempt to
+ # initialise it. If the +callbacks+ object (possibly initialised) responds to
+ # #finish, it will be called.
+ #
+ # Each element of a returned array is a Diff::LCS::ContextChange object,
+ # which can be implicitly converted to an array.
+ #
+ # Diff::LCS.sdiff(a, b).each do |action, (old_pos, old_element), (new_pos, new_element)|
+ # case action
+ # when '!'
+ # # replace
+ # when '-'
+ # # delete
+ # when '+'
+ # # insert
+ # end
+ # end
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#200
+ def sdiff(seq1, seq2, callbacks = T.unsafe(nil), &block); end
+
+ # #traverse_balanced is an alternative to #traverse_sequences. It uses a
+ # different algorithm to iterate through the entries in the computed longest
+ # common subsequence. Instead of viewing the changes as insertions or
+ # deletions from one of the sequences, #traverse_balanced will report
+ # changes between the sequences.
+ #
+ # The arguments to #traverse_balanced are the two sequences to traverse and a
+ # callback object, like this:
+ #
+ # traverse_balanced(seq1, seq2, Diff::LCS::ContextDiffCallbacks.new)
+ #
+ # #sdiff is implemented with #traverse_balanced.
+ #
+ # == Callback Methods
+ #
+ # Optional callback methods are emphasized.
+ #
+ # callbacks#match:: Called when +a+ and +b+ are pointing to
+ # common elements in +A+ and +B+.
+ # callbacks#discard_a:: Called when +a+ is pointing to an
+ # element not in +B+.
+ # callbacks#discard_b:: Called when +b+ is pointing to an
+ # element not in +A+.
+ # callbacks#change:: Called when +a+ and +b+ are pointing to
+ # the same relative position, but
+ # A[a] and B[b] are not
+ # the same; a change has
+ # occurred.
+ #
+ # #traverse_balanced might be a bit slower than #traverse_sequences,
+ # noticable only while processing huge amounts of data.
+ #
+ # == Algorithm
+ #
+ # a---+
+ # v
+ # A = a b c e h j l m n p
+ # B = b c d e f j k l m r s t
+ # ^
+ # b---+
+ #
+ # === Matches
+ #
+ # If there are two arrows (+a+ and +b+) pointing to elements of sequences +A+
+ # and +B+, the arrows will initially point to the first elements of their
+ # respective sequences. #traverse_sequences will advance the arrows through
+ # the sequences one element at a time, calling a method on the user-specified
+ # callback object before each advance. It will advance the arrows in such a
+ # way that if there are elements A[i] and B[j] which are
+ # both equal and part of the longest common subsequence, there will be some
+ # moment during the execution of #traverse_sequences when arrow +a+ is
+ # pointing to A[i] and arrow +b+ is pointing to B[j]. When
+ # this happens, #traverse_sequences will call callbacks#match and
+ # then it will advance both arrows.
+ #
+ # === Discards
+ #
+ # Otherwise, one of the arrows is pointing to an element of its sequence that
+ # is not part of the longest common subsequence. #traverse_sequences will
+ # advance that arrow and will call callbacks#discard_a or
+ # callbacks#discard_b, depending on which arrow it advanced.
+ #
+ # === Changes
+ #
+ # If both +a+ and +b+ point to elements that are not part of the longest
+ # common subsequence, then #traverse_sequences will try to call
+ # callbacks#change and advance both arrows. If
+ # callbacks#change is not implemented, then
+ # callbacks#discard_a and callbacks#discard_b will be
+ # called in turn.
+ #
+ # The methods for callbacks#match, callbacks#discard_a,
+ # callbacks#discard_b, and callbacks#change are invoked
+ # with an event comprising the action ("=", "+", "-", or "!", respectively),
+ # the indicies +i+ and +j+, and the elements A[i] and B[j].
+ # Return values are discarded by #traverse_balanced.
+ #
+ # === Context
+ #
+ # Note that +i+ and +j+ may not be the same index position, even if +a+ and
+ # +b+ are considered to be pointing to matching or changed elements.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#475
+ def traverse_balanced(seq1, seq2, callbacks = T.unsafe(nil)); end
+
+ # #traverse_sequences is the most general facility provided by this module;
+ # #diff and #lcs are implemented as calls to it.
+ #
+ # The arguments to #traverse_sequences are the two sequences to traverse, and
+ # a callback object, like this:
+ #
+ # traverse_sequences(seq1, seq2, Diff::LCS::ContextDiffCallbacks.new)
+ #
+ # == Callback Methods
+ #
+ # Optional callback methods are emphasized.
+ #
+ # callbacks#match:: Called when +a+ and +b+ are pointing to
+ # common elements in +A+ and +B+.
+ # callbacks#discard_a:: Called when +a+ is pointing to an
+ # element not in +B+.
+ # callbacks#discard_b:: Called when +b+ is pointing to an
+ # element not in +A+.
+ # callbacks#finished_a:: Called when +a+ has reached the end of
+ # sequence +A+.
+ # callbacks#finished_b:: Called when +b+ has reached the end of
+ # sequence +B+.
+ #
+ # == Algorithm
+ #
+ # a---+
+ # v
+ # A = a b c e h j l m n p
+ # B = b c d e f j k l m r s t
+ # ^
+ # b---+
+ #
+ # If there are two arrows (+a+ and +b+) pointing to elements of sequences +A+
+ # and +B+, the arrows will initially point to the first elements of their
+ # respective sequences. #traverse_sequences will advance the arrows through
+ # the sequences one element at a time, calling a method on the user-specified
+ # callback object before each advance. It will advance the arrows in such a
+ # way that if there are elements A[i] and B[j] which are
+ # both equal and part of the longest common subsequence, there will be some
+ # moment during the execution of #traverse_sequences when arrow +a+ is
+ # pointing to A[i] and arrow +b+ is pointing to B[j]. When
+ # this happens, #traverse_sequences will call callbacks#match and
+ # then it will advance both arrows.
+ #
+ # Otherwise, one of the arrows is pointing to an element of its sequence that
+ # is not part of the longest common subsequence. #traverse_sequences will
+ # advance that arrow and will call callbacks#discard_a or
+ # callbacks#discard_b, depending on which arrow it advanced. If both
+ # arrows point to elements that are not part of the longest common
+ # subsequence, then #traverse_sequences will advance arrow +a+ and call the
+ # appropriate callback, then it will advance arrow +b+ and call the appropriate
+ # callback.
+ #
+ # The methods for callbacks#match, callbacks#discard_a, and
+ # callbacks#discard_b are invoked with an event comprising the
+ # action ("=", "+", or "-", respectively), the indicies +i+ and +j+, and the
+ # elements A[i] and B[j]. Return values are discarded by
+ # #traverse_sequences.
+ #
+ # === End of Sequences
+ #
+ # If arrow +a+ reaches the end of its sequence before arrow +b+ does,
+ # #traverse_sequence will try to call callbacks#finished_a with the
+ # last index and element of +A+ (A[-1]) and the current index and
+ # element of +B+ (B[j]). If callbacks#finished_a does not
+ # exist, then callbacks#discard_b will be called on each element of
+ # +B+ until the end of the sequence is reached (the call will be done with
+ # A[-1] and B[j] for each element).
+ #
+ # If +b+ reaches the end of +B+ before +a+ reaches the end of +A+,
+ # callbacks#finished_b will be called with the current index and
+ # element of +A+ (A[i]) and the last index and element of +B+
+ # (A[-1]). Again, if callbacks#finished_b does not exist on
+ # the callback object, then callbacks#discard_a will be called on
+ # each element of +A+ until the end of the sequence is reached (A[i]
+ # and B[-1]).
+ #
+ # There is a chance that one additional callbacks#discard_a or
+ # callbacks#discard_b will be called after the end of the sequence
+ # is reached, if +a+ has not yet reached the end of +A+ or +b+ has not yet
+ # reached the end of +B+.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#285
+ def traverse_sequences(seq1, seq2, callbacks = T.unsafe(nil)); end
+
+ # Given a set of patchset, convert the current version to the prior version.
+ # Does no auto-discovery.
+ #
+ # source://diff-lcs//lib/diff/lcs.rb#730
+ def unpatch!(src, patchset); end
+
+ private
+
+ # source://diff-lcs//lib/diff/lcs/internals.rb#4
+ def diff_traversal(method, seq1, seq2, callbacks, &block); end
+ end
+end
+
+# An alias for DefaultCallbacks that is used in
+# Diff::LCS#traverse_balanced.
+#
+# Diff::LCS.LCS(seq1, seq2, Diff::LCS::BalancedCallbacks)
+#
+# source://diff-lcs//lib/diff/lcs/callbacks.rb#50
+Diff::LCS::BalancedCallbacks = Diff::LCS::DefaultCallbacks
+
+# A block is an operation removing, adding, or changing a group of items.
+# Basically, this is just a list of changes, where each change adds or
+# deletes a single item. Used by bin/ldiff.
+#
+# source://diff-lcs//lib/diff/lcs/block.rb#6
+class Diff::LCS::Block
+ # @return [Block] a new instance of Block
+ #
+ # source://diff-lcs//lib/diff/lcs/block.rb#9
+ def initialize(chunk); end
+
+ # Returns the value of attribute changes.
+ #
+ # source://diff-lcs//lib/diff/lcs/block.rb#7
+ def changes; end
+
+ # source://diff-lcs//lib/diff/lcs/block.rb#21
+ def diff_size; end
+
+ # Returns the value of attribute insert.
+ #
+ # source://diff-lcs//lib/diff/lcs/block.rb#7
+ def insert; end
+
+ # source://diff-lcs//lib/diff/lcs/block.rb#25
+ def op; end
+
+ # Returns the value of attribute remove.
+ #
+ # source://diff-lcs//lib/diff/lcs/block.rb#7
+ def remove; end
+end
+
+# Represents a simplistic (non-contextual) change. Represents the removal or
+# addition of an element from either the old or the new sequenced
+# enumerable.
+#
+# source://diff-lcs//lib/diff/lcs/change.rb#6
+class Diff::LCS::Change
+ include ::Comparable
+
+ # @return [Change] a new instance of Change
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#27
+ def initialize(*args); end
+
+ # source://diff-lcs//lib/diff/lcs/change.rb#65
+ def <=>(other); end
+
+ # source://diff-lcs//lib/diff/lcs/change.rb#58
+ def ==(other); end
+
+ # Returns the action this Change represents.
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#20
+ def action; end
+
+ # @return [Boolean]
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#72
+ def adding?; end
+
+ # @return [Boolean]
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#84
+ def changed?; end
+
+ # @return [Boolean]
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#76
+ def deleting?; end
+
+ # Returns the sequence element of the Change.
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#25
+ def element; end
+
+ # @return [Boolean]
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#88
+ def finished_a?; end
+
+ # @return [Boolean]
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#92
+ def finished_b?; end
+
+ # source://diff-lcs//lib/diff/lcs/change.rb#34
+ def inspect(*_args); end
+
+ # Returns the position of the Change.
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#23
+ def position; end
+
+ # source://diff-lcs//lib/diff/lcs/change.rb#38
+ def to_a; end
+
+ # source://diff-lcs//lib/diff/lcs/change.rb#38
+ def to_ary; end
+
+ # @return [Boolean]
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#80
+ def unchanged?; end
+
+ class << self
+ # source://diff-lcs//lib/diff/lcs/change.rb#44
+ def from_a(arr); end
+
+ # @return [Boolean]
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#15
+ def valid_action?(action); end
+ end
+end
+
+# source://diff-lcs//lib/diff/lcs/change.rb#7
+Diff::LCS::Change::IntClass = Integer
+
+# The only actions valid for changes are '+' (add), '-' (delete), '='
+# (no change), '!' (changed), '<' (tail changes from first sequence), or
+# '>' (tail changes from second sequence). The last two ('<>') are only
+# found with Diff::LCS::diff and Diff::LCS::sdiff.
+#
+# source://diff-lcs//lib/diff/lcs/change.rb#13
+Diff::LCS::Change::VALID_ACTIONS = T.let(T.unsafe(nil), Array)
+
+# Represents a contextual change. Contains the position and values of the
+# elements in the old and the new sequenced enumerables as well as the action
+# taken.
+#
+# source://diff-lcs//lib/diff/lcs/change.rb#100
+class Diff::LCS::ContextChange < ::Diff::LCS::Change
+ # @return [ContextChange] a new instance of ContextChange
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#114
+ def initialize(*args); end
+
+ # source://diff-lcs//lib/diff/lcs/change.rb#166
+ def <=>(other); end
+
+ # source://diff-lcs//lib/diff/lcs/change.rb#157
+ def ==(other); end
+
+ # Returns the new element being changed.
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#112
+ def new_element; end
+
+ # Returns the new position being changed.
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#108
+ def new_position; end
+
+ # Returns the old element being changed.
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#110
+ def old_element; end
+
+ # Returns the old position being changed.
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#106
+ def old_position; end
+
+ # source://diff-lcs//lib/diff/lcs/change.rb#122
+ def to_a; end
+
+ # source://diff-lcs//lib/diff/lcs/change.rb#122
+ def to_ary; end
+
+ class << self
+ # source://diff-lcs//lib/diff/lcs/change.rb#132
+ def from_a(arr); end
+
+ # Simplifies a context change for use in some diff callbacks. '<' actions
+ # are converted to '-' and '>' actions are converted to '+'.
+ #
+ # source://diff-lcs//lib/diff/lcs/change.rb#138
+ def simplify(event); end
+ end
+end
+
+# This will produce a compound array of contextual diff change objects. Each
+# element in the #diffs array is a "hunk" array, where each element in each
+# "hunk" array is a single change. Each change is a Diff::LCS::ContextChange
+# that contains both the old index and new index values for the change. The
+# "hunk" provides the full context for the changes. Both old and new objects
+# will be presented for changed objects. +nil+ will be substituted for a
+# discarded object.
+#
+# seq1 = %w(a b c e h j l m n p)
+# seq2 = %w(b c d e f j k l m r s t)
+#
+# diffs = Diff::LCS.diff(seq1, seq2, Diff::LCS::ContextDiffCallbacks)
+# # This example shows a simplified array format.
+# # [ [ [ '-', [ 0, 'a' ], [ 0, nil ] ] ], # 1
+# # [ [ '+', [ 3, nil ], [ 2, 'd' ] ] ], # 2
+# # [ [ '-', [ 4, 'h' ], [ 4, nil ] ], # 3
+# # [ '+', [ 5, nil ], [ 4, 'f' ] ] ],
+# # [ [ '+', [ 6, nil ], [ 6, 'k' ] ] ], # 4
+# # [ [ '-', [ 8, 'n' ], [ 9, nil ] ], # 5
+# # [ '+', [ 9, nil ], [ 9, 'r' ] ],
+# # [ '-', [ 9, 'p' ], [ 10, nil ] ],
+# # [ '+', [ 10, nil ], [ 10, 's' ] ],
+# # [ '+', [ 10, nil ], [ 11, 't' ] ] ] ]
+#
+# The five hunks shown are comprised of individual changes; if there is a
+# related set of changes, they are still shown individually.
+#
+# This callback can also be used with Diff::LCS#sdiff, which will produce
+# results like:
+#
+# diffs = Diff::LCS.sdiff(seq1, seq2, Diff::LCS::ContextCallbacks)
+# # This example shows a simplified array format.
+# # [ [ [ "-", [ 0, "a" ], [ 0, nil ] ] ], # 1
+# # [ [ "+", [ 3, nil ], [ 2, "d" ] ] ], # 2
+# # [ [ "!", [ 4, "h" ], [ 4, "f" ] ] ], # 3
+# # [ [ "+", [ 6, nil ], [ 6, "k" ] ] ], # 4
+# # [ [ "!", [ 8, "n" ], [ 9, "r" ] ], # 5
+# # [ "!", [ 9, "p" ], [ 10, "s" ] ],
+# # [ "+", [ 10, nil ], [ 11, "t" ] ] ] ]
+#
+# The five hunks are still present, but are significantly shorter in total
+# presentation, because changed items are shown as changes ("!") instead of
+# potentially "mismatched" pairs of additions and deletions.
+#
+# The result of this operation is similar to that of
+# Diff::LCS::SDiffCallbacks. They may be compared as:
+#
+# s = Diff::LCS.sdiff(seq1, seq2).reject { |e| e.action == "=" }
+# c = Diff::LCS.sdiff(seq1, seq2, Diff::LCS::ContextDiffCallbacks).flatten(1)
+#
+# s == c # -> true
+#
+# === Use
+#
+# This callback object must be initialised and can be used by the
+# Diff::LCS#diff or Diff::LCS#sdiff methods.
+#
+# cbo = Diff::LCS::ContextDiffCallbacks.new
+# Diff::LCS.LCS(seq1, seq2, cbo)
+# cbo.finish
+#
+# Note that the call to #finish is absolutely necessary, or the last set of
+# changes will not be visible. Alternatively, can be used as:
+#
+# cbo = Diff::LCS::ContextDiffCallbacks.new { |tcbo| Diff::LCS.LCS(seq1, seq2, tcbo) }
+#
+# The necessary #finish call will be made.
+#
+# === Simplified Array Format
+#
+# The simplified array format used in the example above can be obtained
+# with:
+#
+# require 'pp'
+# pp diffs.map { |e| e.map { |f| f.to_a } }
+#
+# source://diff-lcs//lib/diff/lcs/callbacks.rb#225
+class Diff::LCS::ContextDiffCallbacks < ::Diff::LCS::DiffCallbacks
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#234
+ def change(event); end
+
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#226
+ def discard_a(event); end
+
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#230
+ def discard_b(event); end
+end
+
+# This callback object implements the default set of callback events,
+# which only returns the event itself. Note that #finished_a and
+# #finished_b are not implemented -- I haven't yet figured out where they
+# would be useful.
+#
+# Note that this is intended to be called as is, e.g.,
+#
+# Diff::LCS.LCS(seq1, seq2, Diff::LCS::DefaultCallbacks)
+#
+# source://diff-lcs//lib/diff/lcs/callbacks.rb#14
+class Diff::LCS::DefaultCallbacks
+ class << self
+ # Called when both the old and new values have changed.
+ #
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#32
+ def change(event); end
+
+ # Called when the old value is discarded in favour of the new value.
+ #
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#22
+ def discard_a(event); end
+
+ # Called when the new value is discarded in favour of the old value.
+ #
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#27
+ def discard_b(event); end
+
+ # Called when two items match.
+ #
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#17
+ def match(event); end
+
+ private
+
+ def new(*_arg0); end
+ end
+end
+
+# This will produce a compound array of simple diff change objects. Each
+# element in the #diffs array is a +hunk+ or +hunk+ array, where each
+# element in each +hunk+ array is a single Change object representing the
+# addition or removal of a single element from one of the two tested
+# sequences. The +hunk+ provides the full context for the changes.
+#
+# diffs = Diff::LCS.diff(seq1, seq2)
+# # This example shows a simplified array format.
+# # [ [ [ '-', 0, 'a' ] ], # 1
+# # [ [ '+', 2, 'd' ] ], # 2
+# # [ [ '-', 4, 'h' ], # 3
+# # [ '+', 4, 'f' ] ],
+# # [ [ '+', 6, 'k' ] ], # 4
+# # [ [ '-', 8, 'n' ], # 5
+# # [ '-', 9, 'p' ],
+# # [ '+', 9, 'r' ],
+# # [ '+', 10, 's' ],
+# # [ '+', 11, 't' ] ] ]
+#
+# There are five hunks here. The first hunk says that the +a+ at position 0
+# of the first sequence should be deleted ('-'). The second hunk
+# says that the +d+ at position 2 of the second sequence should be inserted
+# ('+'). The third hunk says that the +h+ at position 4 of the
+# first sequence should be removed and replaced with the +f+ from position 4
+# of the second sequence. The other two hunks are described similarly.
+#
+# === Use
+#
+# This callback object must be initialised and is used by the Diff::LCS#diff
+# method.
+#
+# cbo = Diff::LCS::DiffCallbacks.new
+# Diff::LCS.LCS(seq1, seq2, cbo)
+# cbo.finish
+#
+# Note that the call to #finish is absolutely necessary, or the last set of
+# changes will not be visible. Alternatively, can be used as:
+#
+# cbo = Diff::LCS::DiffCallbacks.new { |tcbo| Diff::LCS.LCS(seq1, seq2, tcbo) }
+#
+# The necessary #finish call will be made.
+#
+# === Simplified Array Format
+#
+# The simplified array format used in the example above can be obtained
+# with:
+#
+# require 'pp'
+# pp diffs.map { |e| e.map { |f| f.to_a } }
+#
+# source://diff-lcs//lib/diff/lcs/callbacks.rb#108
+class Diff::LCS::DiffCallbacks
+ # :yields: self
+ #
+ # @return [DiffCallbacks] a new instance of DiffCallbacks
+ #
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#112
+ def initialize; end
+
+ # Returns the difference set collected during the diff process.
+ #
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#110
+ def diffs; end
+
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#135
+ def discard_a(event); end
+
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#139
+ def discard_b(event); end
+
+ # Finalizes the diff process. If an unprocessed hunk still exists, then it
+ # is appended to the diff list.
+ #
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#127
+ def finish; end
+
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#131
+ def match(_event); end
+
+ private
+
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#143
+ def finish_hunk; end
+end
+
+# A Hunk is a group of Blocks which overlap because of the context surrounding
+# each block. (So if we're not using context, every hunk will contain one
+# block.) Used in the diff program (bin/ldiff).
+#
+# source://diff-lcs//lib/diff/lcs/hunk.rb#8
+class Diff::LCS::Hunk
+ # Create a hunk using references to both the old and new data, as well as the
+ # piece of data.
+ #
+ # @return [Hunk] a new instance of Hunk
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#16
+ def initialize(data_old, data_new, piece, flag_context, file_length_difference); end
+
+ # Returns the value of attribute blocks.
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#62
+ def blocks; end
+
+ # Returns a diff string based on a format.
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#115
+ def diff(format, last = T.unsafe(nil)); end
+
+ # Returns the value of attribute end_new.
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#64
+ def end_new; end
+
+ # Returns the value of attribute end_old.
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#64
+ def end_old; end
+
+ # Returns the value of attribute file_length_difference.
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#65
+ def file_length_difference; end
+
+ # Change the "start" and "end" fields to note that context should be added
+ # to this hunk.
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#69
+ def flag_context; end
+
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#71
+ def flag_context=(context); end
+
+ # Merges this hunk and the provided hunk together if they overlap. Returns
+ # a truthy value so that if there is no overlap, you can know the merge
+ # was skipped.
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#97
+ def merge(hunk); end
+
+ # @return [Boolean]
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#331
+ def missing_last_newline?(data); end
+
+ # Determines whether there is an overlap between this hunk and the
+ # provided hunk. This will be true if the difference between the two hunks
+ # start or end positions is within one position of each other.
+ #
+ # @return [Boolean]
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#109
+ def overlaps?(hunk); end
+
+ # Returns the value of attribute start_new.
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#63
+ def start_new; end
+
+ # Returns the value of attribute start_old.
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#63
+ def start_old; end
+
+ # Merges this hunk and the provided hunk together if they overlap. Returns
+ # a truthy value so that if there is no overlap, you can know the merge
+ # was skipped.
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#97
+ def unshift(hunk); end
+
+ private
+
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#214
+ def context_diff(last = T.unsafe(nil)); end
+
+ # Generate a range of item numbers to print. Only print 1 number if the
+ # range has only one item in it. Otherwise, it's 'start,end'
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#298
+ def context_range(mode, op, last = T.unsafe(nil)); end
+
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#276
+ def ed_diff(format, _last = T.unsafe(nil)); end
+
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#344
+ def encode(literal, target_encoding = T.unsafe(nil)); end
+
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#348
+ def encode_as(string, *args); end
+
+ # Note that an old diff can't have any context. Therefore, we know that
+ # there's only one block in the hunk.
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#134
+ def old_diff(_last = T.unsafe(nil)); end
+
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#159
+ def unified_diff(last = T.unsafe(nil)); end
+
+ # Generate a range of item numbers to print for unified diff. Print number
+ # where block starts, followed by number of lines in the block
+ # (don't print number of lines if it's 1)
+ #
+ # source://diff-lcs//lib/diff/lcs/hunk.rb#316
+ def unified_range(mode, last); end
+end
+
+# source://diff-lcs//lib/diff/lcs/hunk.rb#10
+Diff::LCS::Hunk::ED_DIFF_OP_ACTION = T.let(T.unsafe(nil), Hash)
+
+# source://diff-lcs//lib/diff/lcs/hunk.rb#9
+Diff::LCS::Hunk::OLD_DIFF_OP_ACTION = T.let(T.unsafe(nil), Hash)
+
+# source://diff-lcs//lib/diff/lcs/internals.rb#29
+module Diff::LCS::Internals
+ class << self
+ # This method will analyze the provided patchset to provide a single-pass
+ # normalization (conversion of the array form of Diff::LCS::Change objects to
+ # the object form of same) and detection of whether the patchset represents
+ # changes to be made.
+ #
+ # source://diff-lcs//lib/diff/lcs/internals.rb#102
+ def analyze_patchset(patchset, depth = T.unsafe(nil)); end
+
+ # Examine the patchset and the source to see in which direction the
+ # patch should be applied.
+ #
+ # WARNING: By default, this examines the whole patch, so this could take
+ # some time. This also works better with Diff::LCS::ContextChange or
+ # Diff::LCS::Change as its source, as an array will cause the creation
+ # of one of the above.
+ #
+ # source://diff-lcs//lib/diff/lcs/internals.rb#147
+ def intuit_diff_direction(src, patchset, limit = T.unsafe(nil)); end
+
+ # Compute the longest common subsequence between the sequenced
+ # Enumerables +a+ and +b+. The result is an array whose contents is such
+ # that
+ #
+ # result = Diff::LCS::Internals.lcs(a, b)
+ # result.each_with_index do |e, i|
+ # assert_equal(a[i], b[e]) unless e.nil?
+ # end
+ #
+ # source://diff-lcs//lib/diff/lcs/internals.rb#41
+ def lcs(a, b); end
+
+ private
+
+ # If +vector+ maps the matching elements of another collection onto this
+ # Enumerable, compute the inverse of +vector+ that maps this Enumerable
+ # onto the collection. (Currently unused.)
+ #
+ # source://diff-lcs//lib/diff/lcs/internals.rb#286
+ def inverse_vector(a, vector); end
+
+ # Returns a hash mapping each element of an Enumerable to the set of
+ # positions it occupies in the Enumerable, optionally restricted to the
+ # elements specified in the range of indexes specified by +interval+.
+ #
+ # source://diff-lcs//lib/diff/lcs/internals.rb#298
+ def position_hash(enum, interval); end
+
+ # Find the place at which +value+ would normally be inserted into the
+ # Enumerable. If that place is already occupied by +value+, do nothing
+ # and return +nil+. If the place does not exist (i.e., it is off the end
+ # of the Enumerable), add it to the end. Otherwise, replace the element
+ # at that point with +value+. It is assumed that the Enumerable's values
+ # are numeric.
+ #
+ # This operation preserves the sort order.
+ #
+ # source://diff-lcs//lib/diff/lcs/internals.rb#252
+ def replace_next_larger(enum, value, last_index = T.unsafe(nil)); end
+ end
+end
+
+# This will produce a simple array of diff change objects. Each element in
+# the #diffs array is a single ContextChange. In the set of #diffs provided
+# by SDiffCallbacks, both old and new objects will be presented for both
+# changed and unchanged objects. +nil+ will be substituted
+# for a discarded object.
+#
+# The diffset produced by this callback, when provided to Diff::LCS#sdiff,
+# will compute and display the necessary components to show two sequences
+# and their minimized differences side by side, just like the Unix utility
+# +sdiff+.
+#
+# same same
+# before | after
+# old < -
+# - > new
+#
+# seq1 = %w(a b c e h j l m n p)
+# seq2 = %w(b c d e f j k l m r s t)
+#
+# diffs = Diff::LCS.sdiff(seq1, seq2)
+# # This example shows a simplified array format.
+# # [ [ "-", [ 0, "a"], [ 0, nil ] ],
+# # [ "=", [ 1, "b"], [ 0, "b" ] ],
+# # [ "=", [ 2, "c"], [ 1, "c" ] ],
+# # [ "+", [ 3, nil], [ 2, "d" ] ],
+# # [ "=", [ 3, "e"], [ 3, "e" ] ],
+# # [ "!", [ 4, "h"], [ 4, "f" ] ],
+# # [ "=", [ 5, "j"], [ 5, "j" ] ],
+# # [ "+", [ 6, nil], [ 6, "k" ] ],
+# # [ "=", [ 6, "l"], [ 7, "l" ] ],
+# # [ "=", [ 7, "m"], [ 8, "m" ] ],
+# # [ "!", [ 8, "n"], [ 9, "r" ] ],
+# # [ "!", [ 9, "p"], [ 10, "s" ] ],
+# # [ "+", [ 10, nil], [ 11, "t" ] ] ]
+#
+# The result of this operation is similar to that of
+# Diff::LCS::ContextDiffCallbacks. They may be compared as:
+#
+# s = Diff::LCS.sdiff(seq1, seq2).reject { |e| e.action == "=" }
+# c = Diff::LCS.sdiff(seq1, seq2, Diff::LCS::ContextDiffCallbacks).flatten(1)
+#
+# s == c # -> true
+#
+# === Use
+#
+# This callback object must be initialised and is used by the Diff::LCS#sdiff
+# method.
+#
+# cbo = Diff::LCS::SDiffCallbacks.new
+# Diff::LCS.LCS(seq1, seq2, cbo)
+#
+# As with the other initialisable callback objects,
+# Diff::LCS::SDiffCallbacks can be initialised with a block. As there is no
+# "fininishing" to be done, this has no effect on the state of the object.
+#
+# cbo = Diff::LCS::SDiffCallbacks.new { |tcbo| Diff::LCS.LCS(seq1, seq2, tcbo) }
+#
+# === Simplified Array Format
+#
+# The simplified array format used in the example above can be obtained
+# with:
+#
+# require 'pp'
+# pp diffs.map { |e| e.to_a }
+#
+# source://diff-lcs//lib/diff/lcs/callbacks.rb#303
+class Diff::LCS::SDiffCallbacks
+ # :yields: self
+ #
+ # @return [SDiffCallbacks] a new instance of SDiffCallbacks
+ # @yield [_self]
+ # @yieldparam _self [Diff::LCS::SDiffCallbacks] the object that the method was called on
+ #
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#307
+ def initialize; end
+
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#324
+ def change(event); end
+
+ # Returns the difference set collected during the diff process.
+ #
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#305
+ def diffs; end
+
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#316
+ def discard_a(event); end
+
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#320
+ def discard_b(event); end
+
+ # source://diff-lcs//lib/diff/lcs/callbacks.rb#312
+ def match(event); end
+end
+
+# An alias for DefaultCallbacks that is used in
+# Diff::LCS#traverse_sequences.
+#
+# Diff::LCS.LCS(seq1, seq2, Diff::LCS::SequenceCallbacks)
+#
+# source://diff-lcs//lib/diff/lcs/callbacks.rb#44
+Diff::LCS::SequenceCallbacks = Diff::LCS::DefaultCallbacks
+
+# source://diff-lcs//lib/diff/lcs.rb#52
+Diff::LCS::VERSION = T.let(T.unsafe(nil), String)
diff --git a/sorbet/rbi/gems/drb@2.2.1.rbi b/sorbet/rbi/gems/drb@2.2.1.rbi
new file mode 100644
index 0000000..4c77c96
--- /dev/null
+++ b/sorbet/rbi/gems/drb@2.2.1.rbi
@@ -0,0 +1,1301 @@
+# typed: false
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `drb` gem.
+# Please instead update this file by running `bin/tapioca gem drb`.
+
+
+# for ruby-1.8.0
+#
+# source://drb//lib/drb/eq.rb#2
+module DRb
+ private
+
+ # Get the configuration of the current server.
+ #
+ # If there is no current server, this returns the default configuration.
+ # See #current_server and DRbServer::make_config.
+ #
+ # source://drb//lib/drb/drb.rb#1832
+ def config; end
+
+ # Get the 'current' server.
+ #
+ # In the context of execution taking place within the main
+ # thread of a dRuby server (typically, as a result of a remote
+ # call on the server or one of its objects), the current
+ # server is that server. Otherwise, the current server is
+ # the primary server.
+ #
+ # If the above rule fails to find a server, a DRbServerNotFound
+ # error is raised.
+ #
+ # @raise [DRbServerNotFound]
+ #
+ # source://drb//lib/drb/drb.rb#1789
+ def current_server; end
+
+ # Retrieves the server with the given +uri+.
+ #
+ # See also regist_server and remove_server.
+ #
+ # source://drb//lib/drb/drb.rb#1934
+ def fetch_server(uri); end
+
+ # Get the front object of the current server.
+ #
+ # This raises a DRbServerNotFound error if there is no current server.
+ # See #current_server.
+ #
+ # source://drb//lib/drb/drb.rb#1843
+ def front; end
+
+ # Is +uri+ the URI for the current local server?
+ #
+ # @return [Boolean]
+ #
+ # source://drb//lib/drb/drb.rb#1822
+ def here?(uri); end
+
+ # Set the default ACL to +acl+.
+ #
+ # See DRb::DRbServer.default_acl.
+ #
+ # source://drb//lib/drb/drb.rb#1888
+ def install_acl(acl); end
+
+ # Set the default id conversion object.
+ #
+ # This is expected to be an instance such as DRb::DRbIdConv that responds to
+ # #to_id and #to_obj that can convert objects to and from DRb references.
+ #
+ # See DRbServer#default_id_conv.
+ #
+ # source://drb//lib/drb/drb.rb#1880
+ def install_id_conv(idconv); end
+
+ # source://drb//lib/drb/drb.rb#1894
+ def mutex; end
+
+ # The primary local dRuby server.
+ #
+ # This is the server created by the #start_service call.
+ #
+ # source://drb//lib/drb/drb.rb#1776
+ def primary_server; end
+
+ # The primary local dRuby server.
+ #
+ # This is the server created by the #start_service call.
+ #
+ # source://drb//lib/drb/drb.rb#1776
+ def primary_server=(_arg0); end
+
+ # Registers +server+ with DRb.
+ #
+ # This is called when a new DRb::DRbServer is created.
+ #
+ # If there is no primary server then +server+ becomes the primary server.
+ #
+ # Example:
+ #
+ # require 'drb'
+ #
+ # s = DRb::DRbServer.new # automatically calls regist_server
+ # DRb.fetch_server s.uri #=> #
+ #
+ # source://drb//lib/drb/drb.rb#1912
+ def regist_server(server); end
+
+ # Removes +server+ from the list of registered servers.
+ #
+ # source://drb//lib/drb/drb.rb#1921
+ def remove_server(server); end
+
+ # Start a dRuby server locally.
+ #
+ # The new dRuby server will become the primary server, even
+ # if another server is currently the primary server.
+ #
+ # +uri+ is the URI for the server to bind to. If nil,
+ # the server will bind to random port on the default local host
+ # name and use the default dRuby protocol.
+ #
+ # +front+ is the server's front object. This may be nil.
+ #
+ # +config+ is the configuration for the new server. This may
+ # be nil.
+ #
+ # See DRbServer::new.
+ #
+ # source://drb//lib/drb/drb.rb#1768
+ def start_service(uri = T.unsafe(nil), front = T.unsafe(nil), config = T.unsafe(nil)); end
+
+ # Stop the local dRuby server.
+ #
+ # This operates on the primary server. If there is no primary
+ # server currently running, it is a noop.
+ #
+ # source://drb//lib/drb/drb.rb#1801
+ def stop_service; end
+
+ # Get the thread of the primary server.
+ #
+ # This returns nil if there is no primary server. See #primary_server.
+ #
+ # source://drb//lib/drb/drb.rb#1869
+ def thread; end
+
+ # Get a reference id for an object using the current server.
+ #
+ # This raises a DRbServerNotFound error if there is no current server.
+ # See #current_server.
+ #
+ # source://drb//lib/drb/drb.rb#1860
+ def to_id(obj); end
+
+ # Convert a reference into an object using the current server.
+ #
+ # This raises a DRbServerNotFound error if there is no current server.
+ # See #current_server.
+ #
+ # source://drb//lib/drb/drb.rb#1852
+ def to_obj(ref); end
+
+ # Get the URI defining the local dRuby space.
+ #
+ # This is the URI of the current server. See #current_server.
+ #
+ # source://drb//lib/drb/drb.rb#1810
+ def uri; end
+
+ class << self
+ # Get the configuration of the current server.
+ #
+ # If there is no current server, this returns the default configuration.
+ # See #current_server and DRbServer::make_config.
+ #
+ # source://drb//lib/drb/drb.rb#1832
+ def config; end
+
+ # Get the 'current' server.
+ #
+ # In the context of execution taking place within the main
+ # thread of a dRuby server (typically, as a result of a remote
+ # call on the server or one of its objects), the current
+ # server is that server. Otherwise, the current server is
+ # the primary server.
+ #
+ # If the above rule fails to find a server, a DRbServerNotFound
+ # error is raised.
+ #
+ # @raise [DRbServerNotFound]
+ #
+ # source://drb//lib/drb/drb.rb#1789
+ def current_server; end
+
+ # Retrieves the server with the given +uri+.
+ #
+ # See also regist_server and remove_server.
+ #
+ # source://drb//lib/drb/drb.rb#1934
+ def fetch_server(uri); end
+
+ # Get the front object of the current server.
+ #
+ # This raises a DRbServerNotFound error if there is no current server.
+ # See #current_server.
+ #
+ # source://drb//lib/drb/drb.rb#1843
+ def front; end
+
+ # Is +uri+ the URI for the current local server?
+ #
+ # @return [Boolean]
+ #
+ # source://drb//lib/drb/drb.rb#1822
+ def here?(uri); end
+
+ # Set the default ACL to +acl+.
+ #
+ # See DRb::DRbServer.default_acl.
+ #
+ # source://drb//lib/drb/drb.rb#1888
+ def install_acl(acl); end
+
+ # Set the default id conversion object.
+ #
+ # This is expected to be an instance such as DRb::DRbIdConv that responds to
+ # #to_id and #to_obj that can convert objects to and from DRb references.
+ #
+ # See DRbServer#default_id_conv.
+ #
+ # source://drb//lib/drb/drb.rb#1880
+ def install_id_conv(idconv); end
+
+ # source://drb//lib/drb/drb.rb#1894
+ def mutex; end
+
+ # The primary local dRuby server.
+ #
+ # This is the server created by the #start_service call.
+ #
+ # source://drb//lib/drb/drb.rb#1776
+ def primary_server; end
+
+ # The primary local dRuby server.
+ #
+ # This is the server created by the #start_service call.
+ #
+ # source://drb//lib/drb/drb.rb#1776
+ def primary_server=(_arg0); end
+
+ # Registers +server+ with DRb.
+ #
+ # This is called when a new DRb::DRbServer is created.
+ #
+ # If there is no primary server then +server+ becomes the primary server.
+ #
+ # Example:
+ #
+ # require 'drb'
+ #
+ # s = DRb::DRbServer.new # automatically calls regist_server
+ # DRb.fetch_server s.uri #=> #
+ #
+ # source://drb//lib/drb/drb.rb#1912
+ def regist_server(server); end
+
+ # Removes +server+ from the list of registered servers.
+ #
+ # source://drb//lib/drb/drb.rb#1921
+ def remove_server(server); end
+
+ # Start a dRuby server locally.
+ #
+ # The new dRuby server will become the primary server, even
+ # if another server is currently the primary server.
+ #
+ # +uri+ is the URI for the server to bind to. If nil,
+ # the server will bind to random port on the default local host
+ # name and use the default dRuby protocol.
+ #
+ # +front+ is the server's front object. This may be nil.
+ #
+ # +config+ is the configuration for the new server. This may
+ # be nil.
+ #
+ # See DRbServer::new.
+ #
+ # source://drb//lib/drb/drb.rb#1768
+ def start_service(uri = T.unsafe(nil), front = T.unsafe(nil), config = T.unsafe(nil)); end
+
+ # Stop the local dRuby server.
+ #
+ # This operates on the primary server. If there is no primary
+ # server currently running, it is a noop.
+ #
+ # source://drb//lib/drb/drb.rb#1801
+ def stop_service; end
+
+ # Get the thread of the primary server.
+ #
+ # This returns nil if there is no primary server. See #primary_server.
+ #
+ # source://drb//lib/drb/drb.rb#1869
+ def thread; end
+
+ # Get a reference id for an object using the current server.
+ #
+ # This raises a DRbServerNotFound error if there is no current server.
+ # See #current_server.
+ #
+ # source://drb//lib/drb/drb.rb#1860
+ def to_id(obj); end
+
+ # Convert a reference into an object using the current server.
+ #
+ # This raises a DRbServerNotFound error if there is no current server.
+ # See #current_server.
+ #
+ # source://drb//lib/drb/drb.rb#1852
+ def to_obj(ref); end
+
+ # Get the URI defining the local dRuby space.
+ #
+ # This is the URI of the current server. See #current_server.
+ #
+ # source://drb//lib/drb/drb.rb#1810
+ def uri; end
+ end
+end
+
+# An Array wrapper that can be sent to another server via DRb.
+#
+# All entries in the array will be dumped or be references that point to
+# the local server.
+#
+# source://drb//lib/drb/drb.rb#518
+class DRb::DRbArray
+ # Creates a new DRbArray that either dumps or wraps all the items in the
+ # Array +ary+ so they can be loaded by a remote DRb server.
+ #
+ # @return [DRbArray] a new instance of DRbArray
+ #
+ # source://drb//lib/drb/drb.rb#523
+ def initialize(ary); end
+
+ # source://drb//lib/drb/drb.rb#542
+ def _dump(lv); end
+
+ class << self
+ # source://drb//lib/drb/drb.rb#538
+ def _load(s); end
+ end
+end
+
+# Class handling the connection between a DRbObject and the
+# server the real object lives on.
+#
+# This class maintains a pool of connections, to reduce the
+# overhead of starting and closing down connections for each
+# method call.
+#
+# This class is used internally by DRbObject. The user does
+# not normally need to deal with it directly.
+#
+# source://drb//lib/drb/drb.rb#1256
+class DRb::DRbConn
+ # @return [DRbConn] a new instance of DRbConn
+ #
+ # source://drb//lib/drb/drb.rb#1317
+ def initialize(remote_uri); end
+
+ # @return [Boolean]
+ #
+ # source://drb//lib/drb/drb.rb#1333
+ def alive?; end
+
+ # source://drb//lib/drb/drb.rb#1328
+ def close; end
+
+ # source://drb//lib/drb/drb.rb#1323
+ def send_message(ref, msg_id, arg, block); end
+
+ # source://drb//lib/drb/drb.rb#1321
+ def uri; end
+
+ class << self
+ # source://drb//lib/drb/drb.rb#1259
+ def make_pool; end
+
+ # source://drb//lib/drb/drb.rb#1297
+ def open(remote_uri); end
+
+ # source://drb//lib/drb/drb.rb#1292
+ def stop_pool; end
+ end
+end
+
+# Class responsible for converting between an object and its id.
+#
+# This, the default implementation, uses an object's local ObjectSpace
+# __id__ as its id. This means that an object's identification over
+# drb remains valid only while that object instance remains alive
+# within the server runtime.
+#
+# For alternative mechanisms, see DRb::TimerIdConv in drb/timeridconv.rb
+# and DRbNameIdConv in sample/name.rb in the full drb distribution.
+#
+# source://drb//lib/drb/drb.rb#360
+class DRb::DRbIdConv
+ # Convert an object into a reference id.
+ #
+ # This implementation returns the object's __id__ in the local
+ # object space.
+ #
+ # source://drb//lib/drb/drb.rb#374
+ def to_id(obj); end
+
+ # Convert an object reference id to an object.
+ #
+ # This implementation looks up the reference id in the local object
+ # space and returns the object it refers to.
+ #
+ # source://drb//lib/drb/drb.rb#366
+ def to_obj(ref); end
+end
+
+# Handler for sending and receiving drb messages.
+#
+# This takes care of the low-level marshalling and unmarshalling
+# of drb requests and responses sent over the wire between server
+# and client. This relieves the implementor of a new drb
+# protocol layer with having to deal with these details.
+#
+# The user does not have to directly deal with this object in
+# normal use.
+#
+# source://drb//lib/drb/drb.rb#556
+class DRb::DRbMessage
+ # @return [DRbMessage] a new instance of DRbMessage
+ #
+ # source://drb//lib/drb/drb.rb#557
+ def initialize(config); end
+
+ # source://drb//lib/drb/drb.rb#562
+ def dump(obj, error = T.unsafe(nil)); end
+
+ # @raise [DRbConnError]
+ #
+ # source://drb//lib/drb/drb.rb#579
+ def load(soc); end
+
+ # source://drb//lib/drb/drb.rb#639
+ def recv_reply(stream); end
+
+ # @raise [DRbConnError]
+ #
+ # source://drb//lib/drb/drb.rb#619
+ def recv_request(stream); end
+
+ # source://drb//lib/drb/drb.rb#633
+ def send_reply(stream, succ, result); end
+
+ # source://drb//lib/drb/drb.rb#605
+ def send_request(stream, ref, msg_id, arg, b); end
+
+ private
+
+ # source://drb//lib/drb/drb.rb#646
+ def make_proxy(obj, error = T.unsafe(nil)); end
+end
+
+# source://drb//lib/drb/eq.rb#3
+class DRb::DRbObject
+ # Create a new remote object stub.
+ #
+ # +obj+ is the (local) object we want to create a stub for. Normally
+ # this is +nil+. +uri+ is the URI of the remote object that this
+ # will be a stub for.
+ #
+ # @return [DRbObject] a new instance of DRbObject
+ #
+ # source://drb//lib/drb/drb.rb#1089
+ def initialize(obj, uri = T.unsafe(nil)); end
+
+ # source://drb//lib/drb/eq.rb#4
+ def ==(other); end
+
+ # Get the reference of the object, if local.
+ #
+ # source://drb//lib/drb/drb.rb#1115
+ def __drbref; end
+
+ # Get the URI of the remote object.
+ #
+ # source://drb//lib/drb/drb.rb#1110
+ def __drburi; end
+
+ # Marshall this object.
+ #
+ # The URI and ref of the object are marshalled.
+ #
+ # source://drb//lib/drb/drb.rb#1080
+ def _dump(lv); end
+
+ # source://drb//lib/drb/eq.rb#4
+ def eql?(other); end
+
+ # source://drb//lib/drb/eq.rb#9
+ def hash; end
+
+ # source://drb//lib/drb/drb.rb#1135
+ def method_missing(msg_id, *a, **_arg2, &b); end
+
+ # source://drb//lib/drb/drb.rb#1187
+ def pretty_print(q); end
+
+ # source://drb//lib/drb/drb.rb#1191
+ def pretty_print_cycle(q); end
+
+ # Routes respond_to? to the referenced remote object.
+ #
+ # @return [Boolean]
+ #
+ # source://drb//lib/drb/drb.rb#1123
+ def respond_to?(msg_id, priv = T.unsafe(nil)); end
+
+ class << self
+ # Unmarshall a marshalled DRbObject.
+ #
+ # If the referenced object is located within the local server, then
+ # the object itself is returned. Otherwise, a new DRbObject is
+ # created to act as a stub for the remote referenced object.
+ #
+ # source://drb//lib/drb/drb.rb#1051
+ def _load(s); end
+
+ # Creates a DRb::DRbObject given the reference information to the remote
+ # host +uri+ and object +ref+.
+ #
+ # source://drb//lib/drb/drb.rb#1065
+ def new_with(uri, ref); end
+
+ # Create a new DRbObject from a URI alone.
+ #
+ # source://drb//lib/drb/drb.rb#1073
+ def new_with_uri(uri); end
+
+ # Returns a modified backtrace from +result+ with the +uri+ where each call
+ # in the backtrace came from.
+ #
+ # source://drb//lib/drb/drb.rb#1173
+ def prepare_backtrace(uri, result); end
+
+ # Given the +uri+ of another host executes the block provided.
+ #
+ # source://drb//lib/drb/drb.rb#1160
+ def with_friend(uri); end
+ end
+end
+
+# Module managing the underlying network protocol(s) used by drb.
+#
+# By default, drb uses the DRbTCPSocket protocol. Other protocols
+# can be defined. A protocol must define the following class methods:
+#
+# [open(uri, config)] Open a client connection to the server at +uri+,
+# using configuration +config+. Return a protocol
+# instance for this connection.
+# [open_server(uri, config)] Open a server listening at +uri+,
+# using configuration +config+. Return a
+# protocol instance for this listener.
+# [uri_option(uri, config)] Take a URI, possibly containing an option
+# component (e.g. a trailing '?param=val'),
+# and return a [uri, option] tuple.
+#
+# All of these methods should raise a DRbBadScheme error if the URI
+# does not identify the protocol they support (e.g. "druby:" for
+# the standard Ruby protocol). This is how the DRbProtocol module,
+# given a URI, determines which protocol implementation serves that
+# protocol.
+#
+# The protocol instance returned by #open_server must have the
+# following methods:
+#
+# [accept] Accept a new connection to the server. Returns a protocol
+# instance capable of communicating with the client.
+# [close] Close the server connection.
+# [uri] Get the URI for this server.
+#
+# The protocol instance returned by #open must have the following methods:
+#
+# [send_request (ref, msg_id, arg, b)]
+# Send a request to +ref+ with the given message id and arguments.
+# This is most easily implemented by calling DRbMessage.send_request,
+# providing a stream that sits on top of the current protocol.
+# [recv_reply]
+# Receive a reply from the server and return it as a [success-boolean,
+# reply-value] pair. This is most easily implemented by calling
+# DRb.recv_reply, providing a stream that sits on top of the
+# current protocol.
+# [alive?]
+# Is this connection still alive?
+# [close]
+# Close this connection.
+#
+# The protocol instance returned by #open_server().accept() must have
+# the following methods:
+#
+# [recv_request]
+# Receive a request from the client and return a [object, message,
+# args, block] tuple. This is most easily implemented by calling
+# DRbMessage.recv_request, providing a stream that sits on top of
+# the current protocol.
+# [send_reply(succ, result)]
+# Send a reply to the client. This is most easily implemented
+# by calling DRbMessage.send_reply, providing a stream that sits
+# on top of the current protocol.
+# [close]
+# Close this connection.
+#
+# A new protocol is registered with the DRbProtocol module using
+# the add_protocol method.
+#
+# For examples of other protocols, see DRbUNIXSocket in drb/unix.rb,
+# and HTTP0 in sample/http0.rb and sample/http0serv.rb in the full
+# drb distribution.
+#
+# source://drb//lib/drb/drb.rb#721
+module DRb::DRbProtocol
+ private
+
+ # Add a new protocol to the DRbProtocol module.
+ #
+ # source://drb//lib/drb/drb.rb#724
+ def add_protocol(prot); end
+
+ # source://drb//lib/drb/drb.rb#802
+ def auto_load(uri); end
+
+ # Open a client connection to +uri+ with the configuration +config+.
+ #
+ # The DRbProtocol module asks each registered protocol in turn to
+ # try to open the URI. Each protocol signals that it does not handle that
+ # URI by raising a DRbBadScheme error. If no protocol recognises the
+ # URI, then a DRbBadURI error is raised. If a protocol accepts the
+ # URI, but an error occurs in opening it, a DRbConnError is raised.
+ #
+ # @raise [DRbBadURI]
+ #
+ # source://drb//lib/drb/drb.rb#736
+ def open(uri, config, first = T.unsafe(nil)); end
+
+ # Open a server listening for connections at +uri+ with
+ # configuration +config+.
+ #
+ # The DRbProtocol module asks each registered protocol in turn to
+ # try to open a server at the URI. Each protocol signals that it does
+ # not handle that URI by raising a DRbBadScheme error. If no protocol
+ # recognises the URI, then a DRbBadURI error is raised. If a protocol
+ # accepts the URI, but an error occurs in opening it, the underlying
+ # error is passed on to the caller.
+ #
+ # @raise [DRbBadURI]
+ #
+ # source://drb//lib/drb/drb.rb#764
+ def open_server(uri, config, first = T.unsafe(nil)); end
+
+ # Parse +uri+ into a [uri, option] pair.
+ #
+ # The DRbProtocol module asks each registered protocol in turn to
+ # try to parse the URI. Each protocol signals that it does not handle that
+ # URI by raising a DRbBadScheme error. If no protocol recognises the
+ # URI, then a DRbBadURI error is raised.
+ #
+ # @raise [DRbBadURI]
+ #
+ # source://drb//lib/drb/drb.rb#785
+ def uri_option(uri, config, first = T.unsafe(nil)); end
+
+ class << self
+ # Add a new protocol to the DRbProtocol module.
+ #
+ # source://drb//lib/drb/drb.rb#724
+ def add_protocol(prot); end
+
+ # source://drb//lib/drb/drb.rb#802
+ def auto_load(uri); end
+
+ # Open a client connection to +uri+ with the configuration +config+.
+ #
+ # The DRbProtocol module asks each registered protocol in turn to
+ # try to open the URI. Each protocol signals that it does not handle that
+ # URI by raising a DRbBadScheme error. If no protocol recognises the
+ # URI, then a DRbBadURI error is raised. If a protocol accepts the
+ # URI, but an error occurs in opening it, a DRbConnError is raised.
+ #
+ # @raise [DRbBadURI]
+ #
+ # source://drb//lib/drb/drb.rb#736
+ def open(uri, config, first = T.unsafe(nil)); end
+
+ # Open a server listening for connections at +uri+ with
+ # configuration +config+.
+ #
+ # The DRbProtocol module asks each registered protocol in turn to
+ # try to open a server at the URI. Each protocol signals that it does
+ # not handle that URI by raising a DRbBadScheme error. If no protocol
+ # recognises the URI, then a DRbBadURI error is raised. If a protocol
+ # accepts the URI, but an error occurs in opening it, the underlying
+ # error is passed on to the caller.
+ #
+ # @raise [DRbBadURI]
+ #
+ # source://drb//lib/drb/drb.rb#764
+ def open_server(uri, config, first = T.unsafe(nil)); end
+
+ # Parse +uri+ into a [uri, option] pair.
+ #
+ # The DRbProtocol module asks each registered protocol in turn to
+ # try to parse the URI. Each protocol signals that it does not handle that
+ # URI by raising a DRbBadScheme error. If no protocol recognises the
+ # URI, then a DRbBadURI error is raised.
+ #
+ # @raise [DRbBadURI]
+ #
+ # source://drb//lib/drb/drb.rb#785
+ def uri_option(uri, config, first = T.unsafe(nil)); end
+ end
+end
+
+# An exception wrapping an error object
+#
+# source://drb//lib/drb/drb.rb#431
+class DRb::DRbRemoteError < ::DRb::DRbError
+ # Creates a new remote error that wraps the Exception +error+
+ #
+ # @return [DRbRemoteError] a new instance of DRbRemoteError
+ #
+ # source://drb//lib/drb/drb.rb#434
+ def initialize(error); end
+
+ # the class of the error, as a string.
+ #
+ # source://drb//lib/drb/drb.rb#441
+ def reason; end
+end
+
+# source://drb//lib/drb/drb.rb#1350
+class DRb::DRbServer
+ # Create a new DRbServer instance.
+ #
+ # +uri+ is the URI to bind to. This is normally of the form
+ # 'druby://:' where is a hostname of
+ # the local machine. If nil, then the system's default hostname
+ # will be bound to, on a port selected by the system; these value
+ # can be retrieved from the +uri+ attribute. 'druby:' specifies
+ # the default dRuby transport protocol: another protocol, such
+ # as 'drbunix:', can be specified instead.
+ #
+ # +front+ is the front object for the server, that is, the object
+ # to which remote method calls on the server will be passed. If
+ # nil, then the server will not accept remote method calls.
+ #
+ # If +config_or_acl+ is a hash, it is the configuration to
+ # use for this server. The following options are recognised:
+ #
+ # :idconv :: an id-to-object conversion object. This defaults
+ # to an instance of the class DRb::DRbIdConv.
+ # :verbose :: if true, all unsuccessful remote calls on objects
+ # in the server will be logged to $stdout. false
+ # by default.
+ # :tcp_acl :: the access control list for this server. See
+ # the ACL class from the main dRuby distribution.
+ # :load_limit :: the maximum message size in bytes accepted by
+ # the server. Defaults to 25 MB (26214400).
+ # :argc_limit :: the maximum number of arguments to a remote
+ # method accepted by the server. Defaults to
+ # 256.
+ # The default values of these options can be modified on
+ # a class-wide basis by the class methods #default_argc_limit,
+ # #default_load_limit, #default_acl, #default_id_conv,
+ # and #verbose=
+ #
+ # If +config_or_acl+ is not a hash, but is not nil, it is
+ # assumed to be the access control list for this server.
+ # See the :tcp_acl option for more details.
+ #
+ # If no other server is currently set as the primary server,
+ # this will become the primary server.
+ #
+ # The server will immediately start running in its own thread.
+ #
+ # @return [DRbServer] a new instance of DRbServer
+ #
+ # source://drb//lib/drb/drb.rb#1451
+ def initialize(uri = T.unsafe(nil), front = T.unsafe(nil), config_or_acl = T.unsafe(nil)); end
+
+ # Is this server alive?
+ #
+ # @return [Boolean]
+ #
+ # source://drb//lib/drb/drb.rb#1506
+ def alive?; end
+
+ # Check that a method is callable via dRuby.
+ #
+ # +obj+ is the object we want to invoke the method on. +msg_id+ is the
+ # method name, as a Symbol.
+ #
+ # If the method is an insecure method (see #insecure_method?) a
+ # SecurityError is thrown. If the method is private or undefined,
+ # a NameError is thrown.
+ #
+ # @raise [ArgumentError]
+ #
+ # source://drb//lib/drb/drb.rb#1594
+ def check_insecure_method(obj, msg_id); end
+
+ # The configuration of this DRbServer
+ #
+ # source://drb//lib/drb/drb.rb#1493
+ def config; end
+
+ # The front object of the DRbServer.
+ #
+ # This object receives remote method calls made on the server's
+ # URI alone, with an object id.
+ #
+ # source://drb//lib/drb/drb.rb#1490
+ def front; end
+
+ # Is +uri+ the URI for this server?
+ #
+ # @return [Boolean]
+ #
+ # source://drb//lib/drb/drb.rb#1511
+ def here?(uri); end
+
+ # Stop this server.
+ #
+ # source://drb//lib/drb/drb.rb#1516
+ def stop_service; end
+
+ # The main thread of this DRbServer.
+ #
+ # This is the thread that listens for and accepts connections
+ # from clients, not that handles each client's request-response
+ # session.
+ #
+ # source://drb//lib/drb/drb.rb#1484
+ def thread; end
+
+ # Convert a local object to a dRuby reference.
+ #
+ # source://drb//lib/drb/drb.rb#1533
+ def to_id(obj); end
+
+ # Convert a dRuby reference to the local object it refers to.
+ #
+ # source://drb//lib/drb/drb.rb#1526
+ def to_obj(ref); end
+
+ # The URI of this DRbServer.
+ #
+ # source://drb//lib/drb/drb.rb#1477
+ def uri; end
+
+ # Get whether the server is in verbose mode.
+ #
+ # In verbose mode, failed calls are logged to stdout.
+ #
+ # source://drb//lib/drb/drb.rb#1503
+ def verbose; end
+
+ # Set whether to operate in verbose mode.
+ #
+ # In verbose mode, failed calls are logged to stdout.
+ #
+ # source://drb//lib/drb/drb.rb#1498
+ def verbose=(v); end
+
+ private
+
+ # Coerce an object to a string, providing our own representation if
+ # to_s is not defined for the object.
+ #
+ # source://drb//lib/drb/drb.rb#1580
+ def any_to_s(obj); end
+
+ # source://drb//lib/drb/drb.rb#1696
+ def error_print(exception); end
+
+ # Has a method been included in the list of insecure methods?
+ #
+ # @return [Boolean]
+ #
+ # source://drb//lib/drb/drb.rb#1574
+ def insecure_method?(msg_id); end
+
+ # The main loop performed by a DRbServer's internal thread.
+ #
+ # Accepts a connection from a client, and starts up its own
+ # thread to handle it. This thread loops, receiving requests
+ # from the client, invoking them on a local object, and
+ # returning responses, until the client closes the connection
+ # or a local method call fails.
+ #
+ # source://drb//lib/drb/drb.rb#1714
+ def main_loop; end
+
+ # Starts the DRb main loop in a new thread.
+ #
+ # source://drb//lib/drb/drb.rb#1555
+ def run; end
+
+ # source://drb//lib/drb/drb.rb#1540
+ def shutdown; end
+
+ class << self
+ # Set the default access control list to +acl+. The default ACL is +nil+.
+ #
+ # See also DRb::ACL and #new()
+ #
+ # source://drb//lib/drb/drb.rb#1375
+ def default_acl(acl); end
+
+ # Set the default value for the :argc_limit option.
+ #
+ # See #new(). The initial default value is 256.
+ #
+ # source://drb//lib/drb/drb.rb#1361
+ def default_argc_limit(argc); end
+
+ # Set the default value for the :id_conv option.
+ #
+ # See #new(). The initial default value is a DRbIdConv instance.
+ #
+ # source://drb//lib/drb/drb.rb#1382
+ def default_id_conv(idconv); end
+
+ # Set the default value for the :load_limit option.
+ #
+ # See #new(). The initial default value is 25 MB.
+ #
+ # source://drb//lib/drb/drb.rb#1368
+ def default_load_limit(sz); end
+
+ # source://drb//lib/drb/drb.rb#1398
+ def make_config(hash = T.unsafe(nil)); end
+
+ # Get the default value of the :verbose option.
+ #
+ # source://drb//lib/drb/drb.rb#1394
+ def verbose; end
+
+ # Set the default value of the :verbose option.
+ #
+ # See #new(). The initial default value is false.
+ #
+ # source://drb//lib/drb/drb.rb#1389
+ def verbose=(on); end
+ end
+end
+
+# source://drb//lib/drb/drb.rb#1624
+class DRb::DRbServer::InvokeMethod
+ include ::DRb::DRbServer::InvokeMethod18Mixin
+
+ # @return [InvokeMethod] a new instance of InvokeMethod
+ #
+ # source://drb//lib/drb/drb.rb#1625
+ def initialize(drb_server, client); end
+
+ # source://drb//lib/drb/drb.rb#1630
+ def perform; end
+
+ private
+
+ # source://drb//lib/drb/drb.rb#1667
+ def check_insecure_method; end
+
+ # source://drb//lib/drb/drb.rb#1659
+ def init_with_client; end
+
+ # source://drb//lib/drb/drb.rb#1676
+ def perform_without_block; end
+
+ # source://drb//lib/drb/drb.rb#1671
+ def setup_message; end
+end
+
+# source://drb//lib/drb/invokemethod.rb#6
+module DRb::DRbServer::InvokeMethod18Mixin
+ # source://drb//lib/drb/invokemethod.rb#7
+ def block_yield(x); end
+
+ # source://drb//lib/drb/invokemethod.rb#14
+ def perform_with_block; end
+end
+
+# The default drb protocol which communicates over a TCP socket.
+#
+# The DRb TCP protocol URI looks like:
+# druby://:?. The option is optional.
+#
+# source://drb//lib/drb/drb.rb#815
+class DRb::DRbTCPSocket
+ # Create a new DRbTCPSocket instance.
+ #
+ # +uri+ is the URI we are connected to.
+ # +soc+ is the tcp socket we are bound to. +config+ is our
+ # configuration.
+ #
+ # @return [DRbTCPSocket] a new instance of DRbTCPSocket
+ #
+ # source://drb//lib/drb/drb.rb#903
+ def initialize(uri, soc, config = T.unsafe(nil)); end
+
+ # On the server side, for an instance returned by #open_server,
+ # accept a client connection and return a new instance to handle
+ # the server's side of this client-server session.
+ #
+ # source://drb//lib/drb/drb.rb#971
+ def accept; end
+
+ # Check to see if this connection is alive.
+ #
+ # @return [Boolean]
+ #
+ # source://drb//lib/drb/drb.rb#1001
+ def alive?; end
+
+ # Close the connection.
+ #
+ # If this is an instance returned by #open_server, then this stops
+ # listening for new connections altogether. If this is an instance
+ # returned by #open or by #accept, then it closes this particular
+ # client-server session.
+ #
+ # source://drb//lib/drb/drb.rb#953
+ def close; end
+
+ # Get the address of our TCP peer (the other end of the socket
+ # we are bound to.
+ #
+ # source://drb//lib/drb/drb.rb#918
+ def peeraddr; end
+
+ # On the client side, receive a reply from the server.
+ #
+ # source://drb//lib/drb/drb.rb#941
+ def recv_reply; end
+
+ # On the server side, receive a request from the client.
+ #
+ # source://drb//lib/drb/drb.rb#931
+ def recv_request; end
+
+ # On the server side, send a reply to the client.
+ #
+ # source://drb//lib/drb/drb.rb#936
+ def send_reply(succ, result); end
+
+ # On the client side, send a request to the server.
+ #
+ # source://drb//lib/drb/drb.rb#926
+ def send_request(ref, msg_id, arg, b); end
+
+ # source://drb//lib/drb/drb.rb#1010
+ def set_sockopt(soc); end
+
+ # Graceful shutdown
+ #
+ # source://drb//lib/drb/drb.rb#996
+ def shutdown; end
+
+ # Get the socket.
+ #
+ # source://drb//lib/drb/drb.rb#923
+ def stream; end
+
+ # Get the URI that we are connected to.
+ #
+ # source://drb//lib/drb/drb.rb#914
+ def uri; end
+
+ private
+
+ # source://drb//lib/drb/drb.rb#986
+ def accept_or_shutdown; end
+
+ # source://drb//lib/drb/drb.rb#962
+ def close_shutdown_pipe; end
+
+ class << self
+ # Returns the hostname of this server
+ #
+ # source://drb//lib/drb/drb.rb#845
+ def getservername; end
+
+ # Open a client connection to +uri+ (DRb URI string) using configuration
+ # +config+.
+ #
+ # This can raise DRb::DRbBadScheme or DRb::DRbBadURI if +uri+ is not for a
+ # recognized protocol. See DRb::DRbServer.new for information on built-in
+ # URI protocols.
+ #
+ # source://drb//lib/drb/drb.rb#838
+ def open(uri, config); end
+
+ # Open a server listening for connections at +uri+ using
+ # configuration +config+.
+ #
+ # source://drb//lib/drb/drb.rb#876
+ def open_server(uri, config); end
+
+ # For the families available for +host+, returns a TCPServer on +port+.
+ # If +port+ is 0 the first available port is used. IPv4 servers are
+ # preferred over IPv6 servers.
+ #
+ # source://drb//lib/drb/drb.rb#861
+ def open_server_inaddr_any(host, port); end
+
+ # source://drb//lib/drb/drb.rb#818
+ def parse_uri(uri); end
+
+ # Parse +uri+ into a [uri, option] pair.
+ #
+ # source://drb//lib/drb/drb.rb#893
+ def uri_option(uri, config); end
+ end
+end
+
+# source://drb//lib/drb/drb.rb#1021
+class DRb::DRbURIOption
+ # @return [DRbURIOption] a new instance of DRbURIOption
+ #
+ # source://drb//lib/drb/drb.rb#1022
+ def initialize(option); end
+
+ # source://drb//lib/drb/drb.rb#1028
+ def ==(other); end
+
+ # source://drb//lib/drb/drb.rb#1028
+ def eql?(other); end
+
+ # source://drb//lib/drb/drb.rb#1033
+ def hash; end
+
+ # Returns the value of attribute option.
+ #
+ # source://drb//lib/drb/drb.rb#1025
+ def option; end
+
+ # source://drb//lib/drb/drb.rb#1026
+ def to_s; end
+end
+
+# Mixin module making an object undumpable or unmarshallable.
+#
+# If an object which includes this module is returned by method
+# called over drb, then the object remains in the server space
+# and a reference to the object is returned, rather than the
+# object being marshalled and moved into the client space.
+#
+# source://drb//lib/drb/drb.rb#390
+module DRb::DRbUndumped
+ # @raise [TypeError]
+ #
+ # source://drb//lib/drb/drb.rb#391
+ def _dump(dummy); end
+end
+
+# Class wrapping a marshalled object whose type is unknown locally.
+#
+# If an object is returned by a method invoked over drb, but the
+# class of the object is unknown in the client namespace, or
+# the object is a constant unknown in the client namespace, then
+# the still-marshalled object is returned wrapped in a DRbUnknown instance.
+#
+# If this object is passed as an argument to a method invoked over
+# drb, then the wrapped object is passed instead.
+#
+# The class or constant name of the object can be read from the
+# +name+ attribute. The marshalled object is held in the +buf+
+# attribute.
+#
+# source://drb//lib/drb/drb.rb#457
+class DRb::DRbUnknown
+ # Create a new DRbUnknown object.
+ #
+ # +buf+ is a string containing a marshalled object that could not
+ # be unmarshalled. +err+ is the error message that was raised
+ # when the unmarshalling failed. It is used to determine the
+ # name of the unmarshalled object.
+ #
+ # @return [DRbUnknown] a new instance of DRbUnknown
+ #
+ # source://drb//lib/drb/drb.rb#465
+ def initialize(err, buf); end
+
+ # source://drb//lib/drb/drb.rb#494
+ def _dump(lv); end
+
+ # Buffer contained the marshalled, unknown object.
+ #
+ # source://drb//lib/drb/drb.rb#484
+ def buf; end
+
+ # Create a DRbUnknownError exception containing this object.
+ #
+ # source://drb//lib/drb/drb.rb#508
+ def exception; end
+
+ # The name of the unknown thing.
+ #
+ # Class name for unknown objects; variable name for unknown
+ # constants.
+ #
+ # source://drb//lib/drb/drb.rb#481
+ def name; end
+
+ # Attempt to load the wrapped marshalled object again.
+ #
+ # If the class of the object is now known locally, the object
+ # will be unmarshalled and returned. Otherwise, a new
+ # but identical DRbUnknown object will be returned.
+ #
+ # source://drb//lib/drb/drb.rb#503
+ def reload; end
+
+ class << self
+ # source://drb//lib/drb/drb.rb#486
+ def _load(s); end
+ end
+end
+
+# An exception wrapping a DRb::DRbUnknown object
+#
+# source://drb//lib/drb/drb.rb#410
+class DRb::DRbUnknownError < ::DRb::DRbError
+ # Create a new DRbUnknownError for the DRb::DRbUnknown object +unknown+
+ #
+ # @return [DRbUnknownError] a new instance of DRbUnknownError
+ #
+ # source://drb//lib/drb/drb.rb#413
+ def initialize(unknown); end
+
+ # source://drb//lib/drb/drb.rb#425
+ def _dump(lv); end
+
+ # Get the wrapped DRb::DRbUnknown object.
+ #
+ # source://drb//lib/drb/drb.rb#419
+ def unknown; end
+
+ class << self
+ # source://drb//lib/drb/drb.rb#421
+ def _load(s); end
+ end
+end
+
+# source://drb//lib/drb/drb.rb#1199
+class DRb::ThreadObject
+ include ::MonitorMixin
+
+ # @return [ThreadObject] a new instance of ThreadObject
+ #
+ # source://drb//lib/drb/drb.rb#1202
+ def initialize(&blk); end
+
+ # source://drb//lib/drb/drb.rb#1237
+ def _execute; end
+
+ # @return [Boolean]
+ #
+ # source://drb//lib/drb/drb.rb#1213
+ def alive?; end
+
+ # source://drb//lib/drb/drb.rb#1217
+ def kill; end
+
+ # source://drb//lib/drb/drb.rb#1222
+ def method_missing(msg, *arg, &blk); end
+end
+
+# source://drb//lib/drb/version.rb#2
+DRb::VERSION = T.let(T.unsafe(nil), String)
+
+# source://drb//lib/drb/drb.rb#1943
+DRbIdConv = DRb::DRbIdConv
+
+# :stopdoc:
+#
+# source://drb//lib/drb/drb.rb#1941
+DRbObject = DRb::DRbObject
+
+# source://drb//lib/drb/drb.rb#1942
+DRbUndumped = DRb::DRbUndumped
diff --git a/sorbet/rbi/gems/erubi@1.12.0.rbi b/sorbet/rbi/gems/erubi@1.12.0.rbi
new file mode 100644
index 0000000..d16b610
--- /dev/null
+++ b/sorbet/rbi/gems/erubi@1.12.0.rbi
@@ -0,0 +1,146 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `erubi` gem.
+# Please instead update this file by running `bin/tapioca gem erubi`.
+
+
+# source://erubi//lib/erubi.rb#3
+module Erubi
+ class << self
+ def h(_arg0); end
+ end
+end
+
+# source://erubi//lib/erubi.rb#54
+class Erubi::Engine
+ # Initialize a new Erubi::Engine. Options:
+ # +:bufval+ :: The value to use for the buffer variable, as a string (default '::String.new').
+ # +:bufvar+ :: The variable name to use for the buffer variable, as a string.
+ # +:chain_appends+ :: Whether to chain << calls to the buffer variable. Offers better
+ # performance, but can cause issues when the buffer variable is reassigned during
+ # template rendering (default +false+).
+ # +:ensure+ :: Wrap the template in a begin/ensure block restoring the previous value of bufvar.
+ # +:escapefunc+ :: The function to use for escaping, as a string (default: '::Erubi.h').
+ # +:escape+ :: Whether to make <%= escape by default, and <%== not escape by default.
+ # +:escape_html+ :: Same as +:escape+, with lower priority.
+ # +:filename+ :: The filename for the template.
+ # the resulting source code. Note this may cause problems if you are wrapping the resulting
+ # source code in other code, because the magic comment only has an effect at the beginning of
+ # the file, and having the magic comment later in the file can trigger warnings.
+ # +:freeze_template_literals+ :: Whether to suffix all literal strings for template code with .freeze
+ # (default: +true+ on Ruby 2.1+, +false+ on Ruby 2.0 and older).
+ # Can be set to +false+ on Ruby 2.3+ when frozen string literals are enabled
+ # in order to improve performance.
+ # +:literal_prefix+ :: The prefix to output when using escaped tag delimiters (default '<%').
+ # +:literal_postfix+ :: The postfix to output when using escaped tag delimiters (default '%>').
+ # +:outvar+ :: Same as +:bufvar+, with lower priority.
+ # +:postamble+ :: The postamble for the template, by default returns the resulting source code.
+ # +:preamble+ :: The preamble for the template, by default initializes the buffer variable.
+ # +:regexp+ :: The regexp to use for scanning.
+ # +:src+ :: The initial value to use for the source code, an empty string by default.
+ # +:trim+ :: Whether to trim leading and trailing whitespace, true by default.
+ #
+ # @return [Engine] a new instance of Engine
+ #
+ # source://erubi//lib/erubi.rb#94
+ def initialize(input, properties = T.unsafe(nil)); end
+
+ # The variable name used for the buffer variable.
+ #
+ # source://erubi//lib/erubi.rb#65
+ def bufvar; end
+
+ # The filename of the template, if one was given.
+ #
+ # source://erubi//lib/erubi.rb#62
+ def filename; end
+
+ # The frozen ruby source code generated from the template, which can be evaled.
+ #
+ # source://erubi//lib/erubi.rb#59
+ def src; end
+
+ private
+
+ # Add ruby code to the template
+ #
+ # source://erubi//lib/erubi.rb#226
+ def add_code(code); end
+
+ # Add the given ruby expression result to the template,
+ # escaping it based on the indicator given and escape flag.
+ #
+ # source://erubi//lib/erubi.rb#235
+ def add_expression(indicator, code); end
+
+ # Add the result of Ruby expression to the template
+ #
+ # source://erubi//lib/erubi.rb#244
+ def add_expression_result(code); end
+
+ # Add the escaped result of Ruby expression to the template
+ #
+ # source://erubi//lib/erubi.rb#249
+ def add_expression_result_escaped(code); end
+
+ # Add the given postamble to the src. Can be overridden in subclasses
+ # to make additional changes to src that depend on the current state.
+ #
+ # source://erubi//lib/erubi.rb#255
+ def add_postamble(postamble); end
+
+ # Add raw text to the template. Modifies argument if argument is mutable as a memory optimization.
+ # Must be called with a string, cannot be called with nil (Rails's subclass depends on it).
+ #
+ # source://erubi//lib/erubi.rb#213
+ def add_text(text); end
+
+ # Raise an exception, as the base engine class does not support handling other indicators.
+ #
+ # @raise [ArgumentError]
+ #
+ # source://erubi//lib/erubi.rb#261
+ def handle(indicator, code, tailch, rspace, lspace); end
+
+ # Make sure that any current expression has been terminated.
+ # The default is to terminate all expressions, but when
+ # the chain_appends option is used, expressions may not be
+ # terminated.
+ #
+ # source://erubi//lib/erubi.rb#289
+ def terminate_expression; end
+
+ # Make sure the buffer variable is the target of the next append
+ # before yielding to the block. Mark that the buffer is the target
+ # of the next append after the block executes.
+ #
+ # This method should only be called if the block will result in
+ # code where << will append to the bufvar.
+ #
+ # source://erubi//lib/erubi.rb#271
+ def with_buffer; end
+end
+
+# The default regular expression used for scanning.
+#
+# source://erubi//lib/erubi.rb#56
+Erubi::Engine::DEFAULT_REGEXP = T.let(T.unsafe(nil), Regexp)
+
+# source://erubi//lib/erubi.rb#17
+Erubi::FREEZE_TEMPLATE_LITERALS = T.let(T.unsafe(nil), TrueClass)
+
+# source://erubi//lib/erubi.rb#15
+Erubi::MATCH_METHOD = T.let(T.unsafe(nil), Symbol)
+
+# source://erubi//lib/erubi.rb#8
+Erubi::RANGE_FIRST = T.let(T.unsafe(nil), Integer)
+
+# source://erubi//lib/erubi.rb#9
+Erubi::RANGE_LAST = T.let(T.unsafe(nil), Integer)
+
+# source://erubi//lib/erubi.rb#16
+Erubi::SKIP_DEFINED_FOR_INSTANCE_VARIABLE = T.let(T.unsafe(nil), TrueClass)
+
+# source://erubi//lib/erubi.rb#4
+Erubi::VERSION = T.let(T.unsafe(nil), String)
diff --git a/sorbet/rbi/gems/i18n@1.14.5.rbi b/sorbet/rbi/gems/i18n@1.14.5.rbi
new file mode 100644
index 0000000..fa6c663
--- /dev/null
+++ b/sorbet/rbi/gems/i18n@1.14.5.rbi
@@ -0,0 +1,9 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `i18n` gem.
+# Please instead update this file by running `bin/tapioca gem i18n`.
+
+
+# THIS IS AN EMPTY RBI FILE.
+# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem
diff --git a/sorbet/rbi/gems/logger@1.6.0.rbi b/sorbet/rbi/gems/logger@1.6.0.rbi
new file mode 100644
index 0000000..5b699ff
--- /dev/null
+++ b/sorbet/rbi/gems/logger@1.6.0.rbi
@@ -0,0 +1,903 @@
+# typed: false
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `logger` gem.
+# Please instead update this file by running `bin/tapioca gem logger`.
+
+
+# \Class \Logger provides a simple but sophisticated logging utility that
+# you can use to create one or more
+# {event logs}[https://en.wikipedia.org/wiki/Logging_(software)#Event_logs]
+# for your program.
+# Each such log contains a chronological sequence of entries
+# that provides a record of the program's activities.
+#
+# == About the Examples
+#
+# All examples on this page assume that \Logger has been required:
+#
+# require 'logger'
+#
+# == Synopsis
+#
+# Create a log with Logger.new:
+#
+# # Single log file.
+# logger = Logger.new('t.log')
+# # Size-based rotated logging: 3 10-megabyte files.
+# logger = Logger.new('t.log', 3, 10485760)
+# # Period-based rotated logging: daily (also allowed: 'weekly', 'monthly').
+# logger = Logger.new('t.log', 'daily')
+# # Log to an IO stream.
+# logger = Logger.new($stdout)
+#
+# Add entries (level, message) with Logger#add:
+#
+# logger.add(Logger::DEBUG, 'Maximal debugging info')
+# logger.add(Logger::INFO, 'Non-error information')
+# logger.add(Logger::WARN, 'Non-error warning')
+# logger.add(Logger::ERROR, 'Non-fatal error')
+# logger.add(Logger::FATAL, 'Fatal error')
+# logger.add(Logger::UNKNOWN, 'Most severe')
+#
+# Close the log with Logger#close:
+#
+# logger.close
+#
+# == Entries
+#
+# You can add entries with method Logger#add:
+#
+# logger.add(Logger::DEBUG, 'Maximal debugging info')
+# logger.add(Logger::INFO, 'Non-error information')
+# logger.add(Logger::WARN, 'Non-error warning')
+# logger.add(Logger::ERROR, 'Non-fatal error')
+# logger.add(Logger::FATAL, 'Fatal error')
+# logger.add(Logger::UNKNOWN, 'Most severe')
+#
+# These shorthand methods also add entries:
+#
+# logger.debug('Maximal debugging info')
+# logger.info('Non-error information')
+# logger.warn('Non-error warning')
+# logger.error('Non-fatal error')
+# logger.fatal('Fatal error')
+# logger.unknown('Most severe')
+#
+# When you call any of these methods,
+# the entry may or may not be written to the log,
+# depending on the entry's severity and on the log level;
+# see {Log Level}[rdoc-ref:Logger@Log+Level]
+#
+# An entry always has:
+#
+# - A severity (the required argument to #add).
+# - An automatically created timestamp.
+#
+# And may also have:
+#
+# - A message.
+# - A program name.
+#
+# Example:
+#
+# logger = Logger.new($stdout)
+# logger.add(Logger::INFO, 'My message.', 'mung')
+# # => I, [2022-05-07T17:21:46.536234 #20536] INFO -- mung: My message.
+#
+# The default format for an entry is:
+#
+# "%s, [%s #%d] %5s -- %s: %s\n"
+#
+# where the values to be formatted are:
+#
+# - \Severity (one letter).
+# - Timestamp.
+# - Process id.
+# - \Severity (word).
+# - Program name.
+# - Message.
+#
+# You can use a different entry format by:
+#
+# - Setting a custom format proc (affects following entries);
+# see {formatter=}[Logger.html#attribute-i-formatter].
+# - Calling any of the methods above with a block
+# (affects only the one entry).
+# Doing so can have two benefits:
+#
+# - Context: the block can evaluate the entire program context
+# and create a context-dependent message.
+# - Performance: the block is not evaluated unless the log level
+# permits the entry actually to be written:
+#
+# logger.error { my_slow_message_generator }
+#
+# Contrast this with the string form, where the string is
+# always evaluated, regardless of the log level:
+#
+# logger.error("#{my_slow_message_generator}")
+#
+# === \Severity
+#
+# The severity of a log entry has two effects:
+#
+# - Determines whether the entry is selected for inclusion in the log;
+# see {Log Level}[rdoc-ref:Logger@Log+Level].
+# - Indicates to any log reader (whether a person or a program)
+# the relative importance of the entry.
+#
+# === Timestamp
+#
+# The timestamp for a log entry is generated automatically
+# when the entry is created.
+#
+# The logged timestamp is formatted by method
+# {Time#strftime}[rdoc-ref:Time#strftime]
+# using this format string:
+#
+# '%Y-%m-%dT%H:%M:%S.%6N'
+#
+# Example:
+#
+# logger = Logger.new($stdout)
+# logger.add(Logger::INFO)
+# # => I, [2022-05-07T17:04:32.318331 #20536] INFO -- : nil
+#
+# You can set a different format using method #datetime_format=.
+#
+# === Message
+#
+# The message is an optional argument to an entry method:
+#
+# logger = Logger.new($stdout)
+# logger.add(Logger::INFO, 'My message')
+# # => I, [2022-05-07T18:15:37.647581 #20536] INFO -- : My message
+#
+# For the default entry formatter, Logger::Formatter,
+# the message object may be:
+#
+# - A string: used as-is.
+# - An Exception: message.message is used.
+# - Anything else: message.inspect is used.
+#
+# *Note*: Logger::Formatter does not escape or sanitize
+# the message passed to it.
+# Developers should be aware that malicious data (user input)
+# may be in the message, and should explicitly escape untrusted data.
+#
+# You can use a custom formatter to escape message data;
+# see the example at {formatter=}[Logger.html#attribute-i-formatter].
+#
+# === Program Name
+#
+# The program name is an optional argument to an entry method:
+#
+# logger = Logger.new($stdout)
+# logger.add(Logger::INFO, 'My message', 'mung')
+# # => I, [2022-05-07T18:17:38.084716 #20536] INFO -- mung: My message
+#
+# The default program name for a new logger may be set in the call to
+# Logger.new via optional keyword argument +progname+:
+#
+# logger = Logger.new('t.log', progname: 'mung')
+#
+# The default program name for an existing logger may be set
+# by a call to method #progname=:
+#
+# logger.progname = 'mung'
+#
+# The current program name may be retrieved with method
+# {progname}[Logger.html#attribute-i-progname]:
+#
+# logger.progname # => "mung"
+#
+# == Log Level
+#
+# The log level setting determines whether an entry is actually
+# written to the log, based on the entry's severity.
+#
+# These are the defined severities (least severe to most severe):
+#
+# logger = Logger.new($stdout)
+# logger.add(Logger::DEBUG, 'Maximal debugging info')
+# # => D, [2022-05-07T17:57:41.776220 #20536] DEBUG -- : Maximal debugging info
+# logger.add(Logger::INFO, 'Non-error information')
+# # => I, [2022-05-07T17:59:14.349167 #20536] INFO -- : Non-error information
+# logger.add(Logger::WARN, 'Non-error warning')
+# # => W, [2022-05-07T18:00:45.337538 #20536] WARN -- : Non-error warning
+# logger.add(Logger::ERROR, 'Non-fatal error')
+# # => E, [2022-05-07T18:02:41.592912 #20536] ERROR -- : Non-fatal error
+# logger.add(Logger::FATAL, 'Fatal error')
+# # => F, [2022-05-07T18:05:24.703931 #20536] FATAL -- : Fatal error
+# logger.add(Logger::UNKNOWN, 'Most severe')
+# # => A, [2022-05-07T18:07:54.657491 #20536] ANY -- : Most severe
+#
+# The default initial level setting is Logger::DEBUG, the lowest level,
+# which means that all entries are to be written, regardless of severity:
+#
+# logger = Logger.new($stdout)
+# logger.level # => 0
+# logger.add(0, "My message")
+# # => D, [2022-05-11T15:10:59.773668 #20536] DEBUG -- : My message
+#
+# You can specify a different setting in a new logger
+# using keyword argument +level+ with an appropriate value:
+#
+# logger = Logger.new($stdout, level: Logger::ERROR)
+# logger = Logger.new($stdout, level: 'error')
+# logger = Logger.new($stdout, level: :error)
+# logger.level # => 3
+#
+# With this level, entries with severity Logger::ERROR and higher
+# are written, while those with lower severities are not written:
+#
+# logger = Logger.new($stdout, level: Logger::ERROR)
+# logger.add(3)
+# # => E, [2022-05-11T15:17:20.933362 #20536] ERROR -- : nil
+# logger.add(2) # Silent.
+#
+# You can set the log level for an existing logger
+# with method #level=:
+#
+# logger.level = Logger::ERROR
+#
+# These shorthand methods also set the level:
+#
+# logger.debug! # => 0
+# logger.info! # => 1
+# logger.warn! # => 2
+# logger.error! # => 3
+# logger.fatal! # => 4
+#
+# You can retrieve the log level with method #level.
+#
+# logger.level = Logger::ERROR
+# logger.level # => 3
+#
+# These methods return whether a given
+# level is to be written:
+#
+# logger.level = Logger::ERROR
+# logger.debug? # => false
+# logger.info? # => false
+# logger.warn? # => false
+# logger.error? # => true
+# logger.fatal? # => true
+#
+# == Log File Rotation
+#
+# By default, a log file is a single file that grows indefinitely
+# (until explicitly closed); there is no file rotation.
+#
+# To keep log files to a manageable size,
+# you can use _log_ _file_ _rotation_, which uses multiple log files:
+#
+# - Each log file has entries for a non-overlapping
+# time interval.
+# - Only the most recent log file is open and active;
+# the others are closed and inactive.
+#
+# === Size-Based Rotation
+#
+# For size-based log file rotation, call Logger.new with:
+#
+# - Argument +logdev+ as a file path.
+# - Argument +shift_age+ with a positive integer:
+# the number of log files to be in the rotation.
+# - Argument +shift_size+ as a positive integer:
+# the maximum size (in bytes) of each log file;
+# defaults to 1048576 (1 megabyte).
+#
+# Examples:
+#
+# logger = Logger.new('t.log', 3) # Three 1-megabyte files.
+# logger = Logger.new('t.log', 5, 10485760) # Five 10-megabyte files.
+#
+# For these examples, suppose:
+#
+# logger = Logger.new('t.log', 3)
+#
+# Logging begins in the new log file, +t.log+;
+# the log file is "full" and ready for rotation
+# when a new entry would cause its size to exceed +shift_size+.
+#
+# The first time +t.log+ is full:
+#
+# - +t.log+ is closed and renamed to +t.log.0+.
+# - A new file +t.log+ is opened.
+#
+# The second time +t.log+ is full:
+#
+# - +t.log.0 is renamed as +t.log.1+.
+# - +t.log+ is closed and renamed to +t.log.0+.
+# - A new file +t.log+ is opened.
+#
+# Each subsequent time that +t.log+ is full,
+# the log files are rotated:
+#
+# - +t.log.1+ is removed.
+# - +t.log.0 is renamed as +t.log.1+.
+# - +t.log+ is closed and renamed to +t.log.0+.
+# - A new file +t.log+ is opened.
+#
+# === Periodic Rotation
+#
+# For periodic rotation, call Logger.new with:
+#
+# - Argument +logdev+ as a file path.
+# - Argument +shift_age+ as a string period indicator.
+#
+# Examples:
+#
+# logger = Logger.new('t.log', 'daily') # Rotate log files daily.
+# logger = Logger.new('t.log', 'weekly') # Rotate log files weekly.
+# logger = Logger.new('t.log', 'monthly') # Rotate log files monthly.
+#
+# Example:
+#
+# logger = Logger.new('t.log', 'daily')
+#
+# When the given period expires:
+#
+# - The base log file, +t.log+ is closed and renamed
+# with a date-based suffix such as +t.log.20220509+.
+# - A new log file +t.log+ is opened.
+# - Nothing is removed.
+#
+# The default format for the suffix is '%Y%m%d',
+# which produces a suffix similar to the one above.
+# You can set a different format using create-time option
+# +shift_period_suffix+;
+# see details and suggestions at
+# {Time#strftime}[rdoc-ref:Time#strftime].
+class Logger
+ include ::Logger::Severity
+
+ # :call-seq:
+ # Logger.new(logdev, shift_age = 0, shift_size = 1048576, **options)
+ #
+ # With the single argument +logdev+,
+ # returns a new logger with all default options:
+ #
+ # Logger.new('t.log') # => #
+ #
+ # Argument +logdev+ must be one of:
+ #
+ # - A string filepath: entries are to be written
+ # to the file at that path; if the file at that path exists,
+ # new entries are appended.
+ # - An IO stream (typically +$stdout+, +$stderr+. or an open file):
+ # entries are to be written to the given stream.
+ # - +nil+ or +File::NULL+: no entries are to be written.
+ #
+ # Examples:
+ #
+ # Logger.new('t.log')
+ # Logger.new($stdout)
+ #
+ # The keyword options are:
+ #
+ # - +level+: sets the log level; default value is Logger::DEBUG.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level]:
+ #
+ # Logger.new('t.log', level: Logger::ERROR)
+ #
+ # - +progname+: sets the default program name; default is +nil+.
+ # See {Program Name}[rdoc-ref:Logger@Program+Name]:
+ #
+ # Logger.new('t.log', progname: 'mung')
+ #
+ # - +formatter+: sets the entry formatter; default is +nil+.
+ # See {formatter=}[Logger.html#attribute-i-formatter].
+ # - +datetime_format+: sets the format for entry timestamp;
+ # default is +nil+.
+ # See #datetime_format=.
+ # - +binmode+: sets whether the logger writes in binary mode;
+ # default is +false+.
+ # - +shift_period_suffix+: sets the format for the filename suffix
+ # for periodic log file rotation; default is '%Y%m%d'.
+ # See {Periodic Rotation}[rdoc-ref:Logger@Periodic+Rotation].
+ #
+ # @return [Logger] a new instance of Logger
+ #
+ # source://logger//logger.rb#578
+ def initialize(logdev, shift_age = T.unsafe(nil), shift_size = T.unsafe(nil), level: T.unsafe(nil), progname: T.unsafe(nil), formatter: T.unsafe(nil), datetime_format: T.unsafe(nil), binmode: T.unsafe(nil), shift_period_suffix: T.unsafe(nil)); end
+
+ # Writes the given +msg+ to the log with no formatting;
+ # returns the number of characters written,
+ # or +nil+ if no log device exists:
+ #
+ # logger = Logger.new($stdout)
+ # logger << 'My message.' # => 10
+ #
+ # Output:
+ #
+ # My message.
+ #
+ # source://logger//logger.rb#684
+ def <<(msg); end
+
+ # Creates a log entry, which may or may not be written to the log,
+ # depending on the entry's severity and on the log level.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level]
+ # and {Entries}[rdoc-ref:Logger@Entries] for details.
+ #
+ # Examples:
+ #
+ # logger = Logger.new($stdout, progname: 'mung')
+ # logger.add(Logger::INFO)
+ # logger.add(Logger::ERROR, 'No good')
+ # logger.add(Logger::ERROR, 'No good', 'gnum')
+ #
+ # Output:
+ #
+ # I, [2022-05-12T16:25:31.469726 #36328] INFO -- mung: mung
+ # E, [2022-05-12T16:25:55.349414 #36328] ERROR -- mung: No good
+ # E, [2022-05-12T16:26:35.841134 #36328] ERROR -- gnum: No good
+ #
+ # These convenience methods have implicit severity:
+ #
+ # - #debug.
+ # - #info.
+ # - #warn.
+ # - #error.
+ # - #fatal.
+ # - #unknown.
+ #
+ # source://logger//logger.rb#651
+ def add(severity, message = T.unsafe(nil), progname = T.unsafe(nil)); end
+
+ # Closes the logger; returns +nil+:
+ #
+ # logger = Logger.new('t.log')
+ # logger.close # => nil
+ # logger.info('foo') # Prints "log writing failed. closed stream"
+ #
+ # Related: Logger#reopen.
+ #
+ # source://logger//logger.rb#731
+ def close; end
+
+ # Returns the date-time format; see #datetime_format=.
+ #
+ # source://logger//logger.rb#438
+ def datetime_format; end
+
+ # Sets the date-time format.
+ #
+ # Argument +datetime_format+ should be either of these:
+ #
+ # - A string suitable for use as a format for method
+ # {Time#strftime}[rdoc-ref:Time#strftime].
+ # - +nil+: the logger uses '%Y-%m-%dT%H:%M:%S.%6N'.
+ #
+ # source://logger//logger.rb#432
+ def datetime_format=(datetime_format); end
+
+ # Equivalent to calling #add with severity Logger::DEBUG.
+ #
+ # source://logger//logger.rb#690
+ def debug(progname = T.unsafe(nil), &block); end
+
+ # Sets the log level to Logger::DEBUG.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # source://logger//logger.rb#487
+ def debug!; end
+
+ # Returns +true+ if the log level allows entries with severity
+ # Logger::DEBUG to be written, +false+ otherwise.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # @return [Boolean]
+ #
+ # source://logger//logger.rb#482
+ def debug?; end
+
+ # Equivalent to calling #add with severity Logger::ERROR.
+ #
+ # source://logger//logger.rb#708
+ def error(progname = T.unsafe(nil), &block); end
+
+ # Sets the log level to Logger::ERROR.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # source://logger//logger.rb#520
+ def error!; end
+
+ # Returns +true+ if the log level allows entries with severity
+ # Logger::ERROR to be written, +false+ otherwise.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # @return [Boolean]
+ #
+ # source://logger//logger.rb#515
+ def error?; end
+
+ # Equivalent to calling #add with severity Logger::FATAL.
+ #
+ # source://logger//logger.rb#714
+ def fatal(progname = T.unsafe(nil), &block); end
+
+ # Sets the log level to Logger::FATAL.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # source://logger//logger.rb#531
+ def fatal!; end
+
+ # Returns +true+ if the log level allows entries with severity
+ # Logger::FATAL to be written, +false+ otherwise.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # @return [Boolean]
+ #
+ # source://logger//logger.rb#526
+ def fatal?; end
+
+ # Sets or retrieves the logger entry formatter proc.
+ #
+ # When +formatter+ is +nil+, the logger uses Logger::Formatter.
+ #
+ # When +formatter+ is a proc, a new entry is formatted by the proc,
+ # which is called with four arguments:
+ #
+ # - +severity+: The severity of the entry.
+ # - +time+: A Time object representing the entry's timestamp.
+ # - +progname+: The program name for the entry.
+ # - +msg+: The message for the entry (string or string-convertible object).
+ #
+ # The proc should return a string containing the formatted entry.
+ #
+ # This custom formatter uses
+ # {String#dump}[rdoc-ref:String#dump]
+ # to escape the message string:
+ #
+ # logger = Logger.new($stdout, progname: 'mung')
+ # original_formatter = logger.formatter || Logger::Formatter.new
+ # logger.formatter = proc { |severity, time, progname, msg|
+ # original_formatter.call(severity, time, progname, msg.dump)
+ # }
+ # logger.add(Logger::INFO, "hello \n ''")
+ # logger.add(Logger::INFO, "\f\x00\xff\\\"")
+ #
+ # Output:
+ #
+ # I, [2022-05-13T13:16:29.637488 #8492] INFO -- mung: "hello \n ''"
+ # I, [2022-05-13T13:16:29.637610 #8492] INFO -- mung: "\f\x00\xFF\\\""
+ #
+ # source://logger//logger.rb#473
+ def formatter; end
+
+ # Sets or retrieves the logger entry formatter proc.
+ #
+ # When +formatter+ is +nil+, the logger uses Logger::Formatter.
+ #
+ # When +formatter+ is a proc, a new entry is formatted by the proc,
+ # which is called with four arguments:
+ #
+ # - +severity+: The severity of the entry.
+ # - +time+: A Time object representing the entry's timestamp.
+ # - +progname+: The program name for the entry.
+ # - +msg+: The message for the entry (string or string-convertible object).
+ #
+ # The proc should return a string containing the formatted entry.
+ #
+ # This custom formatter uses
+ # {String#dump}[rdoc-ref:String#dump]
+ # to escape the message string:
+ #
+ # logger = Logger.new($stdout, progname: 'mung')
+ # original_formatter = logger.formatter || Logger::Formatter.new
+ # logger.formatter = proc { |severity, time, progname, msg|
+ # original_formatter.call(severity, time, progname, msg.dump)
+ # }
+ # logger.add(Logger::INFO, "hello \n ''")
+ # logger.add(Logger::INFO, "\f\x00\xff\\\"")
+ #
+ # Output:
+ #
+ # I, [2022-05-13T13:16:29.637488 #8492] INFO -- mung: "hello \n ''"
+ # I, [2022-05-13T13:16:29.637610 #8492] INFO -- mung: "\f\x00\xFF\\\""
+ #
+ # source://logger//logger.rb#473
+ def formatter=(_arg0); end
+
+ # Equivalent to calling #add with severity Logger::INFO.
+ #
+ # source://logger//logger.rb#696
+ def info(progname = T.unsafe(nil), &block); end
+
+ # Sets the log level to Logger::INFO.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # source://logger//logger.rb#498
+ def info!; end
+
+ # Returns +true+ if the log level allows entries with severity
+ # Logger::INFO to be written, +false+ otherwise.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # @return [Boolean]
+ #
+ # source://logger//logger.rb#493
+ def info?; end
+
+ # Logging severity threshold (e.g. Logger::INFO).
+ #
+ # source://logger//logger.rb#383
+ def level; end
+
+ # Sets the log level; returns +severity+.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # Argument +severity+ may be an integer, a string, or a symbol:
+ #
+ # logger.level = Logger::ERROR # => 3
+ # logger.level = 3 # => 3
+ # logger.level = 'error' # => "error"
+ # logger.level = :error # => :error
+ #
+ # Logger#sev_threshold= is an alias for Logger#level=.
+ #
+ # source://logger//logger.rb#399
+ def level=(severity); end
+
+ # Creates a log entry, which may or may not be written to the log,
+ # depending on the entry's severity and on the log level.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level]
+ # and {Entries}[rdoc-ref:Logger@Entries] for details.
+ #
+ # Examples:
+ #
+ # logger = Logger.new($stdout, progname: 'mung')
+ # logger.add(Logger::INFO)
+ # logger.add(Logger::ERROR, 'No good')
+ # logger.add(Logger::ERROR, 'No good', 'gnum')
+ #
+ # Output:
+ #
+ # I, [2022-05-12T16:25:31.469726 #36328] INFO -- mung: mung
+ # E, [2022-05-12T16:25:55.349414 #36328] ERROR -- mung: No good
+ # E, [2022-05-12T16:26:35.841134 #36328] ERROR -- gnum: No good
+ #
+ # These convenience methods have implicit severity:
+ #
+ # - #debug.
+ # - #info.
+ # - #warn.
+ # - #error.
+ # - #fatal.
+ # - #unknown.
+ #
+ # source://logger//logger.rb#651
+ def log(severity, message = T.unsafe(nil), progname = T.unsafe(nil)); end
+
+ # Program name to include in log messages.
+ #
+ # source://logger//logger.rb#422
+ def progname; end
+
+ # Program name to include in log messages.
+ #
+ # source://logger//logger.rb#422
+ def progname=(_arg0); end
+
+ # Sets the logger's output stream:
+ #
+ # - If +logdev+ is +nil+, reopens the current output stream.
+ # - If +logdev+ is a filepath, opens the indicated file for append.
+ # - If +logdev+ is an IO stream
+ # (usually $stdout, $stderr, or an open File object),
+ # opens the stream for append.
+ #
+ # Example:
+ #
+ # logger = Logger.new('t.log')
+ # logger.add(Logger::ERROR, 'one')
+ # logger.close
+ # logger.add(Logger::ERROR, 'two') # Prints 'log writing failed. closed stream'
+ # logger.reopen
+ # logger.add(Logger::ERROR, 'three')
+ # logger.close
+ # File.readlines('t.log')
+ # # =>
+ # # ["# Logfile created on 2022-05-12 14:21:19 -0500 by logger.rb/v1.5.0\n",
+ # # "E, [2022-05-12T14:21:27.596726 #22428] ERROR -- : one\n",
+ # # "E, [2022-05-12T14:23:05.847241 #22428] ERROR -- : three\n"]
+ #
+ # source://logger//logger.rb#619
+ def reopen(logdev = T.unsafe(nil)); end
+
+ # Logging severity threshold (e.g. Logger::INFO).
+ #
+ # source://logger//logger.rb#383
+ def sev_threshold; end
+
+ # Sets the log level; returns +severity+.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # Argument +severity+ may be an integer, a string, or a symbol:
+ #
+ # logger.level = Logger::ERROR # => 3
+ # logger.level = 3 # => 3
+ # logger.level = 'error' # => "error"
+ # logger.level = :error # => :error
+ #
+ # Logger#sev_threshold= is an alias for Logger#level=.
+ #
+ # source://logger//logger.rb#399
+ def sev_threshold=(severity); end
+
+ # Equivalent to calling #add with severity Logger::UNKNOWN.
+ #
+ # source://logger//logger.rb#720
+ def unknown(progname = T.unsafe(nil), &block); end
+
+ # Equivalent to calling #add with severity Logger::WARN.
+ #
+ # source://logger//logger.rb#702
+ def warn(progname = T.unsafe(nil), &block); end
+
+ # Sets the log level to Logger::WARN.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # source://logger//logger.rb#509
+ def warn!; end
+
+ # Returns +true+ if the log level allows entries with severity
+ # Logger::WARN to be written, +false+ otherwise.
+ # See {Log Level}[rdoc-ref:Logger@Log+Level].
+ #
+ # @return [Boolean]
+ #
+ # source://logger//logger.rb#504
+ def warn?; end
+
+ # Adjust the log level during the block execution for the current Fiber only
+ #
+ # logger.with_level(:debug) do
+ # logger.debug { "Hello" }
+ # end
+ #
+ # source://logger//logger.rb#408
+ def with_level(severity); end
+
+ private
+
+ # source://logger//logger.rb#744
+ def format_message(severity, datetime, progname, msg); end
+
+ # source://logger//logger.rb#740
+ def format_severity(severity); end
+end
+
+# Default formatter for log messages.
+class Logger::Formatter
+ # @return [Formatter] a new instance of Formatter
+ #
+ # source://logger//logger/formatter.rb#11
+ def initialize; end
+
+ # source://logger//logger/formatter.rb#15
+ def call(severity, time, progname, msg); end
+
+ # Returns the value of attribute datetime_format.
+ #
+ # source://logger//logger/formatter.rb#9
+ def datetime_format; end
+
+ # Sets the attribute datetime_format
+ #
+ # @param value the value to set the attribute datetime_format to.
+ #
+ # source://logger//logger/formatter.rb#9
+ def datetime_format=(_arg0); end
+
+ private
+
+ # source://logger//logger/formatter.rb#21
+ def format_datetime(time); end
+
+ # source://logger//logger/formatter.rb#25
+ def msg2str(msg); end
+end
+
+# source://logger//logger/formatter.rb#7
+Logger::Formatter::DatetimeFormat = T.let(T.unsafe(nil), String)
+
+# source://logger//logger/formatter.rb#6
+Logger::Formatter::Format = T.let(T.unsafe(nil), String)
+
+# Device used for logging messages.
+class Logger::LogDevice
+ include ::Logger::Period
+ include ::MonitorMixin
+
+ # @return [LogDevice] a new instance of LogDevice
+ #
+ # source://logger//logger/log_device.rb#14
+ def initialize(log = T.unsafe(nil), shift_age: T.unsafe(nil), shift_size: T.unsafe(nil), shift_period_suffix: T.unsafe(nil), binmode: T.unsafe(nil)); end
+
+ # source://logger//logger/log_device.rb#52
+ def close; end
+
+ # Returns the value of attribute dev.
+ #
+ # source://logger//logger/log_device.rb#10
+ def dev; end
+
+ # Returns the value of attribute filename.
+ #
+ # source://logger//logger/log_device.rb#11
+ def filename; end
+
+ # source://logger//logger/log_device.rb#62
+ def reopen(log = T.unsafe(nil)); end
+
+ # source://logger//logger/log_device.rb#31
+ def write(message); end
+
+ private
+
+ # source://logger//logger/log_device.rb#119
+ def add_log_header(file); end
+
+ # source://logger//logger/log_device.rb#125
+ def check_shift_log; end
+
+ # source://logger//logger/log_device.rb#103
+ def create_logfile(filename); end
+
+ # source://logger//logger/log_device.rb#145
+ def lock_shift_log; end
+
+ # source://logger//logger/log_device.rb#95
+ def open_logfile(filename); end
+
+ # source://logger//logger/log_device.rb#79
+ def set_dev(log); end
+
+ # source://logger//logger/log_device.rb#176
+ def shift_log_age; end
+
+ # source://logger//logger/log_device.rb#188
+ def shift_log_period(period_end); end
+end
+
+module Logger::Period
+ private
+
+ # source://logger//logger/period.rb#9
+ def next_rotate_time(now, shift_age); end
+
+ # source://logger//logger/period.rb#31
+ def previous_period_end(now, shift_age); end
+
+ class << self
+ # source://logger//logger/period.rb#9
+ def next_rotate_time(now, shift_age); end
+
+ # source://logger//logger/period.rb#31
+ def previous_period_end(now, shift_age); end
+ end
+end
+
+# source://logger//logger/period.rb#7
+Logger::Period::SiD = T.let(T.unsafe(nil), Integer)
+
+# \Severity label for logging (max 5 chars).
+#
+# source://logger//logger.rb#738
+Logger::SEV_LABEL = T.let(T.unsafe(nil), Array)
+
+# Logging severity.
+module Logger::Severity
+ class << self
+ # source://logger//logger/severity.rb#29
+ def coerce(severity); end
+ end
+end
+
+# source://logger//logger/severity.rb#19
+Logger::Severity::LEVELS = T.let(T.unsafe(nil), Hash)
diff --git a/sorbet/rbi/gems/minitest@5.25.1.rbi b/sorbet/rbi/gems/minitest@5.25.1.rbi
new file mode 100644
index 0000000..2536e9b
--- /dev/null
+++ b/sorbet/rbi/gems/minitest@5.25.1.rbi
@@ -0,0 +1,9 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `minitest` gem.
+# Please instead update this file by running `bin/tapioca gem minitest`.
+
+
+# THIS IS AN EMPTY RBI FILE.
+# see https://github.com/Shopify/tapioca#manually-requiring-parts-of-a-gem
diff --git a/sorbet/rbi/gems/netrc@0.11.0.rbi b/sorbet/rbi/gems/netrc@0.11.0.rbi
new file mode 100644
index 0000000..4ae989b
--- /dev/null
+++ b/sorbet/rbi/gems/netrc@0.11.0.rbi
@@ -0,0 +1,159 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `netrc` gem.
+# Please instead update this file by running `bin/tapioca gem netrc`.
+
+
+# source://netrc//lib/netrc.rb#3
+class Netrc
+ # @return [Netrc] a new instance of Netrc
+ #
+ # source://netrc//lib/netrc.rb#166
+ def initialize(path, data); end
+
+ # source://netrc//lib/netrc.rb#180
+ def [](k); end
+
+ # source://netrc//lib/netrc.rb#188
+ def []=(k, info); end
+
+ # source://netrc//lib/netrc.rb#200
+ def delete(key); end
+
+ # source://netrc//lib/netrc.rb#211
+ def each(&block); end
+
+ # source://netrc//lib/netrc.rb#196
+ def length; end
+
+ # source://netrc//lib/netrc.rb#215
+ def new_item(m, l, p); end
+
+ # Returns the value of attribute new_item_prefix.
+ #
+ # source://netrc//lib/netrc.rb#178
+ def new_item_prefix; end
+
+ # Sets the attribute new_item_prefix
+ #
+ # @param value the value to set the attribute new_item_prefix to.
+ #
+ # source://netrc//lib/netrc.rb#178
+ def new_item_prefix=(_arg0); end
+
+ # source://netrc//lib/netrc.rb#219
+ def save; end
+
+ # source://netrc//lib/netrc.rb#233
+ def unparse; end
+
+ class << self
+ # source://netrc//lib/netrc.rb#42
+ def check_permissions(path); end
+
+ # source://netrc//lib/netrc.rb#33
+ def config; end
+
+ # @yield [self.config]
+ #
+ # source://netrc//lib/netrc.rb#37
+ def configure; end
+
+ # source://netrc//lib/netrc.rb#10
+ def default_path; end
+
+ # source://netrc//lib/netrc.rb#14
+ def home_path; end
+
+ # source://netrc//lib/netrc.rb#85
+ def lex(lines); end
+
+ # source://netrc//lib/netrc.rb#29
+ def netrc_filename; end
+
+ # Returns two values, a header and a list of items.
+ # Each item is a tuple, containing some or all of:
+ # - machine keyword (including trailing whitespace+comments)
+ # - machine name
+ # - login keyword (including surrounding whitespace+comments)
+ # - login
+ # - password keyword (including surrounding whitespace+comments)
+ # - password
+ # - trailing chars
+ # This lets us change individual fields, then write out the file
+ # with all its original formatting.
+ #
+ # source://netrc//lib/netrc.rb#129
+ def parse(ts); end
+
+ # Reads path and parses it as a .netrc file. If path doesn't
+ # exist, returns an empty object. Decrypt paths ending in .gpg.
+ #
+ # source://netrc//lib/netrc.rb#51
+ def read(path = T.unsafe(nil)); end
+
+ # @return [Boolean]
+ #
+ # source://netrc//lib/netrc.rb#112
+ def skip?(s); end
+ end
+end
+
+# source://netrc//lib/netrc.rb#8
+Netrc::CYGWIN = T.let(T.unsafe(nil), T.untyped)
+
+# source://netrc//lib/netrc.rb#244
+class Netrc::Entry < ::Struct
+ # Returns the value of attribute login
+ #
+ # @return [Object] the current value of login
+ def login; end
+
+ # Sets the attribute login
+ #
+ # @param value [Object] the value to set the attribute login to.
+ # @return [Object] the newly set value
+ def login=(_); end
+
+ # Returns the value of attribute password
+ #
+ # @return [Object] the current value of password
+ def password; end
+
+ # Sets the attribute password
+ #
+ # @param value [Object] the value to set the attribute password to.
+ # @return [Object] the newly set value
+ def password=(_); end
+
+ def to_ary; end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# source://netrc//lib/netrc.rb#250
+class Netrc::Error < ::StandardError; end
+
+# source://netrc//lib/netrc.rb#68
+class Netrc::TokenArray < ::Array
+ # source://netrc//lib/netrc.rb#76
+ def readto; end
+
+ # source://netrc//lib/netrc.rb#69
+ def take; end
+end
+
+# source://netrc//lib/netrc.rb#4
+Netrc::VERSION = T.let(T.unsafe(nil), String)
+
+# see http://stackoverflow.com/questions/4871309/what-is-the-correct-way-to-detect-if-ruby-is-running-on-windows
+#
+# source://netrc//lib/netrc.rb#7
+Netrc::WINDOWS = T.let(T.unsafe(nil), T.untyped)
diff --git a/sorbet/rbi/gems/parallel@1.23.0.rbi b/sorbet/rbi/gems/parallel@1.23.0.rbi
new file mode 100644
index 0000000..84e20d4
--- /dev/null
+++ b/sorbet/rbi/gems/parallel@1.23.0.rbi
@@ -0,0 +1,274 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `parallel` gem.
+# Please instead update this file by running `bin/tapioca gem parallel`.
+
+
+# source://parallel//lib/parallel/version.rb#2
+module Parallel
+ class << self
+ # @return [Boolean]
+ #
+ # source://parallel//lib/parallel.rb#243
+ def all?(*args, &block); end
+
+ # @return [Boolean]
+ #
+ # source://parallel//lib/parallel.rb#238
+ def any?(*args, &block); end
+
+ # source://parallel//lib/parallel.rb#234
+ def each(array, options = T.unsafe(nil), &block); end
+
+ # source://parallel//lib/parallel.rb#248
+ def each_with_index(array, options = T.unsafe(nil), &block); end
+
+ # source://parallel//lib/parallel.rb#307
+ def filter_map(*args, &block); end
+
+ # source://parallel//lib/parallel.rb#303
+ def flat_map(*args, &block); end
+
+ # source://parallel//lib/parallel.rb#228
+ def in_processes(options = T.unsafe(nil), &block); end
+
+ # source://parallel//lib/parallel.rb#212
+ def in_threads(options = T.unsafe(nil)); end
+
+ # source://parallel//lib/parallel.rb#252
+ def map(source, options = T.unsafe(nil), &block); end
+
+ # source://parallel//lib/parallel.rb#299
+ def map_with_index(array, options = T.unsafe(nil), &block); end
+
+ # Number of physical processor cores on the current system.
+ #
+ # source://parallel//lib/parallel.rb#312
+ def physical_processor_count; end
+
+ # Number of processors seen by the OS, used for process scheduling
+ #
+ # source://parallel//lib/parallel.rb#345
+ def processor_count; end
+
+ # source://parallel//lib/parallel.rb#350
+ def worker_number; end
+
+ # TODO: this does not work when doing threads in forks, so should remove and yield the number instead if needed
+ #
+ # source://parallel//lib/parallel.rb#355
+ def worker_number=(worker_num); end
+
+ private
+
+ # source://parallel//lib/parallel.rb#361
+ def add_progress_bar!(job_factory, options); end
+
+ # source://parallel//lib/parallel.rb#624
+ def call_with_index(item, index, options, &block); end
+
+ # source://parallel//lib/parallel.rb#556
+ def create_workers(job_factory, options, &block); end
+
+ # options is either a Integer or a Hash with :count
+ #
+ # source://parallel//lib/parallel.rb#614
+ def extract_count_from_options(options); end
+
+ # source://parallel//lib/parallel.rb#642
+ def instrument_finish(item, index, result, options); end
+
+ # source://parallel//lib/parallel.rb#647
+ def instrument_start(item, index, options); end
+
+ # source://parallel//lib/parallel.rb#590
+ def process_incoming_jobs(read, write, job_factory, options, &block); end
+
+ # source://parallel//lib/parallel.rb#544
+ def replace_worker(job_factory, workers, index, options, blk); end
+
+ # source://parallel//lib/parallel.rb#635
+ def with_instrumentation(item, index, options); end
+
+ # source://parallel//lib/parallel.rb#386
+ def work_direct(job_factory, options, &block); end
+
+ # source://parallel//lib/parallel.rb#496
+ def work_in_processes(job_factory, options, &blk); end
+
+ # source://parallel//lib/parallel.rb#430
+ def work_in_ractors(job_factory, options); end
+
+ # source://parallel//lib/parallel.rb#405
+ def work_in_threads(job_factory, options, &block); end
+
+ # source://parallel//lib/parallel.rb#564
+ def worker(job_factory, options, &block); end
+ end
+end
+
+# source://parallel//lib/parallel.rb#11
+class Parallel::Break < ::StandardError
+ # @return [Break] a new instance of Break
+ #
+ # source://parallel//lib/parallel.rb#14
+ def initialize(value = T.unsafe(nil)); end
+
+ # Returns the value of attribute value.
+ #
+ # source://parallel//lib/parallel.rb#12
+ def value; end
+end
+
+# source://parallel//lib/parallel.rb#8
+class Parallel::DeadWorker < ::StandardError; end
+
+# source://parallel//lib/parallel.rb#32
+class Parallel::ExceptionWrapper
+ # @return [ExceptionWrapper] a new instance of ExceptionWrapper
+ #
+ # source://parallel//lib/parallel.rb#35
+ def initialize(exception); end
+
+ # Returns the value of attribute exception.
+ #
+ # source://parallel//lib/parallel.rb#33
+ def exception; end
+end
+
+# source://parallel//lib/parallel.rb#98
+class Parallel::JobFactory
+ # @return [JobFactory] a new instance of JobFactory
+ #
+ # source://parallel//lib/parallel.rb#99
+ def initialize(source, mutex); end
+
+ # source://parallel//lib/parallel.rb#107
+ def next; end
+
+ # generate item that is sent to workers
+ # just index is faster + less likely to blow up with unserializable errors
+ #
+ # source://parallel//lib/parallel.rb#136
+ def pack(item, index); end
+
+ # source://parallel//lib/parallel.rb#126
+ def size; end
+
+ # unpack item that is sent to workers
+ #
+ # source://parallel//lib/parallel.rb#141
+ def unpack(data); end
+
+ private
+
+ # @return [Boolean]
+ #
+ # source://parallel//lib/parallel.rb#147
+ def producer?; end
+
+ # source://parallel//lib/parallel.rb#151
+ def queue_wrapper(array); end
+end
+
+# source://parallel//lib/parallel.rb#20
+class Parallel::Kill < ::Parallel::Break; end
+
+# source://parallel//lib/parallel.rb#6
+Parallel::Stop = T.let(T.unsafe(nil), Object)
+
+# source://parallel//lib/parallel.rb#23
+class Parallel::UndumpableException < ::StandardError
+ # @return [UndumpableException] a new instance of UndumpableException
+ #
+ # source://parallel//lib/parallel.rb#26
+ def initialize(original); end
+
+ # Returns the value of attribute backtrace.
+ #
+ # source://parallel//lib/parallel.rb#24
+ def backtrace; end
+end
+
+# source://parallel//lib/parallel.rb#156
+class Parallel::UserInterruptHandler
+ class << self
+ # source://parallel//lib/parallel.rb#181
+ def kill(thing); end
+
+ # kill all these pids or threads if user presses Ctrl+c
+ #
+ # source://parallel//lib/parallel.rb#161
+ def kill_on_ctrl_c(pids, options); end
+
+ private
+
+ # source://parallel//lib/parallel.rb#205
+ def restore_interrupt(old, signal); end
+
+ # source://parallel//lib/parallel.rb#190
+ def trap_interrupt(signal); end
+ end
+end
+
+# source://parallel//lib/parallel.rb#157
+Parallel::UserInterruptHandler::INTERRUPT_SIGNAL = T.let(T.unsafe(nil), Symbol)
+
+# source://parallel//lib/parallel/version.rb#3
+Parallel::VERSION = T.let(T.unsafe(nil), String)
+
+# source://parallel//lib/parallel/version.rb#3
+Parallel::Version = T.let(T.unsafe(nil), String)
+
+# source://parallel//lib/parallel.rb#51
+class Parallel::Worker
+ # @return [Worker] a new instance of Worker
+ #
+ # source://parallel//lib/parallel.rb#55
+ def initialize(read, write, pid); end
+
+ # might be passed to started_processes and simultaneously closed by another thread
+ # when running in isolation mode, so we have to check if it is closed before closing
+ #
+ # source://parallel//lib/parallel.rb#68
+ def close_pipes; end
+
+ # Returns the value of attribute pid.
+ #
+ # source://parallel//lib/parallel.rb#52
+ def pid; end
+
+ # Returns the value of attribute read.
+ #
+ # source://parallel//lib/parallel.rb#52
+ def read; end
+
+ # source://parallel//lib/parallel.rb#61
+ def stop; end
+
+ # Returns the value of attribute thread.
+ #
+ # source://parallel//lib/parallel.rb#53
+ def thread; end
+
+ # Sets the attribute thread
+ #
+ # @param value the value to set the attribute thread to.
+ #
+ # source://parallel//lib/parallel.rb#53
+ def thread=(_arg0); end
+
+ # source://parallel//lib/parallel.rb#73
+ def work(data); end
+
+ # Returns the value of attribute write.
+ #
+ # source://parallel//lib/parallel.rb#52
+ def write; end
+
+ private
+
+ # source://parallel//lib/parallel.rb#91
+ def wait; end
+end
diff --git a/sorbet/rbi/gems/polyfill@1.9.0.rbi b/sorbet/rbi/gems/polyfill@1.9.0.rbi
new file mode 100644
index 0000000..84b9fdd
--- /dev/null
+++ b/sorbet/rbi/gems/polyfill@1.9.0.rbi
@@ -0,0 +1,820 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `polyfill` gem.
+# Please instead update this file by running `bin/tapioca gem polyfill`.
+
+
+class Object < ::BasicObject
+ include ::Kernel
+ include ::PP::ObjectMixin
+
+ private
+
+ # source://polyfill//lib/polyfill.rb#66
+ def Polyfill(options = T.unsafe(nil)); end
+end
+
+# source://polyfill//lib/polyfill/version.rb#1
+module Polyfill
+ private
+
+ # source://polyfill//lib/polyfill.rb#7
+ def get(module_name, methods, options = T.unsafe(nil)); end
+
+ class << self
+ # source://polyfill//lib/polyfill.rb#7
+ def get(module_name, methods, options = T.unsafe(nil)); end
+ end
+end
+
+# source://polyfill//lib/polyfill/internal_utils.rb#2
+module Polyfill::InternalUtils
+ private
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#86
+ def create_module(*args); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#12
+ def current_ruby_version; end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#17
+ def ignore_warnings; end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#41
+ def keep_only_these_methods!(mod, whitelist); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#74
+ def methods_to_keep(modules, methods, lead_symbol, module_name); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#48
+ def modules_to_use(module_name, versions); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#99
+ def namify_arguments(*args); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#27
+ def polyfill_versions_to_use(desired_version = T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#136
+ def to_f(obj); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#149
+ def to_hash(obj); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#123
+ def to_int(obj); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#110
+ def to_str(obj); end
+
+ class << self
+ # source://polyfill//lib/polyfill/internal_utils.rb#86
+ def create_module(*args); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#12
+ def current_ruby_version; end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#17
+ def ignore_warnings; end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#41
+ def keep_only_these_methods!(mod, whitelist); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#74
+ def methods_to_keep(modules, methods, lead_symbol, module_name); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#48
+ def modules_to_use(module_name, versions); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#99
+ def namify_arguments(*args); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#27
+ def polyfill_versions_to_use(desired_version = T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#136
+ def to_f(obj); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#149
+ def to_hash(obj); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#123
+ def to_int(obj); end
+
+ # source://polyfill//lib/polyfill/internal_utils.rb#110
+ def to_str(obj); end
+ end
+end
+
+# source://polyfill//lib/polyfill/internal_utils.rb#3
+Polyfill::InternalUtils::VERSIONS = T.let(T.unsafe(nil), Hash)
+
+# source://polyfill//lib/polyfill.rb#5
+module Polyfill::Module; end
+
+# source://polyfill//lib/polyfill/v2_4/enumerator/lazy.rb#0
+module Polyfill::Module::MezpFbnVtZXJhYmxlPT5bIiNjaHVua193aGlsZSJdLCA6dmVyc2lvbj0_1IjIuNCJ9; end
+
+# source://polyfill//lib/polyfill/v2_5/integer.rb#0
+module Polyfill::Module::MezpJbnRlZ2VyPT5bIiNjZWlsIiwgIiNmbG9vciIsICIjcm91bmQiLCAiI3RydW5jYXRlIl0sIDp2ZXJzaW9uPT4iMi40In0_; end
+
+# source://polyfill//lib/polyfill/v2_6/kernel.rb#0
+module Polyfill::Module::MezpLZXJuZWw9PlsiI3lpZWxkX3NlbGYiXSwgOnZlcnNpb249PiIyLjUifQ__; end
+
+# source://polyfill//lib/polyfill/v2_4/enumerable.rb#0
+module Polyfill::Module::MezpOdW1lcmljPT5bIiNkdXAiXSwgOnZlcnNpb249PiIyLjQifQ__; end
+
+# source://polyfill//lib/polyfill/v2_2/enumerable.rb#2
+module Polyfill::V2_2; end
+
+# source://polyfill//lib/polyfill/v2_2/enumerable.rb#3
+module Polyfill::V2_2::Enumerable
+ # @raise [ArgumentError]
+ #
+ # source://polyfill//lib/polyfill/v2_2/enumerable.rb#4
+ def max(n = T.unsafe(nil)); end
+
+ # @raise [ArgumentError]
+ #
+ # source://polyfill//lib/polyfill/v2_2/enumerable.rb#12
+ def max_by(n = T.unsafe(nil)); end
+
+ # @raise [ArgumentError]
+ #
+ # source://polyfill//lib/polyfill/v2_2/enumerable.rb#22
+ def min(n = T.unsafe(nil)); end
+
+ # @raise [ArgumentError]
+ #
+ # source://polyfill//lib/polyfill/v2_2/enumerable.rb#30
+ def min_by(n = T.unsafe(nil)); end
+
+ # @raise [ArgumentError]
+ #
+ # source://polyfill//lib/polyfill/v2_2/enumerable.rb#40
+ def slice_after(pattern = T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_2/enumerable.rb#61
+ def slice_when; end
+end
+
+# source://polyfill//lib/polyfill/v2_2/kernel.rb#3
+module Polyfill::V2_2::Kernel
+ # source://polyfill//lib/polyfill/v2_2/kernel.rb#4
+ def itself; end
+end
+
+# source://polyfill//lib/polyfill/v2_2/math.rb#3
+module Polyfill::V2_2::Math; end
+
+# source://polyfill//lib/polyfill/v2_2/math.rb#4
+module Polyfill::V2_2::Math::ClassMethods
+ # source://polyfill//lib/polyfill/v2_2/math.rb#5
+ def log(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_2/prime.rb#3
+module Polyfill::V2_2::Prime; end
+
+# source://polyfill//lib/polyfill/v2_2/prime.rb#4
+module Polyfill::V2_2::Prime::ClassMethods
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_2/prime.rb#5
+ def prime?(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_2/vector.rb#3
+module Polyfill::V2_2::Vector
+ # source://polyfill//lib/polyfill/v2_2/vector.rb#4
+ def +@; end
+end
+
+# source://polyfill//lib/polyfill/v2_3/array.rb#2
+module Polyfill::V2_3; end
+
+# source://polyfill//lib/polyfill/v2_3/array.rb#3
+module Polyfill::V2_3::Array
+ # source://polyfill//lib/polyfill/v2_3/array.rb#4
+ def bsearch_index; end
+
+ # source://polyfill//lib/polyfill/v2_3/array.rb#14
+ def dig(head, *rest); end
+end
+
+# source://polyfill//lib/polyfill/v2_3/enumerable.rb#3
+module Polyfill::V2_3::Enumerable
+ # source://polyfill//lib/polyfill/v2_3/enumerable.rb#4
+ def chunk_while; end
+
+ # source://polyfill//lib/polyfill/v2_3/enumerable.rb#23
+ def grep_v(pattern); end
+
+ # source://polyfill//lib/polyfill/v2_3/enumerable.rb#29
+ def slice_before(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_3/enumerator/lazy.rb#3
+module Polyfill::V2_3::Enumerator; end
+
+# source://polyfill//lib/polyfill/v2_3/enumerator/lazy.rb#4
+module Polyfill::V2_3::Enumerator::Lazy
+ # source://polyfill//lib/polyfill/v2_3/enumerator/lazy.rb#5
+ def grep_v(pattern); end
+end
+
+# source://polyfill//lib/polyfill/v2_3/hash.rb#3
+module Polyfill::V2_3::Hash
+ # source://polyfill//lib/polyfill/v2_3/hash.rb#4
+ def <(other); end
+
+ # source://polyfill//lib/polyfill/v2_3/hash.rb#12
+ def <=(other); end
+
+ # source://polyfill//lib/polyfill/v2_3/hash.rb#18
+ def >(other); end
+
+ # source://polyfill//lib/polyfill/v2_3/hash.rb#26
+ def >=(other); end
+
+ # source://polyfill//lib/polyfill/v2_3/hash.rb#32
+ def dig(head, *rest); end
+
+ # source://polyfill//lib/polyfill/v2_3/hash.rb#55
+ def fetch_values(*keys); end
+
+ # source://polyfill//lib/polyfill/v2_3/hash.rb#69
+ def to_proc; end
+end
+
+# source://polyfill//lib/polyfill/v2_3/kernel.rb#3
+module Polyfill::V2_3::Kernel
+ # source://polyfill//lib/polyfill/v2_3/kernel.rb#4
+ def loop; end
+end
+
+# source://polyfill//lib/polyfill/v2_3/numeric.rb#3
+module Polyfill::V2_3::Numeric
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_3/numeric.rb#4
+ def negative?; end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_3/numeric.rb#8
+ def positive?; end
+end
+
+# source://polyfill//lib/polyfill/v2_3/prime.rb#3
+module Polyfill::V2_3::Prime; end
+
+# source://polyfill//lib/polyfill/v2_3/prime.rb#4
+module Polyfill::V2_3::Prime::ClassMethods
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_3/prime.rb#5
+ def prime?(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_3/string.rb#3
+module Polyfill::V2_3::String
+ # source://polyfill//lib/polyfill/v2_3/string.rb#20
+ def +@; end
+
+ # source://polyfill//lib/polyfill/v2_3/string.rb#24
+ def -@; end
+end
+
+# source://polyfill//lib/polyfill/v2_3/string.rb#4
+module Polyfill::V2_3::String::ClassMethods
+ # source://polyfill//lib/polyfill/v2_3/string.rb#5
+ def new(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_3/struct.rb#3
+module Polyfill::V2_3::Struct
+ # source://polyfill//lib/polyfill/v2_3/struct.rb#4
+ def dig(head, *rest); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/numeric.rb#2
+module Polyfill::V2_4; end
+
+# source://polyfill//lib/polyfill/v2_4/array.rb#5
+module Polyfill::V2_4::Array
+ # source://polyfill//lib/polyfill/v2_4/array.rb#8
+ def concat(*others); end
+
+ # source://polyfill//lib/polyfill/v2_4/array.rb#19
+ def sum(init = T.unsafe(nil)); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/comparable.rb#3
+module Polyfill::V2_4::Comparable
+ # source://polyfill//lib/polyfill/v2_4/comparable.rb#4
+ def clamp(min, max); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/dir.rb#3
+module Polyfill::V2_4::Dir; end
+
+# source://polyfill//lib/polyfill/v2_4/dir.rb#4
+module Polyfill::V2_4::Dir::ClassMethods
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_4/dir.rb#5
+ def empty?(path_name); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/enumerable.rb#5
+module Polyfill::V2_4::Enumerable
+ # source://polyfill//lib/polyfill/v2_4/enumerable.rb#8
+ def chunk(*_arg0); end
+
+ # source://polyfill//lib/polyfill/v2_4/enumerable.rb#14
+ def sum(init = T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_4/enumerable.rb#24
+ def uniq; end
+end
+
+# source://polyfill//lib/polyfill/v2_4/enumerator/lazy.rb#3
+module Polyfill::V2_4::Enumerator; end
+
+# source://polyfill//lib/polyfill/v2_4/enumerator/lazy.rb#4
+module Polyfill::V2_4::Enumerator::Lazy
+ # source://polyfill//lib/polyfill/v2_4/enumerator/lazy.rb#7
+ def chunk_while; end
+
+ # source://polyfill//lib/polyfill/v2_4/enumerator/lazy.rb#11
+ def uniq; end
+end
+
+# source://polyfill//lib/polyfill/v2_4/file.rb#3
+module Polyfill::V2_4::File; end
+
+# source://polyfill//lib/polyfill/v2_4/file.rb#4
+module Polyfill::V2_4::File::ClassMethods
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_4/file.rb#5
+ def empty?(file_name); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/float.rb#3
+module Polyfill::V2_4::Float
+ # source://polyfill//lib/polyfill/v2_4/float.rb#4
+ def ceil(ndigits = T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_4/float.rb#17
+ def floor(ndigits = T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_4/float.rb#30
+ def truncate(ndigits = T.unsafe(nil)); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/hash.rb#3
+module Polyfill::V2_4::Hash
+ # source://polyfill//lib/polyfill/v2_4/hash.rb#4
+ def compact; end
+
+ # source://polyfill//lib/polyfill/v2_4/hash.rb#8
+ def compact!; end
+
+ # source://polyfill//lib/polyfill/v2_4/hash.rb#12
+ def transform_values; end
+
+ # source://polyfill//lib/polyfill/v2_4/hash.rb#26
+ def transform_values!; end
+end
+
+# source://polyfill//lib/polyfill/v2_4/io.rb#5
+module Polyfill::V2_4::IO
+ # source://polyfill//lib/polyfill/v2_4/io.rb#58
+ def each_line(*args); end
+
+ # source://polyfill//lib/polyfill/v2_4/io.rb#91
+ def gets(*args); end
+
+ # source://polyfill//lib/polyfill/v2_4/io.rb#107
+ def lines(*args); end
+
+ # source://polyfill//lib/polyfill/v2_4/io.rb#140
+ def readline(*args); end
+
+ # source://polyfill//lib/polyfill/v2_4/io.rb#156
+ def readlines(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/io.rb#6
+module Polyfill::V2_4::IO::ClassMethods
+ # source://polyfill//lib/polyfill/v2_4/io.rb#7
+ def foreach(name, *args); end
+
+ # source://polyfill//lib/polyfill/v2_4/io.rb#41
+ def readlines(file_name, *args); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/i_p_addr.rb#3
+module Polyfill::V2_4::IPAddr
+ # source://polyfill//lib/polyfill/v2_4/i_p_addr.rb#10
+ def <=>(*_arg0); end
+
+ # source://polyfill//lib/polyfill/v2_4/i_p_addr.rb#4
+ def ==(*_arg0); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/integer.rb#3
+module Polyfill::V2_4::Integer
+ # source://polyfill//lib/polyfill/v2_4/integer.rb#4
+ def ceil(ndigits = T.unsafe(nil)); end
+
+ # @raise [Math::DomainError]
+ #
+ # source://polyfill//lib/polyfill/v2_4/integer.rb#13
+ def digits(base = T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_4/integer.rb#28
+ def floor(ndigits = T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_4/integer.rb#37
+ def round(ndigits = T.unsafe(nil), half: T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_4/integer.rb#49
+ def truncate(ndigits = T.unsafe(nil)); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/match_data.rb#3
+module Polyfill::V2_4::MatchData
+ # source://polyfill//lib/polyfill/v2_4/match_data.rb#4
+ def named_captures; end
+
+ # source://polyfill//lib/polyfill/v2_4/match_data.rb#10
+ def values_at(*indexes); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/numeric.rb#3
+module Polyfill::V2_4::Numeric
+ # source://polyfill//lib/polyfill/v2_4/numeric.rb#4
+ def clone(freeze: T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_4/numeric.rb#8
+ def dup; end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_4/numeric.rb#12
+ def finite?; end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_4/numeric.rb#16
+ def infinite?; end
+end
+
+# source://polyfill//lib/polyfill/v2_4/object.rb#3
+module Polyfill::V2_4::Object
+ # source://polyfill//lib/polyfill/v2_4/object.rb#4
+ def clone(freeze: T.unsafe(nil)); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/pathname.rb#3
+module Polyfill::V2_4::Pathname
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_4/pathname.rb#4
+ def empty?; end
+end
+
+# source://polyfill//lib/polyfill/v2_4/regexp.rb#3
+module Polyfill::V2_4::Regexp
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_4/regexp.rb#4
+ def match?(string, position = T.unsafe(nil)); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/string.rb#5
+module Polyfill::V2_4::String
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_4/string.rb#15
+ def casecmp?(other); end
+
+ # source://polyfill//lib/polyfill/v2_4/string.rb#19
+ def concat(*others); end
+
+ # source://polyfill//lib/polyfill/v2_4/string.rb#30
+ def each_line(*args); end
+
+ # source://polyfill//lib/polyfill/v2_4/string.rb#63
+ def lines(*args); end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_4/string.rb#97
+ def match?(pattern, position = T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_4/string.rb#101
+ def prepend(*others); end
+
+ # source://polyfill//lib/polyfill/v2_4/string.rb#112
+ def unpack1(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/string.rb#6
+module Polyfill::V2_4::String::ClassMethods
+ # source://polyfill//lib/polyfill/v2_4/string.rb#7
+ def new(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/string_io.rb#5
+module Polyfill::V2_4::StringIO
+ # source://polyfill//lib/polyfill/v2_4/string_io.rb#58
+ def each_line(*args); end
+
+ # source://polyfill//lib/polyfill/v2_4/string_io.rb#91
+ def gets(*args); end
+
+ # source://polyfill//lib/polyfill/v2_4/string_io.rb#107
+ def lines(*args); end
+
+ # source://polyfill//lib/polyfill/v2_4/string_io.rb#140
+ def readline(*args); end
+
+ # source://polyfill//lib/polyfill/v2_4/string_io.rb#156
+ def readlines(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/string_io.rb#6
+module Polyfill::V2_4::StringIO::ClassMethods
+ # source://polyfill//lib/polyfill/v2_4/string_io.rb#7
+ def foreach(name, *args); end
+
+ # source://polyfill//lib/polyfill/v2_4/string_io.rb#41
+ def readlines(file_name, *args); end
+end
+
+# source://polyfill//lib/polyfill/v2_4/symbol.rb#3
+module Polyfill::V2_4::Symbol
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_4/symbol.rb#4
+ def casecmp?(other); end
+
+ # source://polyfill//lib/polyfill/v2_4/symbol.rb#10
+ def match(*args); end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_4/symbol.rb#18
+ def match?(pattern, position = T.unsafe(nil)); end
+end
+
+# source://polyfill//lib/polyfill/v2_5/array.rb#2
+module Polyfill::V2_5; end
+
+# source://polyfill//lib/polyfill/v2_5/array.rb#3
+module Polyfill::V2_5::Array
+ # source://polyfill//lib/polyfill/v2_5/array.rb#4
+ def append(*args); end
+
+ # source://polyfill//lib/polyfill/v2_5/array.rb#8
+ def prepend(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_5/big_decimal.rb#3
+module Polyfill::V2_5::BigDecimal
+ # source://polyfill//lib/polyfill/v2_5/big_decimal.rb#4
+ def clone; end
+
+ # source://polyfill//lib/polyfill/v2_5/big_decimal.rb#8
+ def dup; end
+end
+
+# source://polyfill//lib/polyfill/v2_5/dir.rb#3
+module Polyfill::V2_5::Dir; end
+
+# source://polyfill//lib/polyfill/v2_5/dir.rb#4
+module Polyfill::V2_5::Dir::ClassMethods
+ # source://polyfill//lib/polyfill/v2_5/dir.rb#5
+ def children(dirname, encoding: T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_5/dir.rb#9
+ def each_child(dirname, encoding: T.unsafe(nil)); end
+end
+
+# source://polyfill//lib/polyfill/v2_5/enumerable.rb#3
+module Polyfill::V2_5::Enumerable
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_5/enumerable.rb#4
+ def all?(*pattern); end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_5/enumerable.rb#10
+ def any?(*pattern); end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_5/enumerable.rb#16
+ def none?(*pattern); end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_5/enumerable.rb#22
+ def one?(*pattern); end
+end
+
+# source://polyfill//lib/polyfill/v2_5/hash.rb#3
+module Polyfill::V2_5::Hash
+ # source://polyfill//lib/polyfill/v2_5/hash.rb#4
+ def slice(*keys); end
+
+ # source://polyfill//lib/polyfill/v2_5/hash.rb#10
+ def transform_keys; end
+end
+
+# source://polyfill//lib/polyfill/v2_5/integer.rb#5
+module Polyfill::V2_5::Integer
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_5/integer.rb#52
+ def allbits?(mask); end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_5/integer.rb#57
+ def anybits?(mask); end
+
+ # source://polyfill//lib/polyfill/v2_5/integer.rb#36
+ def ceil(*_arg0); end
+
+ # source://polyfill//lib/polyfill/v2_5/integer.rb#40
+ def floor(*_arg0); end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_5/integer.rb#61
+ def nobits?(mask); end
+
+ # source://polyfill//lib/polyfill/v2_5/integer.rb#44
+ def round(*_arg0); end
+
+ # source://polyfill//lib/polyfill/v2_5/integer.rb#48
+ def truncate(*_arg0); end
+end
+
+# source://polyfill//lib/polyfill/v2_5/integer.rb#8
+module Polyfill::V2_5::Integer::ClassMethods
+ # source://polyfill//lib/polyfill/v2_5/integer.rb#9
+ def sqrt(n); end
+end
+
+# source://polyfill//lib/polyfill/v2_5/kernel.rb#3
+module Polyfill::V2_5::Kernel
+ # @yield [_self]
+ # @yieldparam _self [Polyfill::V2_5::Kernel] the object that the method was called on
+ #
+ # source://polyfill//lib/polyfill/v2_5/kernel.rb#4
+ def yield_self; end
+end
+
+# source://polyfill//lib/polyfill/v2_5/set.rb#3
+module Polyfill::V2_5::Set
+ # source://polyfill//lib/polyfill/v2_5/set.rb#4
+ def ===(other); end
+
+ # source://polyfill//lib/polyfill/v2_5/set.rb#8
+ def to_s; end
+end
+
+# source://polyfill//lib/polyfill/v2_5/string.rb#3
+module Polyfill::V2_5::String
+ # source://polyfill//lib/polyfill/v2_5/string.rb#4
+ def casecmp(other_str); end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_5/string.rb#10
+ def casecmp?(other_str); end
+
+ # source://polyfill//lib/polyfill/v2_5/string.rb#16
+ def delete_prefix(prefix); end
+
+ # source://polyfill//lib/polyfill/v2_5/string.rb#20
+ def delete_prefix!(prefix); end
+
+ # source://polyfill//lib/polyfill/v2_5/string.rb#26
+ def delete_suffix(suffix); end
+
+ # source://polyfill//lib/polyfill/v2_5/string.rb#30
+ def delete_suffix!(suffix); end
+
+ # source://polyfill//lib/polyfill/v2_5/string.rb#48
+ def each_grapheme_cluster; end
+
+ # source://polyfill//lib/polyfill/v2_5/string.rb#42
+ def grapheme_clusters; end
+
+ # @return [Boolean]
+ #
+ # source://polyfill//lib/polyfill/v2_5/string.rb#34
+ def start_with?(*prefixes); end
+end
+
+# source://polyfill//lib/polyfill/v2_5/struct.rb#3
+module Polyfill::V2_5::Struct; end
+
+# source://polyfill//lib/polyfill/v2_5/struct.rb#4
+module Polyfill::V2_5::Struct::ClassMethods
+ # source://polyfill//lib/polyfill/v2_5/struct.rb#5
+ def new(*args, keyword_init: T.unsafe(nil)); end
+end
+
+# source://polyfill//lib/polyfill/v2_5/time.rb#3
+module Polyfill::V2_5::Time; end
+
+# source://polyfill//lib/polyfill/v2_5/time.rb#4
+module Polyfill::V2_5::Time::ClassMethods
+ # source://polyfill//lib/polyfill/v2_5/time.rb#5
+ def at(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_6/array.rb#2
+module Polyfill::V2_6; end
+
+# source://polyfill//lib/polyfill/v2_6/array.rb#3
+module Polyfill::V2_6::Array
+ # source://polyfill//lib/polyfill/v2_6/array.rb#4
+ def difference(*arrays); end
+
+ # source://polyfill//lib/polyfill/v2_6/array.rb#10
+ def to_h; end
+
+ # source://polyfill//lib/polyfill/v2_6/array.rb#34
+ def union(*arrays); end
+end
+
+# source://polyfill//lib/polyfill/v2_6/enumerable.rb#3
+module Polyfill::V2_6::Enumerable
+ # source://polyfill//lib/polyfill/v2_6/enumerable.rb#4
+ def to_h; end
+end
+
+# source://polyfill//lib/polyfill/v2_6/hash.rb#3
+module Polyfill::V2_6::Hash
+ # source://polyfill//lib/polyfill/v2_6/hash.rb#28
+ def merge(*args); end
+
+ # source://polyfill//lib/polyfill/v2_6/hash.rb#40
+ def merge!(*args); end
+
+ # source://polyfill//lib/polyfill/v2_6/hash.rb#4
+ def to_h; end
+
+ # source://polyfill//lib/polyfill/v2_6/hash.rb#52
+ def update(*args); end
+end
+
+# source://polyfill//lib/polyfill/v2_6/kernel.rb#3
+module Polyfill::V2_6::Kernel
+ # source://polyfill//lib/polyfill/v2_6/kernel.rb#6
+ def Complex(*args, exception: T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_6/kernel.rb#21
+ def Float(arg, exception: T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_6/kernel.rb#31
+ def Integer(arg, exception: T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_6/kernel.rb#41
+ def Rational(*args, exception: T.unsafe(nil)); end
+
+ # source://polyfill//lib/polyfill/v2_6/kernel.rb#51
+ def then; end
+end
+
+# source://polyfill//lib/polyfill/v2_6/open_struct.rb#5
+module Polyfill::V2_6::OpenStruct
+ # source://polyfill//lib/polyfill/v2_6/open_struct.rb#6
+ def to_h; end
+end
+
+# source://polyfill//lib/polyfill/v2_6/string.rb#3
+module Polyfill::V2_6::String
+ # source://polyfill//lib/polyfill/v2_6/string.rb#4
+ def split(*_arg0); end
+end
+
+# source://polyfill//lib/polyfill/v2_6/struct.rb#3
+module Polyfill::V2_6::Struct
+ # source://polyfill//lib/polyfill/v2_6/struct.rb#4
+ def to_h; end
+end
+
+# source://polyfill//lib/polyfill/version.rb#2
+Polyfill::VERSION = T.let(T.unsafe(nil), Gem::Version)
diff --git a/sorbet/rbi/gems/prism@0.30.0.rbi b/sorbet/rbi/gems/prism@0.30.0.rbi
new file mode 100644
index 0000000..3d6fe3e
--- /dev/null
+++ b/sorbet/rbi/gems/prism@0.30.0.rbi
@@ -0,0 +1,37863 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `prism` gem.
+# Please instead update this file by running `bin/tapioca gem prism`.
+
+
+# typed: strict
+
+# =begin
+# This file is generated by the templates/template.rb script and should not be
+# modified manually. See templates/rbi/prism/node.rbi.erb
+# if you are looking to modify the template
+# =end
+# =begin
+# This file is generated by the templates/template.rb script and should not be
+# modified manually. See templates/rbi/prism/visitor.rbi.erb
+# if you are looking to modify the template
+# =end
+
+# We keep these shims in here because our client libraries might not have parser
+# in their bundle.
+module Parser; end
+
+class Parser::Base; end
+
+# The Prism Ruby parser.
+#
+# "Parsing Ruby is suddenly manageable!"
+# - You, hopefully
+#
+# source://prism//lib/prism.rb#8
+module Prism
+ class << self
+ # Mirror the Prism.dump API by using the serialization API.
+ def dump(*_arg0); end
+
+ # Mirror the Prism.dump_file API by using the serialization API.
+ def dump_file(*_arg0); end
+
+ # Mirror the Prism.lex API by using the serialization API.
+ def lex(*_arg0); end
+
+ # :call-seq:
+ # Prism::lex_compat(source, **options) -> LexCompat::Result
+ #
+ # Returns a parse result whose value is an array of tokens that closely
+ # resembles the return value of Ripper::lex. The main difference is that the
+ # `:on_sp` token is not emitted.
+ #
+ # For supported options, see Prism::parse.
+ #
+ # source://prism//lib/prism.rb#45
+ sig { params(source: String, options: T::Hash[Symbol, T.untyped]).returns(Prism::LexCompat::Result) }
+ def lex_compat(source, **options); end
+
+ # Mirror the Prism.lex_file API by using the serialization API.
+ def lex_file(*_arg0); end
+
+ # :call-seq:
+ # Prism::lex_ripper(source) -> Array
+ #
+ # This lexes with the Ripper lex. It drops any space events but otherwise
+ # returns the same tokens. Raises SyntaxError if the syntax in source is
+ # invalid.
+ #
+ # source://prism//lib/prism.rb#55
+ sig { params(source: String).returns(T::Array[T.untyped]) }
+ def lex_ripper(source); end
+
+ # :call-seq:
+ # Prism::load(source, serialized) -> ParseResult
+ #
+ # Load the serialized AST using the source as a reference into a tree.
+ #
+ # source://prism//lib/prism.rb#63
+ sig { params(source: String, serialized: String).returns(Prism::ParseResult) }
+ def load(source, serialized); end
+
+ # Mirror the Prism.parse API by using the serialization API.
+ def parse(*_arg0); end
+
+ # Mirror the Prism.parse_comments API by using the serialization API.
+ def parse_comments(*_arg0); end
+
+ # Mirror the Prism.parse_failure? API by using the serialization API.
+ #
+ # @return [Boolean]
+ def parse_failure?(*_arg0); end
+
+ # Mirror the Prism.parse_file API by using the serialization API. This uses
+ # native strings instead of Ruby strings because it allows us to use mmap
+ # when it is available.
+ def parse_file(*_arg0); end
+
+ # Mirror the Prism.parse_file_comments API by using the serialization
+ # API. This uses native strings instead of Ruby strings because it allows us
+ # to use mmap when it is available.
+ def parse_file_comments(*_arg0); end
+
+ # Mirror the Prism.parse_file_failure? API by using the serialization API.
+ #
+ # @return [Boolean]
+ def parse_file_failure?(*_arg0); end
+
+ # Mirror the Prism.parse_file_success? API by using the serialization API.
+ #
+ # @return [Boolean]
+ def parse_file_success?(*_arg0); end
+
+ # Mirror the Prism.parse_lex API by using the serialization API.
+ def parse_lex(*_arg0); end
+
+ # Mirror the Prism.parse_lex_file API by using the serialization API.
+ def parse_lex_file(*_arg0); end
+
+ # Mirror the Prism.parse_stream API by using the serialization API.
+ def parse_stream(*_arg0); end
+
+ # Mirror the Prism.parse_success? API by using the serialization API.
+ #
+ # @return [Boolean]
+ def parse_success?(*_arg0); end
+
+ # Mirror the Prism.profile API by using the serialization API.
+ def profile(*_arg0); end
+
+ # Mirror the Prism.profile_file API by using the serialization API.
+ def profile_file(*_arg0); end
+ end
+end
+
+# Specialized version of Prism::Source for source code that includes ASCII
+# characters only. This class is used to apply performance optimizations that
+# cannot be applied to sources that include multibyte characters. Sources that
+# include multibyte characters are represented by the Prism::Source class.
+#
+# source://prism//lib/prism/parse_result.rb#126
+class Prism::ASCIISource < ::Prism::Source
+ # Return the column number in characters for the given byte offset.
+ #
+ # source://prism//lib/prism/parse_result.rb#133
+ sig { params(byte_offset: Integer).returns(Integer) }
+ def character_column(byte_offset); end
+
+ # Return the character offset for the given byte offset.
+ #
+ # source://prism//lib/prism/parse_result.rb#128
+ sig { params(byte_offset: Integer).returns(Integer) }
+ def character_offset(byte_offset); end
+
+ # Specialized version of `code_units_column` that does not depend on
+ # `code_units_offset`, which is a more expensive operation. This is
+ # essentialy the same as `Prism::Source#column`.
+ #
+ # source://prism//lib/prism/parse_result.rb#150
+ sig { params(byte_offset: Integer, encoding: Encoding).returns(Integer) }
+ def code_units_column(byte_offset, encoding); end
+
+ # Returns the offset from the start of the file for the given byte offset
+ # counting in code units for the given encoding.
+ #
+ # This method is tested with UTF-8, UTF-16, and UTF-32. If there is the
+ # concept of code units that differs from the number of characters in other
+ # encodings, it is not captured here.
+ #
+ # source://prism//lib/prism/parse_result.rb#143
+ sig { params(byte_offset: Integer, encoding: Encoding).returns(Integer) }
+ def code_units_offset(byte_offset, encoding); end
+end
+
+# Represents the use of the `alias` keyword to alias a global variable.
+#
+# alias $foo $bar
+# ^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#176
+class Prism::AliasGlobalVariableNode < ::Prism::Node
+ # def initialize: (Prism::node new_name, Prism::node old_name, Location keyword_loc, Location location) -> void
+ #
+ # @return [AliasGlobalVariableNode] a new instance of AliasGlobalVariableNode
+ #
+ # source://prism//lib/prism/node.rb#178
+ sig do
+ params(
+ source: Prism::Source,
+ new_name: Prism::Node,
+ old_name: Prism::Node,
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, new_name, old_name, keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#281
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#187
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#192
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#202
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#197
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?new_name: Prism::node, ?old_name: Prism::node, ?keyword_loc: Location, ?location: Location) -> AliasGlobalVariableNode
+ #
+ # source://prism//lib/prism/node.rb#207
+ sig do
+ params(
+ new_name: Prism::Node,
+ old_name: Prism::Node,
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::AliasGlobalVariableNode)
+ end
+ def copy(new_name: T.unsafe(nil), old_name: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#192
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { new_name: Prism::node, old_name: Prism::node, keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#215
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#247
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#242
+ sig { returns(String) }
+ def keyword; end
+
+ # The location of the `alias` keyword.
+ #
+ # alias $foo $bar
+ # ^^^^^
+ #
+ # source://prism//lib/prism/node.rb#235
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # Represents the new name of the global variable that can be used after aliasing. This can be either a global variable, a back reference, or a numbered reference.
+ #
+ # alias $foo $bar
+ # ^^^^
+ #
+ # source://prism//lib/prism/node.rb#223
+ sig { returns(Prism::Node) }
+ def new_name; end
+
+ # Represents the old name of the global variable that could be used before aliasing. This can be either a global variable, a back reference, or a numbered reference.
+ #
+ # alias $foo $bar
+ # ^^^^
+ #
+ # source://prism//lib/prism/node.rb#229
+ sig { returns(Prism::Node) }
+ def old_name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#265
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#275
+ def type; end
+ end
+end
+
+# Represents the use of the `alias` keyword to alias a method.
+#
+# alias foo bar
+# ^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#293
+class Prism::AliasMethodNode < ::Prism::Node
+ # def initialize: (Prism::node new_name, Prism::node old_name, Location keyword_loc, Location location) -> void
+ #
+ # @return [AliasMethodNode] a new instance of AliasMethodNode
+ #
+ # source://prism//lib/prism/node.rb#295
+ sig do
+ params(
+ source: Prism::Source,
+ new_name: Prism::Node,
+ old_name: Prism::Node,
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, new_name, old_name, keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#389
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#304
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#309
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#319
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#314
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?new_name: Prism::node, ?old_name: Prism::node, ?keyword_loc: Location, ?location: Location) -> AliasMethodNode
+ #
+ # source://prism//lib/prism/node.rb#324
+ sig do
+ params(
+ new_name: Prism::Node,
+ old_name: Prism::Node,
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::AliasMethodNode)
+ end
+ def copy(new_name: T.unsafe(nil), old_name: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#309
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { new_name: Prism::node, old_name: Prism::node, keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#332
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#355
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#350
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#343
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # attr_reader new_name: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#337
+ sig { returns(Prism::Node) }
+ def new_name; end
+
+ # attr_reader old_name: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#340
+ sig { returns(Prism::Node) }
+ def old_name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#373
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#383
+ def type; end
+ end
+end
+
+# Represents an alternation pattern in pattern matching.
+#
+# foo => bar | baz
+# ^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#401
+class Prism::AlternationPatternNode < ::Prism::Node
+ # def initialize: (Prism::node left, Prism::node right, Location operator_loc, Location location) -> void
+ #
+ # @return [AlternationPatternNode] a new instance of AlternationPatternNode
+ #
+ # source://prism//lib/prism/node.rb#403
+ sig do
+ params(
+ source: Prism::Source,
+ left: Prism::Node,
+ right: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, left, right, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#497
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#412
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#417
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#427
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#422
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?left: Prism::node, ?right: Prism::node, ?operator_loc: Location, ?location: Location) -> AlternationPatternNode
+ #
+ # source://prism//lib/prism/node.rb#432
+ sig do
+ params(
+ left: Prism::Node,
+ right: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::AlternationPatternNode)
+ end
+ def copy(left: T.unsafe(nil), right: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#417
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { left: Prism::node, right: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#440
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#463
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader left: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#445
+ sig { returns(Prism::Node) }
+ def left; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#458
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#451
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader right: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#448
+ sig { returns(Prism::Node) }
+ def right; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#481
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#491
+ def type; end
+ end
+end
+
+# Represents the use of the `&&` operator or the `and` keyword.
+#
+# left and right
+# ^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#509
+class Prism::AndNode < ::Prism::Node
+ # def initialize: (Prism::node left, Prism::node right, Location operator_loc, Location location) -> void
+ #
+ # @return [AndNode] a new instance of AndNode
+ #
+ # source://prism//lib/prism/node.rb#511
+ sig do
+ params(
+ source: Prism::Source,
+ left: Prism::Node,
+ right: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, left, right, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#620
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#520
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#525
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#535
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#530
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?left: Prism::node, ?right: Prism::node, ?operator_loc: Location, ?location: Location) -> AndNode
+ #
+ # source://prism//lib/prism/node.rb#540
+ sig do
+ params(
+ left: Prism::Node,
+ right: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::AndNode)
+ end
+ def copy(left: T.unsafe(nil), right: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#525
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { left: Prism::node, right: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#548
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#586
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Represents the left side of the expression. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # left and right
+ # ^^^^
+ #
+ # 1 && 2
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#559
+ sig { returns(Prism::Node) }
+ def left; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#581
+ sig { returns(String) }
+ def operator; end
+
+ # The location of the `and` keyword or the `&&` operator.
+ #
+ # left and right
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#574
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Represents the right side of the expression. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # left && right
+ # ^^^^^
+ #
+ # 1 and 2
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#568
+ sig { returns(Prism::Node) }
+ def right; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#604
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#614
+ def type; end
+ end
+end
+
+# Represents a set of arguments to a method or a keyword.
+#
+# return foo, bar, baz
+# ^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#632
+class Prism::ArgumentsNode < ::Prism::Node
+ # def initialize: (Integer flags, Array[Prism::node] arguments, Location location) -> void
+ #
+ # @return [ArgumentsNode] a new instance of ArgumentsNode
+ #
+ # source://prism//lib/prism/node.rb#634
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ arguments: T::Array[Prism::Node],
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, arguments, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#726
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#642
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader arguments: Array[Prism::node]
+ #
+ # source://prism//lib/prism/node.rb#679
+ sig { returns(T::Array[Prism::Node]) }
+ def arguments; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#647
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#657
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#652
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def contains_keyword_splat?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#687
+ sig { returns(T::Boolean) }
+ def contains_keyword_splat?; end
+
+ # def contains_keywords?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#682
+ sig { returns(T::Boolean) }
+ def contains_keywords?; end
+
+ # def copy: (?flags: Integer, ?arguments: Array[Prism::node], ?location: Location) -> ArgumentsNode
+ #
+ # source://prism//lib/prism/node.rb#662
+ sig do
+ params(
+ flags: Integer,
+ arguments: T::Array[Prism::Node],
+ location: Prism::Location
+ ).returns(Prism::ArgumentsNode)
+ end
+ def copy(flags: T.unsafe(nil), arguments: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#647
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, arguments: Array[Prism::node], location: Location }
+ #
+ # source://prism//lib/prism/node.rb#670
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#692
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#710
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#675
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#720
+ def type; end
+ end
+end
+
+# Flags for arguments nodes.
+#
+# source://prism//lib/prism/node.rb#19127
+module Prism::ArgumentsNodeFlags; end
+
+# if arguments contain keywords
+#
+# source://prism//lib/prism/node.rb#19129
+Prism::ArgumentsNodeFlags::CONTAINS_KEYWORDS = T.let(T.unsafe(nil), Integer)
+
+# if arguments contain keyword splat
+#
+# source://prism//lib/prism/node.rb#19132
+Prism::ArgumentsNodeFlags::CONTAINS_KEYWORD_SPLAT = T.let(T.unsafe(nil), Integer)
+
+# Represents an array literal. This can be a regular array using brackets or a special array using % like %w or %i.
+#
+# [1, 2, 3]
+# ^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#738
+class Prism::ArrayNode < ::Prism::Node
+ # def initialize: (Integer flags, Array[Prism::node] elements, Location? opening_loc, Location? closing_loc, Location location) -> void
+ #
+ # @return [ArrayNode] a new instance of ArrayNode
+ #
+ # source://prism//lib/prism/node.rb#740
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ elements: T::Array[Prism::Node],
+ opening_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, elements, opening_loc, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#875
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#750
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#755
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#836
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # Represents the optional source location for the closing token.
+ #
+ # [1,2,3] # "]"
+ # %w[foo bar baz] # "]"
+ # %I(apple orange banana) # ")"
+ # foo = 1, 2, 3 # nil
+ #
+ # source://prism//lib/prism/node.rb#813
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#765
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#760
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def contains_splat?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#826
+ sig { returns(T::Boolean) }
+ def contains_splat?; end
+
+ # def copy: (?flags: Integer, ?elements: Array[Prism::node], ?opening_loc: Location?, ?closing_loc: Location?, ?location: Location) -> ArrayNode
+ #
+ # source://prism//lib/prism/node.rb#770
+ sig do
+ params(
+ flags: Integer,
+ elements: T::Array[Prism::Node],
+ opening_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::ArrayNode)
+ end
+ def copy(flags: T.unsafe(nil), elements: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#755
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, elements: Array[Prism::node], opening_loc: Location?, closing_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#778
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # Represent the list of zero or more [non-void expressions](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression) within the array.
+ #
+ # source://prism//lib/prism/node.rb#787
+ sig { returns(T::Array[Prism::Node]) }
+ def elements; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#841
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def opening: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#831
+ sig { returns(T.nilable(String)) }
+ def opening; end
+
+ # Represents the optional source location for the opening token.
+ #
+ # [1,2,3] # "["
+ # %w[foo bar baz] # "%w["
+ # %I(apple orange banana) # "%I("
+ # foo = 1, 2, 3 # nil
+ #
+ # source://prism//lib/prism/node.rb#795
+ sig { returns(T.nilable(Prism::Location)) }
+ def opening_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#859
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#783
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#869
+ def type; end
+ end
+end
+
+# Flags for array nodes.
+#
+# source://prism//lib/prism/node.rb#19136
+module Prism::ArrayNodeFlags; end
+
+# if array contains splat nodes
+#
+# source://prism//lib/prism/node.rb#19138
+Prism::ArrayNodeFlags::CONTAINS_SPLAT = T.let(T.unsafe(nil), Integer)
+
+# Represents an array pattern in pattern matching.
+#
+# foo in 1, 2
+# ^^^^^^^^^^^
+#
+# foo in [1, 2]
+# ^^^^^^^^^^^^^
+#
+# foo in *1
+# ^^^^^^^^^
+#
+# foo in Bar[]
+# ^^^^^^^^^^^^
+#
+# foo in Bar[1, 2, 3]
+# ^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#901
+class Prism::ArrayPatternNode < ::Prism::Node
+ # def initialize: (Prism::node? constant, Array[Prism::node] requireds, Prism::node? rest, Array[Prism::node] posts, Location? opening_loc, Location? closing_loc, Location location) -> void
+ #
+ # @return [ArrayPatternNode] a new instance of ArrayPatternNode
+ #
+ # source://prism//lib/prism/node.rb#903
+ sig do
+ params(
+ source: Prism::Source,
+ constant: T.nilable(Prism::Node),
+ requireds: T::Array[Prism::Node],
+ rest: T.nilable(Prism::Node),
+ posts: T::Array[Prism::Node],
+ opening_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, constant, requireds, rest, posts, opening_loc, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#1035
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#915
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#920
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#996
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # attr_reader closing_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#978
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#935
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#925
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # attr_reader constant: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#953
+ sig { returns(T.nilable(Prism::Node)) }
+ def constant; end
+
+ # def copy: (?constant: Prism::node?, ?requireds: Array[Prism::node], ?rest: Prism::node?, ?posts: Array[Prism::node], ?opening_loc: Location?, ?closing_loc: Location?, ?location: Location) -> ArrayPatternNode
+ #
+ # source://prism//lib/prism/node.rb#940
+ sig do
+ params(
+ constant: T.nilable(Prism::Node),
+ requireds: T::Array[Prism::Node],
+ rest: T.nilable(Prism::Node),
+ posts: T::Array[Prism::Node],
+ opening_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::ArrayPatternNode)
+ end
+ def copy(constant: T.unsafe(nil), requireds: T.unsafe(nil), rest: T.unsafe(nil), posts: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#920
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { constant: Prism::node?, requireds: Array[Prism::node], rest: Prism::node?, posts: Array[Prism::node], opening_loc: Location?, closing_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#948
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#1001
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def opening: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#991
+ sig { returns(T.nilable(String)) }
+ def opening; end
+
+ # attr_reader opening_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#965
+ sig { returns(T.nilable(Prism::Location)) }
+ def opening_loc; end
+
+ # attr_reader posts: Array[Prism::node]
+ #
+ # source://prism//lib/prism/node.rb#962
+ sig { returns(T::Array[Prism::Node]) }
+ def posts; end
+
+ # attr_reader requireds: Array[Prism::node]
+ #
+ # source://prism//lib/prism/node.rb#956
+ sig { returns(T::Array[Prism::Node]) }
+ def requireds; end
+
+ # attr_reader rest: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#959
+ sig { returns(T.nilable(Prism::Node)) }
+ def rest; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1019
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1029
+ def type; end
+ end
+end
+
+# Represents a hash key/value pair.
+#
+# { a => b }
+# ^^^^^^
+#
+# source://prism//lib/prism/node.rb#1052
+class Prism::AssocNode < ::Prism::Node
+ # def initialize: (Prism::node key, Prism::node value, Location? operator_loc, Location location) -> void
+ #
+ # @return [AssocNode] a new instance of AssocNode
+ #
+ # source://prism//lib/prism/node.rb#1054
+ sig do
+ params(
+ source: Prism::Source,
+ key: Prism::Node,
+ value: Prism::Node,
+ operator_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, key, value, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#1172
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#1063
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1068
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#1078
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#1073
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?key: Prism::node, ?value: Prism::node, ?operator_loc: Location?, ?location: Location) -> AssocNode
+ #
+ # source://prism//lib/prism/node.rb#1083
+ sig do
+ params(
+ key: Prism::Node,
+ value: Prism::Node,
+ operator_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::AssocNode)
+ end
+ def copy(key: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1068
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { key: Prism::node, value: Prism::node, operator_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#1091
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#1138
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The key of the association. This can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # { a: b }
+ # ^
+ #
+ # { foo => bar }
+ # ^^^
+ #
+ # { def a; end => 1 }
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/node.rb#1105
+ sig { returns(Prism::Node) }
+ def key; end
+
+ # def operator: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#1133
+ sig { returns(T.nilable(String)) }
+ def operator; end
+
+ # The location of the `=>` operator, if present.
+ #
+ # { foo => bar }
+ # ^^
+ #
+ # source://prism//lib/prism/node.rb#1120
+ sig { returns(T.nilable(Prism::Location)) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1156
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # The value of the association, if present. This can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # { foo => bar }
+ # ^^^
+ #
+ # { x: 1 }
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#1114
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1166
+ def type; end
+ end
+end
+
+# Represents a splat in a hash literal.
+#
+# { **foo }
+# ^^^^^
+#
+# source://prism//lib/prism/node.rb#1184
+class Prism::AssocSplatNode < ::Prism::Node
+ # def initialize: (Prism::node? value, Location operator_loc, Location location) -> void
+ #
+ # @return [AssocSplatNode] a new instance of AssocSplatNode
+ #
+ # source://prism//lib/prism/node.rb#1186
+ sig do
+ params(
+ source: Prism::Source,
+ value: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, value, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#1284
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#1194
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1199
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#1211
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#1204
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?value: Prism::node?, ?operator_loc: Location, ?location: Location) -> AssocSplatNode
+ #
+ # source://prism//lib/prism/node.rb#1216
+ sig do
+ params(
+ value: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::AssocSplatNode)
+ end
+ def copy(value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1199
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { value: Prism::node?, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#1224
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#1250
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#1245
+ sig { returns(String) }
+ def operator; end
+
+ # The location of the `**` operator.
+ #
+ # { **x }
+ # ^^
+ #
+ # source://prism//lib/prism/node.rb#1238
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1268
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # The value to be splatted, if present. Will be missing when keyword rest argument forwarding is used.
+ #
+ # { **foo }
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#1232
+ sig { returns(T.nilable(Prism::Node)) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1278
+ def type; end
+ end
+end
+
+# The FFI backend is used on other Ruby implementations.
+#
+# source://prism//lib/prism.rb#81
+Prism::BACKEND = T.let(T.unsafe(nil), Symbol)
+
+# Represents reading a reference to a field in the previous match.
+#
+# $'
+# ^^
+#
+# source://prism//lib/prism/node.rb#1295
+class Prism::BackReferenceReadNode < ::Prism::Node
+ # def initialize: (Symbol name, Location location) -> void
+ #
+ # @return [BackReferenceReadNode] a new instance of BackReferenceReadNode
+ #
+ # source://prism//lib/prism/node.rb#1297
+ sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void }
+ def initialize(source, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#1378
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#1304
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1309
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#1319
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#1314
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?location: Location) -> BackReferenceReadNode
+ #
+ # source://prism//lib/prism/node.rb#1324
+ sig { params(name: Symbol, location: Prism::Location).returns(Prism::BackReferenceReadNode) }
+ def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1309
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#1332
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#1344
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the back-reference variable, including the leading `$`.
+ #
+ # $& # name `:$&`
+ #
+ # $+ # name `:$+`
+ #
+ # source://prism//lib/prism/node.rb#1341
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1362
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1372
+ def type; end
+ end
+end
+
+# A class that knows how to walk down the tree. None of the individual visit
+# methods are implemented on this visitor, so it forces the consumer to
+# implement each one that they need. For a default implementation that
+# continues walking the tree, see the Visitor class.
+#
+# source://prism//lib/prism/visitor.rb#14
+class Prism::BasicVisitor
+ # Calls `accept` on the given node if it is not `nil`, which in turn should
+ # call back into this visitor by calling the appropriate `visit_*` method.
+ #
+ # source://prism//lib/prism/visitor.rb#17
+ sig { params(node: T.nilable(Prism::Node)).void }
+ def visit(node); end
+
+ # Visits each node in `nodes` by calling `accept` on each one.
+ #
+ # source://prism//lib/prism/visitor.rb#23
+ sig { params(nodes: T::Array[T.nilable(Prism::Node)]).void }
+ def visit_all(nodes); end
+
+ # Visits the child nodes of `node` by calling `accept` on each one.
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::Node).void }
+ def visit_child_nodes(node); end
+end
+
+# Represents a begin statement.
+#
+# begin
+# foo
+# end
+# ^^^^^
+#
+# source://prism//lib/prism/node.rb#1390
+class Prism::BeginNode < ::Prism::Node
+ # def initialize: (Location? begin_keyword_loc, StatementsNode? statements, RescueNode? rescue_clause, ElseNode? else_clause, EnsureNode? ensure_clause, Location? end_keyword_loc, Location location) -> void
+ #
+ # @return [BeginNode] a new instance of BeginNode
+ #
+ # source://prism//lib/prism/node.rb#1392
+ sig do
+ params(
+ source: Prism::Source,
+ begin_keyword_loc: T.nilable(Prism::Location),
+ statements: T.nilable(Prism::StatementsNode),
+ rescue_clause: T.nilable(Prism::RescueNode),
+ else_clause: T.nilable(Prism::ElseNode),
+ ensure_clause: T.nilable(Prism::EnsureNode),
+ end_keyword_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, begin_keyword_loc, statements, rescue_clause, else_clause, ensure_clause, end_keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#1524
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#1404
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def begin_keyword: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#1480
+ sig { returns(T.nilable(String)) }
+ def begin_keyword; end
+
+ # attr_reader begin_keyword_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#1442
+ sig { returns(T.nilable(Prism::Location)) }
+ def begin_keyword_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1409
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#1424
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#1414
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?begin_keyword_loc: Location?, ?statements: StatementsNode?, ?rescue_clause: RescueNode?, ?else_clause: ElseNode?, ?ensure_clause: EnsureNode?, ?end_keyword_loc: Location?, ?location: Location) -> BeginNode
+ #
+ # source://prism//lib/prism/node.rb#1429
+ sig do
+ params(
+ begin_keyword_loc: T.nilable(Prism::Location),
+ statements: T.nilable(Prism::StatementsNode),
+ rescue_clause: T.nilable(Prism::RescueNode),
+ else_clause: T.nilable(Prism::ElseNode),
+ ensure_clause: T.nilable(Prism::EnsureNode),
+ end_keyword_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::BeginNode)
+ end
+ def copy(begin_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), rescue_clause: T.unsafe(nil), else_clause: T.unsafe(nil), ensure_clause: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1409
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { begin_keyword_loc: Location?, statements: StatementsNode?, rescue_clause: RescueNode?, else_clause: ElseNode?, ensure_clause: EnsureNode?, end_keyword_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#1437
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader else_clause: ElseNode?
+ #
+ # source://prism//lib/prism/node.rb#1461
+ sig { returns(T.nilable(Prism::ElseNode)) }
+ def else_clause; end
+
+ # def end_keyword: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#1485
+ sig { returns(T.nilable(String)) }
+ def end_keyword; end
+
+ # attr_reader end_keyword_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#1467
+ sig { returns(T.nilable(Prism::Location)) }
+ def end_keyword_loc; end
+
+ # attr_reader ensure_clause: EnsureNode?
+ #
+ # source://prism//lib/prism/node.rb#1464
+ sig { returns(T.nilable(Prism::EnsureNode)) }
+ def ensure_clause; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#1490
+ sig { override.returns(String) }
+ def inspect; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#79
+ def newline!(lines); end
+
+ # attr_reader rescue_clause: RescueNode?
+ #
+ # source://prism//lib/prism/node.rb#1458
+ sig { returns(T.nilable(Prism::RescueNode)) }
+ def rescue_clause; end
+
+ # attr_reader statements: StatementsNode?
+ #
+ # source://prism//lib/prism/node.rb#1455
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1508
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1518
+ def type; end
+ end
+end
+
+# Represents block method arguments.
+#
+# bar(&args)
+# ^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#1539
+class Prism::BlockArgumentNode < ::Prism::Node
+ # def initialize: (Prism::node? expression, Location operator_loc, Location location) -> void
+ #
+ # @return [BlockArgumentNode] a new instance of BlockArgumentNode
+ #
+ # source://prism//lib/prism/node.rb#1541
+ sig do
+ params(
+ source: Prism::Source,
+ expression: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, expression, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#1633
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#1549
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1554
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#1566
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#1559
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?expression: Prism::node?, ?operator_loc: Location, ?location: Location) -> BlockArgumentNode
+ #
+ # source://prism//lib/prism/node.rb#1571
+ sig do
+ params(
+ expression: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::BlockArgumentNode)
+ end
+ def copy(expression: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1554
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { expression: Prism::node?, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#1579
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader expression: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#1584
+ sig { returns(T.nilable(Prism::Node)) }
+ def expression; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#1599
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#1594
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#1587
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1617
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1627
+ def type; end
+ end
+end
+
+# Represents a block local variable.
+#
+# a { |; b| }
+# ^
+#
+# source://prism//lib/prism/node.rb#1644
+class Prism::BlockLocalVariableNode < ::Prism::Node
+ # def initialize: (Integer flags, Symbol name, Location location) -> void
+ #
+ # @return [BlockLocalVariableNode] a new instance of BlockLocalVariableNode
+ #
+ # source://prism//lib/prism/node.rb#1646
+ sig { params(source: Prism::Source, flags: Integer, name: Symbol, location: Prism::Location).void }
+ def initialize(source, flags, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#1733
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#1654
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1659
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#1669
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#1664
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?name: Symbol, ?location: Location) -> BlockLocalVariableNode
+ #
+ # source://prism//lib/prism/node.rb#1674
+ sig { params(flags: Integer, name: Symbol, location: Prism::Location).returns(Prism::BlockLocalVariableNode) }
+ def copy(flags: T.unsafe(nil), name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1659
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#1682
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#1699
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#1691
+ sig { returns(Symbol) }
+ def name; end
+
+ # def repeated_parameter?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#1694
+ sig { returns(T::Boolean) }
+ def repeated_parameter?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1717
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#1687
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1727
+ def type; end
+ end
+end
+
+# Represents a block of ruby code.
+#
+# [1, 2, 3].each { |i| puts x }
+# ^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#1744
+class Prism::BlockNode < ::Prism::Node
+ # def initialize: (Array[Symbol] locals, Prism::node? parameters, Prism::node? body, Location opening_loc, Location closing_loc, Location location) -> void
+ #
+ # @return [BlockNode] a new instance of BlockNode
+ #
+ # source://prism//lib/prism/node.rb#1746
+ sig do
+ params(
+ source: Prism::Source,
+ locals: T::Array[Symbol],
+ parameters: T.nilable(Prism::Node),
+ body: T.nilable(Prism::Node),
+ opening_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, locals, parameters, body, opening_loc, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#1860
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#1757
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader body: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#1799
+ sig { returns(T.nilable(Prism::Node)) }
+ def body; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1762
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#1821
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#1809
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#1775
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#1767
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?locals: Array[Symbol], ?parameters: Prism::node?, ?body: Prism::node?, ?opening_loc: Location, ?closing_loc: Location, ?location: Location) -> BlockNode
+ #
+ # source://prism//lib/prism/node.rb#1780
+ sig do
+ params(
+ locals: T::Array[Symbol],
+ parameters: T.nilable(Prism::Node),
+ body: T.nilable(Prism::Node),
+ opening_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::BlockNode)
+ end
+ def copy(locals: T.unsafe(nil), parameters: T.unsafe(nil), body: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1762
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], parameters: Prism::node?, body: Prism::node?, opening_loc: Location, closing_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#1788
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#1826
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader locals: Array[Symbol]
+ #
+ # source://prism//lib/prism/node.rb#1793
+ sig { returns(T::Array[Symbol]) }
+ def locals; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#1816
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#1802
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # attr_reader parameters: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#1796
+ sig { returns(T.nilable(Prism::Node)) }
+ def parameters; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1844
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1854
+ def type; end
+ end
+end
+
+# Represents a block parameter to a method, block, or lambda definition.
+#
+# def a(&b)
+# ^^
+# end
+#
+# source://prism//lib/prism/node.rb#1876
+class Prism::BlockParameterNode < ::Prism::Node
+ # def initialize: (Integer flags, Symbol? name, Location? name_loc, Location operator_loc, Location location) -> void
+ #
+ # @return [BlockParameterNode] a new instance of BlockParameterNode
+ #
+ # source://prism//lib/prism/node.rb#1878
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ name: T.nilable(Symbol),
+ name_loc: T.nilable(Prism::Location),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, name, name_loc, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#1992
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#1888
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1893
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#1903
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#1898
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?name: Symbol?, ?name_loc: Location?, ?operator_loc: Location, ?location: Location) -> BlockParameterNode
+ #
+ # source://prism//lib/prism/node.rb#1908
+ sig do
+ params(
+ flags: Integer,
+ name: T.nilable(Symbol),
+ name_loc: T.nilable(Prism::Location),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::BlockParameterNode)
+ end
+ def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#1893
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol?, name_loc: Location?, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#1916
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#1958
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol?
+ #
+ # source://prism//lib/prism/node.rb#1925
+ sig { returns(T.nilable(Symbol)) }
+ def name; end
+
+ # attr_reader name_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#1928
+ sig { returns(T.nilable(Prism::Location)) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#1953
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#1941
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # def repeated_parameter?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#1948
+ sig { returns(T::Boolean) }
+ def repeated_parameter?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1976
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#1921
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#1986
+ def type; end
+ end
+end
+
+# Represents a block's parameters declaration.
+#
+# -> (a, b = 1; local) { }
+# ^^^^^^^^^^^^^^^^^
+#
+# foo do |a, b = 1; local|
+# ^^^^^^^^^^^^^^^^^
+# end
+#
+# source://prism//lib/prism/node.rb#2009
+class Prism::BlockParametersNode < ::Prism::Node
+ # def initialize: (ParametersNode? parameters, Array[BlockLocalVariableNode] locals, Location? opening_loc, Location? closing_loc, Location location) -> void
+ #
+ # @return [BlockParametersNode] a new instance of BlockParametersNode
+ #
+ # source://prism//lib/prism/node.rb#2011
+ sig do
+ params(
+ source: Prism::Source,
+ parameters: T.nilable(Prism::ParametersNode),
+ locals: T::Array[Prism::BlockLocalVariableNode],
+ opening_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, parameters, locals, opening_loc, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#2133
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#2021
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2026
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2094
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # attr_reader closing_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2076
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#2039
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#2031
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?parameters: ParametersNode?, ?locals: Array[BlockLocalVariableNode], ?opening_loc: Location?, ?closing_loc: Location?, ?location: Location) -> BlockParametersNode
+ #
+ # source://prism//lib/prism/node.rb#2044
+ sig do
+ params(
+ parameters: T.nilable(Prism::ParametersNode),
+ locals: T::Array[Prism::BlockLocalVariableNode],
+ opening_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::BlockParametersNode)
+ end
+ def copy(parameters: T.unsafe(nil), locals: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2026
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { parameters: ParametersNode?, locals: Array[BlockLocalVariableNode], opening_loc: Location?, closing_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#2052
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#2099
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader locals: Array[BlockLocalVariableNode]
+ #
+ # source://prism//lib/prism/node.rb#2060
+ sig { returns(T::Array[Prism::BlockLocalVariableNode]) }
+ def locals; end
+
+ # def opening: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2089
+ sig { returns(T.nilable(String)) }
+ def opening; end
+
+ # attr_reader opening_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2063
+ sig { returns(T.nilable(Prism::Location)) }
+ def opening_loc; end
+
+ # attr_reader parameters: ParametersNode?
+ #
+ # source://prism//lib/prism/node.rb#2057
+ sig { returns(T.nilable(Prism::ParametersNode)) }
+ def parameters; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#2117
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#2127
+ def type; end
+ end
+end
+
+# Represents the use of the `break` keyword.
+#
+# break foo
+# ^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#2147
+class Prism::BreakNode < ::Prism::Node
+ # def initialize: (ArgumentsNode? arguments, Location keyword_loc, Location location) -> void
+ #
+ # @return [BreakNode] a new instance of BreakNode
+ #
+ # source://prism//lib/prism/node.rb#2149
+ sig do
+ params(
+ source: Prism::Source,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, arguments, keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#2247
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#2157
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # The arguments to the break statement, if present. These can be any [non-void expressions](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # break foo
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#2195
+ sig { returns(T.nilable(Prism::ArgumentsNode)) }
+ def arguments; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2162
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#2174
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#2167
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?arguments: ArgumentsNode?, ?keyword_loc: Location, ?location: Location) -> BreakNode
+ #
+ # source://prism//lib/prism/node.rb#2179
+ sig do
+ params(
+ arguments: T.nilable(Prism::ArgumentsNode),
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::BreakNode)
+ end
+ def copy(arguments: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2162
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { arguments: ArgumentsNode?, keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#2187
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#2213
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#2208
+ sig { returns(String) }
+ def keyword; end
+
+ # The location of the `break` keyword.
+ #
+ # break foo
+ # ^^^^^
+ #
+ # source://prism//lib/prism/node.rb#2201
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#2231
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#2241
+ def type; end
+ end
+end
+
+# Represents the use of the `&&=` operator on a call.
+#
+# foo.bar &&= value
+# ^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#2258
+class Prism::CallAndWriteNode < ::Prism::Node
+ # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location? message_loc, Symbol read_name, Symbol write_name, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [CallAndWriteNode] a new instance of CallAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#2260
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ message_loc: T.nilable(Prism::Location),
+ read_name: Symbol,
+ write_name: Symbol,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, receiver, call_operator_loc, message_loc, read_name, write_name, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#2428
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#2274
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def attribute_write?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2369
+ sig { returns(T::Boolean) }
+ def attribute_write?; end
+
+ # def call_operator: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2379
+ sig { returns(T.nilable(String)) }
+ def call_operator; end
+
+ # attr_reader call_operator_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2317
+ sig { returns(T.nilable(Prism::Location)) }
+ def call_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2279
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#2292
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#2284
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?message_loc: Location?, ?read_name: Symbol, ?write_name: Symbol, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> CallAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#2297
+ sig do
+ params(
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ message_loc: T.nilable(Prism::Location),
+ read_name: Symbol,
+ write_name: Symbol,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::CallAndWriteNode)
+ end
+ def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), message_loc: T.unsafe(nil), read_name: T.unsafe(nil), write_name: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2279
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, message_loc: Location?, read_name: Symbol, write_name: Symbol, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#2305
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def ignore_visibility?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2374
+ sig { returns(T::Boolean) }
+ def ignore_visibility?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#2394
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def message: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2384
+ sig { returns(T.nilable(String)) }
+ def message; end
+
+ # attr_reader message_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2330
+ sig { returns(T.nilable(Prism::Location)) }
+ def message_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#2389
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#2349
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader read_name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#2343
+ sig { returns(Symbol) }
+ def read_name; end
+
+ # attr_reader receiver: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#2314
+ sig { returns(T.nilable(Prism::Node)) }
+ def receiver; end
+
+ # def safe_navigation?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2359
+ sig { returns(T::Boolean) }
+ def safe_navigation?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#2412
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#2356
+ sig { returns(Prism::Node) }
+ def value; end
+
+ # def variable_call?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2364
+ sig { returns(T::Boolean) }
+ def variable_call?; end
+
+ # attr_reader write_name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#2346
+ sig { returns(Symbol) }
+ def write_name; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#2310
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#2422
+ def type; end
+ end
+end
+
+# Represents a method call, in all of the various forms that can take.
+#
+# foo
+# ^^^
+#
+# foo()
+# ^^^^^
+#
+# +foo
+# ^^^^
+#
+# foo + bar
+# ^^^^^^^^^
+#
+# foo.bar
+# ^^^^^^^
+#
+# foo&.bar
+# ^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#2460
+class Prism::CallNode < ::Prism::Node
+ # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Symbol name, Location? message_loc, Location? opening_loc, ArgumentsNode? arguments, Location? closing_loc, Prism::node? block, Location location) -> void
+ #
+ # @return [CallNode] a new instance of CallNode
+ #
+ # source://prism//lib/prism/node.rb#2462
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ name: Symbol,
+ message_loc: T.nilable(Prism::Location),
+ opening_loc: T.nilable(Prism::Location),
+ arguments: T.nilable(Prism::ArgumentsNode),
+ closing_loc: T.nilable(Prism::Location),
+ block: T.nilable(Prism::Node),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, receiver, call_operator_loc, name, message_loc, opening_loc, arguments, closing_loc, block, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#2665
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#2477
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader arguments: ArgumentsNode?
+ #
+ # source://prism//lib/prism/node.rb#2572
+ sig { returns(T.nilable(Prism::ArgumentsNode)) }
+ def arguments; end
+
+ # def attribute_write?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2601
+ sig { returns(T::Boolean) }
+ def attribute_write?; end
+
+ # attr_reader block: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#2588
+ sig { returns(T.nilable(Prism::Node)) }
+ def block; end
+
+ # def call_operator: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2611
+ sig { returns(T.nilable(String)) }
+ def call_operator; end
+
+ # attr_reader call_operator_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2530
+ sig { returns(T.nilable(Prism::Location)) }
+ def call_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2482
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2626
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # attr_reader closing_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2575
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#2496
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#2487
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?name: Symbol, ?message_loc: Location?, ?opening_loc: Location?, ?arguments: ArgumentsNode?, ?closing_loc: Location?, ?block: Prism::node?, ?location: Location) -> CallNode
+ #
+ # source://prism//lib/prism/node.rb#2501
+ sig do
+ params(
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ name: Symbol,
+ message_loc: T.nilable(Prism::Location),
+ opening_loc: T.nilable(Prism::Location),
+ arguments: T.nilable(Prism::ArgumentsNode),
+ closing_loc: T.nilable(Prism::Location),
+ block: T.nilable(Prism::Node),
+ location: Prism::Location
+ ).returns(Prism::CallNode)
+ end
+ def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), name: T.unsafe(nil), message_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), arguments: T.unsafe(nil), closing_loc: T.unsafe(nil), block: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2482
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, name: Symbol, message_loc: Location?, opening_loc: Location?, arguments: ArgumentsNode?, closing_loc: Location?, block: Prism::node?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#2509
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # When a call node has the attribute_write flag set, it means that the call
+ # is using the attribute write syntax. This is either a method call to []=
+ # or a method call to a method that ends with =. Either way, the = sign is
+ # present in the source.
+ #
+ # Prism returns the message_loc _without_ the = sign attached, because there
+ # can be any amount of space between the message and the = sign. However,
+ # sometimes you want the location of the full message including the inner
+ # space and the = sign. This method provides that.
+ #
+ # source://prism//lib/prism/node_ext.rb#315
+ sig { returns(T.nilable(Prism::Location)) }
+ def full_message_loc; end
+
+ # def ignore_visibility?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2606
+ sig { returns(T::Boolean) }
+ def ignore_visibility?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#2631
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def message: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2616
+ sig { returns(T.nilable(String)) }
+ def message; end
+
+ # attr_reader message_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2546
+ sig { returns(T.nilable(Prism::Location)) }
+ def message_loc; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#2543
+ sig { returns(Symbol) }
+ def name; end
+
+ # def opening: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2621
+ sig { returns(T.nilable(String)) }
+ def opening; end
+
+ # attr_reader opening_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2559
+ sig { returns(T.nilable(Prism::Location)) }
+ def opening_loc; end
+
+ # The object that the method is being called on. This can be either `nil` or any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # foo.bar
+ # ^^^
+ #
+ # +foo
+ # ^^^
+ #
+ # foo + bar
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#2527
+ sig { returns(T.nilable(Prism::Node)) }
+ def receiver; end
+
+ # def safe_navigation?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2591
+ sig { returns(T::Boolean) }
+ def safe_navigation?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#2649
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # def variable_call?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2596
+ sig { returns(T::Boolean) }
+ def variable_call?; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#2514
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#2659
+ def type; end
+ end
+end
+
+# Flags for call nodes.
+#
+# source://prism//lib/prism/node.rb#19142
+module Prism::CallNodeFlags; end
+
+# a call that is an attribute write, so the value being written should be returned
+#
+# source://prism//lib/prism/node.rb#19150
+Prism::CallNodeFlags::ATTRIBUTE_WRITE = T.let(T.unsafe(nil), Integer)
+
+# a call that ignores method visibility
+#
+# source://prism//lib/prism/node.rb#19153
+Prism::CallNodeFlags::IGNORE_VISIBILITY = T.let(T.unsafe(nil), Integer)
+
+# &. operator
+#
+# source://prism//lib/prism/node.rb#19144
+Prism::CallNodeFlags::SAFE_NAVIGATION = T.let(T.unsafe(nil), Integer)
+
+# a call that could have been a local variable
+#
+# source://prism//lib/prism/node.rb#19147
+Prism::CallNodeFlags::VARIABLE_CALL = T.let(T.unsafe(nil), Integer)
+
+# Represents the use of an assignment operator on a call.
+#
+# foo.bar += baz
+# ^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#2683
+class Prism::CallOperatorWriteNode < ::Prism::Node
+ # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location? message_loc, Symbol read_name, Symbol write_name, Symbol binary_operator, Location binary_operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [CallOperatorWriteNode] a new instance of CallOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#2685
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ message_loc: T.nilable(Prism::Location),
+ read_name: Symbol,
+ write_name: Symbol,
+ binary_operator: Symbol,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, receiver, call_operator_loc, message_loc, read_name, write_name, binary_operator, binary_operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#2852
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#2700
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def attribute_write?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2798
+ sig { returns(T::Boolean) }
+ def attribute_write?; end
+
+ # attr_reader binary_operator: Symbol
+ #
+ # source://prism//lib/prism/node.rb#2775
+ sig { returns(Symbol) }
+ def binary_operator; end
+
+ # attr_reader binary_operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#2778
+ sig { returns(Prism::Location) }
+ def binary_operator_loc; end
+
+ # def call_operator: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2808
+ sig { returns(T.nilable(String)) }
+ def call_operator; end
+
+ # attr_reader call_operator_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2743
+ sig { returns(T.nilable(Prism::Location)) }
+ def call_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2705
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#2718
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#2710
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?message_loc: Location?, ?read_name: Symbol, ?write_name: Symbol, ?binary_operator: Symbol, ?binary_operator_loc: Location, ?value: Prism::node, ?location: Location) -> CallOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#2723
+ sig do
+ params(
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ message_loc: T.nilable(Prism::Location),
+ read_name: Symbol,
+ write_name: Symbol,
+ binary_operator: Symbol,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::CallOperatorWriteNode)
+ end
+ def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), message_loc: T.unsafe(nil), read_name: T.unsafe(nil), write_name: T.unsafe(nil), binary_operator: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2705
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, message_loc: Location?, read_name: Symbol, write_name: Symbol, binary_operator: Symbol, binary_operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#2731
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def ignore_visibility?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2803
+ sig { returns(T::Boolean) }
+ def ignore_visibility?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#2818
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def message: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2813
+ sig { returns(T.nilable(String)) }
+ def message; end
+
+ # attr_reader message_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2756
+ sig { returns(T.nilable(Prism::Location)) }
+ def message_loc; end
+
+ # Returns the binary operator used to modify the receiver. This method is
+ # deprecated in favor of #binary_operator.
+ #
+ # source://prism//lib/prism/node_ext.rb#323
+ def operator; end
+
+ # Returns the location of the binary operator used to modify the receiver.
+ # This method is deprecated in favor of #binary_operator_loc.
+ #
+ # source://prism//lib/prism/node_ext.rb#330
+ def operator_loc; end
+
+ # attr_reader read_name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#2769
+ sig { returns(Symbol) }
+ def read_name; end
+
+ # attr_reader receiver: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#2740
+ sig { returns(T.nilable(Prism::Node)) }
+ def receiver; end
+
+ # def safe_navigation?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2788
+ sig { returns(T::Boolean) }
+ def safe_navigation?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#2836
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#2785
+ sig { returns(Prism::Node) }
+ def value; end
+
+ # def variable_call?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2793
+ sig { returns(T::Boolean) }
+ def variable_call?; end
+
+ # attr_reader write_name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#2772
+ sig { returns(Symbol) }
+ def write_name; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#2736
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#2846
+ def type; end
+ end
+end
+
+# Represents the use of the `||=` operator on a call.
+#
+# foo.bar ||= value
+# ^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#2870
+class Prism::CallOrWriteNode < ::Prism::Node
+ # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location? message_loc, Symbol read_name, Symbol write_name, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [CallOrWriteNode] a new instance of CallOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#2872
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ message_loc: T.nilable(Prism::Location),
+ read_name: Symbol,
+ write_name: Symbol,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, receiver, call_operator_loc, message_loc, read_name, write_name, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#3040
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#2886
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def attribute_write?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2981
+ sig { returns(T::Boolean) }
+ def attribute_write?; end
+
+ # def call_operator: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2991
+ sig { returns(T.nilable(String)) }
+ def call_operator; end
+
+ # attr_reader call_operator_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2929
+ sig { returns(T.nilable(Prism::Location)) }
+ def call_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2891
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#2904
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#2896
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?message_loc: Location?, ?read_name: Symbol, ?write_name: Symbol, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> CallOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#2909
+ sig do
+ params(
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ message_loc: T.nilable(Prism::Location),
+ read_name: Symbol,
+ write_name: Symbol,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::CallOrWriteNode)
+ end
+ def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), message_loc: T.unsafe(nil), read_name: T.unsafe(nil), write_name: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#2891
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, message_loc: Location?, read_name: Symbol, write_name: Symbol, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#2917
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def ignore_visibility?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2986
+ sig { returns(T::Boolean) }
+ def ignore_visibility?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#3006
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def message: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#2996
+ sig { returns(T.nilable(String)) }
+ def message; end
+
+ # attr_reader message_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#2942
+ sig { returns(T.nilable(Prism::Location)) }
+ def message_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#3001
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#2961
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader read_name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#2955
+ sig { returns(Symbol) }
+ def read_name; end
+
+ # attr_reader receiver: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#2926
+ sig { returns(T.nilable(Prism::Node)) }
+ def receiver; end
+
+ # def safe_navigation?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2971
+ sig { returns(T::Boolean) }
+ def safe_navigation?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3024
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#2968
+ sig { returns(Prism::Node) }
+ def value; end
+
+ # def variable_call?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#2976
+ sig { returns(T::Boolean) }
+ def variable_call?; end
+
+ # attr_reader write_name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#2958
+ sig { returns(Symbol) }
+ def write_name; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#2922
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3034
+ def type; end
+ end
+end
+
+# Represents assigning to a method call.
+#
+# foo.bar, = 1
+# ^^^^^^^
+#
+# begin
+# rescue => foo.bar
+# ^^^^^^^
+# end
+#
+# for foo.bar in baz do end
+# ^^^^^^^
+#
+# source://prism//lib/prism/node.rb#3065
+class Prism::CallTargetNode < ::Prism::Node
+ # def initialize: (Integer flags, Prism::node receiver, Location call_operator_loc, Symbol name, Location message_loc, Location location) -> void
+ #
+ # @return [CallTargetNode] a new instance of CallTargetNode
+ #
+ # source://prism//lib/prism/node.rb#3067
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ receiver: Prism::Node,
+ call_operator_loc: Prism::Location,
+ name: Symbol,
+ message_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, receiver, call_operator_loc, name, message_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#3199
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#3078
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def attribute_write?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#3145
+ sig { returns(T::Boolean) }
+ def attribute_write?; end
+
+ # def call_operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#3155
+ sig { returns(String) }
+ def call_operator; end
+
+ # attr_reader call_operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3118
+ sig { returns(Prism::Location) }
+ def call_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3083
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#3093
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#3088
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?receiver: Prism::node, ?call_operator_loc: Location, ?name: Symbol, ?message_loc: Location, ?location: Location) -> CallTargetNode
+ #
+ # source://prism//lib/prism/node.rb#3098
+ sig do
+ params(
+ flags: Integer,
+ receiver: Prism::Node,
+ call_operator_loc: Prism::Location,
+ name: Symbol,
+ message_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::CallTargetNode)
+ end
+ def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), name: T.unsafe(nil), message_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3083
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node, call_operator_loc: Location, name: Symbol, message_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#3106
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def ignore_visibility?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#3150
+ sig { returns(T::Boolean) }
+ def ignore_visibility?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#3165
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def message: () -> String
+ #
+ # source://prism//lib/prism/node.rb#3160
+ sig { returns(String) }
+ def message; end
+
+ # attr_reader message_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3128
+ sig { returns(Prism::Location) }
+ def message_loc; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#3125
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader receiver: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#3115
+ sig { returns(Prism::Node) }
+ def receiver; end
+
+ # def safe_navigation?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#3135
+ sig { returns(T::Boolean) }
+ def safe_navigation?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3183
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # def variable_call?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#3140
+ sig { returns(T::Boolean) }
+ def variable_call?; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#3111
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3193
+ def type; end
+ end
+end
+
+# Represents assigning to a local variable in pattern matching.
+#
+# foo => [bar => baz]
+# ^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#3213
+class Prism::CapturePatternNode < ::Prism::Node
+ # def initialize: (Prism::node value, Prism::node target, Location operator_loc, Location location) -> void
+ #
+ # @return [CapturePatternNode] a new instance of CapturePatternNode
+ #
+ # source://prism//lib/prism/node.rb#3215
+ sig do
+ params(
+ source: Prism::Source,
+ value: Prism::Node,
+ target: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, value, target, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#3309
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#3224
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3229
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#3239
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#3234
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?value: Prism::node, ?target: Prism::node, ?operator_loc: Location, ?location: Location) -> CapturePatternNode
+ #
+ # source://prism//lib/prism/node.rb#3244
+ sig do
+ params(
+ value: Prism::Node,
+ target: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::CapturePatternNode)
+ end
+ def copy(value: T.unsafe(nil), target: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3229
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { value: Prism::node, target: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#3252
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#3275
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#3270
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3263
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader target: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#3260
+ sig { returns(Prism::Node) }
+ def target; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3293
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#3257
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3303
+ def type; end
+ end
+end
+
+# Represents the use of a case statement for pattern matching.
+#
+# case true
+# in false
+# end
+# ^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#3323
+class Prism::CaseMatchNode < ::Prism::Node
+ # def initialize: (Prism::node? predicate, Array[Prism::node] conditions, ElseNode? consequent, Location case_keyword_loc, Location end_keyword_loc, Location location) -> void
+ #
+ # @return [CaseMatchNode] a new instance of CaseMatchNode
+ #
+ # source://prism//lib/prism/node.rb#3325
+ sig do
+ params(
+ source: Prism::Source,
+ predicate: T.nilable(Prism::Node),
+ conditions: T::Array[Prism::Node],
+ consequent: T.nilable(Prism::ElseNode),
+ case_keyword_loc: Prism::Location,
+ end_keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, predicate, conditions, consequent, case_keyword_loc, end_keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#3440
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#3336
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def case_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#3396
+ sig { returns(String) }
+ def case_keyword; end
+
+ # attr_reader case_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3382
+ sig { returns(Prism::Location) }
+ def case_keyword_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3341
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#3355
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#3346
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # attr_reader conditions: Array[Prism::node]
+ #
+ # source://prism//lib/prism/node.rb#3376
+ sig { returns(T::Array[Prism::Node]) }
+ def conditions; end
+
+ # attr_reader consequent: ElseNode?
+ #
+ # source://prism//lib/prism/node.rb#3379
+ sig { returns(T.nilable(Prism::ElseNode)) }
+ def consequent; end
+
+ # def copy: (?predicate: Prism::node?, ?conditions: Array[Prism::node], ?consequent: ElseNode?, ?case_keyword_loc: Location, ?end_keyword_loc: Location, ?location: Location) -> CaseMatchNode
+ #
+ # source://prism//lib/prism/node.rb#3360
+ sig do
+ params(
+ predicate: T.nilable(Prism::Node),
+ conditions: T::Array[Prism::Node],
+ consequent: T.nilable(Prism::ElseNode),
+ case_keyword_loc: Prism::Location,
+ end_keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::CaseMatchNode)
+ end
+ def copy(predicate: T.unsafe(nil), conditions: T.unsafe(nil), consequent: T.unsafe(nil), case_keyword_loc: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3341
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { predicate: Prism::node?, conditions: Array[Prism::node], consequent: ElseNode?, case_keyword_loc: Location, end_keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#3368
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def end_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#3401
+ sig { returns(String) }
+ def end_keyword; end
+
+ # attr_reader end_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3389
+ sig { returns(Prism::Location) }
+ def end_keyword_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#3406
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader predicate: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#3373
+ sig { returns(T.nilable(Prism::Node)) }
+ def predicate; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3424
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3434
+ def type; end
+ end
+end
+
+# Represents the use of a case statement.
+#
+# case true
+# when false
+# end
+# ^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#3457
+class Prism::CaseNode < ::Prism::Node
+ # def initialize: (Prism::node? predicate, Array[Prism::node] conditions, ElseNode? consequent, Location case_keyword_loc, Location end_keyword_loc, Location location) -> void
+ #
+ # @return [CaseNode] a new instance of CaseNode
+ #
+ # source://prism//lib/prism/node.rb#3459
+ sig do
+ params(
+ source: Prism::Source,
+ predicate: T.nilable(Prism::Node),
+ conditions: T::Array[Prism::Node],
+ consequent: T.nilable(Prism::ElseNode),
+ case_keyword_loc: Prism::Location,
+ end_keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, predicate, conditions, consequent, case_keyword_loc, end_keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#3574
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#3470
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def case_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#3530
+ sig { returns(String) }
+ def case_keyword; end
+
+ # attr_reader case_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3516
+ sig { returns(Prism::Location) }
+ def case_keyword_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3475
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#3489
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#3480
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # attr_reader conditions: Array[Prism::node]
+ #
+ # source://prism//lib/prism/node.rb#3510
+ sig { returns(T::Array[Prism::Node]) }
+ def conditions; end
+
+ # attr_reader consequent: ElseNode?
+ #
+ # source://prism//lib/prism/node.rb#3513
+ sig { returns(T.nilable(Prism::ElseNode)) }
+ def consequent; end
+
+ # def copy: (?predicate: Prism::node?, ?conditions: Array[Prism::node], ?consequent: ElseNode?, ?case_keyword_loc: Location, ?end_keyword_loc: Location, ?location: Location) -> CaseNode
+ #
+ # source://prism//lib/prism/node.rb#3494
+ sig do
+ params(
+ predicate: T.nilable(Prism::Node),
+ conditions: T::Array[Prism::Node],
+ consequent: T.nilable(Prism::ElseNode),
+ case_keyword_loc: Prism::Location,
+ end_keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::CaseNode)
+ end
+ def copy(predicate: T.unsafe(nil), conditions: T.unsafe(nil), consequent: T.unsafe(nil), case_keyword_loc: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3475
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { predicate: Prism::node?, conditions: Array[Prism::node], consequent: ElseNode?, case_keyword_loc: Location, end_keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#3502
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def end_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#3535
+ sig { returns(String) }
+ def end_keyword; end
+
+ # attr_reader end_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3523
+ sig { returns(Prism::Location) }
+ def end_keyword_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#3540
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader predicate: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#3507
+ sig { returns(T.nilable(Prism::Node)) }
+ def predicate; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3558
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3568
+ def type; end
+ end
+end
+
+# Represents a class declaration involving the `class` keyword.
+#
+# class Foo end
+# ^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#3589
+class Prism::ClassNode < ::Prism::Node
+ # def initialize: (Array[Symbol] locals, Location class_keyword_loc, Prism::node constant_path, Location? inheritance_operator_loc, Prism::node? superclass, Prism::node? body, Location end_keyword_loc, Symbol name, Location location) -> void
+ #
+ # @return [ClassNode] a new instance of ClassNode
+ #
+ # source://prism//lib/prism/node.rb#3591
+ sig do
+ params(
+ source: Prism::Source,
+ locals: T::Array[Symbol],
+ class_keyword_loc: Prism::Location,
+ constant_path: Prism::Node,
+ inheritance_operator_loc: T.nilable(Prism::Location),
+ superclass: T.nilable(Prism::Node),
+ body: T.nilable(Prism::Node),
+ end_keyword_loc: Prism::Location,
+ name: Symbol,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, locals, class_keyword_loc, constant_path, inheritance_operator_loc, superclass, body, end_keyword_loc, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#3733
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#3605
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader body: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#3671
+ sig { returns(T.nilable(Prism::Node)) }
+ def body; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3610
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def class_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#3684
+ sig { returns(String) }
+ def class_keyword; end
+
+ # attr_reader class_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3645
+ sig { returns(Prism::Location) }
+ def class_keyword_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#3624
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#3615
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # attr_reader constant_path: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#3652
+ sig { returns(Prism::Node) }
+ def constant_path; end
+
+ # def copy: (?locals: Array[Symbol], ?class_keyword_loc: Location, ?constant_path: Prism::node, ?inheritance_operator_loc: Location?, ?superclass: Prism::node?, ?body: Prism::node?, ?end_keyword_loc: Location, ?name: Symbol, ?location: Location) -> ClassNode
+ #
+ # source://prism//lib/prism/node.rb#3629
+ sig do
+ params(
+ locals: T::Array[Symbol],
+ class_keyword_loc: Prism::Location,
+ constant_path: Prism::Node,
+ inheritance_operator_loc: T.nilable(Prism::Location),
+ superclass: T.nilable(Prism::Node),
+ body: T.nilable(Prism::Node),
+ end_keyword_loc: Prism::Location,
+ name: Symbol,
+ location: Prism::Location
+ ).returns(Prism::ClassNode)
+ end
+ def copy(locals: T.unsafe(nil), class_keyword_loc: T.unsafe(nil), constant_path: T.unsafe(nil), inheritance_operator_loc: T.unsafe(nil), superclass: T.unsafe(nil), body: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3610
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], class_keyword_loc: Location, constant_path: Prism::node, inheritance_operator_loc: Location?, superclass: Prism::node?, body: Prism::node?, end_keyword_loc: Location, name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#3637
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def end_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#3694
+ sig { returns(String) }
+ def end_keyword; end
+
+ # attr_reader end_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3674
+ sig { returns(Prism::Location) }
+ def end_keyword_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inheritance_operator: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#3689
+ sig { returns(T.nilable(String)) }
+ def inheritance_operator; end
+
+ # attr_reader inheritance_operator_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#3655
+ sig { returns(T.nilable(Prism::Location)) }
+ def inheritance_operator_loc; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#3699
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader locals: Array[Symbol]
+ #
+ # source://prism//lib/prism/node.rb#3642
+ sig { returns(T::Array[Symbol]) }
+ def locals; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#3681
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader superclass: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#3668
+ sig { returns(T.nilable(Prism::Node)) }
+ def superclass; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3717
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3727
+ def type; end
+ end
+end
+
+# Represents the use of the `&&=` operator for assignment to a class variable.
+#
+# @@target &&= value
+# ^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#3751
+class Prism::ClassVariableAndWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [ClassVariableAndWriteNode] a new instance of ClassVariableAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#3753
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#3855
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#3763
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3768
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#3778
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#3773
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ClassVariableAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#3783
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::ClassVariableAndWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3768
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#3791
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#127
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#3821
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#3796
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3799
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#3816
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3806
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3839
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#3813
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3849
+ def type; end
+ end
+end
+
+# Represents assigning to a class variable using an operator that isn't `=`.
+#
+# @@target += value
+# ^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#3868
+class Prism::ClassVariableOperatorWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location binary_operator_loc, Prism::node value, Symbol binary_operator, Location location) -> void
+ #
+ # @return [ClassVariableOperatorWriteNode] a new instance of ClassVariableOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#3870
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ binary_operator: Symbol,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, binary_operator_loc, value, binary_operator, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#3971
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#3881
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader binary_operator: Symbol
+ #
+ # source://prism//lib/prism/node.rb#3934
+ sig { returns(Symbol) }
+ def binary_operator; end
+
+ # attr_reader binary_operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3924
+ sig { returns(Prism::Location) }
+ def binary_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3886
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#3896
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#3891
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?binary_operator_loc: Location, ?value: Prism::node, ?binary_operator: Symbol, ?location: Location) -> ClassVariableOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#3901
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ binary_operator: Symbol,
+ location: Prism::Location
+ ).returns(Prism::ClassVariableOperatorWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), binary_operator: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#3886
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, binary_operator_loc: Location, value: Prism::node, binary_operator: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#3909
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#139
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#3937
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#3914
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#3917
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # Returns the binary operator used to modify the receiver. This method is
+ # deprecated in favor of #binary_operator.
+ #
+ # source://prism//lib/prism/node_ext.rb#339
+ def operator; end
+
+ # Returns the location of the binary operator used to modify the receiver.
+ # This method is deprecated in favor of #binary_operator_loc.
+ #
+ # source://prism//lib/prism/node_ext.rb#346
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3955
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#3931
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#3965
+ def type; end
+ end
+end
+
+# Represents the use of the `||=` operator for assignment to a class variable.
+#
+# @@target ||= value
+# ^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#3985
+class Prism::ClassVariableOrWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [ClassVariableOrWriteNode] a new instance of ClassVariableOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#3987
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#4089
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#3997
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4002
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#4012
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#4007
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ClassVariableOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#4017
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::ClassVariableOrWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4002
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#4025
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#133
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#4055
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#4030
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#4033
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#4050
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#4040
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4073
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#4047
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4083
+ def type; end
+ end
+end
+
+# Represents referencing a class variable.
+#
+# @@foo
+# ^^^^^
+#
+# source://prism//lib/prism/node.rb#4102
+class Prism::ClassVariableReadNode < ::Prism::Node
+ # def initialize: (Symbol name, Location location) -> void
+ #
+ # @return [ClassVariableReadNode] a new instance of ClassVariableReadNode
+ #
+ # source://prism//lib/prism/node.rb#4104
+ sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void }
+ def initialize(source, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#4185
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#4111
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4116
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#4126
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#4121
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?location: Location) -> ClassVariableReadNode
+ #
+ # source://prism//lib/prism/node.rb#4131
+ sig { params(name: Symbol, location: Prism::Location).returns(Prism::ClassVariableReadNode) }
+ def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4116
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#4139
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#4151
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the class variable, which is a `@@` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers).
+ #
+ # @@abc # name `:@@abc`
+ #
+ # @@_test # name `:@@_test`
+ #
+ # source://prism//lib/prism/node.rb#4148
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4169
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4179
+ def type; end
+ end
+end
+
+# Represents writing to a class variable in a context that doesn't have an explicit value.
+#
+# @@foo, @@bar = baz
+# ^^^^^ ^^^^^
+#
+# source://prism//lib/prism/node.rb#4195
+class Prism::ClassVariableTargetNode < ::Prism::Node
+ # def initialize: (Symbol name, Location location) -> void
+ #
+ # @return [ClassVariableTargetNode] a new instance of ClassVariableTargetNode
+ #
+ # source://prism//lib/prism/node.rb#4197
+ sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void }
+ def initialize(source, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#4274
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#4204
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4209
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#4219
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#4214
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?location: Location) -> ClassVariableTargetNode
+ #
+ # source://prism//lib/prism/node.rb#4224
+ sig { params(name: Symbol, location: Prism::Location).returns(Prism::ClassVariableTargetNode) }
+ def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4209
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#4232
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#4240
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#4237
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4258
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4268
+ def type; end
+ end
+end
+
+# Represents writing to a class variable.
+#
+# @@foo = 1
+# ^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#4284
+class Prism::ClassVariableWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Prism::node value, Location operator_loc, Location location) -> void
+ #
+ # @return [ClassVariableWriteNode] a new instance of ClassVariableWriteNode
+ #
+ # source://prism//lib/prism/node.rb#4286
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, value, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#4404
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#4296
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4301
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#4311
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#4306
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?value: Prism::node, ?operator_loc: Location, ?location: Location) -> ClassVariableWriteNode
+ #
+ # source://prism//lib/prism/node.rb#4316
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::ClassVariableWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4301
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, value: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#4324
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#4370
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the class variable, which is a `@@` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers).
+ #
+ # @@abc = 123 # name `@@abc`
+ #
+ # @@_test = :test # name `@@_test`
+ #
+ # source://prism//lib/prism/node.rb#4333
+ sig { returns(Symbol) }
+ def name; end
+
+ # The location of the variable name.
+ #
+ # @@foo = :bar
+ # ^^^^^
+ #
+ # source://prism//lib/prism/node.rb#4339
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#4365
+ sig { returns(String) }
+ def operator; end
+
+ # The location of the `=` operator.
+ #
+ # @@foo = :bar
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#4358
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4388
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # The value to write to the class variable. This can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # @@foo = :bar
+ # ^^^^
+ #
+ # @@_xyz = 123
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#4352
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4398
+ def type; end
+ end
+end
+
+# This represents a comment that was encountered during parsing. It is the
+# base class for all comment types.
+#
+# source://prism//lib/prism/parse_result.rb#366
+class Prism::Comment
+ abstract!
+
+ # Create a new comment object with the given location.
+ #
+ # @return [Comment] a new instance of Comment
+ #
+ # source://prism//lib/prism/parse_result.rb#371
+ sig { params(location: Prism::Location).void }
+ def initialize(location); end
+
+ # Implement the hash pattern matching interface for Comment.
+ #
+ # source://prism//lib/prism/parse_result.rb#376
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # The location of this comment in the source.
+ #
+ # source://prism//lib/prism/parse_result.rb#368
+ sig { returns(Prism::Location) }
+ def location; end
+
+ # Returns the content of the comment by slicing it from the source code.
+ #
+ # source://prism//lib/prism/parse_result.rb#381
+ sig { returns(String) }
+ def slice; end
+
+ sig { abstract.returns(T::Boolean) }
+ def trailing?; end
+end
+
+# A compiler is a visitor that returns the value of each node as it visits.
+# This is as opposed to a visitor which will only walk the tree. This can be
+# useful when you are trying to compile a tree into a different format.
+#
+# For example, to build a representation of the tree as s-expressions, you
+# could write:
+#
+# class SExpressions < Prism::Compiler
+# def visit_arguments_node(node) = [:arguments, super]
+# def visit_call_node(node) = [:call, super]
+# def visit_integer_node(node) = [:integer]
+# def visit_program_node(node) = [:program, super]
+# end
+#
+# Prism.parse("1 + 2").value.accept(SExpressions.new)
+# # => [:program, [[[:call, [[:integer], [:arguments, [[:integer]]]]]]]]
+#
+# source://prism//lib/prism/compiler.rb#27
+class Prism::Compiler < ::Prism::Visitor
+ # Visit an individual node.
+ #
+ # source://prism//lib/prism/compiler.rb#29
+ sig { params(node: T.nilable(Prism::Node)).returns(T.untyped) }
+ def visit(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a AliasGlobalVariableNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_alias_global_variable_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a AliasMethodNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_alias_method_node(node); end
+
+ # Visit a list of nodes.
+ #
+ # source://prism//lib/prism/compiler.rb#34
+ sig { params(nodes: T::Array[T.nilable(Prism::Node)]).returns(T::Array[T.untyped]) }
+ def visit_all(nodes); end
+
+ # Visit the child nodes of the given node.
+ # Compile a AlternationPatternNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_alternation_pattern_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a AndNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_and_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ArgumentsNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_arguments_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ArrayNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_array_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ArrayPatternNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_array_pattern_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a AssocNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_assoc_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a AssocSplatNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_assoc_splat_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a BackReferenceReadNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_back_reference_read_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a BeginNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_begin_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a BlockArgumentNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_block_argument_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a BlockLocalVariableNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_block_local_variable_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a BlockNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_block_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a BlockParameterNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_block_parameter_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a BlockParametersNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_block_parameters_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a BreakNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_break_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a CallAndWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_call_and_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a CallNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_call_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a CallOperatorWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_call_operator_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a CallOrWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_call_or_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a CallTargetNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_call_target_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a CapturePatternNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_capture_pattern_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a CaseMatchNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_case_match_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a CaseNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_case_node(node); end
+
+ # Visit the child nodes of the given node.
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ sig { params(node: Prism::Node).returns(T::Array[T.untyped]) }
+ def visit_child_nodes(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ClassNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_class_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ClassVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_class_variable_and_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ClassVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_class_variable_operator_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ClassVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_class_variable_or_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ClassVariableReadNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_class_variable_read_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ClassVariableTargetNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_class_variable_target_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ClassVariableWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_class_variable_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantAndWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_and_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantOperatorWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_operator_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantOrWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_or_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantPathAndWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_path_and_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantPathNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_path_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantPathOperatorWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_path_operator_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantPathOrWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_path_or_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantPathTargetNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_path_target_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantPathWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_path_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantReadNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_read_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantTargetNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_target_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ConstantWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_constant_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a DefNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_def_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a DefinedNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_defined_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ElseNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_else_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a EmbeddedStatementsNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_embedded_statements_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a EmbeddedVariableNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_embedded_variable_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a EnsureNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_ensure_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a FalseNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_false_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a FindPatternNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_find_pattern_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a FlipFlopNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_flip_flop_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a FloatNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_float_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ForNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_for_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ForwardingArgumentsNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_forwarding_arguments_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ForwardingParameterNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_forwarding_parameter_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ForwardingSuperNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_forwarding_super_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a GlobalVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_global_variable_and_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a GlobalVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_global_variable_operator_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a GlobalVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_global_variable_or_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a GlobalVariableReadNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_global_variable_read_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a GlobalVariableTargetNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_global_variable_target_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a GlobalVariableWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_global_variable_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a HashNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_hash_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a HashPatternNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_hash_pattern_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a IfNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_if_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ImaginaryNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_imaginary_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ImplicitNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_implicit_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ImplicitRestNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_implicit_rest_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_in_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a IndexAndWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_index_and_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a IndexOperatorWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_index_operator_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a IndexOrWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_index_or_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a IndexTargetNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_index_target_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InstanceVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_instance_variable_and_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InstanceVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_instance_variable_operator_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InstanceVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_instance_variable_or_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InstanceVariableReadNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_instance_variable_read_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InstanceVariableTargetNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_instance_variable_target_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InstanceVariableWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_instance_variable_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a IntegerNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_integer_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InterpolatedMatchLastLineNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_interpolated_match_last_line_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InterpolatedRegularExpressionNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_interpolated_regular_expression_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InterpolatedStringNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_interpolated_string_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InterpolatedSymbolNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_interpolated_symbol_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a InterpolatedXStringNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_interpolated_x_string_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ItLocalVariableReadNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_it_local_variable_read_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ItParametersNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_it_parameters_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a KeywordHashNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_keyword_hash_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a KeywordRestParameterNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_keyword_rest_parameter_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a LambdaNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_lambda_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a LocalVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_local_variable_and_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a LocalVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_local_variable_operator_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a LocalVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_local_variable_or_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a LocalVariableReadNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_local_variable_read_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a LocalVariableTargetNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_local_variable_target_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a LocalVariableWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_local_variable_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a MatchLastLineNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_match_last_line_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a MatchPredicateNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_match_predicate_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a MatchRequiredNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_match_required_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a MatchWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_match_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a MissingNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_missing_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ModuleNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_module_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a MultiTargetNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_multi_target_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a MultiWriteNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_multi_write_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a NextNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_next_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a NilNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_nil_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a NoKeywordsParameterNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_no_keywords_parameter_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a NumberedParametersNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_numbered_parameters_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a NumberedReferenceReadNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_numbered_reference_read_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a OptionalKeywordParameterNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_optional_keyword_parameter_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a OptionalParameterNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_optional_parameter_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a OrNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_or_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ParametersNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_parameters_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ParenthesesNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_parentheses_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a PinnedExpressionNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_pinned_expression_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a PinnedVariableNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_pinned_variable_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a PostExecutionNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_post_execution_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a PreExecutionNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_pre_execution_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ProgramNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_program_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a RangeNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_range_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a RationalNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_rational_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a RedoNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_redo_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a RegularExpressionNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_regular_expression_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a RequiredKeywordParameterNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_required_keyword_parameter_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a RequiredParameterNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_required_parameter_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a RescueModifierNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_rescue_modifier_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a RescueNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_rescue_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a RestParameterNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_rest_parameter_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a RetryNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_retry_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ReturnNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_return_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a SelfNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_self_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a ShareableConstantNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_shareable_constant_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a SingletonClassNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_singleton_class_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a SourceEncodingNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_source_encoding_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a SourceFileNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_source_file_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a SourceLineNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_source_line_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a SplatNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_splat_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a StatementsNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_statements_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a StringNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_string_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a SuperNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_super_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a SymbolNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_symbol_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a TrueNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_true_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a UndefNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_undef_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a UnlessNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_unless_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a UntilNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_until_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a WhenNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_when_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a WhileNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_while_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a XStringNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_x_string_node(node); end
+
+ # Visit the child nodes of the given node.
+ # Compile a YieldNode node
+ #
+ # source://prism//lib/prism/compiler.rb#39
+ def visit_yield_node(node); end
+end
+
+# Represents the use of the `&&=` operator for assignment to a constant.
+#
+# Target &&= value
+# ^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#4417
+class Prism::ConstantAndWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [ConstantAndWriteNode] a new instance of ConstantAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#4419
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#4521
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#4429
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4434
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#4444
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#4439
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ConstantAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#4449
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::ConstantAndWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4434
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#4457
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#145
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#4487
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#4462
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#4465
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#4482
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#4472
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4505
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#4479
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4515
+ def type; end
+ end
+end
+
+# Represents assigning to a constant using an operator that isn't `=`.
+#
+# Target += value
+# ^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#4534
+class Prism::ConstantOperatorWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location binary_operator_loc, Prism::node value, Symbol binary_operator, Location location) -> void
+ #
+ # @return [ConstantOperatorWriteNode] a new instance of ConstantOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#4536
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ binary_operator: Symbol,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, binary_operator_loc, value, binary_operator, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#4637
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#4547
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader binary_operator: Symbol
+ #
+ # source://prism//lib/prism/node.rb#4600
+ sig { returns(Symbol) }
+ def binary_operator; end
+
+ # attr_reader binary_operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#4590
+ sig { returns(Prism::Location) }
+ def binary_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4552
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#4562
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#4557
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?binary_operator_loc: Location, ?value: Prism::node, ?binary_operator: Symbol, ?location: Location) -> ConstantOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#4567
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ binary_operator: Symbol,
+ location: Prism::Location
+ ).returns(Prism::ConstantOperatorWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), binary_operator: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4552
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, binary_operator_loc: Location, value: Prism::node, binary_operator: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#4575
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#157
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#4603
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#4580
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#4583
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # Returns the binary operator used to modify the receiver. This method is
+ # deprecated in favor of #binary_operator.
+ #
+ # source://prism//lib/prism/node_ext.rb#355
+ def operator; end
+
+ # Returns the location of the binary operator used to modify the receiver.
+ # This method is deprecated in favor of #binary_operator_loc.
+ #
+ # source://prism//lib/prism/node_ext.rb#362
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4621
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#4597
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4631
+ def type; end
+ end
+end
+
+# Represents the use of the `||=` operator for assignment to a constant.
+#
+# Target ||= value
+# ^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#4651
+class Prism::ConstantOrWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [ConstantOrWriteNode] a new instance of ConstantOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#4653
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#4755
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#4663
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4668
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#4678
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#4673
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ConstantOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#4683
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::ConstantOrWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4668
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#4691
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#151
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#4721
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#4696
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#4699
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#4716
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#4706
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4739
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#4713
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4749
+ def type; end
+ end
+end
+
+# Represents the use of the `&&=` operator for assignment to a constant path.
+#
+# Parent::Child &&= value
+# ^^^^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#4768
+class Prism::ConstantPathAndWriteNode < ::Prism::Node
+ # def initialize: (ConstantPathNode target, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [ConstantPathAndWriteNode] a new instance of ConstantPathAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#4770
+ sig do
+ params(
+ source: Prism::Source,
+ target: Prism::ConstantPathNode,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, target, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#4864
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#4779
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4784
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#4794
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#4789
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?target: ConstantPathNode, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ConstantPathAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#4799
+ sig do
+ params(
+ target: Prism::ConstantPathNode,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::ConstantPathAndWriteNode)
+ end
+ def copy(target: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4784
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { target: ConstantPathNode, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#4807
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#4830
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#4825
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#4815
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader target: ConstantPathNode
+ #
+ # source://prism//lib/prism/node.rb#4812
+ sig { returns(Prism::ConstantPathNode) }
+ def target; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4848
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#4822
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4858
+ def type; end
+ end
+end
+
+# Represents accessing a constant through a path of `::` operators.
+#
+# Foo::Bar
+# ^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#4876
+class Prism::ConstantPathNode < ::Prism::Node
+ # def initialize: (Prism::node? parent, Symbol? name, Location delimiter_loc, Location name_loc, Location location) -> void
+ #
+ # @return [ConstantPathNode] a new instance of ConstantPathNode
+ #
+ # source://prism//lib/prism/node.rb#4878
+ sig do
+ params(
+ source: Prism::Source,
+ parent: T.nilable(Prism::Node),
+ name: T.nilable(Symbol),
+ delimiter_loc: Prism::Location,
+ name_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, parent, name, delimiter_loc, name_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#5003
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#4888
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # Previously, we had a child node on this class that contained either a
+ # constant read or a missing node. To not cause a breaking change, we
+ # continue to supply that API.
+ #
+ # source://prism//lib/prism/node_ext.rb#196
+ def child; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4893
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#4905
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#4898
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?parent: Prism::node?, ?name: Symbol?, ?delimiter_loc: Location, ?name_loc: Location, ?location: Location) -> ConstantPathNode
+ #
+ # source://prism//lib/prism/node.rb#4910
+ sig do
+ params(
+ parent: T.nilable(Prism::Node),
+ name: T.nilable(Symbol),
+ delimiter_loc: Prism::Location,
+ name_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::ConstantPathNode)
+ end
+ def copy(parent: T.unsafe(nil), name: T.unsafe(nil), delimiter_loc: T.unsafe(nil), name_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#4893
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { parent: Prism::node?, name: Symbol?, delimiter_loc: Location, name_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#4918
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def delimiter: () -> String
+ #
+ # source://prism//lib/prism/node.rb#4964
+ sig { returns(String) }
+ def delimiter; end
+
+ # The location of the `::` delimiter.
+ #
+ # ::Foo
+ # ^^
+ #
+ # One::Two
+ # ^^
+ #
+ # source://prism//lib/prism/node.rb#4944
+ sig { returns(Prism::Location) }
+ def delimiter_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # Returns the full name of this constant path. For example: "Foo::Bar"
+ #
+ # source://prism//lib/prism/node_ext.rb#189
+ sig { returns(String) }
+ def full_name; end
+
+ # Returns the list of parts for the full name of this constant path.
+ # For example: [:Foo, :Bar]
+ #
+ # source://prism//lib/prism/node_ext.rb#167
+ sig { returns(T::Array[Symbol]) }
+ def full_name_parts; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#4969
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the constant being accessed. This could be `nil` in the event of a syntax error.
+ #
+ # source://prism//lib/prism/node.rb#4935
+ sig { returns(T.nilable(Symbol)) }
+ def name; end
+
+ # The location of the name of the constant.
+ #
+ # ::Foo
+ # ^^^
+ #
+ # One::Two
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#4957
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # The left-hand node of the path, if present. It can be `nil` or any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression). It will be `nil` when the constant lookup is at the root of the module tree.
+ #
+ # Foo::Bar
+ # ^^^
+ #
+ # self::Test
+ # ^^^^
+ #
+ # a.b::C
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#4932
+ sig { returns(T.nilable(Prism::Node)) }
+ def parent; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4987
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#4997
+ def type; end
+ end
+end
+
+# An error class raised when dynamic parts are found while computing a
+# constant path's full name. For example:
+# Foo::Bar::Baz -> does not raise because all parts of the constant path are
+# simple constants
+# var::Bar::Baz -> raises because the first part of the constant path is a
+# local variable
+#
+# source://prism//lib/prism/node_ext.rb#158
+class Prism::ConstantPathNode::DynamicPartsInConstantPathError < ::StandardError; end
+
+# An error class raised when missing nodes are found while computing a
+# constant path's full name. For example:
+# Foo:: -> raises because the constant path is missing the last part
+#
+# source://prism//lib/prism/node_ext.rb#163
+class Prism::ConstantPathNode::MissingNodesInConstantPathError < ::StandardError; end
+
+# Represents assigning to a constant path using an operator that isn't `=`.
+#
+# Parent::Child += value
+# ^^^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#5016
+class Prism::ConstantPathOperatorWriteNode < ::Prism::Node
+ # def initialize: (ConstantPathNode target, Location binary_operator_loc, Prism::node value, Symbol binary_operator, Location location) -> void
+ #
+ # @return [ConstantPathOperatorWriteNode] a new instance of ConstantPathOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#5018
+ sig do
+ params(
+ source: Prism::Source,
+ target: Prism::ConstantPathNode,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ binary_operator: Symbol,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, target, binary_operator_loc, value, binary_operator, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#5111
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#5028
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader binary_operator: Symbol
+ #
+ # source://prism//lib/prism/node.rb#5074
+ sig { returns(Symbol) }
+ def binary_operator; end
+
+ # attr_reader binary_operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#5064
+ sig { returns(Prism::Location) }
+ def binary_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5033
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#5043
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#5038
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?target: ConstantPathNode, ?binary_operator_loc: Location, ?value: Prism::node, ?binary_operator: Symbol, ?location: Location) -> ConstantPathOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#5048
+ sig do
+ params(
+ target: Prism::ConstantPathNode,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ binary_operator: Symbol,
+ location: Prism::Location
+ ).returns(Prism::ConstantPathOperatorWriteNode)
+ end
+ def copy(target: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), binary_operator: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5033
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { target: ConstantPathNode, binary_operator_loc: Location, value: Prism::node, binary_operator: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#5056
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#5077
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Returns the binary operator used to modify the receiver. This method is
+ # deprecated in favor of #binary_operator.
+ #
+ # source://prism//lib/prism/node_ext.rb#371
+ def operator; end
+
+ # Returns the location of the binary operator used to modify the receiver.
+ # This method is deprecated in favor of #binary_operator_loc.
+ #
+ # source://prism//lib/prism/node_ext.rb#378
+ def operator_loc; end
+
+ # attr_reader target: ConstantPathNode
+ #
+ # source://prism//lib/prism/node.rb#5061
+ sig { returns(Prism::ConstantPathNode) }
+ def target; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5095
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#5071
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5105
+ def type; end
+ end
+end
+
+# Represents the use of the `||=` operator for assignment to a constant path.
+#
+# Parent::Child ||= value
+# ^^^^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#5124
+class Prism::ConstantPathOrWriteNode < ::Prism::Node
+ # def initialize: (ConstantPathNode target, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [ConstantPathOrWriteNode] a new instance of ConstantPathOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#5126
+ sig do
+ params(
+ source: Prism::Source,
+ target: Prism::ConstantPathNode,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, target, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#5220
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#5135
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5140
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#5150
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#5145
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?target: ConstantPathNode, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ConstantPathOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#5155
+ sig do
+ params(
+ target: Prism::ConstantPathNode,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::ConstantPathOrWriteNode)
+ end
+ def copy(target: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5140
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { target: ConstantPathNode, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#5163
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#5186
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#5181
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#5171
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader target: ConstantPathNode
+ #
+ # source://prism//lib/prism/node.rb#5168
+ sig { returns(Prism::ConstantPathNode) }
+ def target; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5204
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#5178
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5214
+ def type; end
+ end
+end
+
+# Represents writing to a constant path in a context that doesn't have an explicit value.
+#
+# Foo::Foo, Bar::Bar = baz
+# ^^^^^^^^ ^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#5232
+class Prism::ConstantPathTargetNode < ::Prism::Node
+ # def initialize: (Prism::node? parent, Symbol? name, Location delimiter_loc, Location name_loc, Location location) -> void
+ #
+ # @return [ConstantPathTargetNode] a new instance of ConstantPathTargetNode
+ #
+ # source://prism//lib/prism/node.rb#5234
+ sig do
+ params(
+ source: Prism::Source,
+ parent: T.nilable(Prism::Node),
+ name: T.nilable(Symbol),
+ delimiter_loc: Prism::Location,
+ name_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, parent, name, delimiter_loc, name_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#5338
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#5244
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # Previously, we had a child node on this class that contained either a
+ # constant read or a missing node. To not cause a breaking change, we
+ # continue to supply that API.
+ #
+ # source://prism//lib/prism/node_ext.rb#232
+ def child; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5249
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#5261
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#5254
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?parent: Prism::node?, ?name: Symbol?, ?delimiter_loc: Location, ?name_loc: Location, ?location: Location) -> ConstantPathTargetNode
+ #
+ # source://prism//lib/prism/node.rb#5266
+ sig do
+ params(
+ parent: T.nilable(Prism::Node),
+ name: T.nilable(Symbol),
+ delimiter_loc: Prism::Location,
+ name_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::ConstantPathTargetNode)
+ end
+ def copy(parent: T.unsafe(nil), name: T.unsafe(nil), delimiter_loc: T.unsafe(nil), name_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5249
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { parent: Prism::node?, name: Symbol?, delimiter_loc: Location, name_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#5274
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def delimiter: () -> String
+ #
+ # source://prism//lib/prism/node.rb#5299
+ sig { returns(String) }
+ def delimiter; end
+
+ # attr_reader delimiter_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#5285
+ sig { returns(Prism::Location) }
+ def delimiter_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # Returns the full name of this constant path. For example: "Foo::Bar"
+ #
+ # source://prism//lib/prism/node_ext.rb#225
+ sig { returns(String) }
+ def full_name; end
+
+ # Returns the list of parts for the full name of this constant path.
+ # For example: [:Foo, :Bar]
+ #
+ # source://prism//lib/prism/node_ext.rb#205
+ sig { returns(T::Array[Symbol]) }
+ def full_name_parts; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#5304
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol?
+ #
+ # source://prism//lib/prism/node.rb#5282
+ sig { returns(T.nilable(Symbol)) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#5292
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # attr_reader parent: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#5279
+ sig { returns(T.nilable(Prism::Node)) }
+ def parent; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5322
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5332
+ def type; end
+ end
+end
+
+# Represents writing to a constant path.
+#
+# ::Foo = 1
+# ^^^^^^^^^
+#
+# Foo::Bar = 1
+# ^^^^^^^^^^^^
+#
+# ::Foo::Bar = 1
+# ^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#5357
+class Prism::ConstantPathWriteNode < ::Prism::Node
+ # def initialize: (ConstantPathNode target, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [ConstantPathWriteNode] a new instance of ConstantPathWriteNode
+ #
+ # source://prism//lib/prism/node.rb#5359
+ sig do
+ params(
+ source: Prism::Source,
+ target: Prism::ConstantPathNode,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, target, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#5465
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#5368
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5373
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#5383
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#5378
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?target: ConstantPathNode, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> ConstantPathWriteNode
+ #
+ # source://prism//lib/prism/node.rb#5388
+ sig do
+ params(
+ target: Prism::ConstantPathNode,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::ConstantPathWriteNode)
+ end
+ def copy(target: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5373
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { target: ConstantPathNode, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#5396
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#5431
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#5426
+ sig { returns(String) }
+ def operator; end
+
+ # The location of the `=` operator.
+ #
+ # ::ABC = 123
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#5413
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # A node representing the constant path being written to.
+ #
+ # Foo::Bar = 1
+ # ^^^^^^^^
+ #
+ # ::Foo = :abc
+ # ^^^^^
+ #
+ # source://prism//lib/prism/node.rb#5407
+ sig { returns(Prism::ConstantPathNode) }
+ def target; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5449
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # The value to write to the constant path. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # FOO::BAR = :abc
+ # ^^^^
+ #
+ # source://prism//lib/prism/node.rb#5423
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5459
+ def type; end
+ end
+end
+
+# Represents referencing a constant.
+#
+# Foo
+# ^^^
+#
+# source://prism//lib/prism/node.rb#5477
+class Prism::ConstantReadNode < ::Prism::Node
+ # def initialize: (Symbol name, Location location) -> void
+ #
+ # @return [ConstantReadNode] a new instance of ConstantReadNode
+ #
+ # source://prism//lib/prism/node.rb#5479
+ sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void }
+ def initialize(source, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#5560
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#5486
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5491
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#5501
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#5496
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?location: Location) -> ConstantReadNode
+ #
+ # source://prism//lib/prism/node.rb#5506
+ sig { params(name: Symbol, location: Prism::Location).returns(Prism::ConstantReadNode) }
+ def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5491
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#5514
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # Returns the full name of this constant. For example: "Foo"
+ #
+ # source://prism//lib/prism/node_ext.rb#133
+ sig { returns(String) }
+ def full_name; end
+
+ # Returns the list of parts for the full name of this constant.
+ # For example: [:Foo]
+ #
+ # source://prism//lib/prism/node_ext.rb#128
+ sig { returns(T::Array[Symbol]) }
+ def full_name_parts; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#5526
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the [constant](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#constants).
+ #
+ # X # name `:X`
+ #
+ # SOME_CONSTANT # name `:SOME_CONSTANT`
+ #
+ # source://prism//lib/prism/node.rb#5523
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5544
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5554
+ def type; end
+ end
+end
+
+# Represents writing to a constant in a context that doesn't have an explicit value.
+#
+# Foo, Bar = baz
+# ^^^ ^^^
+#
+# source://prism//lib/prism/node.rb#5570
+class Prism::ConstantTargetNode < ::Prism::Node
+ # def initialize: (Symbol name, Location location) -> void
+ #
+ # @return [ConstantTargetNode] a new instance of ConstantTargetNode
+ #
+ # source://prism//lib/prism/node.rb#5572
+ sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void }
+ def initialize(source, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#5649
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#5579
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5584
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#5594
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#5589
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?location: Location) -> ConstantTargetNode
+ #
+ # source://prism//lib/prism/node.rb#5599
+ sig { params(name: Symbol, location: Prism::Location).returns(Prism::ConstantTargetNode) }
+ def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5584
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#5607
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # Returns the full name of this constant. For example: "Foo"
+ #
+ # source://prism//lib/prism/node_ext.rb#246
+ sig { returns(String) }
+ def full_name; end
+
+ # Returns the list of parts for the full name of this constant.
+ # For example: [:Foo]
+ #
+ # source://prism//lib/prism/node_ext.rb#241
+ sig { returns(T::Array[Symbol]) }
+ def full_name_parts; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#5615
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#5612
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5633
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5643
+ def type; end
+ end
+end
+
+# Represents writing to a constant.
+#
+# Foo = 1
+# ^^^^^^^
+#
+# source://prism//lib/prism/node.rb#5659
+class Prism::ConstantWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Prism::node value, Location operator_loc, Location location) -> void
+ #
+ # @return [ConstantWriteNode] a new instance of ConstantWriteNode
+ #
+ # source://prism//lib/prism/node.rb#5661
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, value, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#5779
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#5671
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5676
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#5686
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#5681
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?value: Prism::node, ?operator_loc: Location, ?location: Location) -> ConstantWriteNode
+ #
+ # source://prism//lib/prism/node.rb#5691
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::ConstantWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5676
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, value: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#5699
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # Returns the full name of this constant. For example: "Foo"
+ #
+ # source://prism//lib/prism/node_ext.rb#146
+ sig { returns(String) }
+ def full_name; end
+
+ # Returns the list of parts for the full name of this constant.
+ # For example: [:Foo]
+ #
+ # source://prism//lib/prism/node_ext.rb#141
+ sig { returns(T::Array[Symbol]) }
+ def full_name_parts; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#5745
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the [constant](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#constants).
+ #
+ # Foo = :bar # name `:Foo`
+ #
+ # XYZ = 1 # name `:XYZ`
+ #
+ # source://prism//lib/prism/node.rb#5708
+ sig { returns(Symbol) }
+ def name; end
+
+ # The location of the constant name.
+ #
+ # FOO = 1
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#5714
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#5740
+ sig { returns(String) }
+ def operator; end
+
+ # The location of the `=` operator.
+ #
+ # FOO = :bar
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#5733
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5763
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # The value to write to the constant. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # FOO = :bar
+ # ^^^^
+ #
+ # MyClass = Class.new
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/node.rb#5727
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5773
+ def type; end
+ end
+end
+
+# The DSL module provides a set of methods that can be used to create prism
+# nodes in a more concise manner. For example, instead of writing:
+#
+# source = Prism::Source.for("[1]")
+#
+# Prism::ArrayNode.new(
+# [
+# Prism::IntegerNode.new(
+# Prism::IntegerBaseFlags::DECIMAL,
+# 1,
+# Prism::Location.new(source, 1, 1),
+# source
+# )
+# ],
+# Prism::Location.new(source, 0, 1),
+# Prism::Location.new(source, 2, 1),
+# source
+# )
+#
+# you could instead write:
+#
+# source = Prism::Source.for("[1]")
+#
+# ArrayNode(
+# IntegerNode(Prism::IntegerBaseFlags::DECIMAL, 1, Location(source, 1, 1)), source),
+# Location(source, 0, 1),
+# Location(source, 2, 1),
+# source
+# )
+#
+# This is mostly helpful in the context of writing tests, but can also be used
+# to generate trees programmatically.
+#
+# source://prism//lib/prism/dsl.rb#42
+module Prism::DSL
+ private
+
+ # Create a new AliasGlobalVariableNode node
+ #
+ # source://prism//lib/prism/dsl.rb#51
+ def AliasGlobalVariableNode(new_name, old_name, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new AliasMethodNode node
+ #
+ # source://prism//lib/prism/dsl.rb#56
+ def AliasMethodNode(new_name, old_name, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new AlternationPatternNode node
+ #
+ # source://prism//lib/prism/dsl.rb#61
+ def AlternationPatternNode(left, right, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new AndNode node
+ #
+ # source://prism//lib/prism/dsl.rb#66
+ def AndNode(left, right, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ArgumentsNode node
+ #
+ # source://prism//lib/prism/dsl.rb#71
+ def ArgumentsNode(flags, arguments, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ArrayNode node
+ #
+ # source://prism//lib/prism/dsl.rb#76
+ def ArrayNode(flags, elements, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ArrayPatternNode node
+ #
+ # source://prism//lib/prism/dsl.rb#81
+ def ArrayPatternNode(constant, requireds, rest, posts, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new AssocNode node
+ #
+ # source://prism//lib/prism/dsl.rb#86
+ def AssocNode(key, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new AssocSplatNode node
+ #
+ # source://prism//lib/prism/dsl.rb#91
+ def AssocSplatNode(value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new BackReferenceReadNode node
+ #
+ # source://prism//lib/prism/dsl.rb#96
+ def BackReferenceReadNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new BeginNode node
+ #
+ # source://prism//lib/prism/dsl.rb#101
+ def BeginNode(begin_keyword_loc, statements, rescue_clause, else_clause, ensure_clause, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new BlockArgumentNode node
+ #
+ # source://prism//lib/prism/dsl.rb#106
+ def BlockArgumentNode(expression, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new BlockLocalVariableNode node
+ #
+ # source://prism//lib/prism/dsl.rb#111
+ def BlockLocalVariableNode(flags, name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new BlockNode node
+ #
+ # source://prism//lib/prism/dsl.rb#116
+ def BlockNode(locals, parameters, body, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new BlockParameterNode node
+ #
+ # source://prism//lib/prism/dsl.rb#121
+ def BlockParameterNode(flags, name, name_loc, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new BlockParametersNode node
+ #
+ # source://prism//lib/prism/dsl.rb#126
+ def BlockParametersNode(parameters, locals, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new BreakNode node
+ #
+ # source://prism//lib/prism/dsl.rb#131
+ def BreakNode(arguments, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new CallAndWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#136
+ def CallAndWriteNode(flags, receiver, call_operator_loc, message_loc, read_name, write_name, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new CallNode node
+ #
+ # source://prism//lib/prism/dsl.rb#141
+ def CallNode(flags, receiver, call_operator_loc, name, message_loc, opening_loc, arguments, closing_loc, block, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new CallOperatorWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#146
+ def CallOperatorWriteNode(flags, receiver, call_operator_loc, message_loc, read_name, write_name, binary_operator, binary_operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new CallOrWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#151
+ def CallOrWriteNode(flags, receiver, call_operator_loc, message_loc, read_name, write_name, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new CallTargetNode node
+ #
+ # source://prism//lib/prism/dsl.rb#156
+ def CallTargetNode(flags, receiver, call_operator_loc, name, message_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new CapturePatternNode node
+ #
+ # source://prism//lib/prism/dsl.rb#161
+ def CapturePatternNode(value, target, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new CaseMatchNode node
+ #
+ # source://prism//lib/prism/dsl.rb#166
+ def CaseMatchNode(predicate, conditions, consequent, case_keyword_loc, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new CaseNode node
+ #
+ # source://prism//lib/prism/dsl.rb#171
+ def CaseNode(predicate, conditions, consequent, case_keyword_loc, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ClassNode node
+ #
+ # source://prism//lib/prism/dsl.rb#176
+ def ClassNode(locals, class_keyword_loc, constant_path, inheritance_operator_loc, superclass, body, end_keyword_loc, name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ClassVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#181
+ def ClassVariableAndWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ClassVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#186
+ def ClassVariableOperatorWriteNode(name, name_loc, binary_operator_loc, value, binary_operator, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ClassVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#191
+ def ClassVariableOrWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ClassVariableReadNode node
+ #
+ # source://prism//lib/prism/dsl.rb#196
+ def ClassVariableReadNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ClassVariableTargetNode node
+ #
+ # source://prism//lib/prism/dsl.rb#201
+ def ClassVariableTargetNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ClassVariableWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#206
+ def ClassVariableWriteNode(name, name_loc, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantAndWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#211
+ def ConstantAndWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantOperatorWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#216
+ def ConstantOperatorWriteNode(name, name_loc, binary_operator_loc, value, binary_operator, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantOrWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#221
+ def ConstantOrWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantPathAndWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#226
+ def ConstantPathAndWriteNode(target, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantPathNode node
+ #
+ # source://prism//lib/prism/dsl.rb#231
+ def ConstantPathNode(parent, name, delimiter_loc, name_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantPathOperatorWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#236
+ def ConstantPathOperatorWriteNode(target, binary_operator_loc, value, binary_operator, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantPathOrWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#241
+ def ConstantPathOrWriteNode(target, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantPathTargetNode node
+ #
+ # source://prism//lib/prism/dsl.rb#246
+ def ConstantPathTargetNode(parent, name, delimiter_loc, name_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantPathWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#251
+ def ConstantPathWriteNode(target, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantReadNode node
+ #
+ # source://prism//lib/prism/dsl.rb#256
+ def ConstantReadNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantTargetNode node
+ #
+ # source://prism//lib/prism/dsl.rb#261
+ def ConstantTargetNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ConstantWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#266
+ def ConstantWriteNode(name, name_loc, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new DefNode node
+ #
+ # source://prism//lib/prism/dsl.rb#271
+ def DefNode(name, name_loc, receiver, parameters, body, locals, def_keyword_loc, operator_loc, lparen_loc, rparen_loc, equal_loc, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new DefinedNode node
+ #
+ # source://prism//lib/prism/dsl.rb#276
+ def DefinedNode(lparen_loc, value, rparen_loc, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ElseNode node
+ #
+ # source://prism//lib/prism/dsl.rb#281
+ def ElseNode(else_keyword_loc, statements, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new EmbeddedStatementsNode node
+ #
+ # source://prism//lib/prism/dsl.rb#286
+ def EmbeddedStatementsNode(opening_loc, statements, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new EmbeddedVariableNode node
+ #
+ # source://prism//lib/prism/dsl.rb#291
+ def EmbeddedVariableNode(operator_loc, variable, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new EnsureNode node
+ #
+ # source://prism//lib/prism/dsl.rb#296
+ def EnsureNode(ensure_keyword_loc, statements, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new FalseNode node
+ #
+ # source://prism//lib/prism/dsl.rb#301
+ def FalseNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new FindPatternNode node
+ #
+ # source://prism//lib/prism/dsl.rb#306
+ def FindPatternNode(constant, left, requireds, right, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new FlipFlopNode node
+ #
+ # source://prism//lib/prism/dsl.rb#311
+ def FlipFlopNode(flags, left, right, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new FloatNode node
+ #
+ # source://prism//lib/prism/dsl.rb#316
+ def FloatNode(value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ForNode node
+ #
+ # source://prism//lib/prism/dsl.rb#321
+ def ForNode(index, collection, statements, for_keyword_loc, in_keyword_loc, do_keyword_loc, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ForwardingArgumentsNode node
+ #
+ # source://prism//lib/prism/dsl.rb#326
+ def ForwardingArgumentsNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ForwardingParameterNode node
+ #
+ # source://prism//lib/prism/dsl.rb#331
+ def ForwardingParameterNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ForwardingSuperNode node
+ #
+ # source://prism//lib/prism/dsl.rb#336
+ def ForwardingSuperNode(block, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new GlobalVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#341
+ def GlobalVariableAndWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new GlobalVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#346
+ def GlobalVariableOperatorWriteNode(name, name_loc, binary_operator_loc, value, binary_operator, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new GlobalVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#351
+ def GlobalVariableOrWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new GlobalVariableReadNode node
+ #
+ # source://prism//lib/prism/dsl.rb#356
+ def GlobalVariableReadNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new GlobalVariableTargetNode node
+ #
+ # source://prism//lib/prism/dsl.rb#361
+ def GlobalVariableTargetNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new GlobalVariableWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#366
+ def GlobalVariableWriteNode(name, name_loc, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new HashNode node
+ #
+ # source://prism//lib/prism/dsl.rb#371
+ def HashNode(opening_loc, elements, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new HashPatternNode node
+ #
+ # source://prism//lib/prism/dsl.rb#376
+ def HashPatternNode(constant, elements, rest, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new IfNode node
+ #
+ # source://prism//lib/prism/dsl.rb#381
+ def IfNode(if_keyword_loc, predicate, then_keyword_loc, statements, consequent, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ImaginaryNode node
+ #
+ # source://prism//lib/prism/dsl.rb#386
+ def ImaginaryNode(numeric, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ImplicitNode node
+ #
+ # source://prism//lib/prism/dsl.rb#391
+ def ImplicitNode(value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ImplicitRestNode node
+ #
+ # source://prism//lib/prism/dsl.rb#396
+ def ImplicitRestNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InNode node
+ #
+ # source://prism//lib/prism/dsl.rb#401
+ def InNode(pattern, statements, in_loc, then_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new IndexAndWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#406
+ def IndexAndWriteNode(flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new IndexOperatorWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#411
+ def IndexOperatorWriteNode(flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, binary_operator, binary_operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new IndexOrWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#416
+ def IndexOrWriteNode(flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new IndexTargetNode node
+ #
+ # source://prism//lib/prism/dsl.rb#421
+ def IndexTargetNode(flags, receiver, opening_loc, arguments, closing_loc, block, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InstanceVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#426
+ def InstanceVariableAndWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InstanceVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#431
+ def InstanceVariableOperatorWriteNode(name, name_loc, binary_operator_loc, value, binary_operator, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InstanceVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#436
+ def InstanceVariableOrWriteNode(name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InstanceVariableReadNode node
+ #
+ # source://prism//lib/prism/dsl.rb#441
+ def InstanceVariableReadNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InstanceVariableTargetNode node
+ #
+ # source://prism//lib/prism/dsl.rb#446
+ def InstanceVariableTargetNode(name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InstanceVariableWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#451
+ def InstanceVariableWriteNode(name, name_loc, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new IntegerNode node
+ #
+ # source://prism//lib/prism/dsl.rb#456
+ def IntegerNode(flags, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InterpolatedMatchLastLineNode node
+ #
+ # source://prism//lib/prism/dsl.rb#461
+ def InterpolatedMatchLastLineNode(flags, opening_loc, parts, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InterpolatedRegularExpressionNode node
+ #
+ # source://prism//lib/prism/dsl.rb#466
+ def InterpolatedRegularExpressionNode(flags, opening_loc, parts, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InterpolatedStringNode node
+ #
+ # source://prism//lib/prism/dsl.rb#471
+ def InterpolatedStringNode(flags, opening_loc, parts, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InterpolatedSymbolNode node
+ #
+ # source://prism//lib/prism/dsl.rb#476
+ def InterpolatedSymbolNode(opening_loc, parts, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new InterpolatedXStringNode node
+ #
+ # source://prism//lib/prism/dsl.rb#481
+ def InterpolatedXStringNode(opening_loc, parts, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ItLocalVariableReadNode node
+ #
+ # source://prism//lib/prism/dsl.rb#486
+ def ItLocalVariableReadNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ItParametersNode node
+ #
+ # source://prism//lib/prism/dsl.rb#491
+ def ItParametersNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new KeywordHashNode node
+ #
+ # source://prism//lib/prism/dsl.rb#496
+ def KeywordHashNode(flags, elements, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new KeywordRestParameterNode node
+ #
+ # source://prism//lib/prism/dsl.rb#501
+ def KeywordRestParameterNode(flags, name, name_loc, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new LambdaNode node
+ #
+ # source://prism//lib/prism/dsl.rb#506
+ def LambdaNode(locals, operator_loc, opening_loc, closing_loc, parameters, body, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new LocalVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#511
+ def LocalVariableAndWriteNode(name_loc, operator_loc, value, name, depth, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new LocalVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#516
+ def LocalVariableOperatorWriteNode(name_loc, binary_operator_loc, value, name, binary_operator, depth, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new LocalVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#521
+ def LocalVariableOrWriteNode(name_loc, operator_loc, value, name, depth, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new LocalVariableReadNode node
+ #
+ # source://prism//lib/prism/dsl.rb#526
+ def LocalVariableReadNode(name, depth, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new LocalVariableTargetNode node
+ #
+ # source://prism//lib/prism/dsl.rb#531
+ def LocalVariableTargetNode(name, depth, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new LocalVariableWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#536
+ def LocalVariableWriteNode(name, depth, name_loc, value, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new Location object
+ #
+ # source://prism//lib/prism/dsl.rb#46
+ def Location(source = T.unsafe(nil), start_offset = T.unsafe(nil), length = T.unsafe(nil)); end
+
+ # Create a new MatchLastLineNode node
+ #
+ # source://prism//lib/prism/dsl.rb#541
+ def MatchLastLineNode(flags, opening_loc, content_loc, closing_loc, unescaped, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new MatchPredicateNode node
+ #
+ # source://prism//lib/prism/dsl.rb#546
+ def MatchPredicateNode(value, pattern, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new MatchRequiredNode node
+ #
+ # source://prism//lib/prism/dsl.rb#551
+ def MatchRequiredNode(value, pattern, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new MatchWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#556
+ def MatchWriteNode(call, targets, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new MissingNode node
+ #
+ # source://prism//lib/prism/dsl.rb#561
+ def MissingNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ModuleNode node
+ #
+ # source://prism//lib/prism/dsl.rb#566
+ def ModuleNode(locals, module_keyword_loc, constant_path, body, end_keyword_loc, name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new MultiTargetNode node
+ #
+ # source://prism//lib/prism/dsl.rb#571
+ def MultiTargetNode(lefts, rest, rights, lparen_loc, rparen_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new MultiWriteNode node
+ #
+ # source://prism//lib/prism/dsl.rb#576
+ def MultiWriteNode(lefts, rest, rights, lparen_loc, rparen_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new NextNode node
+ #
+ # source://prism//lib/prism/dsl.rb#581
+ def NextNode(arguments, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new NilNode node
+ #
+ # source://prism//lib/prism/dsl.rb#586
+ def NilNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new NoKeywordsParameterNode node
+ #
+ # source://prism//lib/prism/dsl.rb#591
+ def NoKeywordsParameterNode(operator_loc, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new NumberedParametersNode node
+ #
+ # source://prism//lib/prism/dsl.rb#596
+ def NumberedParametersNode(maximum, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new NumberedReferenceReadNode node
+ #
+ # source://prism//lib/prism/dsl.rb#601
+ def NumberedReferenceReadNode(number, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new OptionalKeywordParameterNode node
+ #
+ # source://prism//lib/prism/dsl.rb#606
+ def OptionalKeywordParameterNode(flags, name, name_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new OptionalParameterNode node
+ #
+ # source://prism//lib/prism/dsl.rb#611
+ def OptionalParameterNode(flags, name, name_loc, operator_loc, value, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new OrNode node
+ #
+ # source://prism//lib/prism/dsl.rb#616
+ def OrNode(left, right, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ParametersNode node
+ #
+ # source://prism//lib/prism/dsl.rb#621
+ def ParametersNode(requireds, optionals, rest, posts, keywords, keyword_rest, block, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ParenthesesNode node
+ #
+ # source://prism//lib/prism/dsl.rb#626
+ def ParenthesesNode(body, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new PinnedExpressionNode node
+ #
+ # source://prism//lib/prism/dsl.rb#631
+ def PinnedExpressionNode(expression, operator_loc, lparen_loc, rparen_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new PinnedVariableNode node
+ #
+ # source://prism//lib/prism/dsl.rb#636
+ def PinnedVariableNode(variable, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new PostExecutionNode node
+ #
+ # source://prism//lib/prism/dsl.rb#641
+ def PostExecutionNode(statements, keyword_loc, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new PreExecutionNode node
+ #
+ # source://prism//lib/prism/dsl.rb#646
+ def PreExecutionNode(statements, keyword_loc, opening_loc, closing_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ProgramNode node
+ #
+ # source://prism//lib/prism/dsl.rb#651
+ def ProgramNode(locals, statements, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new RangeNode node
+ #
+ # source://prism//lib/prism/dsl.rb#656
+ def RangeNode(flags, left, right, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new RationalNode node
+ #
+ # source://prism//lib/prism/dsl.rb#661
+ def RationalNode(flags, numerator, denominator, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new RedoNode node
+ #
+ # source://prism//lib/prism/dsl.rb#666
+ def RedoNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new RegularExpressionNode node
+ #
+ # source://prism//lib/prism/dsl.rb#671
+ def RegularExpressionNode(flags, opening_loc, content_loc, closing_loc, unescaped, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new RequiredKeywordParameterNode node
+ #
+ # source://prism//lib/prism/dsl.rb#676
+ def RequiredKeywordParameterNode(flags, name, name_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new RequiredParameterNode node
+ #
+ # source://prism//lib/prism/dsl.rb#681
+ def RequiredParameterNode(flags, name, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new RescueModifierNode node
+ #
+ # source://prism//lib/prism/dsl.rb#686
+ def RescueModifierNode(expression, keyword_loc, rescue_expression, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new RescueNode node
+ #
+ # source://prism//lib/prism/dsl.rb#691
+ def RescueNode(keyword_loc, exceptions, operator_loc, reference, statements, consequent, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new RestParameterNode node
+ #
+ # source://prism//lib/prism/dsl.rb#696
+ def RestParameterNode(flags, name, name_loc, operator_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new RetryNode node
+ #
+ # source://prism//lib/prism/dsl.rb#701
+ def RetryNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ReturnNode node
+ #
+ # source://prism//lib/prism/dsl.rb#706
+ def ReturnNode(flags, keyword_loc, arguments, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new SelfNode node
+ #
+ # source://prism//lib/prism/dsl.rb#711
+ def SelfNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new ShareableConstantNode node
+ #
+ # source://prism//lib/prism/dsl.rb#716
+ def ShareableConstantNode(flags, write, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new SingletonClassNode node
+ #
+ # source://prism//lib/prism/dsl.rb#721
+ def SingletonClassNode(locals, class_keyword_loc, operator_loc, expression, body, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new SourceEncodingNode node
+ #
+ # source://prism//lib/prism/dsl.rb#726
+ def SourceEncodingNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new SourceFileNode node
+ #
+ # source://prism//lib/prism/dsl.rb#731
+ def SourceFileNode(flags, filepath, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new SourceLineNode node
+ #
+ # source://prism//lib/prism/dsl.rb#736
+ def SourceLineNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new SplatNode node
+ #
+ # source://prism//lib/prism/dsl.rb#741
+ def SplatNode(operator_loc, expression, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new StatementsNode node
+ #
+ # source://prism//lib/prism/dsl.rb#746
+ def StatementsNode(body, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new StringNode node
+ #
+ # source://prism//lib/prism/dsl.rb#751
+ def StringNode(flags, opening_loc, content_loc, closing_loc, unescaped, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new SuperNode node
+ #
+ # source://prism//lib/prism/dsl.rb#756
+ def SuperNode(keyword_loc, lparen_loc, arguments, rparen_loc, block, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new SymbolNode node
+ #
+ # source://prism//lib/prism/dsl.rb#761
+ def SymbolNode(flags, opening_loc, value_loc, closing_loc, unescaped, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new TrueNode node
+ #
+ # source://prism//lib/prism/dsl.rb#766
+ def TrueNode(source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new UndefNode node
+ #
+ # source://prism//lib/prism/dsl.rb#771
+ def UndefNode(names, keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new UnlessNode node
+ #
+ # source://prism//lib/prism/dsl.rb#776
+ def UnlessNode(keyword_loc, predicate, then_keyword_loc, statements, consequent, end_keyword_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new UntilNode node
+ #
+ # source://prism//lib/prism/dsl.rb#781
+ def UntilNode(flags, keyword_loc, closing_loc, predicate, statements, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new WhenNode node
+ #
+ # source://prism//lib/prism/dsl.rb#786
+ def WhenNode(keyword_loc, conditions, then_keyword_loc, statements, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new WhileNode node
+ #
+ # source://prism//lib/prism/dsl.rb#791
+ def WhileNode(flags, keyword_loc, closing_loc, predicate, statements, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new XStringNode node
+ #
+ # source://prism//lib/prism/dsl.rb#796
+ def XStringNode(flags, opening_loc, content_loc, closing_loc, unescaped, source = T.unsafe(nil), location = T.unsafe(nil)); end
+
+ # Create a new YieldNode node
+ #
+ # source://prism//lib/prism/dsl.rb#801
+ def YieldNode(keyword_loc, lparen_loc, arguments, rparen_loc, source = T.unsafe(nil), location = T.unsafe(nil)); end
+end
+
+# Represents a method definition.
+#
+# def method
+# end
+# ^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#5793
+class Prism::DefNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Prism::node? receiver, ParametersNode? parameters, Prism::node? body, Array[Symbol] locals, Location def_keyword_loc, Location? operator_loc, Location? lparen_loc, Location? rparen_loc, Location? equal_loc, Location? end_keyword_loc, Location location) -> void
+ #
+ # @return [DefNode] a new instance of DefNode
+ #
+ # source://prism//lib/prism/node.rb#5795
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ receiver: T.nilable(Prism::Node),
+ parameters: T.nilable(Prism::ParametersNode),
+ body: T.nilable(Prism::Node),
+ locals: T::Array[Symbol],
+ def_keyword_loc: Prism::Location,
+ operator_loc: T.nilable(Prism::Location),
+ lparen_loc: T.nilable(Prism::Location),
+ rparen_loc: T.nilable(Prism::Location),
+ equal_loc: T.nilable(Prism::Location),
+ end_keyword_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, receiver, parameters, body, locals, def_keyword_loc, operator_loc, lparen_loc, rparen_loc, equal_loc, end_keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#6008
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#5813
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader body: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#5866
+ sig { returns(T.nilable(Prism::Node)) }
+ def body; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5818
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#5832
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#5823
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?receiver: Prism::node?, ?parameters: ParametersNode?, ?body: Prism::node?, ?locals: Array[Symbol], ?def_keyword_loc: Location, ?operator_loc: Location?, ?lparen_loc: Location?, ?rparen_loc: Location?, ?equal_loc: Location?, ?end_keyword_loc: Location?, ?location: Location) -> DefNode
+ #
+ # source://prism//lib/prism/node.rb#5837
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ receiver: T.nilable(Prism::Node),
+ parameters: T.nilable(Prism::ParametersNode),
+ body: T.nilable(Prism::Node),
+ locals: T::Array[Symbol],
+ def_keyword_loc: Prism::Location,
+ operator_loc: T.nilable(Prism::Location),
+ lparen_loc: T.nilable(Prism::Location),
+ rparen_loc: T.nilable(Prism::Location),
+ equal_loc: T.nilable(Prism::Location),
+ end_keyword_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::DefNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), receiver: T.unsafe(nil), parameters: T.unsafe(nil), body: T.unsafe(nil), locals: T.unsafe(nil), def_keyword_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), lparen_loc: T.unsafe(nil), rparen_loc: T.unsafe(nil), equal_loc: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#5818
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, receiver: Prism::node?, parameters: ParametersNode?, body: Prism::node?, locals: Array[Symbol], def_keyword_loc: Location, operator_loc: Location?, lparen_loc: Location?, rparen_loc: Location?, equal_loc: Location?, end_keyword_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#5845
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def def_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#5944
+ sig { returns(String) }
+ def def_keyword; end
+
+ # attr_reader def_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#5872
+ sig { returns(Prism::Location) }
+ def def_keyword_loc; end
+
+ # def end_keyword: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#5969
+ sig { returns(T.nilable(String)) }
+ def end_keyword; end
+
+ # attr_reader end_keyword_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#5931
+ sig { returns(T.nilable(Prism::Location)) }
+ def end_keyword_loc; end
+
+ # def equal: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#5964
+ sig { returns(T.nilable(String)) }
+ def equal; end
+
+ # attr_reader equal_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#5918
+ sig { returns(T.nilable(Prism::Location)) }
+ def equal_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#5974
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader locals: Array[Symbol]
+ #
+ # source://prism//lib/prism/node.rb#5869
+ sig { returns(T::Array[Symbol]) }
+ def locals; end
+
+ # def lparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#5954
+ sig { returns(T.nilable(String)) }
+ def lparen; end
+
+ # attr_reader lparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#5892
+ sig { returns(T.nilable(Prism::Location)) }
+ def lparen_loc; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#5850
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#5853
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#5949
+ sig { returns(T.nilable(String)) }
+ def operator; end
+
+ # attr_reader operator_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#5879
+ sig { returns(T.nilable(Prism::Location)) }
+ def operator_loc; end
+
+ # attr_reader parameters: ParametersNode?
+ #
+ # source://prism//lib/prism/node.rb#5863
+ sig { returns(T.nilable(Prism::ParametersNode)) }
+ def parameters; end
+
+ # attr_reader receiver: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#5860
+ sig { returns(T.nilable(Prism::Node)) }
+ def receiver; end
+
+ # def rparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#5959
+ sig { returns(T.nilable(String)) }
+ def rparen; end
+
+ # attr_reader rparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#5905
+ sig { returns(T.nilable(Prism::Location)) }
+ def rparen_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#5992
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6002
+ def type; end
+ end
+end
+
+# Represents the use of the `defined?` keyword.
+#
+# defined?(a)
+# ^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#6030
+class Prism::DefinedNode < ::Prism::Node
+ # def initialize: (Location? lparen_loc, Prism::node value, Location? rparen_loc, Location keyword_loc, Location location) -> void
+ #
+ # @return [DefinedNode] a new instance of DefinedNode
+ #
+ # source://prism//lib/prism/node.rb#6032
+ sig do
+ params(
+ source: Prism::Source,
+ lparen_loc: T.nilable(Prism::Location),
+ value: Prism::Node,
+ rparen_loc: T.nilable(Prism::Location),
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, lparen_loc, value, rparen_loc, keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#6160
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#6042
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6047
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#6057
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#6052
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?lparen_loc: Location?, ?value: Prism::node, ?rparen_loc: Location?, ?keyword_loc: Location, ?location: Location) -> DefinedNode
+ #
+ # source://prism//lib/prism/node.rb#6062
+ sig do
+ params(
+ lparen_loc: T.nilable(Prism::Location),
+ value: Prism::Node,
+ rparen_loc: T.nilable(Prism::Location),
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::DefinedNode)
+ end
+ def copy(lparen_loc: T.unsafe(nil), value: T.unsafe(nil), rparen_loc: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6047
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { lparen_loc: Location?, value: Prism::node, rparen_loc: Location?, keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#6070
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#6126
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#6121
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#6104
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # def lparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#6111
+ sig { returns(T.nilable(String)) }
+ def lparen; end
+
+ # attr_reader lparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#6075
+ sig { returns(T.nilable(Prism::Location)) }
+ def lparen_loc; end
+
+ # def rparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#6116
+ sig { returns(T.nilable(String)) }
+ def rparen; end
+
+ # attr_reader rparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#6091
+ sig { returns(T.nilable(Prism::Location)) }
+ def rparen_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6144
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#6088
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6154
+ def type; end
+ end
+end
+
+# source://prism//lib/prism/desugar_compiler.rb#4
+class Prism::DesugarAndWriteNode
+ # @return [DesugarAndWriteNode] a new instance of DesugarAndWriteNode
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#7
+ def initialize(node, source, read_class, write_class, *arguments); end
+
+ # Returns the value of attribute arguments.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#5
+ def arguments; end
+
+ # Desugar `x &&= y` to `x && x = y`
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#16
+ def compile; end
+
+ # Returns the value of attribute node.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#5
+ def node; end
+
+ # Returns the value of attribute read_class.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#5
+ def read_class; end
+
+ # Returns the value of attribute source.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#5
+ def source; end
+
+ # Returns the value of attribute write_class.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#5
+ def write_class; end
+end
+
+# DesugarCompiler is a compiler that desugars Ruby code into a more primitive
+# form. This is useful for consumers that want to deal with fewer node types.
+#
+# source://prism//lib/prism/desugar_compiler.rb#218
+class Prism::DesugarCompiler < ::Prism::MutationCompiler
+ # @@foo &&= bar
+ #
+ # becomes
+ #
+ # @@foo && @@foo = bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#224
+ def visit_class_variable_and_write_node(node); end
+
+ # @@foo += bar
+ #
+ # becomes
+ #
+ # @@foo = @@foo + bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#242
+ def visit_class_variable_operator_write_node(node); end
+
+ # @@foo ||= bar
+ #
+ # becomes
+ #
+ # defined?(@@foo) ? @@foo : @@foo = bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#233
+ def visit_class_variable_or_write_node(node); end
+
+ # Foo &&= bar
+ #
+ # becomes
+ #
+ # Foo && Foo = bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#251
+ def visit_constant_and_write_node(node); end
+
+ # Foo += bar
+ #
+ # becomes
+ #
+ # Foo = Foo + bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#269
+ def visit_constant_operator_write_node(node); end
+
+ # Foo ||= bar
+ #
+ # becomes
+ #
+ # defined?(Foo) ? Foo : Foo = bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#260
+ def visit_constant_or_write_node(node); end
+
+ # $foo &&= bar
+ #
+ # becomes
+ #
+ # $foo && $foo = bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#278
+ def visit_global_variable_and_write_node(node); end
+
+ # $foo += bar
+ #
+ # becomes
+ #
+ # $foo = $foo + bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#296
+ def visit_global_variable_operator_write_node(node); end
+
+ # $foo ||= bar
+ #
+ # becomes
+ #
+ # defined?($foo) ? $foo : $foo = bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#287
+ def visit_global_variable_or_write_node(node); end
+
+ # becomes
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#305
+ def visit_instance_variable_and_write_node(node); end
+
+ # becomes
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#323
+ def visit_instance_variable_operator_write_node(node); end
+
+ # becomes
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#314
+ def visit_instance_variable_or_write_node(node); end
+
+ # foo &&= bar
+ #
+ # becomes
+ #
+ # foo && foo = bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#332
+ def visit_local_variable_and_write_node(node); end
+
+ # foo += bar
+ #
+ # becomes
+ #
+ # foo = foo + bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#350
+ def visit_local_variable_operator_write_node(node); end
+
+ # foo ||= bar
+ #
+ # becomes
+ #
+ # foo || foo = bar
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#341
+ def visit_local_variable_or_write_node(node); end
+end
+
+# source://prism//lib/prism/desugar_compiler.rb#63
+class Prism::DesugarOperatorWriteNode
+ # @return [DesugarOperatorWriteNode] a new instance of DesugarOperatorWriteNode
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#66
+ def initialize(node, source, read_class, write_class, *arguments); end
+
+ # Returns the value of attribute arguments.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#64
+ def arguments; end
+
+ # Desugar `x += y` to `x = x + y`
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#75
+ def compile; end
+
+ # Returns the value of attribute node.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#64
+ def node; end
+
+ # Returns the value of attribute read_class.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#64
+ def read_class; end
+
+ # Returns the value of attribute source.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#64
+ def source; end
+
+ # Returns the value of attribute write_class.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#64
+ def write_class; end
+end
+
+# source://prism//lib/prism/desugar_compiler.rb#27
+class Prism::DesugarOrWriteDefinedNode
+ # @return [DesugarOrWriteDefinedNode] a new instance of DesugarOrWriteDefinedNode
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#30
+ def initialize(node, source, read_class, write_class, *arguments); end
+
+ # Returns the value of attribute arguments.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#28
+ def arguments; end
+
+ # Desugar `x ||= y` to `defined?(x) ? x : x = y`
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#39
+ def compile; end
+
+ # Returns the value of attribute node.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#28
+ def node; end
+
+ # Returns the value of attribute read_class.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#28
+ def read_class; end
+
+ # Returns the value of attribute source.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#28
+ def source; end
+
+ # Returns the value of attribute write_class.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#28
+ def write_class; end
+end
+
+# source://prism//lib/prism/desugar_compiler.rb#101
+class Prism::DesugarOrWriteNode
+ # @return [DesugarOrWriteNode] a new instance of DesugarOrWriteNode
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#104
+ def initialize(node, source, read_class, write_class, *arguments); end
+
+ # Returns the value of attribute arguments.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#102
+ def arguments; end
+
+ # Desugar `x ||= y` to `x || x = y`
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#113
+ def compile; end
+
+ # Returns the value of attribute node.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#102
+ def node; end
+
+ # Returns the value of attribute read_class.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#102
+ def read_class; end
+
+ # Returns the value of attribute source.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#102
+ def source; end
+
+ # Returns the value of attribute write_class.
+ #
+ # source://prism//lib/prism/desugar_compiler.rb#102
+ def write_class; end
+end
+
+# The dispatcher class fires events for nodes that are found while walking an
+# AST to all registered listeners. It's useful for performing different types
+# of analysis on the AST while only having to walk the tree once.
+#
+# To use the dispatcher, you would first instantiate it and register listeners
+# for the events you're interested in:
+#
+# class OctalListener
+# def on_integer_node_enter(node)
+# if node.octal? && !node.slice.start_with?("0o")
+# warn("Octal integers should be written with the 0o prefix")
+# end
+# end
+# end
+#
+# dispatcher = Dispatcher.new
+# dispatcher.register(listener, :on_integer_node_enter)
+#
+# Then, you can walk any number of trees and dispatch events to the listeners:
+#
+# result = Prism.parse("001 + 002 + 003")
+# dispatcher.dispatch(result.value)
+#
+# Optionally, you can also use `#dispatch_once` to dispatch enter and leave
+# events for a single node without recursing further down the tree. This can
+# be useful in circumstances where you want to reuse the listeners you already
+# have registers but want to stop walking the tree at a certain point.
+#
+# integer = result.value.statements.body.first.receiver.receiver
+# dispatcher.dispatch_once(integer)
+#
+# source://prism//lib/prism/dispatcher.rb#41
+class Prism::Dispatcher < ::Prism::Visitor
+ # Initialize a new dispatcher.
+ #
+ # @return [Dispatcher] a new instance of Dispatcher
+ #
+ # source://prism//lib/prism/dispatcher.rb#46
+ def initialize; end
+
+ # Walks `root` dispatching events to all registered listeners.
+ #
+ # def dispatch: (Node) -> void
+ #
+ # source://prism//lib/prism/visitor.rb#17
+ def dispatch(node); end
+
+ # Dispatches a single event for `node` to all registered listeners.
+ #
+ # def dispatch_once: (Node) -> void
+ #
+ # source://prism//lib/prism/dispatcher.rb#65
+ def dispatch_once(node); end
+
+ # attr_reader listeners: Hash[Symbol, Array[Listener]]
+ #
+ # source://prism//lib/prism/dispatcher.rb#43
+ def listeners; end
+
+ # Register a listener for one or more events.
+ #
+ # def register: (Listener, *Symbol) -> void
+ #
+ # source://prism//lib/prism/dispatcher.rb#53
+ def register(listener, *events); end
+
+ # Dispatch enter and leave events for AliasGlobalVariableNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#71
+ def visit_alias_global_variable_node(node); end
+
+ # Dispatch enter and leave events for AliasMethodNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#79
+ def visit_alias_method_node(node); end
+
+ # Dispatch enter and leave events for AlternationPatternNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#87
+ def visit_alternation_pattern_node(node); end
+
+ # Dispatch enter and leave events for AndNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#95
+ def visit_and_node(node); end
+
+ # Dispatch enter and leave events for ArgumentsNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#103
+ def visit_arguments_node(node); end
+
+ # Dispatch enter and leave events for ArrayNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#111
+ def visit_array_node(node); end
+
+ # Dispatch enter and leave events for ArrayPatternNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#119
+ def visit_array_pattern_node(node); end
+
+ # Dispatch enter and leave events for AssocNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#127
+ def visit_assoc_node(node); end
+
+ # Dispatch enter and leave events for AssocSplatNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#135
+ def visit_assoc_splat_node(node); end
+
+ # Dispatch enter and leave events for BackReferenceReadNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#143
+ def visit_back_reference_read_node(node); end
+
+ # Dispatch enter and leave events for BeginNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#151
+ def visit_begin_node(node); end
+
+ # Dispatch enter and leave events for BlockArgumentNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#159
+ def visit_block_argument_node(node); end
+
+ # Dispatch enter and leave events for BlockLocalVariableNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#167
+ def visit_block_local_variable_node(node); end
+
+ # Dispatch enter and leave events for BlockNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#175
+ def visit_block_node(node); end
+
+ # Dispatch enter and leave events for BlockParameterNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#183
+ def visit_block_parameter_node(node); end
+
+ # Dispatch enter and leave events for BlockParametersNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#191
+ def visit_block_parameters_node(node); end
+
+ # Dispatch enter and leave events for BreakNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#199
+ def visit_break_node(node); end
+
+ # Dispatch enter and leave events for CallAndWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#207
+ def visit_call_and_write_node(node); end
+
+ # Dispatch enter and leave events for CallNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#215
+ def visit_call_node(node); end
+
+ # Dispatch enter and leave events for CallOperatorWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#223
+ def visit_call_operator_write_node(node); end
+
+ # Dispatch enter and leave events for CallOrWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#231
+ def visit_call_or_write_node(node); end
+
+ # Dispatch enter and leave events for CallTargetNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#239
+ def visit_call_target_node(node); end
+
+ # Dispatch enter and leave events for CapturePatternNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#247
+ def visit_capture_pattern_node(node); end
+
+ # Dispatch enter and leave events for CaseMatchNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#255
+ def visit_case_match_node(node); end
+
+ # Dispatch enter and leave events for CaseNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#263
+ def visit_case_node(node); end
+
+ # Dispatch enter and leave events for ClassNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#271
+ def visit_class_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableAndWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#279
+ def visit_class_variable_and_write_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableOperatorWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#287
+ def visit_class_variable_operator_write_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableOrWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#295
+ def visit_class_variable_or_write_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableReadNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#303
+ def visit_class_variable_read_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableTargetNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#311
+ def visit_class_variable_target_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#319
+ def visit_class_variable_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantAndWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#327
+ def visit_constant_and_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantOperatorWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#335
+ def visit_constant_operator_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantOrWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#343
+ def visit_constant_or_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathAndWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#351
+ def visit_constant_path_and_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#359
+ def visit_constant_path_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathOperatorWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#367
+ def visit_constant_path_operator_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathOrWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#375
+ def visit_constant_path_or_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathTargetNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#383
+ def visit_constant_path_target_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#391
+ def visit_constant_path_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantReadNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#399
+ def visit_constant_read_node(node); end
+
+ # Dispatch enter and leave events for ConstantTargetNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#407
+ def visit_constant_target_node(node); end
+
+ # Dispatch enter and leave events for ConstantWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#415
+ def visit_constant_write_node(node); end
+
+ # Dispatch enter and leave events for DefNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#423
+ def visit_def_node(node); end
+
+ # Dispatch enter and leave events for DefinedNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#431
+ def visit_defined_node(node); end
+
+ # Dispatch enter and leave events for ElseNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#439
+ def visit_else_node(node); end
+
+ # Dispatch enter and leave events for EmbeddedStatementsNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#447
+ def visit_embedded_statements_node(node); end
+
+ # Dispatch enter and leave events for EmbeddedVariableNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#455
+ def visit_embedded_variable_node(node); end
+
+ # Dispatch enter and leave events for EnsureNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#463
+ def visit_ensure_node(node); end
+
+ # Dispatch enter and leave events for FalseNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#471
+ def visit_false_node(node); end
+
+ # Dispatch enter and leave events for FindPatternNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#479
+ def visit_find_pattern_node(node); end
+
+ # Dispatch enter and leave events for FlipFlopNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#487
+ def visit_flip_flop_node(node); end
+
+ # Dispatch enter and leave events for FloatNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#495
+ def visit_float_node(node); end
+
+ # Dispatch enter and leave events for ForNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#503
+ def visit_for_node(node); end
+
+ # Dispatch enter and leave events for ForwardingArgumentsNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#511
+ def visit_forwarding_arguments_node(node); end
+
+ # Dispatch enter and leave events for ForwardingParameterNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#519
+ def visit_forwarding_parameter_node(node); end
+
+ # Dispatch enter and leave events for ForwardingSuperNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#527
+ def visit_forwarding_super_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableAndWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#535
+ def visit_global_variable_and_write_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableOperatorWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#543
+ def visit_global_variable_operator_write_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableOrWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#551
+ def visit_global_variable_or_write_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableReadNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#559
+ def visit_global_variable_read_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableTargetNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#567
+ def visit_global_variable_target_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#575
+ def visit_global_variable_write_node(node); end
+
+ # Dispatch enter and leave events for HashNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#583
+ def visit_hash_node(node); end
+
+ # Dispatch enter and leave events for HashPatternNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#591
+ def visit_hash_pattern_node(node); end
+
+ # Dispatch enter and leave events for IfNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#599
+ def visit_if_node(node); end
+
+ # Dispatch enter and leave events for ImaginaryNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#607
+ def visit_imaginary_node(node); end
+
+ # Dispatch enter and leave events for ImplicitNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#615
+ def visit_implicit_node(node); end
+
+ # Dispatch enter and leave events for ImplicitRestNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#623
+ def visit_implicit_rest_node(node); end
+
+ # Dispatch enter and leave events for InNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#631
+ def visit_in_node(node); end
+
+ # Dispatch enter and leave events for IndexAndWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#639
+ def visit_index_and_write_node(node); end
+
+ # Dispatch enter and leave events for IndexOperatorWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#647
+ def visit_index_operator_write_node(node); end
+
+ # Dispatch enter and leave events for IndexOrWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#655
+ def visit_index_or_write_node(node); end
+
+ # Dispatch enter and leave events for IndexTargetNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#663
+ def visit_index_target_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableAndWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#671
+ def visit_instance_variable_and_write_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableOperatorWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#679
+ def visit_instance_variable_operator_write_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableOrWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#687
+ def visit_instance_variable_or_write_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableReadNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#695
+ def visit_instance_variable_read_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableTargetNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#703
+ def visit_instance_variable_target_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#711
+ def visit_instance_variable_write_node(node); end
+
+ # Dispatch enter and leave events for IntegerNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#719
+ def visit_integer_node(node); end
+
+ # Dispatch enter and leave events for InterpolatedMatchLastLineNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#727
+ def visit_interpolated_match_last_line_node(node); end
+
+ # Dispatch enter and leave events for InterpolatedRegularExpressionNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#735
+ def visit_interpolated_regular_expression_node(node); end
+
+ # Dispatch enter and leave events for InterpolatedStringNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#743
+ def visit_interpolated_string_node(node); end
+
+ # Dispatch enter and leave events for InterpolatedSymbolNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#751
+ def visit_interpolated_symbol_node(node); end
+
+ # Dispatch enter and leave events for InterpolatedXStringNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#759
+ def visit_interpolated_x_string_node(node); end
+
+ # Dispatch enter and leave events for ItLocalVariableReadNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#767
+ def visit_it_local_variable_read_node(node); end
+
+ # Dispatch enter and leave events for ItParametersNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#775
+ def visit_it_parameters_node(node); end
+
+ # Dispatch enter and leave events for KeywordHashNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#783
+ def visit_keyword_hash_node(node); end
+
+ # Dispatch enter and leave events for KeywordRestParameterNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#791
+ def visit_keyword_rest_parameter_node(node); end
+
+ # Dispatch enter and leave events for LambdaNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#799
+ def visit_lambda_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableAndWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#807
+ def visit_local_variable_and_write_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableOperatorWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#815
+ def visit_local_variable_operator_write_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableOrWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#823
+ def visit_local_variable_or_write_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableReadNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#831
+ def visit_local_variable_read_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableTargetNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#839
+ def visit_local_variable_target_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#847
+ def visit_local_variable_write_node(node); end
+
+ # Dispatch enter and leave events for MatchLastLineNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#855
+ def visit_match_last_line_node(node); end
+
+ # Dispatch enter and leave events for MatchPredicateNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#863
+ def visit_match_predicate_node(node); end
+
+ # Dispatch enter and leave events for MatchRequiredNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#871
+ def visit_match_required_node(node); end
+
+ # Dispatch enter and leave events for MatchWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#879
+ def visit_match_write_node(node); end
+
+ # Dispatch enter and leave events for MissingNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#887
+ def visit_missing_node(node); end
+
+ # Dispatch enter and leave events for ModuleNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#895
+ def visit_module_node(node); end
+
+ # Dispatch enter and leave events for MultiTargetNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#903
+ def visit_multi_target_node(node); end
+
+ # Dispatch enter and leave events for MultiWriteNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#911
+ def visit_multi_write_node(node); end
+
+ # Dispatch enter and leave events for NextNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#919
+ def visit_next_node(node); end
+
+ # Dispatch enter and leave events for NilNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#927
+ def visit_nil_node(node); end
+
+ # Dispatch enter and leave events for NoKeywordsParameterNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#935
+ def visit_no_keywords_parameter_node(node); end
+
+ # Dispatch enter and leave events for NumberedParametersNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#943
+ def visit_numbered_parameters_node(node); end
+
+ # Dispatch enter and leave events for NumberedReferenceReadNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#951
+ def visit_numbered_reference_read_node(node); end
+
+ # Dispatch enter and leave events for OptionalKeywordParameterNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#959
+ def visit_optional_keyword_parameter_node(node); end
+
+ # Dispatch enter and leave events for OptionalParameterNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#967
+ def visit_optional_parameter_node(node); end
+
+ # Dispatch enter and leave events for OrNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#975
+ def visit_or_node(node); end
+
+ # Dispatch enter and leave events for ParametersNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#983
+ def visit_parameters_node(node); end
+
+ # Dispatch enter and leave events for ParenthesesNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#991
+ def visit_parentheses_node(node); end
+
+ # Dispatch enter and leave events for PinnedExpressionNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#999
+ def visit_pinned_expression_node(node); end
+
+ # Dispatch enter and leave events for PinnedVariableNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1007
+ def visit_pinned_variable_node(node); end
+
+ # Dispatch enter and leave events for PostExecutionNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1015
+ def visit_post_execution_node(node); end
+
+ # Dispatch enter and leave events for PreExecutionNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1023
+ def visit_pre_execution_node(node); end
+
+ # Dispatch enter and leave events for ProgramNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1031
+ def visit_program_node(node); end
+
+ # Dispatch enter and leave events for RangeNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1039
+ def visit_range_node(node); end
+
+ # Dispatch enter and leave events for RationalNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1047
+ def visit_rational_node(node); end
+
+ # Dispatch enter and leave events for RedoNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1055
+ def visit_redo_node(node); end
+
+ # Dispatch enter and leave events for RegularExpressionNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1063
+ def visit_regular_expression_node(node); end
+
+ # Dispatch enter and leave events for RequiredKeywordParameterNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1071
+ def visit_required_keyword_parameter_node(node); end
+
+ # Dispatch enter and leave events for RequiredParameterNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1079
+ def visit_required_parameter_node(node); end
+
+ # Dispatch enter and leave events for RescueModifierNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1087
+ def visit_rescue_modifier_node(node); end
+
+ # Dispatch enter and leave events for RescueNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1095
+ def visit_rescue_node(node); end
+
+ # Dispatch enter and leave events for RestParameterNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1103
+ def visit_rest_parameter_node(node); end
+
+ # Dispatch enter and leave events for RetryNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1111
+ def visit_retry_node(node); end
+
+ # Dispatch enter and leave events for ReturnNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1119
+ def visit_return_node(node); end
+
+ # Dispatch enter and leave events for SelfNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1127
+ def visit_self_node(node); end
+
+ # Dispatch enter and leave events for ShareableConstantNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1135
+ def visit_shareable_constant_node(node); end
+
+ # Dispatch enter and leave events for SingletonClassNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1143
+ def visit_singleton_class_node(node); end
+
+ # Dispatch enter and leave events for SourceEncodingNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1151
+ def visit_source_encoding_node(node); end
+
+ # Dispatch enter and leave events for SourceFileNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1159
+ def visit_source_file_node(node); end
+
+ # Dispatch enter and leave events for SourceLineNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1167
+ def visit_source_line_node(node); end
+
+ # Dispatch enter and leave events for SplatNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1175
+ def visit_splat_node(node); end
+
+ # Dispatch enter and leave events for StatementsNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1183
+ def visit_statements_node(node); end
+
+ # Dispatch enter and leave events for StringNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1191
+ def visit_string_node(node); end
+
+ # Dispatch enter and leave events for SuperNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1199
+ def visit_super_node(node); end
+
+ # Dispatch enter and leave events for SymbolNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1207
+ def visit_symbol_node(node); end
+
+ # Dispatch enter and leave events for TrueNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1215
+ def visit_true_node(node); end
+
+ # Dispatch enter and leave events for UndefNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1223
+ def visit_undef_node(node); end
+
+ # Dispatch enter and leave events for UnlessNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1231
+ def visit_unless_node(node); end
+
+ # Dispatch enter and leave events for UntilNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1239
+ def visit_until_node(node); end
+
+ # Dispatch enter and leave events for WhenNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1247
+ def visit_when_node(node); end
+
+ # Dispatch enter and leave events for WhileNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1255
+ def visit_while_node(node); end
+
+ # Dispatch enter and leave events for XStringNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1263
+ def visit_x_string_node(node); end
+
+ # Dispatch enter and leave events for YieldNode nodes and continue
+ # walking the tree.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1271
+ def visit_yield_node(node); end
+end
+
+# source://prism//lib/prism/dispatcher.rb#1277
+class Prism::Dispatcher::DispatchOnce < ::Prism::Visitor
+ # @return [DispatchOnce] a new instance of DispatchOnce
+ #
+ # source://prism//lib/prism/dispatcher.rb#1280
+ def initialize(listeners); end
+
+ # Returns the value of attribute listeners.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1278
+ def listeners; end
+
+ # Dispatch enter and leave events for AliasGlobalVariableNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1285
+ def visit_alias_global_variable_node(node); end
+
+ # Dispatch enter and leave events for AliasMethodNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1291
+ def visit_alias_method_node(node); end
+
+ # Dispatch enter and leave events for AlternationPatternNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1297
+ def visit_alternation_pattern_node(node); end
+
+ # Dispatch enter and leave events for AndNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1303
+ def visit_and_node(node); end
+
+ # Dispatch enter and leave events for ArgumentsNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1309
+ def visit_arguments_node(node); end
+
+ # Dispatch enter and leave events for ArrayNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1315
+ def visit_array_node(node); end
+
+ # Dispatch enter and leave events for ArrayPatternNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1321
+ def visit_array_pattern_node(node); end
+
+ # Dispatch enter and leave events for AssocNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1327
+ def visit_assoc_node(node); end
+
+ # Dispatch enter and leave events for AssocSplatNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1333
+ def visit_assoc_splat_node(node); end
+
+ # Dispatch enter and leave events for BackReferenceReadNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1339
+ def visit_back_reference_read_node(node); end
+
+ # Dispatch enter and leave events for BeginNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1345
+ def visit_begin_node(node); end
+
+ # Dispatch enter and leave events for BlockArgumentNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1351
+ def visit_block_argument_node(node); end
+
+ # Dispatch enter and leave events for BlockLocalVariableNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1357
+ def visit_block_local_variable_node(node); end
+
+ # Dispatch enter and leave events for BlockNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1363
+ def visit_block_node(node); end
+
+ # Dispatch enter and leave events for BlockParameterNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1369
+ def visit_block_parameter_node(node); end
+
+ # Dispatch enter and leave events for BlockParametersNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1375
+ def visit_block_parameters_node(node); end
+
+ # Dispatch enter and leave events for BreakNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1381
+ def visit_break_node(node); end
+
+ # Dispatch enter and leave events for CallAndWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1387
+ def visit_call_and_write_node(node); end
+
+ # Dispatch enter and leave events for CallNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1393
+ def visit_call_node(node); end
+
+ # Dispatch enter and leave events for CallOperatorWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1399
+ def visit_call_operator_write_node(node); end
+
+ # Dispatch enter and leave events for CallOrWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1405
+ def visit_call_or_write_node(node); end
+
+ # Dispatch enter and leave events for CallTargetNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1411
+ def visit_call_target_node(node); end
+
+ # Dispatch enter and leave events for CapturePatternNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1417
+ def visit_capture_pattern_node(node); end
+
+ # Dispatch enter and leave events for CaseMatchNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1423
+ def visit_case_match_node(node); end
+
+ # Dispatch enter and leave events for CaseNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1429
+ def visit_case_node(node); end
+
+ # Dispatch enter and leave events for ClassNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1435
+ def visit_class_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableAndWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1441
+ def visit_class_variable_and_write_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableOperatorWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1447
+ def visit_class_variable_operator_write_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableOrWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1453
+ def visit_class_variable_or_write_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableReadNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1459
+ def visit_class_variable_read_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableTargetNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1465
+ def visit_class_variable_target_node(node); end
+
+ # Dispatch enter and leave events for ClassVariableWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1471
+ def visit_class_variable_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantAndWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1477
+ def visit_constant_and_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantOperatorWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1483
+ def visit_constant_operator_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantOrWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1489
+ def visit_constant_or_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathAndWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1495
+ def visit_constant_path_and_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1501
+ def visit_constant_path_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathOperatorWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1507
+ def visit_constant_path_operator_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathOrWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1513
+ def visit_constant_path_or_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathTargetNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1519
+ def visit_constant_path_target_node(node); end
+
+ # Dispatch enter and leave events for ConstantPathWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1525
+ def visit_constant_path_write_node(node); end
+
+ # Dispatch enter and leave events for ConstantReadNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1531
+ def visit_constant_read_node(node); end
+
+ # Dispatch enter and leave events for ConstantTargetNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1537
+ def visit_constant_target_node(node); end
+
+ # Dispatch enter and leave events for ConstantWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1543
+ def visit_constant_write_node(node); end
+
+ # Dispatch enter and leave events for DefNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1549
+ def visit_def_node(node); end
+
+ # Dispatch enter and leave events for DefinedNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1555
+ def visit_defined_node(node); end
+
+ # Dispatch enter and leave events for ElseNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1561
+ def visit_else_node(node); end
+
+ # Dispatch enter and leave events for EmbeddedStatementsNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1567
+ def visit_embedded_statements_node(node); end
+
+ # Dispatch enter and leave events for EmbeddedVariableNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1573
+ def visit_embedded_variable_node(node); end
+
+ # Dispatch enter and leave events for EnsureNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1579
+ def visit_ensure_node(node); end
+
+ # Dispatch enter and leave events for FalseNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1585
+ def visit_false_node(node); end
+
+ # Dispatch enter and leave events for FindPatternNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1591
+ def visit_find_pattern_node(node); end
+
+ # Dispatch enter and leave events for FlipFlopNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1597
+ def visit_flip_flop_node(node); end
+
+ # Dispatch enter and leave events for FloatNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1603
+ def visit_float_node(node); end
+
+ # Dispatch enter and leave events for ForNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1609
+ def visit_for_node(node); end
+
+ # Dispatch enter and leave events for ForwardingArgumentsNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1615
+ def visit_forwarding_arguments_node(node); end
+
+ # Dispatch enter and leave events for ForwardingParameterNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1621
+ def visit_forwarding_parameter_node(node); end
+
+ # Dispatch enter and leave events for ForwardingSuperNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1627
+ def visit_forwarding_super_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableAndWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1633
+ def visit_global_variable_and_write_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableOperatorWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1639
+ def visit_global_variable_operator_write_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableOrWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1645
+ def visit_global_variable_or_write_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableReadNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1651
+ def visit_global_variable_read_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableTargetNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1657
+ def visit_global_variable_target_node(node); end
+
+ # Dispatch enter and leave events for GlobalVariableWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1663
+ def visit_global_variable_write_node(node); end
+
+ # Dispatch enter and leave events for HashNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1669
+ def visit_hash_node(node); end
+
+ # Dispatch enter and leave events for HashPatternNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1675
+ def visit_hash_pattern_node(node); end
+
+ # Dispatch enter and leave events for IfNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1681
+ def visit_if_node(node); end
+
+ # Dispatch enter and leave events for ImaginaryNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1687
+ def visit_imaginary_node(node); end
+
+ # Dispatch enter and leave events for ImplicitNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1693
+ def visit_implicit_node(node); end
+
+ # Dispatch enter and leave events for ImplicitRestNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1699
+ def visit_implicit_rest_node(node); end
+
+ # Dispatch enter and leave events for InNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1705
+ def visit_in_node(node); end
+
+ # Dispatch enter and leave events for IndexAndWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1711
+ def visit_index_and_write_node(node); end
+
+ # Dispatch enter and leave events for IndexOperatorWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1717
+ def visit_index_operator_write_node(node); end
+
+ # Dispatch enter and leave events for IndexOrWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1723
+ def visit_index_or_write_node(node); end
+
+ # Dispatch enter and leave events for IndexTargetNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1729
+ def visit_index_target_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableAndWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1735
+ def visit_instance_variable_and_write_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableOperatorWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1741
+ def visit_instance_variable_operator_write_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableOrWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1747
+ def visit_instance_variable_or_write_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableReadNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1753
+ def visit_instance_variable_read_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableTargetNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1759
+ def visit_instance_variable_target_node(node); end
+
+ # Dispatch enter and leave events for InstanceVariableWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1765
+ def visit_instance_variable_write_node(node); end
+
+ # Dispatch enter and leave events for IntegerNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1771
+ def visit_integer_node(node); end
+
+ # Dispatch enter and leave events for InterpolatedMatchLastLineNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1777
+ def visit_interpolated_match_last_line_node(node); end
+
+ # Dispatch enter and leave events for InterpolatedRegularExpressionNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1783
+ def visit_interpolated_regular_expression_node(node); end
+
+ # Dispatch enter and leave events for InterpolatedStringNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1789
+ def visit_interpolated_string_node(node); end
+
+ # Dispatch enter and leave events for InterpolatedSymbolNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1795
+ def visit_interpolated_symbol_node(node); end
+
+ # Dispatch enter and leave events for InterpolatedXStringNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1801
+ def visit_interpolated_x_string_node(node); end
+
+ # Dispatch enter and leave events for ItLocalVariableReadNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1807
+ def visit_it_local_variable_read_node(node); end
+
+ # Dispatch enter and leave events for ItParametersNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1813
+ def visit_it_parameters_node(node); end
+
+ # Dispatch enter and leave events for KeywordHashNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1819
+ def visit_keyword_hash_node(node); end
+
+ # Dispatch enter and leave events for KeywordRestParameterNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1825
+ def visit_keyword_rest_parameter_node(node); end
+
+ # Dispatch enter and leave events for LambdaNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1831
+ def visit_lambda_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableAndWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1837
+ def visit_local_variable_and_write_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableOperatorWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1843
+ def visit_local_variable_operator_write_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableOrWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1849
+ def visit_local_variable_or_write_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableReadNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1855
+ def visit_local_variable_read_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableTargetNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1861
+ def visit_local_variable_target_node(node); end
+
+ # Dispatch enter and leave events for LocalVariableWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1867
+ def visit_local_variable_write_node(node); end
+
+ # Dispatch enter and leave events for MatchLastLineNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1873
+ def visit_match_last_line_node(node); end
+
+ # Dispatch enter and leave events for MatchPredicateNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1879
+ def visit_match_predicate_node(node); end
+
+ # Dispatch enter and leave events for MatchRequiredNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1885
+ def visit_match_required_node(node); end
+
+ # Dispatch enter and leave events for MatchWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1891
+ def visit_match_write_node(node); end
+
+ # Dispatch enter and leave events for MissingNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1897
+ def visit_missing_node(node); end
+
+ # Dispatch enter and leave events for ModuleNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1903
+ def visit_module_node(node); end
+
+ # Dispatch enter and leave events for MultiTargetNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1909
+ def visit_multi_target_node(node); end
+
+ # Dispatch enter and leave events for MultiWriteNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1915
+ def visit_multi_write_node(node); end
+
+ # Dispatch enter and leave events for NextNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1921
+ def visit_next_node(node); end
+
+ # Dispatch enter and leave events for NilNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1927
+ def visit_nil_node(node); end
+
+ # Dispatch enter and leave events for NoKeywordsParameterNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1933
+ def visit_no_keywords_parameter_node(node); end
+
+ # Dispatch enter and leave events for NumberedParametersNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1939
+ def visit_numbered_parameters_node(node); end
+
+ # Dispatch enter and leave events for NumberedReferenceReadNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1945
+ def visit_numbered_reference_read_node(node); end
+
+ # Dispatch enter and leave events for OptionalKeywordParameterNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1951
+ def visit_optional_keyword_parameter_node(node); end
+
+ # Dispatch enter and leave events for OptionalParameterNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1957
+ def visit_optional_parameter_node(node); end
+
+ # Dispatch enter and leave events for OrNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1963
+ def visit_or_node(node); end
+
+ # Dispatch enter and leave events for ParametersNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1969
+ def visit_parameters_node(node); end
+
+ # Dispatch enter and leave events for ParenthesesNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1975
+ def visit_parentheses_node(node); end
+
+ # Dispatch enter and leave events for PinnedExpressionNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1981
+ def visit_pinned_expression_node(node); end
+
+ # Dispatch enter and leave events for PinnedVariableNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1987
+ def visit_pinned_variable_node(node); end
+
+ # Dispatch enter and leave events for PostExecutionNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1993
+ def visit_post_execution_node(node); end
+
+ # Dispatch enter and leave events for PreExecutionNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#1999
+ def visit_pre_execution_node(node); end
+
+ # Dispatch enter and leave events for ProgramNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2005
+ def visit_program_node(node); end
+
+ # Dispatch enter and leave events for RangeNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2011
+ def visit_range_node(node); end
+
+ # Dispatch enter and leave events for RationalNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2017
+ def visit_rational_node(node); end
+
+ # Dispatch enter and leave events for RedoNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2023
+ def visit_redo_node(node); end
+
+ # Dispatch enter and leave events for RegularExpressionNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2029
+ def visit_regular_expression_node(node); end
+
+ # Dispatch enter and leave events for RequiredKeywordParameterNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2035
+ def visit_required_keyword_parameter_node(node); end
+
+ # Dispatch enter and leave events for RequiredParameterNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2041
+ def visit_required_parameter_node(node); end
+
+ # Dispatch enter and leave events for RescueModifierNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2047
+ def visit_rescue_modifier_node(node); end
+
+ # Dispatch enter and leave events for RescueNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2053
+ def visit_rescue_node(node); end
+
+ # Dispatch enter and leave events for RestParameterNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2059
+ def visit_rest_parameter_node(node); end
+
+ # Dispatch enter and leave events for RetryNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2065
+ def visit_retry_node(node); end
+
+ # Dispatch enter and leave events for ReturnNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2071
+ def visit_return_node(node); end
+
+ # Dispatch enter and leave events for SelfNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2077
+ def visit_self_node(node); end
+
+ # Dispatch enter and leave events for ShareableConstantNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2083
+ def visit_shareable_constant_node(node); end
+
+ # Dispatch enter and leave events for SingletonClassNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2089
+ def visit_singleton_class_node(node); end
+
+ # Dispatch enter and leave events for SourceEncodingNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2095
+ def visit_source_encoding_node(node); end
+
+ # Dispatch enter and leave events for SourceFileNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2101
+ def visit_source_file_node(node); end
+
+ # Dispatch enter and leave events for SourceLineNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2107
+ def visit_source_line_node(node); end
+
+ # Dispatch enter and leave events for SplatNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2113
+ def visit_splat_node(node); end
+
+ # Dispatch enter and leave events for StatementsNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2119
+ def visit_statements_node(node); end
+
+ # Dispatch enter and leave events for StringNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2125
+ def visit_string_node(node); end
+
+ # Dispatch enter and leave events for SuperNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2131
+ def visit_super_node(node); end
+
+ # Dispatch enter and leave events for SymbolNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2137
+ def visit_symbol_node(node); end
+
+ # Dispatch enter and leave events for TrueNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2143
+ def visit_true_node(node); end
+
+ # Dispatch enter and leave events for UndefNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2149
+ def visit_undef_node(node); end
+
+ # Dispatch enter and leave events for UnlessNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2155
+ def visit_unless_node(node); end
+
+ # Dispatch enter and leave events for UntilNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2161
+ def visit_until_node(node); end
+
+ # Dispatch enter and leave events for WhenNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2167
+ def visit_when_node(node); end
+
+ # Dispatch enter and leave events for WhileNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2173
+ def visit_while_node(node); end
+
+ # Dispatch enter and leave events for XStringNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2179
+ def visit_x_string_node(node); end
+
+ # Dispatch enter and leave events for YieldNode nodes.
+ #
+ # source://prism//lib/prism/dispatcher.rb#2185
+ def visit_yield_node(node); end
+end
+
+# This visitor provides the ability to call Node#to_dot, which converts a
+# subtree into a graphviz dot graph.
+#
+# source://prism//lib/prism/dot_visitor.rb#14
+class Prism::DotVisitor < ::Prism::Visitor
+ # Initialize a new dot visitor.
+ #
+ # @return [DotVisitor] a new instance of DotVisitor
+ #
+ # source://prism//lib/prism/dot_visitor.rb#106
+ def initialize; end
+
+ # The digraph that is being built.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#103
+ def digraph; end
+
+ # Convert this visitor into a graphviz dot graph string.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#111
+ def to_dot; end
+
+ # Visit a AliasGlobalVariableNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#116
+ def visit_alias_global_variable_node(node); end
+
+ # Visit a AliasMethodNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#141
+ def visit_alias_method_node(node); end
+
+ # Visit a AlternationPatternNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#166
+ def visit_alternation_pattern_node(node); end
+
+ # Visit a AndNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#191
+ def visit_and_node(node); end
+
+ # Visit a ArgumentsNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#216
+ def visit_arguments_node(node); end
+
+ # Visit a ArrayNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#246
+ def visit_array_node(node); end
+
+ # Visit a ArrayPatternNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#286
+ def visit_array_pattern_node(node); end
+
+ # Visit a AssocNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#348
+ def visit_assoc_node(node); end
+
+ # Visit a AssocSplatNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#375
+ def visit_assoc_splat_node(node); end
+
+ # Visit a BackReferenceReadNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#398
+ def visit_back_reference_read_node(node); end
+
+ # Visit a BeginNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#415
+ def visit_begin_node(node); end
+
+ # Visit a BlockArgumentNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#463
+ def visit_block_argument_node(node); end
+
+ # Visit a BlockLocalVariableNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#486
+ def visit_block_local_variable_node(node); end
+
+ # Visit a BlockNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#506
+ def visit_block_node(node); end
+
+ # Visit a BlockParameterNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#541
+ def visit_block_parameter_node(node); end
+
+ # Visit a BlockParametersNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#569
+ def visit_block_parameters_node(node); end
+
+ # Visit a BreakNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#612
+ def visit_break_node(node); end
+
+ # Visit a CallAndWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#635
+ def visit_call_and_write_node(node); end
+
+ # Visit a CallNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#681
+ def visit_call_node(node); end
+
+ # Visit a CallOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#739
+ def visit_call_operator_write_node(node); end
+
+ # Visit a CallOrWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#788
+ def visit_call_or_write_node(node); end
+
+ # Visit a CallTargetNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#834
+ def visit_call_target_node(node); end
+
+ # Visit a CapturePatternNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#864
+ def visit_capture_pattern_node(node); end
+
+ # Visit a CaseMatchNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#889
+ def visit_case_match_node(node); end
+
+ # Visit a CaseNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#934
+ def visit_case_node(node); end
+
+ # Visit a ClassNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#979
+ def visit_class_node(node); end
+
+ # Visit a ClassVariableAndWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1026
+ def visit_class_variable_and_write_node(node); end
+
+ # Visit a ClassVariableOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1053
+ def visit_class_variable_operator_write_node(node); end
+
+ # Visit a ClassVariableOrWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1083
+ def visit_class_variable_or_write_node(node); end
+
+ # Visit a ClassVariableReadNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1110
+ def visit_class_variable_read_node(node); end
+
+ # Visit a ClassVariableTargetNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1127
+ def visit_class_variable_target_node(node); end
+
+ # Visit a ClassVariableWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1144
+ def visit_class_variable_write_node(node); end
+
+ # Visit a ConstantAndWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1171
+ def visit_constant_and_write_node(node); end
+
+ # Visit a ConstantOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1198
+ def visit_constant_operator_write_node(node); end
+
+ # Visit a ConstantOrWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1228
+ def visit_constant_or_write_node(node); end
+
+ # Visit a ConstantPathAndWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1255
+ def visit_constant_path_and_write_node(node); end
+
+ # Visit a ConstantPathNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1280
+ def visit_constant_path_node(node); end
+
+ # Visit a ConstantPathOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1309
+ def visit_constant_path_operator_write_node(node); end
+
+ # Visit a ConstantPathOrWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1337
+ def visit_constant_path_or_write_node(node); end
+
+ # Visit a ConstantPathTargetNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1362
+ def visit_constant_path_target_node(node); end
+
+ # Visit a ConstantPathWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1391
+ def visit_constant_path_write_node(node); end
+
+ # Visit a ConstantReadNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1416
+ def visit_constant_read_node(node); end
+
+ # Visit a ConstantTargetNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1433
+ def visit_constant_target_node(node); end
+
+ # Visit a ConstantWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1450
+ def visit_constant_write_node(node); end
+
+ # Visit a DefNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1477
+ def visit_def_node(node); end
+
+ # Visit a DefinedNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1546
+ def visit_defined_node(node); end
+
+ # Visit a ElseNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1577
+ def visit_else_node(node); end
+
+ # Visit a EmbeddedStatementsNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1605
+ def visit_embedded_statements_node(node); end
+
+ # Visit a EmbeddedVariableNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1631
+ def visit_embedded_variable_node(node); end
+
+ # Visit a EnsureNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1652
+ def visit_ensure_node(node); end
+
+ # Visit a FalseNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1678
+ def visit_false_node(node); end
+
+ # Visit a FindPatternNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1692
+ def visit_find_pattern_node(node); end
+
+ # Visit a FlipFlopNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1743
+ def visit_flip_flop_node(node); end
+
+ # Visit a FloatNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1775
+ def visit_float_node(node); end
+
+ # Visit a ForNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1792
+ def visit_for_node(node); end
+
+ # Visit a ForwardingArgumentsNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1834
+ def visit_forwarding_arguments_node(node); end
+
+ # Visit a ForwardingParameterNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1848
+ def visit_forwarding_parameter_node(node); end
+
+ # Visit a ForwardingSuperNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1862
+ def visit_forwarding_super_node(node); end
+
+ # Visit a GlobalVariableAndWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1882
+ def visit_global_variable_and_write_node(node); end
+
+ # Visit a GlobalVariableOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1909
+ def visit_global_variable_operator_write_node(node); end
+
+ # Visit a GlobalVariableOrWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1939
+ def visit_global_variable_or_write_node(node); end
+
+ # Visit a GlobalVariableReadNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1966
+ def visit_global_variable_read_node(node); end
+
+ # Visit a GlobalVariableTargetNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#1983
+ def visit_global_variable_target_node(node); end
+
+ # Visit a GlobalVariableWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2000
+ def visit_global_variable_write_node(node); end
+
+ # Visit a HashNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2027
+ def visit_hash_node(node); end
+
+ # Visit a HashPatternNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2060
+ def visit_hash_pattern_node(node); end
+
+ # Visit a IfNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2109
+ def visit_if_node(node); end
+
+ # Visit a ImaginaryNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2154
+ def visit_imaginary_node(node); end
+
+ # Visit a ImplicitNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2172
+ def visit_implicit_node(node); end
+
+ # Visit a ImplicitRestNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2190
+ def visit_implicit_rest_node(node); end
+
+ # Visit a InNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2204
+ def visit_in_node(node); end
+
+ # Visit a IndexAndWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2236
+ def visit_index_and_write_node(node); end
+
+ # Visit a IndexOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2289
+ def visit_index_operator_write_node(node); end
+
+ # Visit a IndexOrWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2345
+ def visit_index_or_write_node(node); end
+
+ # Visit a IndexTargetNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2398
+ def visit_index_target_node(node); end
+
+ # Visit a InstanceVariableAndWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2437
+ def visit_instance_variable_and_write_node(node); end
+
+ # Visit a InstanceVariableOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2464
+ def visit_instance_variable_operator_write_node(node); end
+
+ # Visit a InstanceVariableOrWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2494
+ def visit_instance_variable_or_write_node(node); end
+
+ # Visit a InstanceVariableReadNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2521
+ def visit_instance_variable_read_node(node); end
+
+ # Visit a InstanceVariableTargetNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2538
+ def visit_instance_variable_target_node(node); end
+
+ # Visit a InstanceVariableWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2555
+ def visit_instance_variable_write_node(node); end
+
+ # Visit a IntegerNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2582
+ def visit_integer_node(node); end
+
+ # Visit a InterpolatedMatchLastLineNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2602
+ def visit_interpolated_match_last_line_node(node); end
+
+ # Visit a InterpolatedRegularExpressionNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2638
+ def visit_interpolated_regular_expression_node(node); end
+
+ # Visit a InterpolatedStringNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2674
+ def visit_interpolated_string_node(node); end
+
+ # Visit a InterpolatedSymbolNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2714
+ def visit_interpolated_symbol_node(node); end
+
+ # Visit a InterpolatedXStringNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2751
+ def visit_interpolated_x_string_node(node); end
+
+ # Visit a ItLocalVariableReadNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2784
+ def visit_it_local_variable_read_node(node); end
+
+ # Visit a ItParametersNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2798
+ def visit_it_parameters_node(node); end
+
+ # Visit a KeywordHashNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2812
+ def visit_keyword_hash_node(node); end
+
+ # Visit a KeywordRestParameterNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2842
+ def visit_keyword_rest_parameter_node(node); end
+
+ # Visit a LambdaNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2870
+ def visit_lambda_node(node); end
+
+ # Visit a LocalVariableAndWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2908
+ def visit_local_variable_and_write_node(node); end
+
+ # Visit a LocalVariableOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2938
+ def visit_local_variable_operator_write_node(node); end
+
+ # Visit a LocalVariableOrWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#2971
+ def visit_local_variable_or_write_node(node); end
+
+ # Visit a LocalVariableReadNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3001
+ def visit_local_variable_read_node(node); end
+
+ # Visit a LocalVariableTargetNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3021
+ def visit_local_variable_target_node(node); end
+
+ # Visit a LocalVariableWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3041
+ def visit_local_variable_write_node(node); end
+
+ # Visit a MatchLastLineNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3071
+ def visit_match_last_line_node(node); end
+
+ # Visit a MatchPredicateNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3100
+ def visit_match_predicate_node(node); end
+
+ # Visit a MatchRequiredNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3125
+ def visit_match_required_node(node); end
+
+ # Visit a MatchWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3150
+ def visit_match_write_node(node); end
+
+ # Visit a MissingNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3181
+ def visit_missing_node(node); end
+
+ # Visit a ModuleNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3195
+ def visit_module_node(node); end
+
+ # Visit a MultiTargetNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3231
+ def visit_multi_target_node(node); end
+
+ # Visit a MultiWriteNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3287
+ def visit_multi_write_node(node); end
+
+ # Visit a NextNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3350
+ def visit_next_node(node); end
+
+ # Visit a NilNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3373
+ def visit_nil_node(node); end
+
+ # Visit a NoKeywordsParameterNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3387
+ def visit_no_keywords_parameter_node(node); end
+
+ # Visit a NumberedParametersNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3407
+ def visit_numbered_parameters_node(node); end
+
+ # Visit a NumberedReferenceReadNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3424
+ def visit_numbered_reference_read_node(node); end
+
+ # Visit a OptionalKeywordParameterNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3441
+ def visit_optional_keyword_parameter_node(node); end
+
+ # Visit a OptionalParameterNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3468
+ def visit_optional_parameter_node(node); end
+
+ # Visit a OrNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3498
+ def visit_or_node(node); end
+
+ # Visit a ParametersNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3523
+ def visit_parameters_node(node); end
+
+ # Visit a ParenthesesNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3607
+ def visit_parentheses_node(node); end
+
+ # Visit a PinnedExpressionNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3633
+ def visit_pinned_expression_node(node); end
+
+ # Visit a PinnedVariableNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3660
+ def visit_pinned_variable_node(node); end
+
+ # Visit a PostExecutionNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3681
+ def visit_post_execution_node(node); end
+
+ # Visit a PreExecutionNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3710
+ def visit_pre_execution_node(node); end
+
+ # Visit a ProgramNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3739
+ def visit_program_node(node); end
+
+ # Visit a RangeNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3760
+ def visit_range_node(node); end
+
+ # Visit a RationalNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3792
+ def visit_rational_node(node); end
+
+ # Visit a RedoNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3815
+ def visit_redo_node(node); end
+
+ # Visit a RegularExpressionNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3829
+ def visit_regular_expression_node(node); end
+
+ # Visit a RequiredKeywordParameterNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3858
+ def visit_required_keyword_parameter_node(node); end
+
+ # Visit a RequiredParameterNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3881
+ def visit_required_parameter_node(node); end
+
+ # Visit a RescueModifierNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3901
+ def visit_rescue_modifier_node(node); end
+
+ # Visit a RescueNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3926
+ def visit_rescue_node(node); end
+
+ # Visit a RestParameterNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#3979
+ def visit_rest_parameter_node(node); end
+
+ # Visit a RetryNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4007
+ def visit_retry_node(node); end
+
+ # Visit a ReturnNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4021
+ def visit_return_node(node); end
+
+ # Visit a SelfNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4047
+ def visit_self_node(node); end
+
+ # Visit a ShareableConstantNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4061
+ def visit_shareable_constant_node(node); end
+
+ # Visit a SingletonClassNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4082
+ def visit_singleton_class_node(node); end
+
+ # Visit a SourceEncodingNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4118
+ def visit_source_encoding_node(node); end
+
+ # Visit a SourceFileNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4132
+ def visit_source_file_node(node); end
+
+ # Visit a SourceLineNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4152
+ def visit_source_line_node(node); end
+
+ # Visit a SplatNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4166
+ def visit_splat_node(node); end
+
+ # Visit a StatementsNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4189
+ def visit_statements_node(node); end
+
+ # Visit a StringNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4216
+ def visit_string_node(node); end
+
+ # Visit a SuperNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4249
+ def visit_super_node(node); end
+
+ # Visit a SymbolNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4288
+ def visit_symbol_node(node); end
+
+ # Visit a TrueNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4323
+ def visit_true_node(node); end
+
+ # Visit a UndefNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4337
+ def visit_undef_node(node); end
+
+ # Visit a UnlessNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4367
+ def visit_unless_node(node); end
+
+ # Visit a UntilNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4410
+ def visit_until_node(node); end
+
+ # Visit a WhenNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4445
+ def visit_when_node(node); end
+
+ # Visit a WhileNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4486
+ def visit_while_node(node); end
+
+ # Visit a XStringNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4521
+ def visit_x_string_node(node); end
+
+ # Visit a YieldNode node.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4550
+ def visit_yield_node(node); end
+
+ private
+
+ # Inspect a node that has arguments_node_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4596
+ def arguments_node_flags_inspect(node); end
+
+ # Inspect a node that has array_node_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4605
+ def array_node_flags_inspect(node); end
+
+ # Inspect a node that has call_node_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4613
+ def call_node_flags_inspect(node); end
+
+ # Inspect a node that has encoding_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4624
+ def encoding_flags_inspect(node); end
+
+ # Inspect a node that has integer_base_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4633
+ def integer_base_flags_inspect(node); end
+
+ # Inspect a node that has interpolated_string_node_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4644
+ def interpolated_string_node_flags_inspect(node); end
+
+ # Inspect a node that has keyword_hash_node_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4653
+ def keyword_hash_node_flags_inspect(node); end
+
+ # Inspect a location to display the start and end line and column numbers.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4590
+ def location_inspect(location); end
+
+ # Inspect a node that has loop_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4661
+ def loop_flags_inspect(node); end
+
+ # Generate a unique node ID for a node throughout the digraph.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4585
+ def node_id(node); end
+
+ # Inspect a node that has parameter_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4669
+ def parameter_flags_inspect(node); end
+
+ # Inspect a node that has range_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4677
+ def range_flags_inspect(node); end
+
+ # Inspect a node that has regular_expression_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4685
+ def regular_expression_flags_inspect(node); end
+
+ # Inspect a node that has return_node_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4703
+ def return_node_flags_inspect(node); end
+
+ # Inspect a node that has shareable_constant_node_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4711
+ def shareable_constant_node_flags_inspect(node); end
+
+ # Inspect a node that has string_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4721
+ def string_flags_inspect(node); end
+
+ # Inspect a node that has symbol_flags flags to display the flags as a
+ # comma-separated list.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#4732
+ def symbol_flags_inspect(node); end
+end
+
+# source://prism//lib/prism/dot_visitor.rb#59
+class Prism::DotVisitor::Digraph
+ # @return [Digraph] a new instance of Digraph
+ #
+ # source://prism//lib/prism/dot_visitor.rb#62
+ def initialize; end
+
+ # source://prism//lib/prism/dot_visitor.rb#76
+ def edge(value); end
+
+ # Returns the value of attribute edges.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#60
+ def edges; end
+
+ # source://prism//lib/prism/dot_visitor.rb#68
+ def node(value); end
+
+ # Returns the value of attribute nodes.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#60
+ def nodes; end
+
+ # source://prism//lib/prism/dot_visitor.rb#80
+ def to_dot; end
+
+ # source://prism//lib/prism/dot_visitor.rb#72
+ def waypoint(value); end
+
+ # Returns the value of attribute waypoints.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#60
+ def waypoints; end
+end
+
+# source://prism//lib/prism/dot_visitor.rb#15
+class Prism::DotVisitor::Field
+ # @return [Field] a new instance of Field
+ #
+ # source://prism//lib/prism/dot_visitor.rb#18
+ def initialize(name, value, port); end
+
+ # Returns the value of attribute name.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#16
+ def name; end
+
+ # Returns the value of attribute port.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#16
+ def port; end
+
+ # source://prism//lib/prism/dot_visitor.rb#24
+ def to_dot; end
+
+ # Returns the value of attribute value.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#16
+ def value; end
+end
+
+# source://prism//lib/prism/dot_visitor.rb#33
+class Prism::DotVisitor::Table
+ # @return [Table] a new instance of Table
+ #
+ # source://prism//lib/prism/dot_visitor.rb#36
+ def initialize(name); end
+
+ # source://prism//lib/prism/dot_visitor.rb#41
+ def field(name, value = T.unsafe(nil), port: T.unsafe(nil)); end
+
+ # Returns the value of attribute fields.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#34
+ def fields; end
+
+ # Returns the value of attribute name.
+ #
+ # source://prism//lib/prism/dot_visitor.rb#34
+ def name; end
+
+ # source://prism//lib/prism/dot_visitor.rb#45
+ def to_dot; end
+end
+
+# Represents an `else` clause in a `case`, `if`, or `unless` statement.
+#
+# if a then b else c end
+# ^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#6173
+class Prism::ElseNode < ::Prism::Node
+ # def initialize: (Location else_keyword_loc, StatementsNode? statements, Location? end_keyword_loc, Location location) -> void
+ #
+ # @return [ElseNode] a new instance of ElseNode
+ #
+ # source://prism//lib/prism/node.rb#6175
+ sig do
+ params(
+ source: Prism::Source,
+ else_keyword_loc: Prism::Location,
+ statements: T.nilable(Prism::StatementsNode),
+ end_keyword_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, else_keyword_loc, statements, end_keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#6286
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#6184
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6189
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#6201
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#6194
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?else_keyword_loc: Location, ?statements: StatementsNode?, ?end_keyword_loc: Location?, ?location: Location) -> ElseNode
+ #
+ # source://prism//lib/prism/node.rb#6206
+ sig do
+ params(
+ else_keyword_loc: Prism::Location,
+ statements: T.nilable(Prism::StatementsNode),
+ end_keyword_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::ElseNode)
+ end
+ def copy(else_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6189
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { else_keyword_loc: Location, statements: StatementsNode?, end_keyword_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#6214
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def else_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#6242
+ sig { returns(String) }
+ def else_keyword; end
+
+ # attr_reader else_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#6219
+ sig { returns(Prism::Location) }
+ def else_keyword_loc; end
+
+ # def end_keyword: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#6247
+ sig { returns(T.nilable(String)) }
+ def end_keyword; end
+
+ # attr_reader end_keyword_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#6229
+ sig { returns(T.nilable(Prism::Location)) }
+ def end_keyword_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#6252
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader statements: StatementsNode?
+ #
+ # source://prism//lib/prism/node.rb#6226
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6270
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6280
+ def type; end
+ end
+end
+
+# EmbDocComment objects correspond to comments that are surrounded by =begin
+# and =end.
+#
+# source://prism//lib/prism/parse_result.rb#403
+class Prism::EmbDocComment < ::Prism::Comment
+ # Returns a string representation of this comment.
+ #
+ # source://prism//lib/prism/parse_result.rb#410
+ sig { returns(String) }
+ def inspect; end
+
+ # This can only be true for inline comments.
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/parse_result.rb#405
+ sig { override.returns(T::Boolean) }
+ def trailing?; end
+end
+
+# Represents an interpolated set of statements.
+#
+# "foo #{bar}"
+# ^^^^^^
+#
+# source://prism//lib/prism/node.rb#6298
+class Prism::EmbeddedStatementsNode < ::Prism::Node
+ # def initialize: (Location opening_loc, StatementsNode? statements, Location closing_loc, Location location) -> void
+ #
+ # @return [EmbeddedStatementsNode] a new instance of EmbeddedStatementsNode
+ #
+ # source://prism//lib/prism/node.rb#6300
+ sig do
+ params(
+ source: Prism::Source,
+ opening_loc: Prism::Location,
+ statements: T.nilable(Prism::StatementsNode),
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, opening_loc, statements, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#6405
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#6309
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6314
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#6366
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#6354
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#6326
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#6319
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?opening_loc: Location, ?statements: StatementsNode?, ?closing_loc: Location, ?location: Location) -> EmbeddedStatementsNode
+ #
+ # source://prism//lib/prism/node.rb#6331
+ sig do
+ params(
+ opening_loc: Prism::Location,
+ statements: T.nilable(Prism::StatementsNode),
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::EmbeddedStatementsNode)
+ end
+ def copy(opening_loc: T.unsafe(nil), statements: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6314
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { opening_loc: Location, statements: StatementsNode?, closing_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#6339
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#6371
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#6361
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#6344
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # attr_reader statements: StatementsNode?
+ #
+ # source://prism//lib/prism/node.rb#6351
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6389
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6399
+ def type; end
+ end
+end
+
+# Represents an interpolated variable.
+#
+# "foo #@bar"
+# ^^^^^
+#
+# source://prism//lib/prism/node.rb#6417
+class Prism::EmbeddedVariableNode < ::Prism::Node
+ # def initialize: (Location operator_loc, Prism::node variable, Location location) -> void
+ #
+ # @return [EmbeddedVariableNode] a new instance of EmbeddedVariableNode
+ #
+ # source://prism//lib/prism/node.rb#6419
+ sig do
+ params(
+ source: Prism::Source,
+ operator_loc: Prism::Location,
+ variable: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, operator_loc, variable, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#6509
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#6427
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6432
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#6442
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#6437
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?operator_loc: Location, ?variable: Prism::node, ?location: Location) -> EmbeddedVariableNode
+ #
+ # source://prism//lib/prism/node.rb#6447
+ sig do
+ params(
+ operator_loc: Prism::Location,
+ variable: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::EmbeddedVariableNode)
+ end
+ def copy(operator_loc: T.unsafe(nil), variable: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6432
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { operator_loc: Location, variable: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#6455
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#6475
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#6470
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#6460
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6493
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader variable: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#6467
+ sig { returns(Prism::Node) }
+ def variable; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6503
+ def type; end
+ end
+end
+
+# Flags for nodes that have unescaped content.
+#
+# source://prism//lib/prism/node.rb#19157
+module Prism::EncodingFlags; end
+
+# internal bytes forced the encoding to binary
+#
+# source://prism//lib/prism/node.rb#19162
+Prism::EncodingFlags::FORCED_BINARY_ENCODING = T.let(T.unsafe(nil), Integer)
+
+# internal bytes forced the encoding to UTF-8
+#
+# source://prism//lib/prism/node.rb#19159
+Prism::EncodingFlags::FORCED_UTF8_ENCODING = T.let(T.unsafe(nil), Integer)
+
+# Represents an `ensure` clause in a `begin` statement.
+#
+# begin
+# foo
+# ensure
+# ^^^^^^
+# bar
+# end
+#
+# source://prism//lib/prism/node.rb#6524
+class Prism::EnsureNode < ::Prism::Node
+ # def initialize: (Location ensure_keyword_loc, StatementsNode? statements, Location end_keyword_loc, Location location) -> void
+ #
+ # @return [EnsureNode] a new instance of EnsureNode
+ #
+ # source://prism//lib/prism/node.rb#6526
+ sig do
+ params(
+ source: Prism::Source,
+ ensure_keyword_loc: Prism::Location,
+ statements: T.nilable(Prism::StatementsNode),
+ end_keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, ensure_keyword_loc, statements, end_keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#6631
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#6535
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6540
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#6552
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#6545
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?ensure_keyword_loc: Location, ?statements: StatementsNode?, ?end_keyword_loc: Location, ?location: Location) -> EnsureNode
+ #
+ # source://prism//lib/prism/node.rb#6557
+ sig do
+ params(
+ ensure_keyword_loc: Prism::Location,
+ statements: T.nilable(Prism::StatementsNode),
+ end_keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::EnsureNode)
+ end
+ def copy(ensure_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6540
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { ensure_keyword_loc: Location, statements: StatementsNode?, end_keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#6565
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def end_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#6592
+ sig { returns(String) }
+ def end_keyword; end
+
+ # attr_reader end_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#6580
+ sig { returns(Prism::Location) }
+ def end_keyword_loc; end
+
+ # def ensure_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#6587
+ sig { returns(String) }
+ def ensure_keyword; end
+
+ # attr_reader ensure_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#6570
+ sig { returns(Prism::Location) }
+ def ensure_keyword_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#6597
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader statements: StatementsNode?
+ #
+ # source://prism//lib/prism/node.rb#6577
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6615
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6625
+ def type; end
+ end
+end
+
+# Represents the use of the literal `false` keyword.
+#
+# false
+# ^^^^^
+#
+# source://prism//lib/prism/node.rb#6643
+class Prism::FalseNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [FalseNode] a new instance of FalseNode
+ #
+ # source://prism//lib/prism/node.rb#6645
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#6718
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#6651
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6656
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#6666
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#6661
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> FalseNode
+ #
+ # source://prism//lib/prism/node.rb#6671
+ sig { params(location: Prism::Location).returns(Prism::FalseNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6656
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#6679
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#6684
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6702
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6712
+ def type; end
+ end
+end
+
+# Represents a find pattern in pattern matching.
+#
+# foo in *bar, baz, *qux
+# ^^^^^^^^^^^^^^^
+#
+# foo in [*bar, baz, *qux]
+# ^^^^^^^^^^^^^^^^^
+#
+# foo in Foo(*bar, baz, *qux)
+# ^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#6733
+class Prism::FindPatternNode < ::Prism::Node
+ # def initialize: (Prism::node? constant, Prism::node left, Array[Prism::node] requireds, Prism::node right, Location? opening_loc, Location? closing_loc, Location location) -> void
+ #
+ # @return [FindPatternNode] a new instance of FindPatternNode
+ #
+ # source://prism//lib/prism/node.rb#6735
+ sig do
+ params(
+ source: Prism::Source,
+ constant: T.nilable(Prism::Node),
+ left: Prism::Node,
+ requireds: T::Array[Prism::Node],
+ right: Prism::Node,
+ opening_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, constant, left, requireds, right, opening_loc, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#6867
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#6747
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6752
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#6828
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # attr_reader closing_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#6810
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#6767
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#6757
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # attr_reader constant: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#6785
+ sig { returns(T.nilable(Prism::Node)) }
+ def constant; end
+
+ # def copy: (?constant: Prism::node?, ?left: Prism::node, ?requireds: Array[Prism::node], ?right: Prism::node, ?opening_loc: Location?, ?closing_loc: Location?, ?location: Location) -> FindPatternNode
+ #
+ # source://prism//lib/prism/node.rb#6772
+ sig do
+ params(
+ constant: T.nilable(Prism::Node),
+ left: Prism::Node,
+ requireds: T::Array[Prism::Node],
+ right: Prism::Node,
+ opening_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::FindPatternNode)
+ end
+ def copy(constant: T.unsafe(nil), left: T.unsafe(nil), requireds: T.unsafe(nil), right: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6752
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { constant: Prism::node?, left: Prism::node, requireds: Array[Prism::node], right: Prism::node, opening_loc: Location?, closing_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#6780
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#6833
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader left: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#6788
+ sig { returns(Prism::Node) }
+ def left; end
+
+ # def opening: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#6823
+ sig { returns(T.nilable(String)) }
+ def opening; end
+
+ # attr_reader opening_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#6797
+ sig { returns(T.nilable(Prism::Location)) }
+ def opening_loc; end
+
+ # attr_reader requireds: Array[Prism::node]
+ #
+ # source://prism//lib/prism/node.rb#6791
+ sig { returns(T::Array[Prism::Node]) }
+ def requireds; end
+
+ # attr_reader right: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#6794
+ sig { returns(Prism::Node) }
+ def right; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6851
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6861
+ def type; end
+ end
+end
+
+# Represents the use of the `..` or `...` operators to create flip flops.
+#
+# baz if foo .. bar
+# ^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#6883
+class Prism::FlipFlopNode < ::Prism::Node
+ # def initialize: (Integer flags, Prism::node? left, Prism::node? right, Location operator_loc, Location location) -> void
+ #
+ # @return [FlipFlopNode] a new instance of FlipFlopNode
+ #
+ # source://prism//lib/prism/node.rb#6885
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ left: T.nilable(Prism::Node),
+ right: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, left, right, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#6992
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#6895
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6900
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#6913
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#6905
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?left: Prism::node?, ?right: Prism::node?, ?operator_loc: Location, ?location: Location) -> FlipFlopNode
+ #
+ # source://prism//lib/prism/node.rb#6918
+ sig do
+ params(
+ flags: Integer,
+ left: T.nilable(Prism::Node),
+ right: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::FlipFlopNode)
+ end
+ def copy(flags: T.unsafe(nil), left: T.unsafe(nil), right: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#6900
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, left: Prism::node?, right: Prism::node?, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#6926
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def exclude_end?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#6948
+ sig { returns(T::Boolean) }
+ def exclude_end?; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#6958
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader left: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#6935
+ sig { returns(T.nilable(Prism::Node)) }
+ def left; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#6953
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#6941
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader right: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#6938
+ sig { returns(T.nilable(Prism::Node)) }
+ def right; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6976
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#6931
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#6986
+ def type; end
+ end
+end
+
+# Represents a floating point number literal.
+#
+# 1.0
+# ^^^
+#
+# source://prism//lib/prism/node.rb#7005
+class Prism::FloatNode < ::Prism::Node
+ # def initialize: (Float value, Location location) -> void
+ #
+ # @return [FloatNode] a new instance of FloatNode
+ #
+ # source://prism//lib/prism/node.rb#7007
+ sig { params(source: Prism::Source, value: Float, location: Prism::Location).void }
+ def initialize(source, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#7084
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#7014
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7019
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#7029
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#7024
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?value: Float, ?location: Location) -> FloatNode
+ #
+ # source://prism//lib/prism/node.rb#7034
+ sig { params(value: Float, location: Prism::Location).returns(Prism::FloatNode) }
+ def copy(value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7019
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { value: Float, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#7042
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#7050
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7068
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # The value of the floating point number as a Float.
+ #
+ # source://prism//lib/prism/node.rb#7047
+ sig { returns(Float) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7078
+ def type; end
+ end
+end
+
+# Represents the use of the `for` keyword.
+#
+# for i in a end
+# ^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#7094
+class Prism::ForNode < ::Prism::Node
+ # def initialize: (Prism::node index, Prism::node collection, StatementsNode? statements, Location for_keyword_loc, Location in_keyword_loc, Location? do_keyword_loc, Location end_keyword_loc, Location location) -> void
+ #
+ # @return [ForNode] a new instance of ForNode
+ #
+ # source://prism//lib/prism/node.rb#7096
+ sig do
+ params(
+ source: Prism::Source,
+ index: Prism::Node,
+ collection: Prism::Node,
+ statements: T.nilable(Prism::StatementsNode),
+ for_keyword_loc: Prism::Location,
+ in_keyword_loc: Prism::Location,
+ do_keyword_loc: T.nilable(Prism::Location),
+ end_keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, index, collection, statements, for_keyword_loc, in_keyword_loc, do_keyword_loc, end_keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#7266
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#7109
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7114
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # The collection to iterate over.
+ #
+ # for i in a end
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#7155
+ sig { returns(Prism::Node) }
+ def collection; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#7128
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#7119
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?index: Prism::node, ?collection: Prism::node, ?statements: StatementsNode?, ?for_keyword_loc: Location, ?in_keyword_loc: Location, ?do_keyword_loc: Location?, ?end_keyword_loc: Location, ?location: Location) -> ForNode
+ #
+ # source://prism//lib/prism/node.rb#7133
+ sig do
+ params(
+ index: Prism::Node,
+ collection: Prism::Node,
+ statements: T.nilable(Prism::StatementsNode),
+ for_keyword_loc: Prism::Location,
+ in_keyword_loc: Prism::Location,
+ do_keyword_loc: T.nilable(Prism::Location),
+ end_keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::ForNode)
+ end
+ def copy(index: T.unsafe(nil), collection: T.unsafe(nil), statements: T.unsafe(nil), for_keyword_loc: T.unsafe(nil), in_keyword_loc: T.unsafe(nil), do_keyword_loc: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7114
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { index: Prism::node, collection: Prism::node, statements: StatementsNode?, for_keyword_loc: Location, in_keyword_loc: Location, do_keyword_loc: Location?, end_keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#7141
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def do_keyword: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#7222
+ sig { returns(T.nilable(String)) }
+ def do_keyword; end
+
+ # The location of the `do` keyword, if present.
+ #
+ # for i in a do end
+ # ^^
+ #
+ # source://prism//lib/prism/node.rb#7189
+ sig { returns(T.nilable(Prism::Location)) }
+ def do_keyword_loc; end
+
+ # def end_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#7227
+ sig { returns(String) }
+ def end_keyword; end
+
+ # The location of the `end` keyword.
+ #
+ # for i in a end
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#7205
+ sig { returns(Prism::Location) }
+ def end_keyword_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def for_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#7212
+ sig { returns(String) }
+ def for_keyword; end
+
+ # The location of the `for` keyword.
+ #
+ # for i in a end
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#7169
+ sig { returns(Prism::Location) }
+ def for_keyword_loc; end
+
+ # def in_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#7217
+ sig { returns(String) }
+ def in_keyword; end
+
+ # The location of the `in` keyword.
+ #
+ # for i in a end
+ # ^^
+ #
+ # source://prism//lib/prism/node.rb#7179
+ sig { returns(Prism::Location) }
+ def in_keyword_loc; end
+
+ # The index expression for `for` loops.
+ #
+ # for i in a end
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#7149
+ sig { returns(Prism::Node) }
+ def index; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#7232
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Represents the body of statements to execute for each iteration of the loop.
+ #
+ # for i in a
+ # foo(i)
+ # ^^^^^^
+ # end
+ #
+ # source://prism//lib/prism/node.rb#7163
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7250
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7260
+ def type; end
+ end
+end
+
+# Represents forwarding all arguments to this method to another method.
+#
+# def foo(...)
+# bar(...)
+# ^^^
+# end
+#
+# source://prism//lib/prism/node.rb#7284
+class Prism::ForwardingArgumentsNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [ForwardingArgumentsNode] a new instance of ForwardingArgumentsNode
+ #
+ # source://prism//lib/prism/node.rb#7286
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#7359
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#7292
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7297
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#7307
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#7302
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> ForwardingArgumentsNode
+ #
+ # source://prism//lib/prism/node.rb#7312
+ sig { params(location: Prism::Location).returns(Prism::ForwardingArgumentsNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7297
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#7320
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#7325
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7343
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7353
+ def type; end
+ end
+end
+
+# Represents the use of the forwarding parameter in a method, block, or lambda declaration.
+#
+# def foo(...)
+# ^^^
+# end
+#
+# source://prism//lib/prism/node.rb#7369
+class Prism::ForwardingParameterNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [ForwardingParameterNode] a new instance of ForwardingParameterNode
+ #
+ # source://prism//lib/prism/node.rb#7371
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#7444
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#7377
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7382
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#7392
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#7387
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> ForwardingParameterNode
+ #
+ # source://prism//lib/prism/node.rb#7397
+ sig { params(location: Prism::Location).returns(Prism::ForwardingParameterNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7382
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#7405
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#7410
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7428
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7438
+ def type; end
+ end
+end
+
+# Represents the use of the `super` keyword without parentheses or arguments.
+#
+# super
+# ^^^^^
+#
+# source://prism//lib/prism/node.rb#7453
+class Prism::ForwardingSuperNode < ::Prism::Node
+ # def initialize: (BlockNode? block, Location location) -> void
+ #
+ # @return [ForwardingSuperNode] a new instance of ForwardingSuperNode
+ #
+ # source://prism//lib/prism/node.rb#7455
+ sig { params(source: Prism::Source, block: T.nilable(Prism::BlockNode), location: Prism::Location).void }
+ def initialize(source, block, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#7534
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#7462
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader block: BlockNode?
+ #
+ # source://prism//lib/prism/node.rb#7497
+ sig { returns(T.nilable(Prism::BlockNode)) }
+ def block; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7467
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#7479
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#7472
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?block: BlockNode?, ?location: Location) -> ForwardingSuperNode
+ #
+ # source://prism//lib/prism/node.rb#7484
+ sig { params(block: T.nilable(Prism::BlockNode), location: Prism::Location).returns(Prism::ForwardingSuperNode) }
+ def copy(block: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7467
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { block: BlockNode?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#7492
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#7500
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7518
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7528
+ def type; end
+ end
+end
+
+# Represents the use of the `&&=` operator for assignment to a global variable.
+#
+# $target &&= value
+# ^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#7544
+class Prism::GlobalVariableAndWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [GlobalVariableAndWriteNode] a new instance of GlobalVariableAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#7546
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#7648
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#7556
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7561
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#7571
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#7566
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> GlobalVariableAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#7576
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::GlobalVariableAndWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7561
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#7584
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#163
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#7614
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#7589
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#7592
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#7609
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#7599
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7632
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#7606
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7642
+ def type; end
+ end
+end
+
+# Represents assigning to a global variable using an operator that isn't `=`.
+#
+# $target += value
+# ^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#7661
+class Prism::GlobalVariableOperatorWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location binary_operator_loc, Prism::node value, Symbol binary_operator, Location location) -> void
+ #
+ # @return [GlobalVariableOperatorWriteNode] a new instance of GlobalVariableOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#7663
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ binary_operator: Symbol,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, binary_operator_loc, value, binary_operator, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#7764
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#7674
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader binary_operator: Symbol
+ #
+ # source://prism//lib/prism/node.rb#7727
+ sig { returns(Symbol) }
+ def binary_operator; end
+
+ # attr_reader binary_operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#7717
+ sig { returns(Prism::Location) }
+ def binary_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7679
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#7689
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#7684
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?binary_operator_loc: Location, ?value: Prism::node, ?binary_operator: Symbol, ?location: Location) -> GlobalVariableOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#7694
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ binary_operator: Symbol,
+ location: Prism::Location
+ ).returns(Prism::GlobalVariableOperatorWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), binary_operator: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7679
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, binary_operator_loc: Location, value: Prism::node, binary_operator: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#7702
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#175
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#7730
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#7707
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#7710
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # Returns the binary operator used to modify the receiver. This method is
+ # deprecated in favor of #binary_operator.
+ #
+ # source://prism//lib/prism/node_ext.rb#387
+ def operator; end
+
+ # Returns the location of the binary operator used to modify the receiver.
+ # This method is deprecated in favor of #binary_operator_loc.
+ #
+ # source://prism//lib/prism/node_ext.rb#394
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7748
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#7724
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7758
+ def type; end
+ end
+end
+
+# Represents the use of the `||=` operator for assignment to a global variable.
+#
+# $target ||= value
+# ^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#7778
+class Prism::GlobalVariableOrWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [GlobalVariableOrWriteNode] a new instance of GlobalVariableOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#7780
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#7882
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#7790
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7795
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#7805
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#7800
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> GlobalVariableOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#7810
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::GlobalVariableOrWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7795
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#7818
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#169
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#7848
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#7823
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#7826
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#7843
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#7833
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7866
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#7840
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7876
+ def type; end
+ end
+end
+
+# Represents referencing a global variable.
+#
+# $foo
+# ^^^^
+#
+# source://prism//lib/prism/node.rb#7895
+class Prism::GlobalVariableReadNode < ::Prism::Node
+ # def initialize: (Symbol name, Location location) -> void
+ #
+ # @return [GlobalVariableReadNode] a new instance of GlobalVariableReadNode
+ #
+ # source://prism//lib/prism/node.rb#7897
+ sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void }
+ def initialize(source, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#7978
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#7904
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7909
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#7919
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#7914
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?location: Location) -> GlobalVariableReadNode
+ #
+ # source://prism//lib/prism/node.rb#7924
+ sig { params(name: Symbol, location: Prism::Location).returns(Prism::GlobalVariableReadNode) }
+ def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#7909
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#7932
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#7944
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the global variable, which is a `$` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifier). Alternatively, it can be one of the special global variables designated by a symbol.
+ #
+ # $foo # name `:$foo`
+ #
+ # $_Test # name `:$_Test`
+ #
+ # source://prism//lib/prism/node.rb#7941
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7962
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#7972
+ def type; end
+ end
+end
+
+# Represents writing to a global variable in a context that doesn't have an explicit value.
+#
+# $foo, $bar = baz
+# ^^^^ ^^^^
+#
+# source://prism//lib/prism/node.rb#7988
+class Prism::GlobalVariableTargetNode < ::Prism::Node
+ # def initialize: (Symbol name, Location location) -> void
+ #
+ # @return [GlobalVariableTargetNode] a new instance of GlobalVariableTargetNode
+ #
+ # source://prism//lib/prism/node.rb#7990
+ sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void }
+ def initialize(source, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#8067
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#7997
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8002
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#8012
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#8007
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?location: Location) -> GlobalVariableTargetNode
+ #
+ # source://prism//lib/prism/node.rb#8017
+ sig { params(name: Symbol, location: Prism::Location).returns(Prism::GlobalVariableTargetNode) }
+ def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8002
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#8025
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#8033
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#8030
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8051
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8061
+ def type; end
+ end
+end
+
+# Represents writing to a global variable.
+#
+# $foo = 1
+# ^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#8077
+class Prism::GlobalVariableWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Prism::node value, Location operator_loc, Location location) -> void
+ #
+ # @return [GlobalVariableWriteNode] a new instance of GlobalVariableWriteNode
+ #
+ # source://prism//lib/prism/node.rb#8079
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, value, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#8197
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#8089
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8094
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#8104
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#8099
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?value: Prism::node, ?operator_loc: Location, ?location: Location) -> GlobalVariableWriteNode
+ #
+ # source://prism//lib/prism/node.rb#8109
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::GlobalVariableWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8094
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, value: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#8117
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#8163
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the global variable, which is a `$` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifier). Alternatively, it can be one of the special global variables designated by a symbol.
+ #
+ # $foo = :bar # name `:$foo`
+ #
+ # $_Test = 123 # name `:$_Test`
+ #
+ # source://prism//lib/prism/node.rb#8126
+ sig { returns(Symbol) }
+ def name; end
+
+ # The location of the global variable's name.
+ #
+ # $foo = :bar
+ # ^^^^
+ #
+ # source://prism//lib/prism/node.rb#8132
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#8158
+ sig { returns(String) }
+ def operator; end
+
+ # The location of the `=` operator.
+ #
+ # $foo = :bar
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#8151
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8181
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # The value to write to the global variable. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # $foo = :bar
+ # ^^^^
+ #
+ # $-xyz = 123
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#8145
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8191
+ def type; end
+ end
+end
+
+# Represents a hash literal.
+#
+# { a => b }
+# ^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#8210
+class Prism::HashNode < ::Prism::Node
+ # def initialize: (Location opening_loc, Array[AssocNode | AssocSplatNode] elements, Location closing_loc, Location location) -> void
+ #
+ # @return [HashNode] a new instance of HashNode
+ #
+ # source://prism//lib/prism/node.rb#8212
+ sig do
+ params(
+ source: Prism::Source,
+ opening_loc: Prism::Location,
+ elements: T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)],
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, opening_loc, elements, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#8327
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#8221
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8226
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#8288
+ sig { returns(String) }
+ def closing; end
+
+ # The location of the closing brace.
+ #
+ # { a => b }
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#8276
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#8236
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#8231
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?opening_loc: Location, ?elements: Array[AssocNode | AssocSplatNode], ?closing_loc: Location, ?location: Location) -> HashNode
+ #
+ # source://prism//lib/prism/node.rb#8241
+ sig do
+ params(
+ opening_loc: Prism::Location,
+ elements: T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)],
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::HashNode)
+ end
+ def copy(opening_loc: T.unsafe(nil), elements: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8226
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { opening_loc: Location, elements: Array[AssocNode | AssocSplatNode], closing_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#8249
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # The elements of the hash. These can be either `AssocNode`s or `AssocSplatNode`s.
+ #
+ # { a: b }
+ # ^^^^
+ #
+ # { **foo }
+ # ^^^^^
+ #
+ # source://prism//lib/prism/node.rb#8270
+ sig { returns(T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)]) }
+ def elements; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#8293
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#8283
+ sig { returns(String) }
+ def opening; end
+
+ # The location of the opening brace.
+ #
+ # { a => b }
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#8257
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8311
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8321
+ def type; end
+ end
+end
+
+# Represents a hash pattern in pattern matching.
+#
+# foo => { a: 1, b: 2 }
+# ^^^^^^^^^^^^^^
+#
+# foo => { a: 1, b: 2, **c }
+# ^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#8343
+class Prism::HashPatternNode < ::Prism::Node
+ # def initialize: (Prism::node? constant, Array[AssocNode] elements, AssocSplatNode | NoKeywordsParameterNode | nil rest, Location? opening_loc, Location? closing_loc, Location location) -> void
+ #
+ # @return [HashPatternNode] a new instance of HashPatternNode
+ #
+ # source://prism//lib/prism/node.rb#8345
+ sig do
+ params(
+ source: Prism::Source,
+ constant: T.nilable(Prism::Node),
+ elements: T::Array[Prism::AssocNode],
+ rest: T.nilable(T.any(Prism::AssocSplatNode, Prism::NoKeywordsParameterNode)),
+ opening_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, constant, elements, rest, opening_loc, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#8472
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#8356
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8361
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#8433
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # attr_reader closing_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#8415
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#8375
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#8366
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # attr_reader constant: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#8393
+ sig { returns(T.nilable(Prism::Node)) }
+ def constant; end
+
+ # def copy: (?constant: Prism::node?, ?elements: Array[AssocNode], ?rest: AssocSplatNode | NoKeywordsParameterNode | nil, ?opening_loc: Location?, ?closing_loc: Location?, ?location: Location) -> HashPatternNode
+ #
+ # source://prism//lib/prism/node.rb#8380
+ sig do
+ params(
+ constant: T.nilable(Prism::Node),
+ elements: T::Array[Prism::AssocNode],
+ rest: T.nilable(T.any(Prism::AssocSplatNode, Prism::NoKeywordsParameterNode)),
+ opening_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::HashPatternNode)
+ end
+ def copy(constant: T.unsafe(nil), elements: T.unsafe(nil), rest: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8361
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { constant: Prism::node?, elements: Array[AssocNode], rest: AssocSplatNode | NoKeywordsParameterNode | nil, opening_loc: Location?, closing_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#8388
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader elements: Array[AssocNode]
+ #
+ # source://prism//lib/prism/node.rb#8396
+ sig { returns(T::Array[Prism::AssocNode]) }
+ def elements; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#8438
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def opening: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#8428
+ sig { returns(T.nilable(String)) }
+ def opening; end
+
+ # attr_reader opening_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#8402
+ sig { returns(T.nilable(Prism::Location)) }
+ def opening_loc; end
+
+ # attr_reader rest: AssocSplatNode | NoKeywordsParameterNode | nil
+ #
+ # source://prism//lib/prism/node.rb#8399
+ sig { returns(T.nilable(T.any(Prism::AssocSplatNode, Prism::NoKeywordsParameterNode))) }
+ def rest; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8456
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8466
+ def type; end
+ end
+end
+
+# source://prism//lib/prism/node_ext.rb#49
+module Prism::HeredocQuery
+ # Returns true if this node was represented as a heredoc in the source code.
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node_ext.rb#51
+ def heredoc?; end
+end
+
+# Represents the use of the `if` keyword, either in the block form or the modifier form, or a ternary expression.
+#
+# bar if foo
+# ^^^^^^^^^^
+#
+# if foo then bar end
+# ^^^^^^^^^^^^^^^^^^^
+#
+# foo ? bar : baz
+# ^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#8493
+class Prism::IfNode < ::Prism::Node
+ # def initialize: (Location? if_keyword_loc, Prism::node predicate, Location? then_keyword_loc, StatementsNode? statements, Prism::node? consequent, Location? end_keyword_loc, Location location) -> void
+ #
+ # @return [IfNode] a new instance of IfNode
+ #
+ # source://prism//lib/prism/node.rb#8495
+ sig do
+ params(
+ source: Prism::Source,
+ if_keyword_loc: T.nilable(Prism::Location),
+ predicate: Prism::Node,
+ then_keyword_loc: T.nilable(Prism::Location),
+ statements: T.nilable(Prism::StatementsNode),
+ consequent: T.nilable(Prism::Node),
+ end_keyword_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, if_keyword_loc, predicate, then_keyword_loc, statements, consequent, end_keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#8687
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#8507
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8512
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#8526
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#8517
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # Represents an `ElseNode` or an `IfNode` when there is an `else` or an `elsif` in the `if` statement.
+ #
+ # if foo
+ # bar
+ # elsif baz
+ # ^^^^^^^^^
+ # qux
+ # ^^^
+ # end
+ # ^^^
+ #
+ # if foo then bar else baz end
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/node.rb#8617
+ sig { returns(T.nilable(Prism::Node)) }
+ def consequent; end
+
+ # def copy: (?if_keyword_loc: Location?, ?predicate: Prism::node, ?then_keyword_loc: Location?, ?statements: StatementsNode?, ?consequent: Prism::node?, ?end_keyword_loc: Location?, ?location: Location) -> IfNode
+ #
+ # source://prism//lib/prism/node.rb#8531
+ sig do
+ params(
+ if_keyword_loc: T.nilable(Prism::Location),
+ predicate: Prism::Node,
+ then_keyword_loc: T.nilable(Prism::Location),
+ statements: T.nilable(Prism::StatementsNode),
+ consequent: T.nilable(Prism::Node),
+ end_keyword_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::IfNode)
+ end
+ def copy(if_keyword_loc: T.unsafe(nil), predicate: T.unsafe(nil), then_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), consequent: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8512
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { if_keyword_loc: Location?, predicate: Prism::node, then_keyword_loc: Location?, statements: StatementsNode?, consequent: Prism::node?, end_keyword_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#8539
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def end_keyword: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#8648
+ sig { returns(T.nilable(String)) }
+ def end_keyword; end
+
+ # The location of the `end` keyword if present, `nil` otherwise.
+ #
+ # if foo
+ # bar
+ # end
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#8625
+ sig { returns(T.nilable(Prism::Location)) }
+ def end_keyword_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def if_keyword: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#8638
+ sig { returns(T.nilable(String)) }
+ def if_keyword; end
+
+ # The location of the `if` keyword if present.
+ #
+ # bar if foo
+ # ^^
+ #
+ # The `if_keyword_loc` field will be `nil` when the `IfNode` represents a ternary expression.
+ #
+ # source://prism//lib/prism/node.rb#8549
+ sig { returns(T.nilable(Prism::Location)) }
+ def if_keyword_loc; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#8653
+ sig { override.returns(String) }
+ def inspect; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#91
+ def newline!(lines); end
+
+ # The node for the condition the `IfNode` is testing.
+ #
+ # if foo
+ # ^^^
+ # bar
+ # end
+ #
+ # bar if foo
+ # ^^^
+ #
+ # foo ? bar : baz
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#8573
+ sig { returns(Prism::Node) }
+ def predicate; end
+
+ # Represents the body of statements that will be executed when the predicate is evaluated as truthy. Will be `nil` when no body is provided.
+ #
+ # if foo
+ # bar
+ # ^^^
+ # baz
+ # ^^^
+ # end
+ #
+ # source://prism//lib/prism/node.rb#8602
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # def then_keyword: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#8643
+ sig { returns(T.nilable(String)) }
+ def then_keyword; end
+
+ # The location of the `then` keyword (if present) or the `?` in a ternary expression, `nil` otherwise.
+ #
+ # if foo then bar end
+ # ^^^^
+ #
+ # a ? b : c
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#8582
+ sig { returns(T.nilable(Prism::Location)) }
+ def then_keyword_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8671
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8681
+ def type; end
+ end
+end
+
+# Represents an imaginary number literal.
+#
+# 1.0i
+# ^^^^
+#
+# source://prism//lib/prism/node.rb#8702
+class Prism::ImaginaryNode < ::Prism::Node
+ # def initialize: (FloatNode | IntegerNode | RationalNode numeric, Location location) -> void
+ #
+ # @return [ImaginaryNode] a new instance of ImaginaryNode
+ #
+ # source://prism//lib/prism/node.rb#8704
+ sig do
+ params(
+ source: Prism::Source,
+ numeric: T.any(Prism::FloatNode, Prism::IntegerNode, Prism::RationalNode),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, numeric, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#8781
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#8711
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8716
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#8726
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#8721
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?numeric: FloatNode | IntegerNode | RationalNode, ?location: Location) -> ImaginaryNode
+ #
+ # source://prism//lib/prism/node.rb#8731
+ sig do
+ params(
+ numeric: T.any(Prism::FloatNode, Prism::IntegerNode, Prism::RationalNode),
+ location: Prism::Location
+ ).returns(Prism::ImaginaryNode)
+ end
+ def copy(numeric: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8716
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { numeric: FloatNode | IntegerNode | RationalNode, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#8739
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#8747
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader numeric: FloatNode | IntegerNode | RationalNode
+ #
+ # source://prism//lib/prism/node.rb#8744
+ sig { returns(T.any(Prism::FloatNode, Prism::IntegerNode, Prism::RationalNode)) }
+ def numeric; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8765
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # Returns the value of the node as a Ruby Complex.
+ #
+ # source://prism//lib/prism/node_ext.rb#101
+ sig { returns(Complex) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8775
+ def type; end
+ end
+end
+
+# Represents a node that is implicitly being added to the tree but doesn't correspond directly to a node in the source.
+#
+# { foo: }
+# ^^^^
+#
+# { Foo: }
+# ^^^^
+#
+# foo in { bar: }
+# ^^^^
+#
+# source://prism//lib/prism/node.rb#8797
+class Prism::ImplicitNode < ::Prism::Node
+ # def initialize: (Prism::node value, Location location) -> void
+ #
+ # @return [ImplicitNode] a new instance of ImplicitNode
+ #
+ # source://prism//lib/prism/node.rb#8799
+ sig { params(source: Prism::Source, value: Prism::Node, location: Prism::Location).void }
+ def initialize(source, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#8876
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#8806
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8811
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#8821
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#8816
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?value: Prism::node, ?location: Location) -> ImplicitNode
+ #
+ # source://prism//lib/prism/node.rb#8826
+ sig { params(value: Prism::Node, location: Prism::Location).returns(Prism::ImplicitNode) }
+ def copy(value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8811
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#8834
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#8842
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8860
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#8839
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8870
+ def type; end
+ end
+end
+
+# Represents using a trailing comma to indicate an implicit rest parameter.
+#
+# foo { |bar,| }
+# ^
+#
+# foo in [bar,]
+# ^
+#
+# for foo, in bar do end
+# ^
+#
+# foo, = bar
+# ^
+#
+# source://prism//lib/prism/node.rb#8895
+class Prism::ImplicitRestNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [ImplicitRestNode] a new instance of ImplicitRestNode
+ #
+ # source://prism//lib/prism/node.rb#8897
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#8970
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#8903
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8908
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#8918
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#8913
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> ImplicitRestNode
+ #
+ # source://prism//lib/prism/node.rb#8923
+ sig { params(location: Prism::Location).returns(Prism::ImplicitRestNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8908
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#8931
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#8936
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8954
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#8964
+ def type; end
+ end
+end
+
+# Represents the use of the `in` keyword in a case statement.
+#
+# case a; in b then c end
+# ^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#8979
+class Prism::InNode < ::Prism::Node
+ # def initialize: (Prism::node pattern, StatementsNode? statements, Location in_loc, Location? then_loc, Location location) -> void
+ #
+ # @return [InNode] a new instance of InNode
+ #
+ # source://prism//lib/prism/node.rb#8981
+ sig do
+ params(
+ source: Prism::Source,
+ pattern: Prism::Node,
+ statements: T.nilable(Prism::StatementsNode),
+ in_loc: Prism::Location,
+ then_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, pattern, statements, in_loc, then_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#9097
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#8991
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8996
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#9009
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#9001
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?pattern: Prism::node, ?statements: StatementsNode?, ?in_loc: Location, ?then_loc: Location?, ?location: Location) -> InNode
+ #
+ # source://prism//lib/prism/node.rb#9014
+ sig do
+ params(
+ pattern: Prism::Node,
+ statements: T.nilable(Prism::StatementsNode),
+ in_loc: Prism::Location,
+ then_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::InNode)
+ end
+ def copy(pattern: T.unsafe(nil), statements: T.unsafe(nil), in_loc: T.unsafe(nil), then_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#8996
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { pattern: Prism::node, statements: StatementsNode?, in_loc: Location, then_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#9022
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def in: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9053
+ sig { returns(String) }
+ def in; end
+
+ # attr_reader in_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9033
+ sig { returns(Prism::Location) }
+ def in_loc; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#9063
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader pattern: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#9027
+ sig { returns(Prism::Node) }
+ def pattern; end
+
+ # attr_reader statements: StatementsNode?
+ #
+ # source://prism//lib/prism/node.rb#9030
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # def then: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#9058
+ sig { returns(T.nilable(String)) }
+ def then; end
+
+ # attr_reader then_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#9040
+ sig { returns(T.nilable(Prism::Location)) }
+ def then_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9081
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9091
+ def type; end
+ end
+end
+
+# Represents the use of the `&&=` operator on a call to the `[]` method.
+#
+# foo.bar[baz] &&= value
+# ^^^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#9110
+class Prism::IndexAndWriteNode < ::Prism::Node
+ # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location opening_loc, ArgumentsNode? arguments, Location closing_loc, Prism::node? block, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [IndexAndWriteNode] a new instance of IndexAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#9112
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ opening_loc: Prism::Location,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ closing_loc: Prism::Location,
+ block: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#9289
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#9127
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader arguments: ArgumentsNode?
+ #
+ # source://prism//lib/prism/node.rb#9192
+ sig { returns(T.nilable(Prism::ArgumentsNode)) }
+ def arguments; end
+
+ # def attribute_write?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9225
+ sig { returns(T::Boolean) }
+ def attribute_write?; end
+
+ # attr_reader block: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#9202
+ sig { returns(T.nilable(Prism::Node)) }
+ def block; end
+
+ # def call_operator: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#9235
+ sig { returns(T.nilable(String)) }
+ def call_operator; end
+
+ # attr_reader call_operator_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#9172
+ sig { returns(T.nilable(Prism::Location)) }
+ def call_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#9132
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9245
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9195
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#9147
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#9137
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?opening_loc: Location, ?arguments: ArgumentsNode?, ?closing_loc: Location, ?block: Prism::node?, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> IndexAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#9152
+ sig do
+ params(
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ opening_loc: Prism::Location,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ closing_loc: Prism::Location,
+ block: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::IndexAndWriteNode)
+ end
+ def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), arguments: T.unsafe(nil), closing_loc: T.unsafe(nil), block: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#9132
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, opening_loc: Location, arguments: ArgumentsNode?, closing_loc: Location, block: Prism::node?, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#9160
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def ignore_visibility?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9230
+ sig { returns(T::Boolean) }
+ def ignore_visibility?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#9255
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9240
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9185
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9250
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9205
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader receiver: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#9169
+ sig { returns(T.nilable(Prism::Node)) }
+ def receiver; end
+
+ # def safe_navigation?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9215
+ sig { returns(T::Boolean) }
+ def safe_navigation?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9273
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#9212
+ sig { returns(Prism::Node) }
+ def value; end
+
+ # def variable_call?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9220
+ sig { returns(T::Boolean) }
+ def variable_call?; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#9165
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9283
+ def type; end
+ end
+end
+
+# Represents the use of an assignment operator on a call to `[]`.
+#
+# foo.bar[baz] += value
+# ^^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#9307
+class Prism::IndexOperatorWriteNode < ::Prism::Node
+ # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location opening_loc, ArgumentsNode? arguments, Location closing_loc, Prism::node? block, Symbol binary_operator, Location binary_operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [IndexOperatorWriteNode] a new instance of IndexOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#9309
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ opening_loc: Prism::Location,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ closing_loc: Prism::Location,
+ block: T.nilable(Prism::Node),
+ binary_operator: Symbol,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, binary_operator, binary_operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#9485
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#9325
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader arguments: ArgumentsNode?
+ #
+ # source://prism//lib/prism/node.rb#9390
+ sig { returns(T.nilable(Prism::ArgumentsNode)) }
+ def arguments; end
+
+ # def attribute_write?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9426
+ sig { returns(T::Boolean) }
+ def attribute_write?; end
+
+ # attr_reader binary_operator: Symbol
+ #
+ # source://prism//lib/prism/node.rb#9403
+ sig { returns(Symbol) }
+ def binary_operator; end
+
+ # attr_reader binary_operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9406
+ sig { returns(Prism::Location) }
+ def binary_operator_loc; end
+
+ # attr_reader block: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#9400
+ sig { returns(T.nilable(Prism::Node)) }
+ def block; end
+
+ # def call_operator: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#9436
+ sig { returns(T.nilable(String)) }
+ def call_operator; end
+
+ # attr_reader call_operator_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#9370
+ sig { returns(T.nilable(Prism::Location)) }
+ def call_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#9330
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9446
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9393
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#9345
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#9335
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?opening_loc: Location, ?arguments: ArgumentsNode?, ?closing_loc: Location, ?block: Prism::node?, ?binary_operator: Symbol, ?binary_operator_loc: Location, ?value: Prism::node, ?location: Location) -> IndexOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#9350
+ sig do
+ params(
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ opening_loc: Prism::Location,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ closing_loc: Prism::Location,
+ block: T.nilable(Prism::Node),
+ binary_operator: Symbol,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::IndexOperatorWriteNode)
+ end
+ def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), arguments: T.unsafe(nil), closing_loc: T.unsafe(nil), block: T.unsafe(nil), binary_operator: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#9330
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, opening_loc: Location, arguments: ArgumentsNode?, closing_loc: Location, block: Prism::node?, binary_operator: Symbol, binary_operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#9358
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def ignore_visibility?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9431
+ sig { returns(T::Boolean) }
+ def ignore_visibility?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#9451
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9441
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9383
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # Returns the binary operator used to modify the receiver. This method is
+ # deprecated in favor of #binary_operator.
+ #
+ # source://prism//lib/prism/node_ext.rb#403
+ def operator; end
+
+ # Returns the location of the binary operator used to modify the receiver.
+ # This method is deprecated in favor of #binary_operator_loc.
+ #
+ # source://prism//lib/prism/node_ext.rb#410
+ def operator_loc; end
+
+ # attr_reader receiver: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#9367
+ sig { returns(T.nilable(Prism::Node)) }
+ def receiver; end
+
+ # def safe_navigation?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9416
+ sig { returns(T::Boolean) }
+ def safe_navigation?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9469
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#9413
+ sig { returns(Prism::Node) }
+ def value; end
+
+ # def variable_call?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9421
+ sig { returns(T::Boolean) }
+ def variable_call?; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#9363
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9479
+ def type; end
+ end
+end
+
+# Represents the use of the `||=` operator on a call to `[]`.
+#
+# foo.bar[baz] ||= value
+# ^^^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#9504
+class Prism::IndexOrWriteNode < ::Prism::Node
+ # def initialize: (Integer flags, Prism::node? receiver, Location? call_operator_loc, Location opening_loc, ArgumentsNode? arguments, Location closing_loc, Prism::node? block, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [IndexOrWriteNode] a new instance of IndexOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#9506
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ opening_loc: Prism::Location,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ closing_loc: Prism::Location,
+ block: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, receiver, call_operator_loc, opening_loc, arguments, closing_loc, block, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#9683
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#9521
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader arguments: ArgumentsNode?
+ #
+ # source://prism//lib/prism/node.rb#9586
+ sig { returns(T.nilable(Prism::ArgumentsNode)) }
+ def arguments; end
+
+ # def attribute_write?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9619
+ sig { returns(T::Boolean) }
+ def attribute_write?; end
+
+ # attr_reader block: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#9596
+ sig { returns(T.nilable(Prism::Node)) }
+ def block; end
+
+ # def call_operator: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#9629
+ sig { returns(T.nilable(String)) }
+ def call_operator; end
+
+ # attr_reader call_operator_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#9566
+ sig { returns(T.nilable(Prism::Location)) }
+ def call_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#9526
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9639
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9589
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#9541
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#9531
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?receiver: Prism::node?, ?call_operator_loc: Location?, ?opening_loc: Location, ?arguments: ArgumentsNode?, ?closing_loc: Location, ?block: Prism::node?, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> IndexOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#9546
+ sig do
+ params(
+ flags: Integer,
+ receiver: T.nilable(Prism::Node),
+ call_operator_loc: T.nilable(Prism::Location),
+ opening_loc: Prism::Location,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ closing_loc: Prism::Location,
+ block: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::IndexOrWriteNode)
+ end
+ def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), call_operator_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), arguments: T.unsafe(nil), closing_loc: T.unsafe(nil), block: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#9526
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node?, call_operator_loc: Location?, opening_loc: Location, arguments: ArgumentsNode?, closing_loc: Location, block: Prism::node?, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#9554
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def ignore_visibility?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9624
+ sig { returns(T::Boolean) }
+ def ignore_visibility?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#9649
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9634
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9579
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9644
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9599
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader receiver: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#9563
+ sig { returns(T.nilable(Prism::Node)) }
+ def receiver; end
+
+ # def safe_navigation?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9609
+ sig { returns(T::Boolean) }
+ def safe_navigation?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9667
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#9606
+ sig { returns(Prism::Node) }
+ def value; end
+
+ # def variable_call?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9614
+ sig { returns(T::Boolean) }
+ def variable_call?; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#9559
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9677
+ def type; end
+ end
+end
+
+# Represents assigning to an index.
+#
+# foo[bar], = 1
+# ^^^^^^^^
+#
+# begin
+# rescue => foo[bar]
+# ^^^^^^^^
+# end
+#
+# for foo[bar] in baz do end
+# ^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#9709
+class Prism::IndexTargetNode < ::Prism::Node
+ # def initialize: (Integer flags, Prism::node receiver, Location opening_loc, ArgumentsNode? arguments, Location closing_loc, Prism::node? block, Location location) -> void
+ #
+ # @return [IndexTargetNode] a new instance of IndexTargetNode
+ #
+ # source://prism//lib/prism/node.rb#9711
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ receiver: Prism::Node,
+ opening_loc: Prism::Location,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ closing_loc: Prism::Location,
+ block: T.nilable(Prism::Node),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, receiver, opening_loc, arguments, closing_loc, block, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#9851
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#9723
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader arguments: ArgumentsNode?
+ #
+ # source://prism//lib/prism/node.rb#9774
+ sig { returns(T.nilable(Prism::ArgumentsNode)) }
+ def arguments; end
+
+ # def attribute_write?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9797
+ sig { returns(T::Boolean) }
+ def attribute_write?; end
+
+ # attr_reader block: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#9784
+ sig { returns(T.nilable(Prism::Node)) }
+ def block; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#9728
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9812
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9777
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#9742
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#9733
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?receiver: Prism::node, ?opening_loc: Location, ?arguments: ArgumentsNode?, ?closing_loc: Location, ?block: Prism::node?, ?location: Location) -> IndexTargetNode
+ #
+ # source://prism//lib/prism/node.rb#9747
+ sig do
+ params(
+ flags: Integer,
+ receiver: Prism::Node,
+ opening_loc: Prism::Location,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ closing_loc: Prism::Location,
+ block: T.nilable(Prism::Node),
+ location: Prism::Location
+ ).returns(Prism::IndexTargetNode)
+ end
+ def copy(flags: T.unsafe(nil), receiver: T.unsafe(nil), opening_loc: T.unsafe(nil), arguments: T.unsafe(nil), closing_loc: T.unsafe(nil), block: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#9728
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, receiver: Prism::node, opening_loc: Location, arguments: ArgumentsNode?, closing_loc: Location, block: Prism::node?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#9755
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def ignore_visibility?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9802
+ sig { returns(T::Boolean) }
+ def ignore_visibility?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#9817
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9807
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9767
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # attr_reader receiver: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#9764
+ sig { returns(Prism::Node) }
+ def receiver; end
+
+ # def safe_navigation?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9787
+ sig { returns(T::Boolean) }
+ def safe_navigation?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9835
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # def variable_call?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#9792
+ sig { returns(T::Boolean) }
+ def variable_call?; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#9760
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9845
+ def type; end
+ end
+end
+
+# InlineComment objects are the most common. They correspond to comments in
+# the source file like this one that start with #.
+#
+# source://prism//lib/prism/parse_result.rb#388
+class Prism::InlineComment < ::Prism::Comment
+ # Returns a string representation of this comment.
+ #
+ # source://prism//lib/prism/parse_result.rb#396
+ sig { returns(String) }
+ def inspect; end
+
+ # Returns true if this comment happens on the same line as other code and
+ # false if the comment is by itself.
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/parse_result.rb#391
+ sig { override.returns(T::Boolean) }
+ def trailing?; end
+end
+
+# This visitor is responsible for composing the strings that get returned by
+# the various #inspect methods defined on each of the nodes.
+#
+# source://prism//lib/prism/inspect_visitor.rb#12
+class Prism::InspectVisitor < ::Prism::Visitor
+ # Initializes a new instance of the InspectVisitor.
+ #
+ # @return [InspectVisitor] a new instance of InspectVisitor
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#35
+ sig { params(indent: String).void }
+ def initialize(indent = T.unsafe(nil)); end
+
+ # The list of commands that we need to execute in order to compose the
+ # final string.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#32
+ def commands; end
+
+ # Compose the final string.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#48
+ sig { returns(String) }
+ def compose; end
+
+ # The current prefix string.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#28
+ def indent; end
+
+ # Inspect a AliasGlobalVariableNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#77
+ def visit_alias_global_variable_node(node); end
+
+ # Inspect a AliasMethodNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#87
+ def visit_alias_method_node(node); end
+
+ # Inspect a AlternationPatternNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#97
+ def visit_alternation_pattern_node(node); end
+
+ # Inspect a AndNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#107
+ def visit_and_node(node); end
+
+ # Inspect a ArgumentsNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#117
+ def visit_arguments_node(node); end
+
+ # Inspect a ArrayNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#133
+ def visit_array_node(node); end
+
+ # Inspect a ArrayPatternNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#151
+ def visit_array_pattern_node(node); end
+
+ # Inspect a AssocNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#188
+ def visit_assoc_node(node); end
+
+ # Inspect a AssocSplatNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#198
+ def visit_assoc_splat_node(node); end
+
+ # Inspect a BackReferenceReadNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#210
+ def visit_back_reference_read_node(node); end
+
+ # Inspect a BeginNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#216
+ def visit_begin_node(node); end
+
+ # Inspect a BlockArgumentNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#247
+ def visit_block_argument_node(node); end
+
+ # Inspect a BlockLocalVariableNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#259
+ def visit_block_local_variable_node(node); end
+
+ # Inspect a BlockNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#267
+ def visit_block_node(node); end
+
+ # Inspect a BlockParameterNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#287
+ def visit_block_parameter_node(node); end
+
+ # Inspect a BlockParametersNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#301
+ def visit_block_parameters_node(node); end
+
+ # Inspect a BreakNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#323
+ def visit_break_node(node); end
+
+ # Inspect a CallAndWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#335
+ def visit_call_and_write_node(node); end
+
+ # Inspect a CallNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#355
+ def visit_call_node(node); end
+
+ # Inspect a CallOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#385
+ def visit_call_operator_write_node(node); end
+
+ # Inspect a CallOrWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#406
+ def visit_call_or_write_node(node); end
+
+ # Inspect a CallTargetNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#426
+ def visit_call_target_node(node); end
+
+ # Inspect a CapturePatternNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#438
+ def visit_capture_pattern_node(node); end
+
+ # Inspect a CaseMatchNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#448
+ def visit_case_match_node(node); end
+
+ # Inspect a CaseNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#476
+ def visit_case_node(node); end
+
+ # Inspect a ClassNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#504
+ def visit_class_node(node); end
+
+ # Inspect a ClassVariableAndWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#528
+ def visit_class_variable_and_write_node(node); end
+
+ # Inspect a ClassVariableOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#538
+ def visit_class_variable_operator_write_node(node); end
+
+ # Inspect a ClassVariableOrWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#549
+ def visit_class_variable_or_write_node(node); end
+
+ # Inspect a ClassVariableReadNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#559
+ def visit_class_variable_read_node(node); end
+
+ # Inspect a ClassVariableTargetNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#565
+ def visit_class_variable_target_node(node); end
+
+ # Inspect a ClassVariableWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#571
+ def visit_class_variable_write_node(node); end
+
+ # Inspect a ConstantAndWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#581
+ def visit_constant_and_write_node(node); end
+
+ # Inspect a ConstantOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#591
+ def visit_constant_operator_write_node(node); end
+
+ # Inspect a ConstantOrWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#602
+ def visit_constant_or_write_node(node); end
+
+ # Inspect a ConstantPathAndWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#612
+ def visit_constant_path_and_write_node(node); end
+
+ # Inspect a ConstantPathNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#622
+ def visit_constant_path_node(node); end
+
+ # Inspect a ConstantPathOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#640
+ def visit_constant_path_operator_write_node(node); end
+
+ # Inspect a ConstantPathOrWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#651
+ def visit_constant_path_or_write_node(node); end
+
+ # Inspect a ConstantPathTargetNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#661
+ def visit_constant_path_target_node(node); end
+
+ # Inspect a ConstantPathWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#679
+ def visit_constant_path_write_node(node); end
+
+ # Inspect a ConstantReadNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#689
+ def visit_constant_read_node(node); end
+
+ # Inspect a ConstantTargetNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#695
+ def visit_constant_target_node(node); end
+
+ # Inspect a ConstantWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#701
+ def visit_constant_write_node(node); end
+
+ # Inspect a DefNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#711
+ def visit_def_node(node); end
+
+ # Inspect a DefinedNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#743
+ def visit_defined_node(node); end
+
+ # Inspect a ElseNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#753
+ def visit_else_node(node); end
+
+ # Inspect a EmbeddedStatementsNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#766
+ def visit_embedded_statements_node(node); end
+
+ # Inspect a EmbeddedVariableNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#779
+ def visit_embedded_variable_node(node); end
+
+ # Inspect a EnsureNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#787
+ def visit_ensure_node(node); end
+
+ # Inspect a FalseNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#800
+ def visit_false_node(node); end
+
+ # Inspect a FindPatternNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#805
+ def visit_find_pattern_node(node); end
+
+ # Inspect a FlipFlopNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#831
+ def visit_flip_flop_node(node); end
+
+ # Inspect a FloatNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#851
+ def visit_float_node(node); end
+
+ # Inspect a ForNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#857
+ def visit_for_node(node); end
+
+ # Inspect a ForwardingArgumentsNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#876
+ def visit_forwarding_arguments_node(node); end
+
+ # Inspect a ForwardingParameterNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#881
+ def visit_forwarding_parameter_node(node); end
+
+ # Inspect a ForwardingSuperNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#886
+ def visit_forwarding_super_node(node); end
+
+ # Inspect a GlobalVariableAndWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#897
+ def visit_global_variable_and_write_node(node); end
+
+ # Inspect a GlobalVariableOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#907
+ def visit_global_variable_operator_write_node(node); end
+
+ # Inspect a GlobalVariableOrWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#918
+ def visit_global_variable_or_write_node(node); end
+
+ # Inspect a GlobalVariableReadNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#928
+ def visit_global_variable_read_node(node); end
+
+ # Inspect a GlobalVariableTargetNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#934
+ def visit_global_variable_target_node(node); end
+
+ # Inspect a GlobalVariableWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#940
+ def visit_global_variable_write_node(node); end
+
+ # Inspect a HashNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#950
+ def visit_hash_node(node); end
+
+ # Inspect a HashPatternNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#966
+ def visit_hash_pattern_node(node); end
+
+ # Inspect a IfNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#994
+ def visit_if_node(node); end
+
+ # Inspect a ImaginaryNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1016
+ def visit_imaginary_node(node); end
+
+ # Inspect a ImplicitNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1023
+ def visit_implicit_node(node); end
+
+ # Inspect a ImplicitRestNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1030
+ def visit_implicit_rest_node(node); end
+
+ # Inspect a InNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1035
+ def visit_in_node(node); end
+
+ # Inspect a IndexAndWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1050
+ def visit_index_and_write_node(node); end
+
+ # Inspect a IndexOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1081
+ def visit_index_operator_write_node(node); end
+
+ # Inspect a IndexOrWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1113
+ def visit_index_or_write_node(node); end
+
+ # Inspect a IndexTargetNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1144
+ def visit_index_target_node(node); end
+
+ # Inspect a InstanceVariableAndWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1167
+ def visit_instance_variable_and_write_node(node); end
+
+ # Inspect a InstanceVariableOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1177
+ def visit_instance_variable_operator_write_node(node); end
+
+ # Inspect a InstanceVariableOrWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1188
+ def visit_instance_variable_or_write_node(node); end
+
+ # Inspect a InstanceVariableReadNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1198
+ def visit_instance_variable_read_node(node); end
+
+ # Inspect a InstanceVariableTargetNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1204
+ def visit_instance_variable_target_node(node); end
+
+ # Inspect a InstanceVariableWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1210
+ def visit_instance_variable_write_node(node); end
+
+ # Inspect a IntegerNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1220
+ def visit_integer_node(node); end
+
+ # Inspect a InterpolatedMatchLastLineNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1228
+ def visit_interpolated_match_last_line_node(node); end
+
+ # Inspect a InterpolatedRegularExpressionNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1246
+ def visit_interpolated_regular_expression_node(node); end
+
+ # Inspect a InterpolatedStringNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1264
+ def visit_interpolated_string_node(node); end
+
+ # Inspect a InterpolatedSymbolNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1282
+ def visit_interpolated_symbol_node(node); end
+
+ # Inspect a InterpolatedXStringNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1298
+ def visit_interpolated_x_string_node(node); end
+
+ # Inspect a ItLocalVariableReadNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1314
+ def visit_it_local_variable_read_node(node); end
+
+ # Inspect a ItParametersNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1319
+ def visit_it_parameters_node(node); end
+
+ # Inspect a KeywordHashNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1324
+ def visit_keyword_hash_node(node); end
+
+ # Inspect a KeywordRestParameterNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1340
+ def visit_keyword_rest_parameter_node(node); end
+
+ # Inspect a LambdaNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1354
+ def visit_lambda_node(node); end
+
+ # Inspect a LocalVariableAndWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1375
+ def visit_local_variable_and_write_node(node); end
+
+ # Inspect a LocalVariableOperatorWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1386
+ def visit_local_variable_operator_write_node(node); end
+
+ # Inspect a LocalVariableOrWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1398
+ def visit_local_variable_or_write_node(node); end
+
+ # Inspect a LocalVariableReadNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1409
+ def visit_local_variable_read_node(node); end
+
+ # Inspect a LocalVariableTargetNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1416
+ def visit_local_variable_target_node(node); end
+
+ # Inspect a LocalVariableWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1423
+ def visit_local_variable_write_node(node); end
+
+ # Inspect a MatchLastLineNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1434
+ def visit_match_last_line_node(node); end
+
+ # Inspect a MatchPredicateNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1445
+ def visit_match_predicate_node(node); end
+
+ # Inspect a MatchRequiredNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1455
+ def visit_match_required_node(node); end
+
+ # Inspect a MatchWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1465
+ def visit_match_write_node(node); end
+
+ # Inspect a MissingNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1481
+ def visit_missing_node(node); end
+
+ # Inspect a ModuleNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1486
+ def visit_module_node(node); end
+
+ # Inspect a MultiTargetNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1503
+ def visit_multi_target_node(node); end
+
+ # Inspect a MultiWriteNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1534
+ def visit_multi_write_node(node); end
+
+ # Inspect a NextNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1568
+ def visit_next_node(node); end
+
+ # Inspect a NilNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1580
+ def visit_nil_node(node); end
+
+ # Inspect a NoKeywordsParameterNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1585
+ def visit_no_keywords_parameter_node(node); end
+
+ # Inspect a NumberedParametersNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1592
+ def visit_numbered_parameters_node(node); end
+
+ # Inspect a NumberedReferenceReadNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1598
+ def visit_numbered_reference_read_node(node); end
+
+ # Inspect a OptionalKeywordParameterNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1604
+ def visit_optional_keyword_parameter_node(node); end
+
+ # Inspect a OptionalParameterNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1615
+ def visit_optional_parameter_node(node); end
+
+ # Inspect a OrNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1627
+ def visit_or_node(node); end
+
+ # Inspect a ParametersNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1637
+ def visit_parameters_node(node); end
+
+ # Inspect a ParenthesesNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1696
+ def visit_parentheses_node(node); end
+
+ # Inspect a PinnedExpressionNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1709
+ def visit_pinned_expression_node(node); end
+
+ # Inspect a PinnedVariableNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1719
+ def visit_pinned_variable_node(node); end
+
+ # Inspect a PostExecutionNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1727
+ def visit_post_execution_node(node); end
+
+ # Inspect a PreExecutionNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1741
+ def visit_pre_execution_node(node); end
+
+ # Inspect a ProgramNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1755
+ def visit_program_node(node); end
+
+ # Inspect a RangeNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1763
+ def visit_range_node(node); end
+
+ # Inspect a RationalNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1783
+ def visit_rational_node(node); end
+
+ # Inspect a RedoNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1792
+ def visit_redo_node(node); end
+
+ # Inspect a RegularExpressionNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1797
+ def visit_regular_expression_node(node); end
+
+ # Inspect a RequiredKeywordParameterNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1808
+ def visit_required_keyword_parameter_node(node); end
+
+ # Inspect a RequiredParameterNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1817
+ def visit_required_parameter_node(node); end
+
+ # Inspect a RescueModifierNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1825
+ def visit_rescue_modifier_node(node); end
+
+ # Inspect a RescueNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1835
+ def visit_rescue_node(node); end
+
+ # Inspect a RestParameterNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1869
+ def visit_rest_parameter_node(node); end
+
+ # Inspect a RetryNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1883
+ def visit_retry_node(node); end
+
+ # Inspect a ReturnNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1888
+ def visit_return_node(node); end
+
+ # Inspect a SelfNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1902
+ def visit_self_node(node); end
+
+ # Inspect a ShareableConstantNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1907
+ def visit_shareable_constant_node(node); end
+
+ # Inspect a SingletonClassNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1916
+ def visit_singleton_class_node(node); end
+
+ # Inspect a SourceEncodingNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1933
+ def visit_source_encoding_node(node); end
+
+ # Inspect a SourceFileNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1938
+ def visit_source_file_node(node); end
+
+ # Inspect a SourceLineNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1946
+ def visit_source_line_node(node); end
+
+ # Inspect a SplatNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1951
+ def visit_splat_node(node); end
+
+ # Inspect a StatementsNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1963
+ def visit_statements_node(node); end
+
+ # Inspect a StringNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1977
+ def visit_string_node(node); end
+
+ # Inspect a SuperNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#1988
+ def visit_super_node(node); end
+
+ # Inspect a SymbolNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#2008
+ def visit_symbol_node(node); end
+
+ # Inspect a TrueNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#2019
+ def visit_true_node(node); end
+
+ # Inspect a UndefNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#2024
+ def visit_undef_node(node); end
+
+ # Inspect a UnlessNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#2039
+ def visit_unless_node(node); end
+
+ # Inspect a UntilNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#2061
+ def visit_until_node(node); end
+
+ # Inspect a WhenNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#2078
+ def visit_when_node(node); end
+
+ # Inspect a WhileNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#2100
+ def visit_while_node(node); end
+
+ # Inspect a XStringNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#2117
+ def visit_x_string_node(node); end
+
+ # Inspect a YieldNode node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#2128
+ def visit_yield_node(node); end
+
+ private
+
+ # Compose a string representing the given inner location field.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#2150
+ def inspect_location(location); end
+
+ # Compose a header for the given node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#2144
+ def inspect_node(name, node); end
+
+ class << self
+ # Compose an inspect string for the given node.
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#41
+ sig { params(node: Prism::Node).returns(String) }
+ def compose(node); end
+ end
+end
+
+# Most of the time, we can simply pass down the indent to the next node.
+# However, when we are inside a list we want some extra special formatting
+# when we hit an element in that list. In this case, we have a special
+# command that replaces the subsequent indent with the given value.
+#
+# source://prism//lib/prism/inspect_visitor.rb#17
+class Prism::InspectVisitor::Replace
+ # @return [Replace] a new instance of Replace
+ #
+ # source://prism//lib/prism/inspect_visitor.rb#20
+ def initialize(value); end
+
+ # source://prism//lib/prism/inspect_visitor.rb#18
+ def value; end
+end
+
+# Represents the use of the `&&=` operator for assignment to an instance variable.
+#
+# @target &&= value
+# ^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#9866
+class Prism::InstanceVariableAndWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [InstanceVariableAndWriteNode] a new instance of InstanceVariableAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#9868
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#9970
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#9878
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#9883
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#9893
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#9888
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> InstanceVariableAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#9898
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::InstanceVariableAndWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#9883
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#9906
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#181
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#9936
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#9911
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9914
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#9931
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#9921
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9954
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#9928
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#9964
+ def type; end
+ end
+end
+
+# Represents assigning to an instance variable using an operator that isn't `=`.
+#
+# @target += value
+# ^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#9983
+class Prism::InstanceVariableOperatorWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location binary_operator_loc, Prism::node value, Symbol binary_operator, Location location) -> void
+ #
+ # @return [InstanceVariableOperatorWriteNode] a new instance of InstanceVariableOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#9985
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ binary_operator: Symbol,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, binary_operator_loc, value, binary_operator, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#10086
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#9996
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader binary_operator: Symbol
+ #
+ # source://prism//lib/prism/node.rb#10049
+ sig { returns(Symbol) }
+ def binary_operator; end
+
+ # attr_reader binary_operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#10039
+ sig { returns(Prism::Location) }
+ def binary_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10001
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#10011
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#10006
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?binary_operator_loc: Location, ?value: Prism::node, ?binary_operator: Symbol, ?location: Location) -> InstanceVariableOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#10016
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ binary_operator: Symbol,
+ location: Prism::Location
+ ).returns(Prism::InstanceVariableOperatorWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), binary_operator: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10001
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, binary_operator_loc: Location, value: Prism::node, binary_operator: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#10024
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#193
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#10052
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#10029
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#10032
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # Returns the binary operator used to modify the receiver. This method is
+ # deprecated in favor of #binary_operator.
+ #
+ # source://prism//lib/prism/node_ext.rb#419
+ def operator; end
+
+ # Returns the location of the binary operator used to modify the receiver.
+ # This method is deprecated in favor of #binary_operator_loc.
+ #
+ # source://prism//lib/prism/node_ext.rb#426
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10070
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#10046
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10080
+ def type; end
+ end
+end
+
+# Represents the use of the `||=` operator for assignment to an instance variable.
+#
+# @target ||= value
+# ^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#10100
+class Prism::InstanceVariableOrWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [InstanceVariableOrWriteNode] a new instance of InstanceVariableOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#10102
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#10204
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#10112
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10117
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#10127
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#10122
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> InstanceVariableOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#10132
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::InstanceVariableOrWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10117
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#10140
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # source://prism//lib/prism/desugar_compiler.rb#187
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#10170
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#10145
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#10148
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#10165
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#10155
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10188
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#10162
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10198
+ def type; end
+ end
+end
+
+# Represents referencing an instance variable.
+#
+# @foo
+# ^^^^
+#
+# source://prism//lib/prism/node.rb#10217
+class Prism::InstanceVariableReadNode < ::Prism::Node
+ # def initialize: (Symbol name, Location location) -> void
+ #
+ # @return [InstanceVariableReadNode] a new instance of InstanceVariableReadNode
+ #
+ # source://prism//lib/prism/node.rb#10219
+ sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void }
+ def initialize(source, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#10300
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#10226
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10231
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#10241
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#10236
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?location: Location) -> InstanceVariableReadNode
+ #
+ # source://prism//lib/prism/node.rb#10246
+ sig { params(name: Symbol, location: Prism::Location).returns(Prism::InstanceVariableReadNode) }
+ def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10231
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#10254
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#10266
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the instance variable, which is a `@` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers).
+ #
+ # @x # name `:@x`
+ #
+ # @_test # name `:@_test`
+ #
+ # source://prism//lib/prism/node.rb#10263
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10284
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10294
+ def type; end
+ end
+end
+
+# Represents writing to an instance variable in a context that doesn't have an explicit value.
+#
+# @foo, @bar = baz
+# ^^^^ ^^^^
+#
+# source://prism//lib/prism/node.rb#10310
+class Prism::InstanceVariableTargetNode < ::Prism::Node
+ # def initialize: (Symbol name, Location location) -> void
+ #
+ # @return [InstanceVariableTargetNode] a new instance of InstanceVariableTargetNode
+ #
+ # source://prism//lib/prism/node.rb#10312
+ sig { params(source: Prism::Source, name: Symbol, location: Prism::Location).void }
+ def initialize(source, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#10389
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#10319
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10324
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#10334
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#10329
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?location: Location) -> InstanceVariableTargetNode
+ #
+ # source://prism//lib/prism/node.rb#10339
+ sig { params(name: Symbol, location: Prism::Location).returns(Prism::InstanceVariableTargetNode) }
+ def copy(name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10324
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#10347
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#10355
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#10352
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10373
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10383
+ def type; end
+ end
+end
+
+# Represents writing to an instance variable.
+#
+# @foo = 1
+# ^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#10399
+class Prism::InstanceVariableWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Location name_loc, Prism::node value, Location operator_loc, Location location) -> void
+ #
+ # @return [InstanceVariableWriteNode] a new instance of InstanceVariableWriteNode
+ #
+ # source://prism//lib/prism/node.rb#10401
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, name_loc, value, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#10519
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#10411
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10416
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#10426
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#10421
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?name_loc: Location, ?value: Prism::node, ?operator_loc: Location, ?location: Location) -> InstanceVariableWriteNode
+ #
+ # source://prism//lib/prism/node.rb#10431
+ sig do
+ params(
+ name: Symbol,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::InstanceVariableWriteNode)
+ end
+ def copy(name: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10416
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, name_loc: Location, value: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#10439
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#10485
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the instance variable, which is a `@` followed by an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers).
+ #
+ # @x = :y # name `:@x`
+ #
+ # @_foo = "bar" # name `@_foo`
+ #
+ # source://prism//lib/prism/node.rb#10448
+ sig { returns(Symbol) }
+ def name; end
+
+ # The location of the variable name.
+ #
+ # @_x = 1
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#10454
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#10480
+ sig { returns(String) }
+ def operator; end
+
+ # The location of the `=` operator.
+ #
+ # @x = y
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#10473
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10503
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # The value to write to the instance variable. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # @foo = :bar
+ # ^^^^
+ #
+ # @_x = 1234
+ # ^^^^
+ #
+ # source://prism//lib/prism/node.rb#10467
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10513
+ def type; end
+ end
+end
+
+# Flags for integer nodes that correspond to the base of the integer.
+#
+# source://prism//lib/prism/node.rb#19166
+module Prism::IntegerBaseFlags; end
+
+# 0b prefix
+#
+# source://prism//lib/prism/node.rb#19168
+Prism::IntegerBaseFlags::BINARY = T.let(T.unsafe(nil), Integer)
+
+# 0d or no prefix
+#
+# source://prism//lib/prism/node.rb#19171
+Prism::IntegerBaseFlags::DECIMAL = T.let(T.unsafe(nil), Integer)
+
+# 0x prefix
+#
+# source://prism//lib/prism/node.rb#19177
+Prism::IntegerBaseFlags::HEXADECIMAL = T.let(T.unsafe(nil), Integer)
+
+# 0o or 0 prefix
+#
+# source://prism//lib/prism/node.rb#19174
+Prism::IntegerBaseFlags::OCTAL = T.let(T.unsafe(nil), Integer)
+
+# Represents an integer number literal.
+#
+# 1
+# ^
+#
+# source://prism//lib/prism/node.rb#10532
+class Prism::IntegerNode < ::Prism::Node
+ # def initialize: (Integer flags, Integer value, Location location) -> void
+ #
+ # @return [IntegerNode] a new instance of IntegerNode
+ #
+ # source://prism//lib/prism/node.rb#10534
+ sig { params(source: Prism::Source, flags: Integer, value: Integer, location: Prism::Location).void }
+ def initialize(source, flags, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#10636
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#10542
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def binary?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10582
+ sig { returns(T::Boolean) }
+ def binary?; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10547
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#10557
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#10552
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?value: Integer, ?location: Location) -> IntegerNode
+ #
+ # source://prism//lib/prism/node.rb#10562
+ sig { params(flags: Integer, value: Integer, location: Prism::Location).returns(Prism::IntegerNode) }
+ def copy(flags: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def decimal?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10587
+ sig { returns(T::Boolean) }
+ def decimal?; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10547
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, value: Integer, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#10570
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def hexadecimal?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10597
+ sig { returns(T::Boolean) }
+ def hexadecimal?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#10602
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def octal?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10592
+ sig { returns(T::Boolean) }
+ def octal?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10620
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # The value of the integer literal as a number.
+ #
+ # source://prism//lib/prism/node.rb#10579
+ sig { returns(Integer) }
+ def value; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#10575
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10630
+ def type; end
+ end
+end
+
+# Represents a regular expression literal that contains interpolation that is being used in the predicate of a conditional to implicitly match against the last line read by an IO object.
+#
+# if /foo #{bar} baz/ then end
+# ^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#10647
+class Prism::InterpolatedMatchLastLineNode < ::Prism::Node
+ include ::Prism::RegularExpressionOptions
+
+ # def initialize: (Integer flags, Location opening_loc, Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] parts, Location closing_loc, Location location) -> void
+ #
+ # @return [InterpolatedMatchLastLineNode] a new instance of InterpolatedMatchLastLineNode
+ #
+ # source://prism//lib/prism/node.rb#10649
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ opening_loc: Prism::Location,
+ parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)],
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, opening_loc, parts, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#10812
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#10659
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def ascii_8bit?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10738
+ sig { returns(T::Boolean) }
+ def ascii_8bit?; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10664
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#10773
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#10706
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#10674
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#10669
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?opening_loc: Location, ?parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], ?closing_loc: Location, ?location: Location) -> InterpolatedMatchLastLineNode
+ #
+ # source://prism//lib/prism/node.rb#10679
+ sig do
+ params(
+ flags: Integer,
+ opening_loc: Prism::Location,
+ parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)],
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::InterpolatedMatchLastLineNode)
+ end
+ def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), parts: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10664
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location, parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], closing_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#10687
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def euc_jp?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10733
+ sig { returns(T::Boolean) }
+ def euc_jp?; end
+
+ # def extended?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10718
+ sig { returns(T::Boolean) }
+ def extended?; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def forced_binary_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10758
+ sig { returns(T::Boolean) }
+ def forced_binary_encoding?; end
+
+ # def forced_us_ascii_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10763
+ sig { returns(T::Boolean) }
+ def forced_us_ascii_encoding?; end
+
+ # def forced_utf8_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10753
+ sig { returns(T::Boolean) }
+ def forced_utf8_encoding?; end
+
+ # def ignore_case?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10713
+ sig { returns(T::Boolean) }
+ def ignore_case?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#10778
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def multi_line?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10723
+ sig { returns(T::Boolean) }
+ def multi_line?; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#121
+ def newline!(lines); end
+
+ # def once?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10728
+ sig { returns(T::Boolean) }
+ def once?; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#10768
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#10696
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ sig { returns(Integer) }
+ def options; end
+
+ # attr_reader parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode]
+ #
+ # source://prism//lib/prism/node.rb#10703
+ sig { returns(T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)]) }
+ def parts; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10796
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # def utf_8?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10748
+ sig { returns(T::Boolean) }
+ def utf_8?; end
+
+ # def windows_31j?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10743
+ sig { returns(T::Boolean) }
+ def windows_31j?; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#10692
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10806
+ def type; end
+ end
+end
+
+# Represents a regular expression literal that contains interpolation.
+#
+# /foo #{bar} baz/
+# ^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#10826
+class Prism::InterpolatedRegularExpressionNode < ::Prism::Node
+ include ::Prism::RegularExpressionOptions
+
+ # def initialize: (Integer flags, Location opening_loc, Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] parts, Location closing_loc, Location location) -> void
+ #
+ # @return [InterpolatedRegularExpressionNode] a new instance of InterpolatedRegularExpressionNode
+ #
+ # source://prism//lib/prism/node.rb#10828
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ opening_loc: Prism::Location,
+ parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)],
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, opening_loc, parts, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#10991
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#10838
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def ascii_8bit?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10917
+ sig { returns(T::Boolean) }
+ def ascii_8bit?; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10843
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#10952
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#10885
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#10853
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#10848
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?opening_loc: Location, ?parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], ?closing_loc: Location, ?location: Location) -> InterpolatedRegularExpressionNode
+ #
+ # source://prism//lib/prism/node.rb#10858
+ sig do
+ params(
+ flags: Integer,
+ opening_loc: Prism::Location,
+ parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)],
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::InterpolatedRegularExpressionNode)
+ end
+ def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), parts: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#10843
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location, parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], closing_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#10866
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def euc_jp?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10912
+ sig { returns(T::Boolean) }
+ def euc_jp?; end
+
+ # def extended?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10897
+ sig { returns(T::Boolean) }
+ def extended?; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def forced_binary_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10937
+ sig { returns(T::Boolean) }
+ def forced_binary_encoding?; end
+
+ # def forced_us_ascii_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10942
+ sig { returns(T::Boolean) }
+ def forced_us_ascii_encoding?; end
+
+ # def forced_utf8_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10932
+ sig { returns(T::Boolean) }
+ def forced_utf8_encoding?; end
+
+ # def ignore_case?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10892
+ sig { returns(T::Boolean) }
+ def ignore_case?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#10957
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def multi_line?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10902
+ sig { returns(T::Boolean) }
+ def multi_line?; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#128
+ def newline!(lines); end
+
+ # def once?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10907
+ sig { returns(T::Boolean) }
+ def once?; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#10947
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#10875
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ sig { returns(Integer) }
+ def options; end
+
+ # attr_reader parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode]
+ #
+ # source://prism//lib/prism/node.rb#10882
+ sig { returns(T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)]) }
+ def parts; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10975
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # def utf_8?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10927
+ sig { returns(T::Boolean) }
+ def utf_8?; end
+
+ # def windows_31j?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#10922
+ sig { returns(T::Boolean) }
+ def windows_31j?; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#10871
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#10985
+ def type; end
+ end
+end
+
+# Represents a string literal that contains interpolation.
+#
+# "foo #{bar} baz"
+# ^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#11005
+class Prism::InterpolatedStringNode < ::Prism::Node
+ include ::Prism::HeredocQuery
+
+ # def initialize: (Integer flags, Location? opening_loc, Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode | InterpolatedStringNode] parts, Location? closing_loc, Location location) -> void
+ #
+ # @return [InterpolatedStringNode] a new instance of InterpolatedStringNode
+ #
+ # source://prism//lib/prism/node.rb#11007
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ opening_loc: T.nilable(Prism::Location),
+ parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode, Prism::InterpolatedStringNode)],
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, opening_loc, parts, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#11137
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#11017
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11022
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#11098
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # attr_reader closing_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#11070
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#11032
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#11027
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?opening_loc: Location?, ?parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode | InterpolatedStringNode], ?closing_loc: Location?, ?location: Location) -> InterpolatedStringNode
+ #
+ # source://prism//lib/prism/node.rb#11037
+ sig do
+ params(
+ flags: Integer,
+ opening_loc: T.nilable(Prism::Location),
+ parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode, Prism::InterpolatedStringNode)],
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::InterpolatedStringNode)
+ end
+ def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), parts: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11022
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location?, parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode | InterpolatedStringNode], closing_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#11045
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def frozen?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#11083
+ sig { returns(T::Boolean) }
+ def frozen?; end
+
+ sig { returns(T::Boolean) }
+ def heredoc?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#11103
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def mutable?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#11088
+ sig { returns(T::Boolean) }
+ def mutable?; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#135
+ def newline!(lines); end
+
+ # def opening: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#11093
+ sig { returns(T.nilable(String)) }
+ def opening; end
+
+ # attr_reader opening_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#11054
+ sig { returns(T.nilable(Prism::Location)) }
+ def opening_loc; end
+
+ # attr_reader parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode | InterpolatedStringNode]
+ #
+ # source://prism//lib/prism/node.rb#11067
+ sig do
+ returns(T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode, Prism::InterpolatedStringNode)])
+ end
+ def parts; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11121
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#11050
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11131
+ def type; end
+ end
+end
+
+# Flags for interpolated string nodes that indicated mutability if they are also marked as literals.
+#
+# source://prism//lib/prism/node.rb#19181
+module Prism::InterpolatedStringNodeFlags; end
+
+# source://prism//lib/prism/node.rb#19183
+Prism::InterpolatedStringNodeFlags::FROZEN = T.let(T.unsafe(nil), Integer)
+
+# source://prism//lib/prism/node.rb#19186
+Prism::InterpolatedStringNodeFlags::MUTABLE = T.let(T.unsafe(nil), Integer)
+
+# Represents a symbol literal that contains interpolation.
+#
+# :"foo #{bar} baz"
+# ^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#11151
+class Prism::InterpolatedSymbolNode < ::Prism::Node
+ # def initialize: (Location? opening_loc, Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] parts, Location? closing_loc, Location location) -> void
+ #
+ # @return [InterpolatedSymbolNode] a new instance of InterpolatedSymbolNode
+ #
+ # source://prism//lib/prism/node.rb#11153
+ sig do
+ params(
+ source: Prism::Source,
+ opening_loc: T.nilable(Prism::Location),
+ parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)],
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, opening_loc, parts, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#11268
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#11162
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11167
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#11229
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # attr_reader closing_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#11211
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#11177
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#11172
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?opening_loc: Location?, ?parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], ?closing_loc: Location?, ?location: Location) -> InterpolatedSymbolNode
+ #
+ # source://prism//lib/prism/node.rb#11182
+ sig do
+ params(
+ opening_loc: T.nilable(Prism::Location),
+ parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)],
+ closing_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::InterpolatedSymbolNode)
+ end
+ def copy(opening_loc: T.unsafe(nil), parts: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11167
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { opening_loc: Location?, parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], closing_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#11190
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#11234
+ sig { override.returns(String) }
+ def inspect; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#142
+ def newline!(lines); end
+
+ # def opening: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#11224
+ sig { returns(T.nilable(String)) }
+ def opening; end
+
+ # attr_reader opening_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#11195
+ sig { returns(T.nilable(Prism::Location)) }
+ def opening_loc; end
+
+ # attr_reader parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode]
+ #
+ # source://prism//lib/prism/node.rb#11208
+ sig { returns(T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)]) }
+ def parts; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11252
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11262
+ def type; end
+ end
+end
+
+# Represents an xstring literal that contains interpolation.
+#
+# `foo #{bar} baz`
+# ^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#11281
+class Prism::InterpolatedXStringNode < ::Prism::Node
+ include ::Prism::HeredocQuery
+
+ # def initialize: (Location opening_loc, Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode] parts, Location closing_loc, Location location) -> void
+ #
+ # @return [InterpolatedXStringNode] a new instance of InterpolatedXStringNode
+ #
+ # source://prism//lib/prism/node.rb#11283
+ sig do
+ params(
+ source: Prism::Source,
+ opening_loc: Prism::Location,
+ parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)],
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, opening_loc, parts, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#11386
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#11292
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11297
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#11347
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#11335
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#11307
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#11302
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?opening_loc: Location, ?parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], ?closing_loc: Location, ?location: Location) -> InterpolatedXStringNode
+ #
+ # source://prism//lib/prism/node.rb#11312
+ sig do
+ params(
+ opening_loc: Prism::Location,
+ parts: T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)],
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::InterpolatedXStringNode)
+ end
+ def copy(opening_loc: T.unsafe(nil), parts: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11297
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { opening_loc: Location, parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode], closing_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#11320
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ sig { returns(T::Boolean) }
+ def heredoc?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#11352
+ sig { override.returns(String) }
+ def inspect; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#149
+ def newline!(lines); end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#11342
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#11325
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # attr_reader parts: Array[StringNode | EmbeddedStatementsNode | EmbeddedVariableNode]
+ #
+ # source://prism//lib/prism/node.rb#11332
+ sig { returns(T::Array[T.any(Prism::StringNode, Prism::EmbeddedStatementsNode, Prism::EmbeddedVariableNode)]) }
+ def parts; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11370
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11380
+ def type; end
+ end
+end
+
+# Represents reading from the implicit `it` local variable.
+#
+# -> { it }
+# ^^
+#
+# source://prism//lib/prism/node.rb#11399
+class Prism::ItLocalVariableReadNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [ItLocalVariableReadNode] a new instance of ItLocalVariableReadNode
+ #
+ # source://prism//lib/prism/node.rb#11401
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#11474
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#11407
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11412
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#11422
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#11417
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> ItLocalVariableReadNode
+ #
+ # source://prism//lib/prism/node.rb#11427
+ sig { params(location: Prism::Location).returns(Prism::ItLocalVariableReadNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11412
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#11435
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#11440
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11458
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11468
+ def type; end
+ end
+end
+
+# Represents an implicit set of parameters through the use of the `it` keyword within a block or lambda.
+#
+# -> { it + it }
+# ^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#11483
+class Prism::ItParametersNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [ItParametersNode] a new instance of ItParametersNode
+ #
+ # source://prism//lib/prism/node.rb#11485
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#11558
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#11491
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11496
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#11506
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#11501
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> ItParametersNode
+ #
+ # source://prism//lib/prism/node.rb#11511
+ sig { params(location: Prism::Location).returns(Prism::ItParametersNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11496
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#11519
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#11524
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11542
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11552
+ def type; end
+ end
+end
+
+# Represents a hash literal without opening and closing braces.
+#
+# foo(a: b)
+# ^^^^
+#
+# source://prism//lib/prism/node.rb#11567
+class Prism::KeywordHashNode < ::Prism::Node
+ # def initialize: (Integer flags, Array[AssocNode | AssocSplatNode] elements, Location location) -> void
+ #
+ # @return [KeywordHashNode] a new instance of KeywordHashNode
+ #
+ # source://prism//lib/prism/node.rb#11569
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ elements: T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)],
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, elements, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#11656
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#11577
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11582
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#11592
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#11587
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?elements: Array[AssocNode | AssocSplatNode], ?location: Location) -> KeywordHashNode
+ #
+ # source://prism//lib/prism/node.rb#11597
+ sig do
+ params(
+ flags: Integer,
+ elements: T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)],
+ location: Prism::Location
+ ).returns(Prism::KeywordHashNode)
+ end
+ def copy(flags: T.unsafe(nil), elements: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11582
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, elements: Array[AssocNode | AssocSplatNode], location: Location }
+ #
+ # source://prism//lib/prism/node.rb#11605
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader elements: Array[AssocNode | AssocSplatNode]
+ #
+ # source://prism//lib/prism/node.rb#11614
+ sig { returns(T::Array[T.any(Prism::AssocNode, Prism::AssocSplatNode)]) }
+ def elements; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#11622
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def symbol_keys?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#11617
+ sig { returns(T::Boolean) }
+ def symbol_keys?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11640
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#11610
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11650
+ def type; end
+ end
+end
+
+# Flags for keyword hash nodes.
+#
+# source://prism//lib/prism/node.rb#19190
+module Prism::KeywordHashNodeFlags; end
+
+# a keyword hash which only has `AssocNode` elements all with symbol keys, which means the elements can be treated as keyword arguments
+#
+# source://prism//lib/prism/node.rb#19192
+Prism::KeywordHashNodeFlags::SYMBOL_KEYS = T.let(T.unsafe(nil), Integer)
+
+# Represents a keyword rest parameter to a method, block, or lambda definition.
+#
+# def a(**b)
+# ^^^
+# end
+#
+# source://prism//lib/prism/node.rb#11669
+class Prism::KeywordRestParameterNode < ::Prism::Node
+ # def initialize: (Integer flags, Symbol? name, Location? name_loc, Location operator_loc, Location location) -> void
+ #
+ # @return [KeywordRestParameterNode] a new instance of KeywordRestParameterNode
+ #
+ # source://prism//lib/prism/node.rb#11671
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ name: T.nilable(Symbol),
+ name_loc: T.nilable(Prism::Location),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, name, name_loc, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#11785
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#11681
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11686
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#11696
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#11691
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?name: Symbol?, ?name_loc: Location?, ?operator_loc: Location, ?location: Location) -> KeywordRestParameterNode
+ #
+ # source://prism//lib/prism/node.rb#11701
+ sig do
+ params(
+ flags: Integer,
+ name: T.nilable(Symbol),
+ name_loc: T.nilable(Prism::Location),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::KeywordRestParameterNode)
+ end
+ def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11686
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol?, name_loc: Location?, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#11709
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#11751
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol?
+ #
+ # source://prism//lib/prism/node.rb#11718
+ sig { returns(T.nilable(Symbol)) }
+ def name; end
+
+ # attr_reader name_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#11721
+ sig { returns(T.nilable(Prism::Location)) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#11746
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#11734
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # def repeated_parameter?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#11741
+ sig { returns(T::Boolean) }
+ def repeated_parameter?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11769
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#11714
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11779
+ def type; end
+ end
+end
+
+# Represents using a lambda literal (not the lambda method call).
+#
+# ->(value) { value * 2 }
+# ^^^^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#11798
+class Prism::LambdaNode < ::Prism::Node
+ # def initialize: (Array[Symbol] locals, Location operator_loc, Location opening_loc, Location closing_loc, Prism::node? parameters, Prism::node? body, Location location) -> void
+ #
+ # @return [LambdaNode] a new instance of LambdaNode
+ #
+ # source://prism//lib/prism/node.rb#11800
+ sig do
+ params(
+ source: Prism::Source,
+ locals: T::Array[Symbol],
+ operator_loc: Prism::Location,
+ opening_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ parameters: T.nilable(Prism::Node),
+ body: T.nilable(Prism::Node),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, locals, operator_loc, opening_loc, closing_loc, parameters, body, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#11927
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#11812
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader body: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#11875
+ sig { returns(T.nilable(Prism::Node)) }
+ def body; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11817
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#11888
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#11865
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#11830
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#11822
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?locals: Array[Symbol], ?operator_loc: Location, ?opening_loc: Location, ?closing_loc: Location, ?parameters: Prism::node?, ?body: Prism::node?, ?location: Location) -> LambdaNode
+ #
+ # source://prism//lib/prism/node.rb#11835
+ sig do
+ params(
+ locals: T::Array[Symbol],
+ operator_loc: Prism::Location,
+ opening_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ parameters: T.nilable(Prism::Node),
+ body: T.nilable(Prism::Node),
+ location: Prism::Location
+ ).returns(Prism::LambdaNode)
+ end
+ def copy(locals: T.unsafe(nil), operator_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), parameters: T.unsafe(nil), body: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11817
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], operator_loc: Location, opening_loc: Location, closing_loc: Location, parameters: Prism::node?, body: Prism::node?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#11843
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#11893
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader locals: Array[Symbol]
+ #
+ # source://prism//lib/prism/node.rb#11848
+ sig { returns(T::Array[Symbol]) }
+ def locals; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#11883
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#11858
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#11878
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#11851
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader parameters: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#11872
+ sig { returns(T.nilable(Prism::Node)) }
+ def parameters; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11911
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#11921
+ def type; end
+ end
+end
+
+# This class is responsible for lexing the source using prism and then
+# converting those tokens to be compatible with Ripper. In the vast majority
+# of cases, this is a one-to-one mapping of the token type. Everything else
+# generally lines up. However, there are a few cases that require special
+# handling.
+#
+# source://prism//lib/prism/lex_compat.rb#12
+class Prism::LexCompat
+ # @return [LexCompat] a new instance of LexCompat
+ #
+ # source://prism//lib/prism/lex_compat.rb#619
+ def initialize(source, **options); end
+
+ # Returns the value of attribute options.
+ #
+ # source://prism//lib/prism/lex_compat.rb#617
+ def options; end
+
+ # source://prism//lib/prism/lex_compat.rb#624
+ def result; end
+
+ # Returns the value of attribute source.
+ #
+ # source://prism//lib/prism/lex_compat.rb#617
+ def source; end
+end
+
+# Ripper doesn't include the rest of the token in the event, so we need to
+# trim it down to just the content on the first line when comparing.
+#
+# source://prism//lib/prism/lex_compat.rb#230
+class Prism::LexCompat::EndContentToken < ::Prism::LexCompat::Token
+ # source://prism//lib/prism/lex_compat.rb#231
+ def ==(other); end
+end
+
+# A heredoc in this case is a list of tokens that belong to the body of the
+# heredoc that should be appended onto the list of tokens when the heredoc
+# closes.
+#
+# source://prism//lib/prism/lex_compat.rb#291
+module Prism::LexCompat::Heredoc
+ class << self
+ # Here we will split between the two types of heredocs and return the
+ # object that will store their tokens.
+ #
+ # source://prism//lib/prism/lex_compat.rb#603
+ def build(opening); end
+ end
+end
+
+# Dash heredocs are a little more complicated. They are a list of tokens
+# that need to be split on "\\\n" to mimic Ripper's behavior. We also need
+# to keep track of the state that the heredoc was opened in.
+#
+# source://prism//lib/prism/lex_compat.rb#315
+class Prism::LexCompat::Heredoc::DashHeredoc
+ # @return [DashHeredoc] a new instance of DashHeredoc
+ #
+ # source://prism//lib/prism/lex_compat.rb#318
+ def initialize(split); end
+
+ # source://prism//lib/prism/lex_compat.rb#323
+ def <<(token); end
+
+ # source://prism//lib/prism/lex_compat.rb#316
+ def split; end
+
+ # source://prism//lib/prism/lex_compat.rb#327
+ def to_a; end
+
+ # source://prism//lib/prism/lex_compat.rb#316
+ def tokens; end
+end
+
+# Heredocs that are dedenting heredocs are a little more complicated.
+# Ripper outputs on_ignored_sp tokens for the whitespace that is being
+# removed from the output. prism only modifies the node itself and keeps
+# the token the same. This simplifies prism, but makes comparing against
+# Ripper much harder because there is a length mismatch.
+#
+# Fortunately, we already have to pull out the heredoc tokens in order to
+# insert them into the stream in the correct order. As such, we can do
+# some extra manipulation on the tokens to make them match Ripper's
+# output by mirroring the dedent logic that Ripper uses.
+#
+# source://prism//lib/prism/lex_compat.rb#374
+class Prism::LexCompat::Heredoc::DedentingHeredoc
+ # @return [DedentingHeredoc] a new instance of DedentingHeredoc
+ #
+ # source://prism//lib/prism/lex_compat.rb#379
+ def initialize; end
+
+ # As tokens are coming in, we track the minimum amount of common leading
+ # whitespace on plain string content tokens. This allows us to later
+ # remove that amount of whitespace from the beginning of each line.
+ #
+ # source://prism//lib/prism/lex_compat.rb#390
+ def <<(token); end
+
+ # Returns the value of attribute dedent.
+ #
+ # source://prism//lib/prism/lex_compat.rb#377
+ def dedent; end
+
+ # Returns the value of attribute dedent_next.
+ #
+ # source://prism//lib/prism/lex_compat.rb#377
+ def dedent_next; end
+
+ # Returns the value of attribute embexpr_balance.
+ #
+ # source://prism//lib/prism/lex_compat.rb#377
+ def embexpr_balance; end
+
+ # source://prism//lib/prism/lex_compat.rb#427
+ def to_a; end
+
+ # Returns the value of attribute tokens.
+ #
+ # source://prism//lib/prism/lex_compat.rb#377
+ def tokens; end
+end
+
+# source://prism//lib/prism/lex_compat.rb#375
+Prism::LexCompat::Heredoc::DedentingHeredoc::TAB_WIDTH = T.let(T.unsafe(nil), Integer)
+
+# Heredocs that are no dash or tilde heredocs are just a list of tokens.
+# We need to keep them around so that we can insert them in the correct
+# order back into the token stream and set the state of the last token to
+# the state that the heredoc was opened in.
+#
+# source://prism//lib/prism/lex_compat.rb#296
+class Prism::LexCompat::Heredoc::PlainHeredoc
+ # @return [PlainHeredoc] a new instance of PlainHeredoc
+ #
+ # source://prism//lib/prism/lex_compat.rb#299
+ def initialize; end
+
+ # source://prism//lib/prism/lex_compat.rb#303
+ def <<(token); end
+
+ # source://prism//lib/prism/lex_compat.rb#307
+ def to_a; end
+
+ # source://prism//lib/prism/lex_compat.rb#297
+ def tokens; end
+end
+
+# Ident tokens for the most part are exactly the same, except sometimes we
+# know an ident is a local when ripper doesn't (when they are introduced
+# through named captures in regular expressions). In that case we don't
+# compare the state.
+#
+# source://prism//lib/prism/lex_compat.rb#248
+class Prism::LexCompat::IdentToken < ::Prism::LexCompat::Token
+ # source://prism//lib/prism/lex_compat.rb#249
+ def ==(other); end
+end
+
+# Tokens where state should be ignored
+# used for :on_comment, :on_heredoc_end, :on_embexpr_end
+#
+# source://prism//lib/prism/lex_compat.rb#238
+class Prism::LexCompat::IgnoreStateToken < ::Prism::LexCompat::Token
+ # source://prism//lib/prism/lex_compat.rb#239
+ def ==(other); end
+end
+
+# Ignored newlines can occasionally have a LABEL state attached to them, so
+# we compare the state differently here.
+#
+# source://prism//lib/prism/lex_compat.rb#259
+class Prism::LexCompat::IgnoredNewlineToken < ::Prism::LexCompat::Token
+ # source://prism//lib/prism/lex_compat.rb#260
+ def ==(other); end
+end
+
+# If we have an identifier that follows a method name like:
+#
+# def foo bar
+#
+# then Ripper will mark bar as END|LABEL if there is a local in a parent
+# scope named bar because it hasn't pushed the local table yet. We do this
+# more accurately, so we need to allow comparing against both END and
+# END|LABEL.
+#
+# source://prism//lib/prism/lex_compat.rb#279
+class Prism::LexCompat::ParamToken < ::Prism::LexCompat::Token
+ # source://prism//lib/prism/lex_compat.rb#280
+ def ==(other); end
+end
+
+# This is a mapping of prism token types to Ripper token types. This is a
+# many-to-one mapping because we split up our token types, whereas Ripper
+# tends to group them.
+#
+# source://prism//lib/prism/lex_compat.rb#33
+Prism::LexCompat::RIPPER = T.let(T.unsafe(nil), Hash)
+
+# A result class specialized for holding tokens produced by the lexer.
+#
+# source://prism//lib/prism/lex_compat.rb#14
+class Prism::LexCompat::Result < ::Prism::Result
+ # Create a new lex compat result object with the given values.
+ #
+ # @return [Result] a new instance of Result
+ #
+ # source://prism//lib/prism/lex_compat.rb#19
+ def initialize(value, comments, magic_comments, data_loc, errors, warnings, source); end
+
+ # Implement the hash pattern matching interface for Result.
+ #
+ # source://prism//lib/prism/lex_compat.rb#25
+ def deconstruct_keys(keys); end
+
+ # The list of tokens that were produced by the lexer.
+ #
+ # source://prism//lib/prism/lex_compat.rb#16
+ def value; end
+end
+
+# When we produce tokens, we produce the same arrays that Ripper does.
+# However, we add a couple of convenience methods onto them to make them a
+# little easier to work with. We delegate all other methods to the array.
+#
+# source://prism//lib/prism/lex_compat.rb#204
+class Prism::LexCompat::Token < ::SimpleDelegator
+ # The type of the token.
+ #
+ # source://prism//lib/prism/lex_compat.rb#213
+ def event; end
+
+ # The location of the token in the source.
+ #
+ # source://prism//lib/prism/lex_compat.rb#208
+ def location; end
+
+ # The state of the lexer when this token was produced.
+ #
+ # source://prism//lib/prism/lex_compat.rb#223
+ def state; end
+
+ # The slice of the source that this token represents.
+ #
+ # source://prism//lib/prism/lex_compat.rb#218
+ def value; end
+end
+
+# This is a result specific to the `lex` and `lex_file` methods.
+#
+# source://prism//lib/prism/parse_result.rb#610
+class Prism::LexResult < ::Prism::Result
+ # Create a new lex result object with the given values.
+ #
+ # @return [LexResult] a new instance of LexResult
+ #
+ # source://prism//lib/prism/parse_result.rb#615
+ sig do
+ params(
+ value: T::Array[T.untyped],
+ comments: T::Array[Prism::Comment],
+ magic_comments: T::Array[Prism::MagicComment],
+ data_loc: T.nilable(Prism::Location),
+ errors: T::Array[Prism::ParseError],
+ warnings: T::Array[Prism::ParseWarning],
+ source: Prism::Source
+ ).void
+ end
+ def initialize(value, comments, magic_comments, data_loc, errors, warnings, source); end
+
+ # Implement the hash pattern matching interface for LexResult.
+ #
+ # source://prism//lib/prism/parse_result.rb#621
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # The list of tokens that were parsed from the source code.
+ #
+ # source://prism//lib/prism/parse_result.rb#612
+ sig { returns(T::Array[T.untyped]) }
+ def value; end
+end
+
+# This is a class that wraps the Ripper lexer to produce almost exactly the
+# same tokens.
+#
+# source://prism//lib/prism/lex_compat.rb#872
+class Prism::LexRipper
+ # @return [LexRipper] a new instance of LexRipper
+ #
+ # source://prism//lib/prism/lex_compat.rb#875
+ def initialize(source); end
+
+ # source://prism//lib/prism/lex_compat.rb#879
+ def result; end
+
+ # source://prism//lib/prism/lex_compat.rb#873
+ def source; end
+
+ private
+
+ # source://prism//lib/prism/lex_compat.rb#913
+ def lex(source); end
+end
+
+# Represents the use of the `&&=` operator for assignment to a local variable.
+#
+# target &&= value
+# ^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#11943
+class Prism::LocalVariableAndWriteNode < ::Prism::Node
+ # def initialize: (Location name_loc, Location operator_loc, Prism::node value, Symbol name, Integer depth, Location location) -> void
+ #
+ # @return [LocalVariableAndWriteNode] a new instance of LocalVariableAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#11945
+ sig do
+ params(
+ source: Prism::Source,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ name: Symbol,
+ depth: Integer,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name_loc, operator_loc, value, name, depth, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#12051
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#11956
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11961
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#11971
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#11966
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?name: Symbol, ?depth: Integer, ?location: Location) -> LocalVariableAndWriteNode
+ #
+ # source://prism//lib/prism/node.rb#11976
+ sig do
+ params(
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ name: Symbol,
+ depth: Integer,
+ location: Prism::Location
+ ).returns(Prism::LocalVariableAndWriteNode)
+ end
+ def copy(name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), name: T.unsafe(nil), depth: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#11961
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name_loc: Location, operator_loc: Location, value: Prism::node, name: Symbol, depth: Integer, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#11984
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader depth: Integer
+ #
+ # source://prism//lib/prism/node.rb#12009
+ sig { returns(Integer) }
+ def depth; end
+
+ # source://prism//lib/prism/desugar_compiler.rb#199
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#12017
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#12006
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#11989
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#12012
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#11996
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12035
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#12003
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12045
+ def type; end
+ end
+end
+
+# Represents assigning to a local variable using an operator that isn't `=`.
+#
+# target += value
+# ^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#12065
+class Prism::LocalVariableOperatorWriteNode < ::Prism::Node
+ # def initialize: (Location name_loc, Location binary_operator_loc, Prism::node value, Symbol name, Symbol binary_operator, Integer depth, Location location) -> void
+ #
+ # @return [LocalVariableOperatorWriteNode] a new instance of LocalVariableOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#12067
+ sig do
+ params(
+ source: Prism::Source,
+ name_loc: Prism::Location,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ name: Symbol,
+ binary_operator: Symbol,
+ depth: Integer,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name_loc, binary_operator_loc, value, name, binary_operator, depth, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#12172
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#12079
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader binary_operator: Symbol
+ #
+ # source://prism//lib/prism/node.rb#12132
+ sig { returns(Symbol) }
+ def binary_operator; end
+
+ # attr_reader binary_operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#12119
+ sig { returns(Prism::Location) }
+ def binary_operator_loc; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12084
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#12094
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#12089
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name_loc: Location, ?binary_operator_loc: Location, ?value: Prism::node, ?name: Symbol, ?binary_operator: Symbol, ?depth: Integer, ?location: Location) -> LocalVariableOperatorWriteNode
+ #
+ # source://prism//lib/prism/node.rb#12099
+ sig do
+ params(
+ name_loc: Prism::Location,
+ binary_operator_loc: Prism::Location,
+ value: Prism::Node,
+ name: Symbol,
+ binary_operator: Symbol,
+ depth: Integer,
+ location: Prism::Location
+ ).returns(Prism::LocalVariableOperatorWriteNode)
+ end
+ def copy(name_loc: T.unsafe(nil), binary_operator_loc: T.unsafe(nil), value: T.unsafe(nil), name: T.unsafe(nil), binary_operator: T.unsafe(nil), depth: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12084
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name_loc: Location, binary_operator_loc: Location, value: Prism::node, name: Symbol, binary_operator: Symbol, depth: Integer, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#12107
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader depth: Integer
+ #
+ # source://prism//lib/prism/node.rb#12135
+ sig { returns(Integer) }
+ def depth; end
+
+ # source://prism//lib/prism/desugar_compiler.rb#211
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#12138
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#12129
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#12112
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # Returns the binary operator used to modify the receiver. This method is
+ # deprecated in favor of #binary_operator.
+ #
+ # source://prism//lib/prism/node_ext.rb#435
+ def operator; end
+
+ # Returns the location of the binary operator used to modify the receiver.
+ # This method is deprecated in favor of #binary_operator_loc.
+ #
+ # source://prism//lib/prism/node_ext.rb#442
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12156
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#12126
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12166
+ def type; end
+ end
+end
+
+# Represents the use of the `||=` operator for assignment to a local variable.
+#
+# target ||= value
+# ^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#12187
+class Prism::LocalVariableOrWriteNode < ::Prism::Node
+ # def initialize: (Location name_loc, Location operator_loc, Prism::node value, Symbol name, Integer depth, Location location) -> void
+ #
+ # @return [LocalVariableOrWriteNode] a new instance of LocalVariableOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#12189
+ sig do
+ params(
+ source: Prism::Source,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ name: Symbol,
+ depth: Integer,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name_loc, operator_loc, value, name, depth, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#12295
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#12200
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12205
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#12215
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#12210
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?name: Symbol, ?depth: Integer, ?location: Location) -> LocalVariableOrWriteNode
+ #
+ # source://prism//lib/prism/node.rb#12220
+ sig do
+ params(
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ name: Symbol,
+ depth: Integer,
+ location: Prism::Location
+ ).returns(Prism::LocalVariableOrWriteNode)
+ end
+ def copy(name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), name: T.unsafe(nil), depth: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12205
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name_loc: Location, operator_loc: Location, value: Prism::node, name: Symbol, depth: Integer, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#12228
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader depth: Integer
+ #
+ # source://prism//lib/prism/node.rb#12253
+ sig { returns(Integer) }
+ def depth; end
+
+ # source://prism//lib/prism/desugar_compiler.rb#205
+ def desugar; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#12261
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#12250
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#12233
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#12256
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#12240
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12279
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#12247
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12289
+ def type; end
+ end
+end
+
+# Represents reading a local variable. Note that this requires that a local variable of the same name has already been written to in the same scope, otherwise it is parsed as a method call.
+#
+# foo
+# ^^^
+#
+# source://prism//lib/prism/node.rb#12309
+class Prism::LocalVariableReadNode < ::Prism::Node
+ # def initialize: (Symbol name, Integer depth, Location location) -> void
+ #
+ # @return [LocalVariableReadNode] a new instance of LocalVariableReadNode
+ #
+ # source://prism//lib/prism/node.rb#12311
+ sig { params(source: Prism::Source, name: Symbol, depth: Integer, location: Prism::Location).void }
+ def initialize(source, name, depth, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#12406
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#12319
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12324
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#12334
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#12329
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?depth: Integer, ?location: Location) -> LocalVariableReadNode
+ #
+ # source://prism//lib/prism/node.rb#12339
+ sig { params(name: Symbol, depth: Integer, location: Prism::Location).returns(Prism::LocalVariableReadNode) }
+ def copy(name: T.unsafe(nil), depth: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12324
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, depth: Integer, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#12347
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # The number of visible scopes that should be searched to find the origin of this local variable.
+ #
+ # foo = 1; foo # depth 0
+ #
+ # bar = 2; tap { bar } # depth 1
+ #
+ # The specific rules for calculating the depth may differ from individual Ruby implementations, as they are not specified by the language. For more information, see [the Prism documentation](https://github.com/ruby/prism/blob/main/docs/local_variable_depth.md).
+ #
+ # source://prism//lib/prism/node.rb#12369
+ sig { returns(Integer) }
+ def depth; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#12372
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the local variable, which is an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers).
+ #
+ # x # name `:x`
+ #
+ # _Test # name `:_Test`
+ #
+ # Note that this can also be an underscore followed by a number for the default block parameters.
+ #
+ # _1 # name `:_1`
+ #
+ # source://prism//lib/prism/node.rb#12360
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12390
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12400
+ def type; end
+ end
+end
+
+# Represents writing to a local variable in a context that doesn't have an explicit value.
+#
+# foo, bar = baz
+# ^^^ ^^^
+#
+# source://prism//lib/prism/node.rb#12417
+class Prism::LocalVariableTargetNode < ::Prism::Node
+ # def initialize: (Symbol name, Integer depth, Location location) -> void
+ #
+ # @return [LocalVariableTargetNode] a new instance of LocalVariableTargetNode
+ #
+ # source://prism//lib/prism/node.rb#12419
+ sig { params(source: Prism::Source, name: Symbol, depth: Integer, location: Prism::Location).void }
+ def initialize(source, name, depth, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#12500
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#12427
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12432
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#12442
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#12437
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?depth: Integer, ?location: Location) -> LocalVariableTargetNode
+ #
+ # source://prism//lib/prism/node.rb#12447
+ sig { params(name: Symbol, depth: Integer, location: Prism::Location).returns(Prism::LocalVariableTargetNode) }
+ def copy(name: T.unsafe(nil), depth: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12432
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, depth: Integer, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#12455
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader depth: Integer
+ #
+ # source://prism//lib/prism/node.rb#12463
+ sig { returns(Integer) }
+ def depth; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#12466
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#12460
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12484
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12494
+ def type; end
+ end
+end
+
+# Represents writing to a local variable.
+#
+# foo = 1
+# ^^^^^^^
+#
+# source://prism//lib/prism/node.rb#12511
+class Prism::LocalVariableWriteNode < ::Prism::Node
+ # def initialize: (Symbol name, Integer depth, Location name_loc, Prism::node value, Location operator_loc, Location location) -> void
+ #
+ # @return [LocalVariableWriteNode] a new instance of LocalVariableWriteNode
+ #
+ # source://prism//lib/prism/node.rb#12513
+ sig do
+ params(
+ source: Prism::Source,
+ name: Symbol,
+ depth: Integer,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, name, depth, name_loc, value, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#12645
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#12524
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12529
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#12539
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#12534
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?name: Symbol, ?depth: Integer, ?name_loc: Location, ?value: Prism::node, ?operator_loc: Location, ?location: Location) -> LocalVariableWriteNode
+ #
+ # source://prism//lib/prism/node.rb#12544
+ sig do
+ params(
+ name: Symbol,
+ depth: Integer,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::LocalVariableWriteNode)
+ end
+ def copy(name: T.unsafe(nil), depth: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12529
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { name: Symbol, depth: Integer, name_loc: Location, value: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#12552
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # The number of semantic scopes we have to traverse to find the declaration of this variable.
+ #
+ # foo = 1 # depth 0
+ #
+ # tap { foo = 1 } # depth 1
+ #
+ # The specific rules for calculating the depth may differ from individual Ruby implementations, as they are not specified by the language. For more information, see [the Prism documentation](https://github.com/ruby/prism/blob/main/docs/local_variable_depth.md).
+ #
+ # source://prism//lib/prism/node.rb#12570
+ sig { returns(Integer) }
+ def depth; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#12611
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The name of the local variable, which is an [identifier](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#identifiers).
+ #
+ # foo = :bar # name `:foo`
+ #
+ # abc = 123 # name `:abc`
+ #
+ # source://prism//lib/prism/node.rb#12561
+ sig { returns(Symbol) }
+ def name; end
+
+ # The location of the variable name.
+ #
+ # foo = :bar
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#12576
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#12606
+ sig { returns(String) }
+ def operator; end
+
+ # The location of the `=` operator.
+ #
+ # x = :y
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#12599
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12629
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # The value to write to the local variable. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # foo = :bar
+ # ^^^^
+ #
+ # abc = 1234
+ # ^^^^
+ #
+ # Note that since the name of a local variable is known before the value is parsed, it is valid for a local variable to appear within the value of its own write.
+ #
+ # foo = foo
+ #
+ # source://prism//lib/prism/node.rb#12593
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12639
+ def type; end
+ end
+end
+
+# This represents a location in the source.
+#
+# source://prism//lib/prism/parse_result.rb#156
+class Prism::Location
+ # Create a new location object with the given source, start byte offset, and
+ # byte length.
+ #
+ # @return [Location] a new instance of Location
+ #
+ # source://prism//lib/prism/parse_result.rb#171
+ sig { params(source: Prism::Source, start_offset: Integer, length: Integer).void }
+ def initialize(source, start_offset, length); end
+
+ # Returns true if the given other location is equal to this location.
+ #
+ # source://prism//lib/prism/parse_result.rb#335
+ sig { params(other: T.untyped).returns(T::Boolean) }
+ def ==(other); end
+
+ # Join this location with the first occurrence of the string in the source
+ # that occurs after this location on the same line, and return the new
+ # location. This will raise an error if the string does not exist.
+ #
+ # source://prism//lib/prism/parse_result.rb#354
+ sig { params(string: String).returns(Prism::Location) }
+ def adjoin(string); end
+
+ # Returns a new location that is the result of chopping off the last byte.
+ #
+ # source://prism//lib/prism/parse_result.rb#217
+ sig { returns(Prism::Location) }
+ def chop; end
+
+ # Returns all comments that are associated with this location (both leading
+ # and trailing comments).
+ #
+ # source://prism//lib/prism/parse_result.rb#207
+ sig { returns(T::Array[Prism::Comment]) }
+ def comments; end
+
+ # Create a new location object with the given options.
+ #
+ # source://prism//lib/prism/parse_result.rb#212
+ sig { params(source: Prism::Source, start_offset: Integer, length: Integer).returns(Prism::Location) }
+ def copy(source: T.unsafe(nil), start_offset: T.unsafe(nil), length: T.unsafe(nil)); end
+
+ # Implement the hash pattern matching interface for Location.
+ #
+ # source://prism//lib/prism/parse_result.rb#325
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # The column number in characters where this location ends from the start of
+ # the line.
+ #
+ # source://prism//lib/prism/parse_result.rb#314
+ sig { returns(Integer) }
+ def end_character_column; end
+
+ # The character offset from the beginning of the source where this location
+ # ends.
+ #
+ # source://prism//lib/prism/parse_result.rb#263
+ sig { returns(Integer) }
+ def end_character_offset; end
+
+ # The column number in code units of the given encoding where this location
+ # ends from the start of the line.
+ #
+ # source://prism//lib/prism/parse_result.rb#320
+ sig { params(encoding: Encoding).returns(Integer) }
+ def end_code_units_column(encoding = T.unsafe(nil)); end
+
+ # The offset from the start of the file in code units of the given encoding.
+ #
+ # source://prism//lib/prism/parse_result.rb#268
+ sig { params(encoding: Encoding).returns(Integer) }
+ def end_code_units_offset(encoding = T.unsafe(nil)); end
+
+ # The column number in bytes where this location ends from the start of the
+ # line.
+ #
+ # source://prism//lib/prism/parse_result.rb#308
+ sig { returns(Integer) }
+ def end_column; end
+
+ # The line number where this location ends.
+ #
+ # source://prism//lib/prism/parse_result.rb#284
+ sig { returns(Integer) }
+ def end_line; end
+
+ # The byte offset from the beginning of the source where this location ends.
+ #
+ # source://prism//lib/prism/parse_result.rb#257
+ sig { returns(Integer) }
+ def end_offset; end
+
+ # Returns a string representation of this location.
+ #
+ # source://prism//lib/prism/parse_result.rb#222
+ sig { returns(String) }
+ def inspect; end
+
+ # Returns a new location that stretches from this location to the given
+ # other location. Raises an error if this location is not before the other
+ # location or if they don't share the same source.
+ #
+ # source://prism//lib/prism/parse_result.rb#344
+ sig { params(other: Prism::Location).returns(Prism::Location) }
+ def join(other); end
+
+ # Attach a comment to the leading comments of this location.
+ #
+ # source://prism//lib/prism/parse_result.rb#190
+ sig { params(comment: Prism::Comment).void }
+ def leading_comment(comment); end
+
+ # These are the comments that are associated with this location that exist
+ # before the start of this location.
+ #
+ # source://prism//lib/prism/parse_result.rb#185
+ sig { returns(T::Array[Prism::Comment]) }
+ def leading_comments; end
+
+ # The length of this location in bytes.
+ #
+ # source://prism//lib/prism/parse_result.rb#167
+ sig { returns(Integer) }
+ def length; end
+
+ # Implement the pretty print interface for Location.
+ #
+ # source://prism//lib/prism/parse_result.rb#330
+ sig { params(q: T.untyped).void }
+ def pretty_print(q); end
+
+ # The source code that this location represents.
+ #
+ # source://prism//lib/prism/parse_result.rb#232
+ sig { returns(String) }
+ def slice; end
+
+ # The source code that this location represents starting from the beginning
+ # of the line that this location starts on to the end of the line that this
+ # location ends on.
+ #
+ # source://prism//lib/prism/parse_result.rb#239
+ def slice_lines; end
+
+ # Returns all of the lines of the source code associated with this location.
+ #
+ # source://prism//lib/prism/parse_result.rb#227
+ sig { returns(T::Array[String]) }
+ def source_lines; end
+
+ # The column number in characters where this location ends from the start of
+ # the line.
+ #
+ # source://prism//lib/prism/parse_result.rb#296
+ sig { returns(Integer) }
+ def start_character_column; end
+
+ # The character offset from the beginning of the source where this location
+ # starts.
+ #
+ # source://prism//lib/prism/parse_result.rb#247
+ sig { returns(Integer) }
+ def start_character_offset; end
+
+ # The column number in code units of the given encoding where this location
+ # starts from the start of the line.
+ #
+ # source://prism//lib/prism/parse_result.rb#302
+ sig { params(encoding: Encoding).returns(Integer) }
+ def start_code_units_column(encoding = T.unsafe(nil)); end
+
+ # The offset from the start of the file in code units of the given encoding.
+ #
+ # source://prism//lib/prism/parse_result.rb#252
+ sig { params(encoding: Encoding).returns(Integer) }
+ def start_code_units_offset(encoding = T.unsafe(nil)); end
+
+ # The column number in bytes where this location starts from the start of
+ # the line.
+ #
+ # source://prism//lib/prism/parse_result.rb#290
+ sig { returns(Integer) }
+ def start_column; end
+
+ # The line number where this location starts.
+ #
+ # source://prism//lib/prism/parse_result.rb#273
+ sig { returns(Integer) }
+ def start_line; end
+
+ # The content of the line where this location starts before this location.
+ #
+ # source://prism//lib/prism/parse_result.rb#278
+ sig { returns(String) }
+ def start_line_slice; end
+
+ # The byte offset from the beginning of the source where this location
+ # starts.
+ #
+ # source://prism//lib/prism/parse_result.rb#164
+ sig { returns(Integer) }
+ def start_offset; end
+
+ # Attach a comment to the trailing comments of this location.
+ #
+ # source://prism//lib/prism/parse_result.rb#201
+ sig { params(comment: Prism::Comment).void }
+ def trailing_comment(comment); end
+
+ # These are the comments that are associated with this location that exist
+ # after the end of this location.
+ #
+ # source://prism//lib/prism/parse_result.rb#196
+ sig { returns(T::Array[Prism::Comment]) }
+ def trailing_comments; end
+
+ protected
+
+ # A Source object that is used to determine more information from the given
+ # offset and length.
+ #
+ # source://prism//lib/prism/parse_result.rb#159
+ sig { returns(Prism::Source) }
+ def source; end
+end
+
+# Flags for while and until loop nodes.
+#
+# source://prism//lib/prism/node.rb#19196
+module Prism::LoopFlags; end
+
+# a loop after a begin statement, so the body is executed first before the condition
+#
+# source://prism//lib/prism/node.rb#19198
+Prism::LoopFlags::BEGIN_MODIFIER = T.let(T.unsafe(nil), Integer)
+
+# This represents a magic comment that was encountered during parsing.
+#
+# source://prism//lib/prism/parse_result.rb#416
+class Prism::MagicComment
+ # Create a new magic comment object with the given key and value locations.
+ #
+ # @return [MagicComment] a new instance of MagicComment
+ #
+ # source://prism//lib/prism/parse_result.rb#424
+ sig { params(key_loc: Prism::Location, value_loc: Prism::Location).void }
+ def initialize(key_loc, value_loc); end
+
+ # Implement the hash pattern matching interface for MagicComment.
+ #
+ # source://prism//lib/prism/parse_result.rb#440
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # Returns a string representation of this magic comment.
+ #
+ # source://prism//lib/prism/parse_result.rb#445
+ sig { returns(String) }
+ def inspect; end
+
+ # Returns the key of the magic comment by slicing it from the source code.
+ #
+ # source://prism//lib/prism/parse_result.rb#430
+ sig { returns(String) }
+ def key; end
+
+ # A Location object representing the location of the key in the source.
+ #
+ # source://prism//lib/prism/parse_result.rb#418
+ sig { returns(Prism::Location) }
+ def key_loc; end
+
+ # Returns the value of the magic comment by slicing it from the source code.
+ #
+ # source://prism//lib/prism/parse_result.rb#435
+ sig { returns(String) }
+ def value; end
+
+ # A Location object representing the location of the value in the source.
+ #
+ # source://prism//lib/prism/parse_result.rb#421
+ sig { returns(Prism::Location) }
+ def value_loc; end
+end
+
+# Represents a regular expression literal used in the predicate of a conditional to implicitly match against the last line read by an IO object.
+#
+# if /foo/i then end
+# ^^^^^^
+#
+# source://prism//lib/prism/node.rb#12659
+class Prism::MatchLastLineNode < ::Prism::Node
+ include ::Prism::RegularExpressionOptions
+
+ # def initialize: (Integer flags, Location opening_loc, Location content_loc, Location closing_loc, String unescaped, Location location) -> void
+ #
+ # @return [MatchLastLineNode] a new instance of MatchLastLineNode
+ #
+ # source://prism//lib/prism/node.rb#12661
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ opening_loc: Prism::Location,
+ content_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ unescaped: String,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, opening_loc, content_loc, closing_loc, unescaped, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#12837
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#12672
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def ascii_8bit?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#12758
+ sig { returns(T::Boolean) }
+ def ascii_8bit?; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12677
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#12798
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#12723
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#12687
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#12682
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def content: () -> String
+ #
+ # source://prism//lib/prism/node.rb#12793
+ sig { returns(String) }
+ def content; end
+
+ # attr_reader content_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#12716
+ sig { returns(Prism::Location) }
+ def content_loc; end
+
+ # def copy: (?flags: Integer, ?opening_loc: Location, ?content_loc: Location, ?closing_loc: Location, ?unescaped: String, ?location: Location) -> MatchLastLineNode
+ #
+ # source://prism//lib/prism/node.rb#12692
+ sig do
+ params(
+ flags: Integer,
+ opening_loc: Prism::Location,
+ content_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ unescaped: String,
+ location: Prism::Location
+ ).returns(Prism::MatchLastLineNode)
+ end
+ def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), content_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), unescaped: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12677
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location, content_loc: Location, closing_loc: Location, unescaped: String, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#12700
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def euc_jp?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#12753
+ sig { returns(T::Boolean) }
+ def euc_jp?; end
+
+ # def extended?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#12738
+ sig { returns(T::Boolean) }
+ def extended?; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def forced_binary_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#12778
+ sig { returns(T::Boolean) }
+ def forced_binary_encoding?; end
+
+ # def forced_us_ascii_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#12783
+ sig { returns(T::Boolean) }
+ def forced_us_ascii_encoding?; end
+
+ # def forced_utf8_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#12773
+ sig { returns(T::Boolean) }
+ def forced_utf8_encoding?; end
+
+ # def ignore_case?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#12733
+ sig { returns(T::Boolean) }
+ def ignore_case?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#12803
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def multi_line?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#12743
+ sig { returns(T::Boolean) }
+ def multi_line?; end
+
+ # def once?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#12748
+ sig { returns(T::Boolean) }
+ def once?; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#12788
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#12709
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ sig { returns(Integer) }
+ def options; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12821
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader unescaped: String
+ #
+ # source://prism//lib/prism/node.rb#12730
+ sig { returns(String) }
+ def unescaped; end
+
+ # def utf_8?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#12768
+ sig { returns(T::Boolean) }
+ def utf_8?; end
+
+ # def windows_31j?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#12763
+ sig { returns(T::Boolean) }
+ def windows_31j?; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#12705
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12831
+ def type; end
+ end
+end
+
+# Represents the use of the modifier `in` operator.
+#
+# foo in bar
+# ^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#12851
+class Prism::MatchPredicateNode < ::Prism::Node
+ # def initialize: (Prism::node value, Prism::node pattern, Location operator_loc, Location location) -> void
+ #
+ # @return [MatchPredicateNode] a new instance of MatchPredicateNode
+ #
+ # source://prism//lib/prism/node.rb#12853
+ sig do
+ params(
+ source: Prism::Source,
+ value: Prism::Node,
+ pattern: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, value, pattern, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#12947
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#12862
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12867
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#12877
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#12872
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?value: Prism::node, ?pattern: Prism::node, ?operator_loc: Location, ?location: Location) -> MatchPredicateNode
+ #
+ # source://prism//lib/prism/node.rb#12882
+ sig do
+ params(
+ value: Prism::Node,
+ pattern: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::MatchPredicateNode)
+ end
+ def copy(value: T.unsafe(nil), pattern: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12867
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { value: Prism::node, pattern: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#12890
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#12913
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#12908
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#12901
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader pattern: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#12898
+ sig { returns(Prism::Node) }
+ def pattern; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12931
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#12895
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#12941
+ def type; end
+ end
+end
+
+# Represents the use of the `=>` operator.
+#
+# foo => bar
+# ^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#12959
+class Prism::MatchRequiredNode < ::Prism::Node
+ # def initialize: (Prism::node value, Prism::node pattern, Location operator_loc, Location location) -> void
+ #
+ # @return [MatchRequiredNode] a new instance of MatchRequiredNode
+ #
+ # source://prism//lib/prism/node.rb#12961
+ sig do
+ params(
+ source: Prism::Source,
+ value: Prism::Node,
+ pattern: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, value, pattern, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#13055
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#12970
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12975
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#12985
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#12980
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?value: Prism::node, ?pattern: Prism::node, ?operator_loc: Location, ?location: Location) -> MatchRequiredNode
+ #
+ # source://prism//lib/prism/node.rb#12990
+ sig do
+ params(
+ value: Prism::Node,
+ pattern: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::MatchRequiredNode)
+ end
+ def copy(value: T.unsafe(nil), pattern: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#12975
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { value: Prism::node, pattern: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#12998
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#13021
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#13016
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#13009
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader pattern: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#13006
+ sig { returns(Prism::Node) }
+ def pattern; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13039
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#13003
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13049
+ def type; end
+ end
+end
+
+# Represents writing local variables using a regular expression match with named capture groups.
+#
+# /(?bar)/ =~ baz
+# ^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#13067
+class Prism::MatchWriteNode < ::Prism::Node
+ # def initialize: (CallNode call, Array[LocalVariableTargetNode] targets, Location location) -> void
+ #
+ # @return [MatchWriteNode] a new instance of MatchWriteNode
+ #
+ # source://prism//lib/prism/node.rb#13069
+ sig do
+ params(
+ source: Prism::Source,
+ call: Prism::CallNode,
+ targets: T::Array[Prism::LocalVariableTargetNode],
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, call, targets, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#13150
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#13077
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader call: CallNode
+ #
+ # source://prism//lib/prism/node.rb#13110
+ sig { returns(Prism::CallNode) }
+ def call; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13082
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#13092
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#13087
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?call: CallNode, ?targets: Array[LocalVariableTargetNode], ?location: Location) -> MatchWriteNode
+ #
+ # source://prism//lib/prism/node.rb#13097
+ sig do
+ params(
+ call: Prism::CallNode,
+ targets: T::Array[Prism::LocalVariableTargetNode],
+ location: Prism::Location
+ ).returns(Prism::MatchWriteNode)
+ end
+ def copy(call: T.unsafe(nil), targets: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13082
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { call: CallNode, targets: Array[LocalVariableTargetNode], location: Location }
+ #
+ # source://prism//lib/prism/node.rb#13105
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#13116
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader targets: Array[LocalVariableTargetNode]
+ #
+ # source://prism//lib/prism/node.rb#13113
+ sig { returns(T::Array[Prism::LocalVariableTargetNode]) }
+ def targets; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13134
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13144
+ def type; end
+ end
+end
+
+# Represents a node that is missing from the source and results in a syntax error.
+#
+# source://prism//lib/prism/node.rb#13159
+class Prism::MissingNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [MissingNode] a new instance of MissingNode
+ #
+ # source://prism//lib/prism/node.rb#13161
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#13234
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#13167
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13172
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#13182
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#13177
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> MissingNode
+ #
+ # source://prism//lib/prism/node.rb#13187
+ sig { params(location: Prism::Location).returns(Prism::MissingNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13172
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#13195
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#13200
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13218
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13228
+ def type; end
+ end
+end
+
+# Represents a module declaration involving the `module` keyword.
+#
+# module Foo end
+# ^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#13243
+class Prism::ModuleNode < ::Prism::Node
+ # def initialize: (Array[Symbol] locals, Location module_keyword_loc, Prism::node constant_path, Prism::node? body, Location end_keyword_loc, Symbol name, Location location) -> void
+ #
+ # @return [ModuleNode] a new instance of ModuleNode
+ #
+ # source://prism//lib/prism/node.rb#13245
+ sig do
+ params(
+ source: Prism::Source,
+ locals: T::Array[Symbol],
+ module_keyword_loc: Prism::Location,
+ constant_path: Prism::Node,
+ body: T.nilable(Prism::Node),
+ end_keyword_loc: Prism::Location,
+ name: Symbol,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, locals, module_keyword_loc, constant_path, body, end_keyword_loc, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#13363
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#13257
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader body: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#13306
+ sig { returns(T.nilable(Prism::Node)) }
+ def body; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13262
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#13275
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#13267
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # attr_reader constant_path: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#13303
+ sig { returns(Prism::Node) }
+ def constant_path; end
+
+ # def copy: (?locals: Array[Symbol], ?module_keyword_loc: Location, ?constant_path: Prism::node, ?body: Prism::node?, ?end_keyword_loc: Location, ?name: Symbol, ?location: Location) -> ModuleNode
+ #
+ # source://prism//lib/prism/node.rb#13280
+ sig do
+ params(
+ locals: T::Array[Symbol],
+ module_keyword_loc: Prism::Location,
+ constant_path: Prism::Node,
+ body: T.nilable(Prism::Node),
+ end_keyword_loc: Prism::Location,
+ name: Symbol,
+ location: Prism::Location
+ ).returns(Prism::ModuleNode)
+ end
+ def copy(locals: T.unsafe(nil), module_keyword_loc: T.unsafe(nil), constant_path: T.unsafe(nil), body: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13262
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], module_keyword_loc: Location, constant_path: Prism::node, body: Prism::node?, end_keyword_loc: Location, name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#13288
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def end_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#13324
+ sig { returns(String) }
+ def end_keyword; end
+
+ # attr_reader end_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#13309
+ sig { returns(Prism::Location) }
+ def end_keyword_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#13329
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader locals: Array[Symbol]
+ #
+ # source://prism//lib/prism/node.rb#13293
+ sig { returns(T::Array[Symbol]) }
+ def locals; end
+
+ # def module_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#13319
+ sig { returns(String) }
+ def module_keyword; end
+
+ # attr_reader module_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#13296
+ sig { returns(Prism::Location) }
+ def module_keyword_loc; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#13316
+ sig { returns(Symbol) }
+ def name; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13347
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13357
+ def type; end
+ end
+end
+
+# Represents a multi-target expression.
+#
+# a, (b, c) = 1, 2, 3
+# ^^^^^^
+#
+# source://prism//lib/prism/node.rb#13379
+class Prism::MultiTargetNode < ::Prism::Node
+ # def initialize: (Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode | NumberedReferenceReadNode] lefts, Prism::node? rest, Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode] rights, Location? lparen_loc, Location? rparen_loc, Location location) -> void
+ #
+ # @return [MultiTargetNode] a new instance of MultiTargetNode
+ #
+ # source://prism//lib/prism/node.rb#13381
+ sig do
+ params(
+ source: Prism::Source,
+ lefts: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode, Prism::NumberedReferenceReadNode)],
+ rest: T.nilable(Prism::Node),
+ rights: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode)],
+ lparen_loc: T.nilable(Prism::Location),
+ rparen_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, lefts, rest, rights, lparen_loc, rparen_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#13508
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#13392
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13397
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#13411
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#13402
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode | NumberedReferenceReadNode], ?rest: Prism::node?, ?rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode], ?lparen_loc: Location?, ?rparen_loc: Location?, ?location: Location) -> MultiTargetNode
+ #
+ # source://prism//lib/prism/node.rb#13416
+ sig do
+ params(
+ lefts: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode, Prism::NumberedReferenceReadNode)],
+ rest: T.nilable(Prism::Node),
+ rights: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode)],
+ lparen_loc: T.nilable(Prism::Location),
+ rparen_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::MultiTargetNode)
+ end
+ def copy(lefts: T.unsafe(nil), rest: T.unsafe(nil), rights: T.unsafe(nil), lparen_loc: T.unsafe(nil), rparen_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13397
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode | NumberedReferenceReadNode], rest: Prism::node?, rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode], lparen_loc: Location?, rparen_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#13424
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#13474
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode | NumberedReferenceReadNode]
+ #
+ # source://prism//lib/prism/node.rb#13429
+ sig do
+ returns(T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode, Prism::NumberedReferenceReadNode)])
+ end
+ def lefts; end
+
+ # def lparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#13464
+ sig { returns(T.nilable(String)) }
+ def lparen; end
+
+ # attr_reader lparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#13438
+ sig { returns(T.nilable(Prism::Location)) }
+ def lparen_loc; end
+
+ # attr_reader rest: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#13432
+ sig { returns(T.nilable(Prism::Node)) }
+ def rest; end
+
+ # attr_reader rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode | RequiredParameterNode | BackReferenceReadNode]
+ #
+ # source://prism//lib/prism/node.rb#13435
+ sig do
+ returns(T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode, Prism::RequiredParameterNode, Prism::BackReferenceReadNode)])
+ end
+ def rights; end
+
+ # def rparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#13469
+ sig { returns(T.nilable(String)) }
+ def rparen; end
+
+ # attr_reader rparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#13451
+ sig { returns(T.nilable(Prism::Location)) }
+ def rparen_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13492
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13502
+ def type; end
+ end
+end
+
+# Represents a write to a multi-target expression.
+#
+# a, b, c = 1, 2, 3
+# ^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#13524
+class Prism::MultiWriteNode < ::Prism::Node
+ # def initialize: (Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode] lefts, Prism::node? rest, Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode] rights, Location? lparen_loc, Location? rparen_loc, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [MultiWriteNode] a new instance of MultiWriteNode
+ #
+ # source://prism//lib/prism/node.rb#13526
+ sig do
+ params(
+ source: Prism::Source,
+ lefts: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)],
+ rest: T.nilable(Prism::Node),
+ rights: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)],
+ lparen_loc: T.nilable(Prism::Location),
+ rparen_loc: T.nilable(Prism::Location),
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, lefts, rest, rights, lparen_loc, rparen_loc, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#13671
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#13539
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13544
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#13559
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#13549
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode], ?rest: Prism::node?, ?rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode], ?lparen_loc: Location?, ?rparen_loc: Location?, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> MultiWriteNode
+ #
+ # source://prism//lib/prism/node.rb#13564
+ sig do
+ params(
+ lefts: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)],
+ rest: T.nilable(Prism::Node),
+ rights: T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)],
+ lparen_loc: T.nilable(Prism::Location),
+ rparen_loc: T.nilable(Prism::Location),
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::MultiWriteNode)
+ end
+ def copy(lefts: T.unsafe(nil), rest: T.unsafe(nil), rights: T.unsafe(nil), lparen_loc: T.unsafe(nil), rparen_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13544
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode], rest: Prism::node?, rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode], lparen_loc: Location?, rparen_loc: Location?, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#13572
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#13637
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader lefts: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode]
+ #
+ # source://prism//lib/prism/node.rb#13577
+ sig do
+ returns(T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)])
+ end
+ def lefts; end
+
+ # def lparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#13622
+ sig { returns(T.nilable(String)) }
+ def lparen; end
+
+ # attr_reader lparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#13586
+ sig { returns(T.nilable(Prism::Location)) }
+ def lparen_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#13632
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#13612
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # attr_reader rest: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#13580
+ sig { returns(T.nilable(Prism::Node)) }
+ def rest; end
+
+ # attr_reader rights: Array[LocalVariableTargetNode | InstanceVariableTargetNode | ClassVariableTargetNode | GlobalVariableTargetNode | ConstantTargetNode | ConstantPathTargetNode | CallTargetNode | IndexTargetNode | MultiTargetNode]
+ #
+ # source://prism//lib/prism/node.rb#13583
+ sig do
+ returns(T::Array[T.any(Prism::LocalVariableTargetNode, Prism::InstanceVariableTargetNode, Prism::ClassVariableTargetNode, Prism::GlobalVariableTargetNode, Prism::ConstantTargetNode, Prism::ConstantPathTargetNode, Prism::CallTargetNode, Prism::IndexTargetNode, Prism::MultiTargetNode)])
+ end
+ def rights; end
+
+ # def rparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#13627
+ sig { returns(T.nilable(String)) }
+ def rparen; end
+
+ # attr_reader rparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#13599
+ sig { returns(T.nilable(Prism::Location)) }
+ def rparen_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13655
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#13619
+ sig { returns(Prism::Node) }
+ def value; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13665
+ def type; end
+ end
+end
+
+# This visitor walks through the tree and copies each node as it is being
+# visited. This is useful for consumers that want to mutate the tree, as you
+# can change subtrees in place without effecting the rest of the tree.
+#
+# source://prism//lib/prism/mutation_compiler.rb#13
+class Prism::MutationCompiler < ::Prism::Compiler
+ # Copy a AliasGlobalVariableNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#15
+ def visit_alias_global_variable_node(node); end
+
+ # Copy a AliasMethodNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#20
+ def visit_alias_method_node(node); end
+
+ # Copy a AlternationPatternNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#25
+ def visit_alternation_pattern_node(node); end
+
+ # Copy a AndNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#30
+ def visit_and_node(node); end
+
+ # Copy a ArgumentsNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#35
+ def visit_arguments_node(node); end
+
+ # Copy a ArrayNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#40
+ def visit_array_node(node); end
+
+ # Copy a ArrayPatternNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#45
+ def visit_array_pattern_node(node); end
+
+ # Copy a AssocNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#50
+ def visit_assoc_node(node); end
+
+ # Copy a AssocSplatNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#55
+ def visit_assoc_splat_node(node); end
+
+ # Copy a BackReferenceReadNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#60
+ def visit_back_reference_read_node(node); end
+
+ # Copy a BeginNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#65
+ def visit_begin_node(node); end
+
+ # Copy a BlockArgumentNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#70
+ def visit_block_argument_node(node); end
+
+ # Copy a BlockLocalVariableNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#75
+ def visit_block_local_variable_node(node); end
+
+ # Copy a BlockNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#80
+ def visit_block_node(node); end
+
+ # Copy a BlockParameterNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#85
+ def visit_block_parameter_node(node); end
+
+ # Copy a BlockParametersNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#90
+ def visit_block_parameters_node(node); end
+
+ # Copy a BreakNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#95
+ def visit_break_node(node); end
+
+ # Copy a CallAndWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#100
+ def visit_call_and_write_node(node); end
+
+ # Copy a CallNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#105
+ def visit_call_node(node); end
+
+ # Copy a CallOperatorWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#110
+ def visit_call_operator_write_node(node); end
+
+ # Copy a CallOrWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#115
+ def visit_call_or_write_node(node); end
+
+ # Copy a CallTargetNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#120
+ def visit_call_target_node(node); end
+
+ # Copy a CapturePatternNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#125
+ def visit_capture_pattern_node(node); end
+
+ # Copy a CaseMatchNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#130
+ def visit_case_match_node(node); end
+
+ # Copy a CaseNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#135
+ def visit_case_node(node); end
+
+ # Copy a ClassNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#140
+ def visit_class_node(node); end
+
+ # Copy a ClassVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#145
+ def visit_class_variable_and_write_node(node); end
+
+ # Copy a ClassVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#150
+ def visit_class_variable_operator_write_node(node); end
+
+ # Copy a ClassVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#155
+ def visit_class_variable_or_write_node(node); end
+
+ # Copy a ClassVariableReadNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#160
+ def visit_class_variable_read_node(node); end
+
+ # Copy a ClassVariableTargetNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#165
+ def visit_class_variable_target_node(node); end
+
+ # Copy a ClassVariableWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#170
+ def visit_class_variable_write_node(node); end
+
+ # Copy a ConstantAndWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#175
+ def visit_constant_and_write_node(node); end
+
+ # Copy a ConstantOperatorWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#180
+ def visit_constant_operator_write_node(node); end
+
+ # Copy a ConstantOrWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#185
+ def visit_constant_or_write_node(node); end
+
+ # Copy a ConstantPathAndWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#190
+ def visit_constant_path_and_write_node(node); end
+
+ # Copy a ConstantPathNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#195
+ def visit_constant_path_node(node); end
+
+ # Copy a ConstantPathOperatorWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#200
+ def visit_constant_path_operator_write_node(node); end
+
+ # Copy a ConstantPathOrWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#205
+ def visit_constant_path_or_write_node(node); end
+
+ # Copy a ConstantPathTargetNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#210
+ def visit_constant_path_target_node(node); end
+
+ # Copy a ConstantPathWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#215
+ def visit_constant_path_write_node(node); end
+
+ # Copy a ConstantReadNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#220
+ def visit_constant_read_node(node); end
+
+ # Copy a ConstantTargetNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#225
+ def visit_constant_target_node(node); end
+
+ # Copy a ConstantWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#230
+ def visit_constant_write_node(node); end
+
+ # Copy a DefNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#235
+ def visit_def_node(node); end
+
+ # Copy a DefinedNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#240
+ def visit_defined_node(node); end
+
+ # Copy a ElseNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#245
+ def visit_else_node(node); end
+
+ # Copy a EmbeddedStatementsNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#250
+ def visit_embedded_statements_node(node); end
+
+ # Copy a EmbeddedVariableNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#255
+ def visit_embedded_variable_node(node); end
+
+ # Copy a EnsureNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#260
+ def visit_ensure_node(node); end
+
+ # Copy a FalseNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#265
+ def visit_false_node(node); end
+
+ # Copy a FindPatternNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#270
+ def visit_find_pattern_node(node); end
+
+ # Copy a FlipFlopNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#275
+ def visit_flip_flop_node(node); end
+
+ # Copy a FloatNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#280
+ def visit_float_node(node); end
+
+ # Copy a ForNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#285
+ def visit_for_node(node); end
+
+ # Copy a ForwardingArgumentsNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#290
+ def visit_forwarding_arguments_node(node); end
+
+ # Copy a ForwardingParameterNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#295
+ def visit_forwarding_parameter_node(node); end
+
+ # Copy a ForwardingSuperNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#300
+ def visit_forwarding_super_node(node); end
+
+ # Copy a GlobalVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#305
+ def visit_global_variable_and_write_node(node); end
+
+ # Copy a GlobalVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#310
+ def visit_global_variable_operator_write_node(node); end
+
+ # Copy a GlobalVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#315
+ def visit_global_variable_or_write_node(node); end
+
+ # Copy a GlobalVariableReadNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#320
+ def visit_global_variable_read_node(node); end
+
+ # Copy a GlobalVariableTargetNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#325
+ def visit_global_variable_target_node(node); end
+
+ # Copy a GlobalVariableWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#330
+ def visit_global_variable_write_node(node); end
+
+ # Copy a HashNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#335
+ def visit_hash_node(node); end
+
+ # Copy a HashPatternNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#340
+ def visit_hash_pattern_node(node); end
+
+ # Copy a IfNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#345
+ def visit_if_node(node); end
+
+ # Copy a ImaginaryNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#350
+ def visit_imaginary_node(node); end
+
+ # Copy a ImplicitNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#355
+ def visit_implicit_node(node); end
+
+ # Copy a ImplicitRestNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#360
+ def visit_implicit_rest_node(node); end
+
+ # Copy a InNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#365
+ def visit_in_node(node); end
+
+ # Copy a IndexAndWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#370
+ def visit_index_and_write_node(node); end
+
+ # Copy a IndexOperatorWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#375
+ def visit_index_operator_write_node(node); end
+
+ # Copy a IndexOrWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#380
+ def visit_index_or_write_node(node); end
+
+ # Copy a IndexTargetNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#385
+ def visit_index_target_node(node); end
+
+ # Copy a InstanceVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#390
+ def visit_instance_variable_and_write_node(node); end
+
+ # Copy a InstanceVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#395
+ def visit_instance_variable_operator_write_node(node); end
+
+ # Copy a InstanceVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#400
+ def visit_instance_variable_or_write_node(node); end
+
+ # Copy a InstanceVariableReadNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#405
+ def visit_instance_variable_read_node(node); end
+
+ # Copy a InstanceVariableTargetNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#410
+ def visit_instance_variable_target_node(node); end
+
+ # Copy a InstanceVariableWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#415
+ def visit_instance_variable_write_node(node); end
+
+ # Copy a IntegerNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#420
+ def visit_integer_node(node); end
+
+ # Copy a InterpolatedMatchLastLineNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#425
+ def visit_interpolated_match_last_line_node(node); end
+
+ # Copy a InterpolatedRegularExpressionNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#430
+ def visit_interpolated_regular_expression_node(node); end
+
+ # Copy a InterpolatedStringNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#435
+ def visit_interpolated_string_node(node); end
+
+ # Copy a InterpolatedSymbolNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#440
+ def visit_interpolated_symbol_node(node); end
+
+ # Copy a InterpolatedXStringNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#445
+ def visit_interpolated_x_string_node(node); end
+
+ # Copy a ItLocalVariableReadNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#450
+ def visit_it_local_variable_read_node(node); end
+
+ # Copy a ItParametersNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#455
+ def visit_it_parameters_node(node); end
+
+ # Copy a KeywordHashNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#460
+ def visit_keyword_hash_node(node); end
+
+ # Copy a KeywordRestParameterNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#465
+ def visit_keyword_rest_parameter_node(node); end
+
+ # Copy a LambdaNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#470
+ def visit_lambda_node(node); end
+
+ # Copy a LocalVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#475
+ def visit_local_variable_and_write_node(node); end
+
+ # Copy a LocalVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#480
+ def visit_local_variable_operator_write_node(node); end
+
+ # Copy a LocalVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#485
+ def visit_local_variable_or_write_node(node); end
+
+ # Copy a LocalVariableReadNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#490
+ def visit_local_variable_read_node(node); end
+
+ # Copy a LocalVariableTargetNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#495
+ def visit_local_variable_target_node(node); end
+
+ # Copy a LocalVariableWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#500
+ def visit_local_variable_write_node(node); end
+
+ # Copy a MatchLastLineNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#505
+ def visit_match_last_line_node(node); end
+
+ # Copy a MatchPredicateNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#510
+ def visit_match_predicate_node(node); end
+
+ # Copy a MatchRequiredNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#515
+ def visit_match_required_node(node); end
+
+ # Copy a MatchWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#520
+ def visit_match_write_node(node); end
+
+ # Copy a MissingNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#525
+ def visit_missing_node(node); end
+
+ # Copy a ModuleNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#530
+ def visit_module_node(node); end
+
+ # Copy a MultiTargetNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#535
+ def visit_multi_target_node(node); end
+
+ # Copy a MultiWriteNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#540
+ def visit_multi_write_node(node); end
+
+ # Copy a NextNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#545
+ def visit_next_node(node); end
+
+ # Copy a NilNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#550
+ def visit_nil_node(node); end
+
+ # Copy a NoKeywordsParameterNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#555
+ def visit_no_keywords_parameter_node(node); end
+
+ # Copy a NumberedParametersNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#560
+ def visit_numbered_parameters_node(node); end
+
+ # Copy a NumberedReferenceReadNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#565
+ def visit_numbered_reference_read_node(node); end
+
+ # Copy a OptionalKeywordParameterNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#570
+ def visit_optional_keyword_parameter_node(node); end
+
+ # Copy a OptionalParameterNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#575
+ def visit_optional_parameter_node(node); end
+
+ # Copy a OrNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#580
+ def visit_or_node(node); end
+
+ # Copy a ParametersNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#585
+ def visit_parameters_node(node); end
+
+ # Copy a ParenthesesNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#590
+ def visit_parentheses_node(node); end
+
+ # Copy a PinnedExpressionNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#595
+ def visit_pinned_expression_node(node); end
+
+ # Copy a PinnedVariableNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#600
+ def visit_pinned_variable_node(node); end
+
+ # Copy a PostExecutionNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#605
+ def visit_post_execution_node(node); end
+
+ # Copy a PreExecutionNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#610
+ def visit_pre_execution_node(node); end
+
+ # Copy a ProgramNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#615
+ def visit_program_node(node); end
+
+ # Copy a RangeNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#620
+ def visit_range_node(node); end
+
+ # Copy a RationalNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#625
+ def visit_rational_node(node); end
+
+ # Copy a RedoNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#630
+ def visit_redo_node(node); end
+
+ # Copy a RegularExpressionNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#635
+ def visit_regular_expression_node(node); end
+
+ # Copy a RequiredKeywordParameterNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#640
+ def visit_required_keyword_parameter_node(node); end
+
+ # Copy a RequiredParameterNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#645
+ def visit_required_parameter_node(node); end
+
+ # Copy a RescueModifierNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#650
+ def visit_rescue_modifier_node(node); end
+
+ # Copy a RescueNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#655
+ def visit_rescue_node(node); end
+
+ # Copy a RestParameterNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#660
+ def visit_rest_parameter_node(node); end
+
+ # Copy a RetryNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#665
+ def visit_retry_node(node); end
+
+ # Copy a ReturnNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#670
+ def visit_return_node(node); end
+
+ # Copy a SelfNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#675
+ def visit_self_node(node); end
+
+ # Copy a ShareableConstantNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#680
+ def visit_shareable_constant_node(node); end
+
+ # Copy a SingletonClassNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#685
+ def visit_singleton_class_node(node); end
+
+ # Copy a SourceEncodingNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#690
+ def visit_source_encoding_node(node); end
+
+ # Copy a SourceFileNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#695
+ def visit_source_file_node(node); end
+
+ # Copy a SourceLineNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#700
+ def visit_source_line_node(node); end
+
+ # Copy a SplatNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#705
+ def visit_splat_node(node); end
+
+ # Copy a StatementsNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#710
+ def visit_statements_node(node); end
+
+ # Copy a StringNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#715
+ def visit_string_node(node); end
+
+ # Copy a SuperNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#720
+ def visit_super_node(node); end
+
+ # Copy a SymbolNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#725
+ def visit_symbol_node(node); end
+
+ # Copy a TrueNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#730
+ def visit_true_node(node); end
+
+ # Copy a UndefNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#735
+ def visit_undef_node(node); end
+
+ # Copy a UnlessNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#740
+ def visit_unless_node(node); end
+
+ # Copy a UntilNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#745
+ def visit_until_node(node); end
+
+ # Copy a WhenNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#750
+ def visit_when_node(node); end
+
+ # Copy a WhileNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#755
+ def visit_while_node(node); end
+
+ # Copy a XStringNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#760
+ def visit_x_string_node(node); end
+
+ # Copy a YieldNode node
+ #
+ # source://prism//lib/prism/mutation_compiler.rb#765
+ def visit_yield_node(node); end
+end
+
+# Represents the use of the `next` keyword.
+#
+# next 1
+# ^^^^^^
+#
+# source://prism//lib/prism/node.rb#13689
+class Prism::NextNode < ::Prism::Node
+ # def initialize: (ArgumentsNode? arguments, Location keyword_loc, Location location) -> void
+ #
+ # @return [NextNode] a new instance of NextNode
+ #
+ # source://prism//lib/prism/node.rb#13691
+ sig do
+ params(
+ source: Prism::Source,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, arguments, keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#13783
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#13699
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader arguments: ArgumentsNode?
+ #
+ # source://prism//lib/prism/node.rb#13734
+ sig { returns(T.nilable(Prism::ArgumentsNode)) }
+ def arguments; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13704
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#13716
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#13709
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?arguments: ArgumentsNode?, ?keyword_loc: Location, ?location: Location) -> NextNode
+ #
+ # source://prism//lib/prism/node.rb#13721
+ sig do
+ params(
+ arguments: T.nilable(Prism::ArgumentsNode),
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::NextNode)
+ end
+ def copy(arguments: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13704
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { arguments: ArgumentsNode?, keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#13729
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#13749
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#13744
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#13737
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13767
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13777
+ def type; end
+ end
+end
+
+# Represents the use of the `nil` keyword.
+#
+# nil
+# ^^^
+#
+# source://prism//lib/prism/node.rb#13794
+class Prism::NilNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [NilNode] a new instance of NilNode
+ #
+ # source://prism//lib/prism/node.rb#13796
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#13869
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#13802
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13807
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#13817
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#13812
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> NilNode
+ #
+ # source://prism//lib/prism/node.rb#13822
+ sig { params(location: Prism::Location).returns(Prism::NilNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13807
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#13830
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#13835
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13853
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13863
+ def type; end
+ end
+end
+
+# Represents the use of `**nil` inside method arguments.
+#
+# def a(**nil)
+# ^^^^^
+# end
+#
+# source://prism//lib/prism/node.rb#13879
+class Prism::NoKeywordsParameterNode < ::Prism::Node
+ # def initialize: (Location operator_loc, Location keyword_loc, Location location) -> void
+ #
+ # @return [NoKeywordsParameterNode] a new instance of NoKeywordsParameterNode
+ #
+ # source://prism//lib/prism/node.rb#13881
+ sig do
+ params(
+ source: Prism::Source,
+ operator_loc: Prism::Location,
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, operator_loc, keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#13980
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#13889
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13894
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#13904
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#13899
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?operator_loc: Location, ?keyword_loc: Location, ?location: Location) -> NoKeywordsParameterNode
+ #
+ # source://prism//lib/prism/node.rb#13909
+ sig do
+ params(
+ operator_loc: Prism::Location,
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::NoKeywordsParameterNode)
+ end
+ def copy(operator_loc: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#13894
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { operator_loc: Location, keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#13917
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#13946
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#13941
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#13929
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#13936
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#13922
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13964
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#13974
+ def type; end
+ end
+end
+
+# This represents a node in the tree. It is the parent class of all of the
+# various node types.
+#
+# source://prism//lib/prism/node.rb#12
+class Prism::Node
+ abstract!
+
+ # Accepts a visitor and calls back into the specialized visit function.
+ #
+ # @raise [NoMethodError]
+ #
+ # source://prism//lib/prism/node.rb#131
+ sig { abstract.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # Returns an array of child nodes, including `nil`s in the place of optional
+ # nodes that were not present.
+ #
+ # @raise [NoMethodError]
+ #
+ # source://prism//lib/prism/node.rb#137
+ sig { abstract.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # Returns an array of child nodes and locations that could potentially have
+ # comments attached to them.
+ #
+ # @raise [NoMethodError]
+ #
+ # source://prism//lib/prism/node.rb#151
+ sig { abstract.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # Returns an array of child nodes, excluding any `nil`s in the place of
+ # optional nodes that were not present.
+ #
+ # @raise [NoMethodError]
+ #
+ # source://prism//lib/prism/node.rb#145
+ sig { abstract.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # Returns an array of child nodes, including `nil`s in the place of optional
+ # nodes that were not present.
+ #
+ # @raise [NoMethodError]
+ #
+ # source://prism//lib/prism/node.rb#137
+ sig { abstract.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # source://prism//lib/prism/node_ext.rb#7
+ def deprecated(*replacements); end
+
+ # The end offset of the node in the source. This method is effectively a
+ # delegate method to the location object.
+ #
+ # source://prism//lib/prism/node.rb#34
+ sig { returns(Integer) }
+ def end_offset; end
+
+ sig { abstract.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # Returns a string representation of the node.
+ #
+ # @raise [NoMethodError]
+ #
+ # source://prism//lib/prism/node.rb#162
+ sig { abstract.returns(String) }
+ def inspect; end
+
+ # A Location instance that represents the location of this node in the
+ # source.
+ #
+ # source://prism//lib/prism/node.rb#19
+ sig { returns(Prism::Location) }
+ def location; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#69
+ def newline!(lines); end
+
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/parse_result/newlines.rb#65
+ def newline?; end
+
+ # Similar to inspect, but respects the current level of indentation given by
+ # the pretty print object.
+ #
+ # source://prism//lib/prism/node.rb#62
+ sig { params(q: T.untyped).void }
+ def pretty_print(q); end
+
+ # Returns all of the lines of the source code associated with this node.
+ # An alias for source_lines, used to mimic the API from
+ # RubyVM::AbstractSyntaxTree to make it easier to migrate.
+ #
+ # source://prism//lib/prism/node.rb#40
+ sig { returns(T::Array[String]) }
+ def script_lines; end
+
+ # Slice the location of the node from the source.
+ #
+ # source://prism//lib/prism/node.rb#49
+ sig { returns(String) }
+ def slice; end
+
+ # Slice the location of the node from the source, starting at the beginning
+ # of the line that the location starts on, ending at the end of the line
+ # that the location ends on.
+ #
+ # source://prism//lib/prism/node.rb#56
+ sig { returns(String) }
+ def slice_lines; end
+
+ # Returns all of the lines of the source code associated with this node.
+ #
+ # source://prism//lib/prism/node.rb#40
+ sig { returns(T::Array[String]) }
+ def source_lines; end
+
+ # The start offset of the node in the source. This method is effectively a
+ # delegate method to the location object.
+ #
+ # source://prism//lib/prism/node.rb#27
+ sig { returns(Integer) }
+ def start_offset; end
+
+ # Convert this node into a graphviz dot graph string.
+ #
+ # source://prism//lib/prism/node.rb#70
+ sig { returns(String) }
+ def to_dot; end
+
+ # Returns a list of nodes that are descendants of this node that contain the
+ # given line and column. This is useful for locating a node that is selected
+ # based on the line and column of the source code.
+ #
+ # Important to note is that the column given to this method should be in
+ # bytes, as opposed to characters or code units.
+ #
+ # source://prism//lib/prism/node.rb#81
+ sig { params(line: Integer, column: Integer).returns(T::Array[Prism::Node]) }
+ def tunnel(line, column); end
+
+ # Returns a symbol symbolizing the type of node that this represents. This
+ # is particularly useful for case statements and array comparisons.
+ #
+ # @raise [NoMethodError]
+ #
+ # source://prism//lib/prism/node.rb#157
+ sig { abstract.returns(Symbol) }
+ def type; end
+
+ private
+
+ # A pointer to the source that this node was created from.
+ #
+ # source://prism//lib/prism/node.rb#14
+ sig { returns(Prism::Source) }
+ def source; end
+
+ class << self
+ # Returns a list of the fields that exist for this node class. Fields
+ # describe the structure of the node. This kind of reflection is useful for
+ # things like recursively visiting each node _and_ field in the tree.
+ #
+ # @raise [NoMethodError]
+ #
+ # source://prism//lib/prism/node.rb#115
+ def fields; end
+
+ # Returns the type of the node as a symbol.
+ #
+ # @raise [NoMethodError]
+ #
+ # source://prism//lib/prism/node.rb#167
+ def type; end
+ end
+end
+
+# Represents an implicit set of parameters through the use of numbered parameters within a block or lambda.
+#
+# -> { _1 + _2 }
+# ^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#13991
+class Prism::NumberedParametersNode < ::Prism::Node
+ # def initialize: (Integer maximum, Location location) -> void
+ #
+ # @return [NumberedParametersNode] a new instance of NumberedParametersNode
+ #
+ # source://prism//lib/prism/node.rb#13993
+ sig { params(source: Prism::Source, maximum: Integer, location: Prism::Location).void }
+ def initialize(source, maximum, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#14070
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#14000
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14005
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#14015
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#14010
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?maximum: Integer, ?location: Location) -> NumberedParametersNode
+ #
+ # source://prism//lib/prism/node.rb#14020
+ sig { params(maximum: Integer, location: Prism::Location).returns(Prism::NumberedParametersNode) }
+ def copy(maximum: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14005
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { maximum: Integer, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#14028
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#14036
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader maximum: Integer
+ #
+ # source://prism//lib/prism/node.rb#14033
+ sig { returns(Integer) }
+ def maximum; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14054
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14064
+ def type; end
+ end
+end
+
+# Represents reading a numbered reference to a capture in the previous match.
+#
+# $1
+# ^^
+#
+# source://prism//lib/prism/node.rb#14080
+class Prism::NumberedReferenceReadNode < ::Prism::Node
+ # def initialize: (Integer number, Location location) -> void
+ #
+ # @return [NumberedReferenceReadNode] a new instance of NumberedReferenceReadNode
+ #
+ # source://prism//lib/prism/node.rb#14082
+ sig { params(source: Prism::Source, number: Integer, location: Prism::Location).void }
+ def initialize(source, number, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#14165
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#14089
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14094
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#14104
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#14099
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?number: Integer, ?location: Location) -> NumberedReferenceReadNode
+ #
+ # source://prism//lib/prism/node.rb#14109
+ sig { params(number: Integer, location: Prism::Location).returns(Prism::NumberedReferenceReadNode) }
+ def copy(number: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14094
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { number: Integer, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#14117
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#14131
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The (1-indexed, from the left) number of the capture group. Numbered references that are too large result in this value being `0`.
+ #
+ # $1 # number `1`
+ #
+ # $5432 # number `5432`
+ #
+ # $4294967296 # number `0`
+ #
+ # source://prism//lib/prism/node.rb#14128
+ sig { returns(Integer) }
+ def number; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14149
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14159
+ def type; end
+ end
+end
+
+# Represents an optional keyword parameter to a method, block, or lambda definition.
+#
+# def a(b: 1)
+# ^^^^
+# end
+#
+# source://prism//lib/prism/node.rb#14176
+class Prism::OptionalKeywordParameterNode < ::Prism::Node
+ # def initialize: (Integer flags, Symbol name, Location name_loc, Prism::node value, Location location) -> void
+ #
+ # @return [OptionalKeywordParameterNode] a new instance of OptionalKeywordParameterNode
+ #
+ # source://prism//lib/prism/node.rb#14178
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ name: Symbol,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, name, name_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#14277
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#14188
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14193
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#14203
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#14198
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?name: Symbol, ?name_loc: Location, ?value: Prism::node, ?location: Location) -> OptionalKeywordParameterNode
+ #
+ # source://prism//lib/prism/node.rb#14208
+ sig do
+ params(
+ flags: Integer,
+ name: Symbol,
+ name_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::OptionalKeywordParameterNode)
+ end
+ def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14193
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol, name_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#14216
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#14243
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#14225
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#14228
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def repeated_parameter?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#14238
+ sig { returns(T::Boolean) }
+ def repeated_parameter?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14261
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#14235
+ sig { returns(Prism::Node) }
+ def value; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#14221
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14271
+ def type; end
+ end
+end
+
+# Represents an optional parameter to a method, block, or lambda definition.
+#
+# def a(b = 1)
+# ^^^^^
+# end
+#
+# source://prism//lib/prism/node.rb#14291
+class Prism::OptionalParameterNode < ::Prism::Node
+ # def initialize: (Integer flags, Symbol name, Location name_loc, Location operator_loc, Prism::node value, Location location) -> void
+ #
+ # @return [OptionalParameterNode] a new instance of OptionalParameterNode
+ #
+ # source://prism//lib/prism/node.rb#14293
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, name, name_loc, operator_loc, value, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#14405
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#14304
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14309
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#14319
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#14314
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?name: Symbol, ?name_loc: Location, ?operator_loc: Location, ?value: Prism::node, ?location: Location) -> OptionalParameterNode
+ #
+ # source://prism//lib/prism/node.rb#14324
+ sig do
+ params(
+ flags: Integer,
+ name: Symbol,
+ name_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ value: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::OptionalParameterNode)
+ end
+ def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), value: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14309
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol, name_loc: Location, operator_loc: Location, value: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#14332
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#14371
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#14341
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#14344
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#14366
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#14351
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # def repeated_parameter?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#14361
+ sig { returns(T::Boolean) }
+ def repeated_parameter?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14389
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader value: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#14358
+ sig { returns(Prism::Node) }
+ def value; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#14337
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14399
+ def type; end
+ end
+end
+
+# Represents the use of the `||` operator or the `or` keyword.
+#
+# left or right
+# ^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#14419
+class Prism::OrNode < ::Prism::Node
+ # def initialize: (Prism::node left, Prism::node right, Location operator_loc, Location location) -> void
+ #
+ # @return [OrNode] a new instance of OrNode
+ #
+ # source://prism//lib/prism/node.rb#14421
+ sig do
+ params(
+ source: Prism::Source,
+ left: Prism::Node,
+ right: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, left, right, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#14530
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#14430
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14435
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#14445
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#14440
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?left: Prism::node, ?right: Prism::node, ?operator_loc: Location, ?location: Location) -> OrNode
+ #
+ # source://prism//lib/prism/node.rb#14450
+ sig do
+ params(
+ left: Prism::Node,
+ right: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::OrNode)
+ end
+ def copy(left: T.unsafe(nil), right: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14435
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { left: Prism::node, right: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#14458
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#14496
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Represents the left side of the expression. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # left or right
+ # ^^^^
+ #
+ # 1 || 2
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#14469
+ sig { returns(Prism::Node) }
+ def left; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#14491
+ sig { returns(String) }
+ def operator; end
+
+ # The location of the `or` keyword or the `||` operator.
+ #
+ # left or right
+ # ^^
+ #
+ # source://prism//lib/prism/node.rb#14484
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Represents the right side of the expression. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # left || right
+ # ^^^^^
+ #
+ # 1 or 2
+ # ^
+ #
+ # source://prism//lib/prism/node.rb#14478
+ sig { returns(Prism::Node) }
+ def right; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14514
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14524
+ def type; end
+ end
+end
+
+# A parser for the pack template language.
+#
+# source://prism//lib/prism/pack.rb#6
+module Prism::Pack
+ class << self
+ def parse(_arg0, _arg1, _arg2); end
+ end
+end
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::AGNOSTIC_ENDIAN = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::BACK = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::BER = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::BIG_ENDIAN = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::COMMENT = T.let(T.unsafe(nil), Symbol)
+
+# A directive in the pack template language.
+#
+# source://prism//lib/prism/pack.rb#60
+class Prism::Pack::Directive
+ # Initialize a new directive with the given values.
+ #
+ # @return [Directive] a new instance of Directive
+ #
+ # source://prism//lib/prism/pack.rb#89
+ def initialize(version, variant, source, type, signed, endian, size, length_type, length); end
+
+ # Provide a human-readable description of the directive.
+ #
+ # source://prism//lib/prism/pack.rb#131
+ def describe; end
+
+ # The type of endianness of the directive.
+ #
+ # source://prism//lib/prism/pack.rb#77
+ def endian; end
+
+ # The length of this directive (used for integers).
+ #
+ # source://prism//lib/prism/pack.rb#86
+ def length; end
+
+ # The length type of this directive (used for integers).
+ #
+ # source://prism//lib/prism/pack.rb#83
+ def length_type; end
+
+ # The type of signedness of the directive.
+ #
+ # source://prism//lib/prism/pack.rb#74
+ def signed; end
+
+ # The size of the directive.
+ #
+ # source://prism//lib/prism/pack.rb#80
+ def size; end
+
+ # A byteslice of the source string that this directive represents.
+ #
+ # source://prism//lib/prism/pack.rb#68
+ def source; end
+
+ # The type of the directive.
+ #
+ # source://prism//lib/prism/pack.rb#71
+ def type; end
+
+ # A symbol representing whether or not we are packing or unpacking.
+ #
+ # source://prism//lib/prism/pack.rb#65
+ def variant; end
+
+ # A symbol representing the version of Ruby.
+ #
+ # source://prism//lib/prism/pack.rb#62
+ def version; end
+end
+
+# The descriptions of the various types of endianness.
+#
+# source://prism//lib/prism/pack.rb#102
+Prism::Pack::Directive::ENDIAN_DESCRIPTIONS = T.let(T.unsafe(nil), Hash)
+
+# The descriptions of the various types of signedness.
+#
+# source://prism//lib/prism/pack.rb#111
+Prism::Pack::Directive::SIGNED_DESCRIPTIONS = T.let(T.unsafe(nil), Hash)
+
+# The descriptions of the various types of sizes.
+#
+# source://prism//lib/prism/pack.rb#118
+Prism::Pack::Directive::SIZE_DESCRIPTIONS = T.let(T.unsafe(nil), Hash)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::ENDIAN_NA = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::FLOAT = T.let(T.unsafe(nil), Symbol)
+
+# The result of parsing a pack template.
+#
+# source://prism//lib/prism/pack.rb#198
+class Prism::Pack::Format
+ # Create a new Format with the given directives and encoding.
+ #
+ # @return [Format] a new instance of Format
+ #
+ # source://prism//lib/prism/pack.rb#206
+ def initialize(directives, encoding); end
+
+ # Provide a human-readable description of the format.
+ #
+ # source://prism//lib/prism/pack.rb#212
+ def describe; end
+
+ # A list of the directives in the template.
+ #
+ # source://prism//lib/prism/pack.rb#200
+ def directives; end
+
+ # The encoding of the template.
+ #
+ # source://prism//lib/prism/pack.rb#203
+ def encoding; end
+end
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::INTEGER = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::LENGTH_FIXED = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::LENGTH_MAX = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::LENGTH_NA = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::LENGTH_RELATIVE = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::LITTLE_ENDIAN = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::MOVE = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::NATIVE_ENDIAN = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::NULL = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIGNED = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIGNED_NA = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIZE_16 = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIZE_32 = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIZE_64 = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIZE_8 = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIZE_INT = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIZE_LONG = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIZE_LONG_LONG = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIZE_NA = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIZE_P = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SIZE_SHORT = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::SPACE = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_BASE64 = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_FIXED = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_HEX_HIGH = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_HEX_LOW = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_LSB = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_MIME = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_MSB = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_NULL_PADDED = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_NULL_TERMINATED = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_POINTER = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_SPACE_PADDED = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::STRING_UU = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::UNSIGNED = T.let(T.unsafe(nil), Symbol)
+
+# source://prism//lib/prism/pack.rb#56
+Prism::Pack::UTF8 = T.let(T.unsafe(nil), Symbol)
+
+# Flags for parameter nodes.
+#
+# source://prism//lib/prism/node.rb#19202
+module Prism::ParameterFlags; end
+
+# a parameter name that has been repeated in the method signature
+#
+# source://prism//lib/prism/node.rb#19204
+Prism::ParameterFlags::REPEATED_PARAMETER = T.let(T.unsafe(nil), Integer)
+
+# Represents the list of parameters on a method, block, or lambda definition.
+#
+# def a(b, c, d)
+# ^^^^^^^
+# end
+#
+# source://prism//lib/prism/node.rb#14543
+class Prism::ParametersNode < ::Prism::Node
+ # def initialize: (Array[RequiredParameterNode | MultiTargetNode] requireds, Array[OptionalParameterNode] optionals, RestParameterNode | ImplicitRestNode | nil rest, Array[RequiredParameterNode | MultiTargetNode | KeywordRestParameterNode | NoKeywordsParameterNode | ForwardingParameterNode] posts, Array[RequiredKeywordParameterNode | OptionalKeywordParameterNode] keywords, KeywordRestParameterNode | ForwardingParameterNode | NoKeywordsParameterNode | nil keyword_rest, BlockParameterNode? block, Location location) -> void
+ #
+ # @return [ParametersNode] a new instance of ParametersNode
+ #
+ # source://prism//lib/prism/node.rb#14545
+ sig do
+ params(
+ source: Prism::Source,
+ requireds: T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode)],
+ optionals: T::Array[Prism::OptionalParameterNode],
+ rest: T.nilable(T.any(Prism::RestParameterNode, Prism::ImplicitRestNode)),
+ posts: T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode, Prism::KeywordRestParameterNode, Prism::NoKeywordsParameterNode, Prism::ForwardingParameterNode)],
+ keywords: T::Array[T.any(Prism::RequiredKeywordParameterNode, Prism::OptionalKeywordParameterNode)],
+ keyword_rest: T.nilable(T.any(Prism::KeywordRestParameterNode, Prism::ForwardingParameterNode, Prism::NoKeywordsParameterNode)),
+ block: T.nilable(Prism::BlockParameterNode),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, requireds, optionals, rest, posts, keywords, keyword_rest, block, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#14654
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#14558
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader block: BlockParameterNode?
+ #
+ # source://prism//lib/prism/node.rb#14617
+ sig { returns(T.nilable(Prism::BlockParameterNode)) }
+ def block; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14563
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#14581
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#14568
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?requireds: Array[RequiredParameterNode | MultiTargetNode], ?optionals: Array[OptionalParameterNode], ?rest: RestParameterNode | ImplicitRestNode | nil, ?posts: Array[RequiredParameterNode | MultiTargetNode | KeywordRestParameterNode | NoKeywordsParameterNode | ForwardingParameterNode], ?keywords: Array[RequiredKeywordParameterNode | OptionalKeywordParameterNode], ?keyword_rest: KeywordRestParameterNode | ForwardingParameterNode | NoKeywordsParameterNode | nil, ?block: BlockParameterNode?, ?location: Location) -> ParametersNode
+ #
+ # source://prism//lib/prism/node.rb#14586
+ sig do
+ params(
+ requireds: T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode)],
+ optionals: T::Array[Prism::OptionalParameterNode],
+ rest: T.nilable(T.any(Prism::RestParameterNode, Prism::ImplicitRestNode)),
+ posts: T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode, Prism::KeywordRestParameterNode, Prism::NoKeywordsParameterNode, Prism::ForwardingParameterNode)],
+ keywords: T::Array[T.any(Prism::RequiredKeywordParameterNode, Prism::OptionalKeywordParameterNode)],
+ keyword_rest: T.nilable(T.any(Prism::KeywordRestParameterNode, Prism::ForwardingParameterNode, Prism::NoKeywordsParameterNode)),
+ block: T.nilable(Prism::BlockParameterNode),
+ location: Prism::Location
+ ).returns(Prism::ParametersNode)
+ end
+ def copy(requireds: T.unsafe(nil), optionals: T.unsafe(nil), rest: T.unsafe(nil), posts: T.unsafe(nil), keywords: T.unsafe(nil), keyword_rest: T.unsafe(nil), block: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14563
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { requireds: Array[RequiredParameterNode | MultiTargetNode], optionals: Array[OptionalParameterNode], rest: RestParameterNode | ImplicitRestNode | nil, posts: Array[RequiredParameterNode | MultiTargetNode | KeywordRestParameterNode | NoKeywordsParameterNode | ForwardingParameterNode], keywords: Array[RequiredKeywordParameterNode | OptionalKeywordParameterNode], keyword_rest: KeywordRestParameterNode | ForwardingParameterNode | NoKeywordsParameterNode | nil, block: BlockParameterNode?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#14594
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#14620
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader keyword_rest: KeywordRestParameterNode | ForwardingParameterNode | NoKeywordsParameterNode | nil
+ #
+ # source://prism//lib/prism/node.rb#14614
+ sig do
+ returns(T.nilable(T.any(Prism::KeywordRestParameterNode, Prism::ForwardingParameterNode, Prism::NoKeywordsParameterNode)))
+ end
+ def keyword_rest; end
+
+ # attr_reader keywords: Array[RequiredKeywordParameterNode | OptionalKeywordParameterNode]
+ #
+ # source://prism//lib/prism/node.rb#14611
+ sig { returns(T::Array[T.any(Prism::RequiredKeywordParameterNode, Prism::OptionalKeywordParameterNode)]) }
+ def keywords; end
+
+ # attr_reader optionals: Array[OptionalParameterNode]
+ #
+ # source://prism//lib/prism/node.rb#14602
+ sig { returns(T::Array[Prism::OptionalParameterNode]) }
+ def optionals; end
+
+ # attr_reader posts: Array[RequiredParameterNode | MultiTargetNode | KeywordRestParameterNode | NoKeywordsParameterNode | ForwardingParameterNode]
+ #
+ # source://prism//lib/prism/node.rb#14608
+ sig do
+ returns(T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode, Prism::KeywordRestParameterNode, Prism::NoKeywordsParameterNode, Prism::ForwardingParameterNode)])
+ end
+ def posts; end
+
+ # attr_reader requireds: Array[RequiredParameterNode | MultiTargetNode]
+ #
+ # source://prism//lib/prism/node.rb#14599
+ sig { returns(T::Array[T.any(Prism::RequiredParameterNode, Prism::MultiTargetNode)]) }
+ def requireds; end
+
+ # attr_reader rest: RestParameterNode | ImplicitRestNode | nil
+ #
+ # source://prism//lib/prism/node.rb#14605
+ sig { returns(T.nilable(T.any(Prism::RestParameterNode, Prism::ImplicitRestNode))) }
+ def rest; end
+
+ # Mirrors the Method#parameters method.
+ #
+ # source://prism//lib/prism/node_ext.rb#253
+ sig { returns(T::Array[T.any([Symbol, Symbol], [Symbol])]) }
+ def signature; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14638
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14648
+ def type; end
+ end
+end
+
+# Represents a parenthesized expression
+#
+# (10 + 34)
+# ^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#14674
+class Prism::ParenthesesNode < ::Prism::Node
+ # def initialize: (Prism::node? body, Location opening_loc, Location closing_loc, Location location) -> void
+ #
+ # @return [ParenthesesNode] a new instance of ParenthesesNode
+ #
+ # source://prism//lib/prism/node.rb#14676
+ sig do
+ params(
+ source: Prism::Source,
+ body: T.nilable(Prism::Node),
+ opening_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, body, opening_loc, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#14781
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#14685
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader body: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#14720
+ sig { returns(T.nilable(Prism::Node)) }
+ def body; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14690
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#14742
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#14730
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#14702
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#14695
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?body: Prism::node?, ?opening_loc: Location, ?closing_loc: Location, ?location: Location) -> ParenthesesNode
+ #
+ # source://prism//lib/prism/node.rb#14707
+ sig do
+ params(
+ body: T.nilable(Prism::Node),
+ opening_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::ParenthesesNode)
+ end
+ def copy(body: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14690
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { body: Prism::node?, opening_loc: Location, closing_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#14715
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#14747
+ sig { override.returns(String) }
+ def inspect; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#85
+ def newline!(lines); end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#14737
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#14723
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14765
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14775
+ def type; end
+ end
+end
+
+# This represents an error that was encountered during parsing.
+#
+# source://prism//lib/prism/parse_result.rb#451
+class Prism::ParseError
+ # Create a new error object with the given message and location.
+ #
+ # @return [ParseError] a new instance of ParseError
+ #
+ # source://prism//lib/prism/parse_result.rb#466
+ sig { params(type: Symbol, message: String, location: Prism::Location, level: Symbol).void }
+ def initialize(type, message, location, level); end
+
+ # Implement the hash pattern matching interface for ParseError.
+ #
+ # source://prism//lib/prism/parse_result.rb#474
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # Returns a string representation of this error.
+ #
+ # source://prism//lib/prism/parse_result.rb#479
+ sig { returns(String) }
+ def inspect; end
+
+ # The level of this error.
+ #
+ # source://prism//lib/prism/parse_result.rb#463
+ sig { returns(Symbol) }
+ def level; end
+
+ # A Location object representing the location of this error in the source.
+ #
+ # source://prism//lib/prism/parse_result.rb#460
+ sig { returns(Prism::Location) }
+ def location; end
+
+ # The message associated with this error.
+ #
+ # source://prism//lib/prism/parse_result.rb#457
+ sig { returns(String) }
+ def message; end
+
+ # The type of error. This is an _internal_ symbol that is used for
+ # communicating with translation layers. It is not meant to be public API.
+ #
+ # source://prism//lib/prism/parse_result.rb#454
+ sig { returns(Symbol) }
+ def type; end
+end
+
+# This is a result specific to the `parse_lex` and `parse_lex_file` methods.
+#
+# source://prism//lib/prism/parse_result.rb#627
+class Prism::ParseLexResult < ::Prism::Result
+ # Create a new parse lex result object with the given values.
+ #
+ # @return [ParseLexResult] a new instance of ParseLexResult
+ #
+ # source://prism//lib/prism/parse_result.rb#633
+ sig do
+ params(
+ value: [Prism::ProgramNode, T::Array[T.untyped]],
+ comments: T::Array[Prism::Comment],
+ magic_comments: T::Array[Prism::MagicComment],
+ data_loc: T.nilable(Prism::Location),
+ errors: T::Array[Prism::ParseError],
+ warnings: T::Array[Prism::ParseWarning],
+ source: Prism::Source
+ ).void
+ end
+ def initialize(value, comments, magic_comments, data_loc, errors, warnings, source); end
+
+ # Implement the hash pattern matching interface for ParseLexResult.
+ #
+ # source://prism//lib/prism/parse_result.rb#639
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # A tuple of the syntax tree and the list of tokens that were parsed from
+ # the source code.
+ #
+ # source://prism//lib/prism/parse_result.rb#630
+ sig { returns([Prism::ProgramNode, T::Array[T.untyped]]) }
+ def value; end
+end
+
+# This is a result specific to the `parse` and `parse_file` methods.
+#
+# source://prism//lib/prism/parse_result.rb#576
+class Prism::ParseResult < ::Prism::Result
+ # Create a new parse result object with the given values.
+ #
+ # @return [ParseResult] a new instance of ParseResult
+ #
+ # source://prism//lib/prism/parse_result.rb#587
+ sig do
+ params(
+ value: Prism::ProgramNode,
+ comments: T::Array[Prism::Comment],
+ magic_comments: T::Array[Prism::MagicComment],
+ data_loc: T.nilable(Prism::Location),
+ errors: T::Array[Prism::ParseError],
+ warnings: T::Array[Prism::ParseWarning],
+ source: Prism::Source
+ ).void
+ end
+ def initialize(value, comments, magic_comments, data_loc, errors, warnings, source); end
+
+ # Attach the list of comments to their respective locations in the tree.
+ #
+ # source://prism//lib/prism/parse_result.rb#598
+ def attach_comments!; end
+
+ # Implement the hash pattern matching interface for ParseResult.
+ #
+ # source://prism//lib/prism/parse_result.rb#593
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # Walk the tree and mark nodes that are on a new line, loosely emulating
+ # the behavior of CRuby's `:line` tracepoint event.
+ #
+ # source://prism//lib/prism/parse_result.rb#604
+ def mark_newlines!; end
+
+ # The syntax tree that was parsed from the source code.
+ #
+ # source://prism//lib/prism/parse_result.rb#584
+ sig { returns(Prism::ProgramNode) }
+ def value; end
+end
+
+# When we've parsed the source, we have both the syntax tree and the list of
+# comments that we found in the source. This class is responsible for
+# walking the tree and finding the nearest location to attach each comment.
+#
+# It does this by first finding the nearest locations to each comment.
+# Locations can either come from nodes directly or from location fields on
+# nodes. For example, a `ClassNode` has an overall location encompassing the
+# entire class, but it also has a location for the `class` keyword.
+#
+# Once the nearest locations are found, it determines which one to attach
+# to. If it's a trailing comment (a comment on the same line as other source
+# code), it will favor attaching to the nearest location that occurs before
+# the comment. Otherwise it will favor attaching to the nearest location
+# that is after the comment.
+#
+# source://prism//lib/prism/parse_result/comments.rb#19
+class Prism::ParseResult::Comments
+ # Create a new Comments object that will attach comments to the given
+ # parse result.
+ #
+ # @return [Comments] a new instance of Comments
+ #
+ # source://prism//lib/prism/parse_result/comments.rb#86
+ def initialize(parse_result); end
+
+ # Attach the comments to their respective locations in the tree by
+ # mutating the parse result.
+ #
+ # source://prism//lib/prism/parse_result/comments.rb#92
+ def attach!; end
+
+ # The parse result that we are attaching comments to.
+ #
+ # source://prism//lib/prism/parse_result/comments.rb#82
+ def parse_result; end
+
+ private
+
+ # Responsible for finding the nearest targets to the given comment within
+ # the context of the given encapsulating node.
+ #
+ # source://prism//lib/prism/parse_result/comments.rb#119
+ def nearest_targets(node, comment); end
+end
+
+# A target for attaching comments that is based on a location field on a
+# node. For example, the `end` token of a ClassNode.
+#
+# source://prism//lib/prism/parse_result/comments.rb#53
+class Prism::ParseResult::Comments::LocationTarget
+ # @return [LocationTarget] a new instance of LocationTarget
+ #
+ # source://prism//lib/prism/parse_result/comments.rb#56
+ def initialize(location); end
+
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/parse_result/comments.rb#68
+ def encloses?(comment); end
+
+ # source://prism//lib/prism/parse_result/comments.rb#64
+ def end_offset; end
+
+ # source://prism//lib/prism/parse_result/comments.rb#72
+ def leading_comment(comment); end
+
+ # source://prism//lib/prism/parse_result/comments.rb#54
+ def location; end
+
+ # source://prism//lib/prism/parse_result/comments.rb#60
+ def start_offset; end
+
+ # source://prism//lib/prism/parse_result/comments.rb#76
+ def trailing_comment(comment); end
+end
+
+# A target for attaching comments that is based on a specific node's
+# location.
+#
+# source://prism//lib/prism/parse_result/comments.rb#22
+class Prism::ParseResult::Comments::NodeTarget
+ # @return [NodeTarget] a new instance of NodeTarget
+ #
+ # source://prism//lib/prism/parse_result/comments.rb#25
+ def initialize(node); end
+
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/parse_result/comments.rb#37
+ def encloses?(comment); end
+
+ # source://prism//lib/prism/parse_result/comments.rb#33
+ def end_offset; end
+
+ # source://prism//lib/prism/parse_result/comments.rb#42
+ def leading_comment(comment); end
+
+ # source://prism//lib/prism/parse_result/comments.rb#23
+ def node; end
+
+ # source://prism//lib/prism/parse_result/comments.rb#29
+ def start_offset; end
+
+ # source://prism//lib/prism/parse_result/comments.rb#46
+ def trailing_comment(comment); end
+end
+
+# The :line tracepoint event gets fired whenever the Ruby VM encounters an
+# expression on a new line. The types of expressions that can trigger this
+# event are:
+#
+# * if statements
+# * unless statements
+# * nodes that are children of statements lists
+#
+# In order to keep track of the newlines, we have a list of offsets that
+# come back from the parser. We assign these offsets to the first nodes that
+# we find in the tree that are on those lines.
+#
+# Note that the logic in this file should be kept in sync with the Java
+# MarkNewlinesVisitor, since that visitor is responsible for marking the
+# newlines for JRuby/TruffleRuby.
+#
+# This file is autoloaded only when `mark_newlines!` is called, so the
+# re-opening of the various nodes in this file will only be performed in
+# that case. We do that to avoid storing the extra `@newline` instance
+# variable on every node if we don't need it.
+#
+# source://prism//lib/prism/parse_result/newlines.rb#25
+class Prism::ParseResult::Newlines < ::Prism::Visitor
+ # Create a new Newlines visitor with the given newline offsets.
+ #
+ # @return [Newlines] a new instance of Newlines
+ #
+ # source://prism//lib/prism/parse_result/newlines.rb#27
+ def initialize(lines); end
+
+ # Permit block/lambda nodes to mark newlines within themselves.
+ #
+ # source://prism//lib/prism/parse_result/newlines.rb#33
+ def visit_block_node(node); end
+
+ # Mark if/unless nodes as newlines.
+ #
+ # source://prism//lib/prism/parse_result/newlines.rb#47
+ def visit_if_node(node); end
+
+ # Permit block/lambda nodes to mark newlines within themselves.
+ #
+ # source://prism//lib/prism/parse_result/newlines.rb#33
+ def visit_lambda_node(node); end
+
+ # Permit statements lists to mark newlines within themselves.
+ #
+ # source://prism//lib/prism/parse_result/newlines.rb#55
+ def visit_statements_node(node); end
+
+ # Mark if/unless nodes as newlines.
+ #
+ # source://prism//lib/prism/parse_result/newlines.rb#47
+ def visit_unless_node(node); end
+end
+
+# This represents a warning that was encountered during parsing.
+#
+# source://prism//lib/prism/parse_result.rb#485
+class Prism::ParseWarning
+ # Create a new warning object with the given message and location.
+ #
+ # @return [ParseWarning] a new instance of ParseWarning
+ #
+ # source://prism//lib/prism/parse_result.rb#500
+ sig { params(type: Symbol, message: String, location: Prism::Location, level: Symbol).void }
+ def initialize(type, message, location, level); end
+
+ # Implement the hash pattern matching interface for ParseWarning.
+ #
+ # source://prism//lib/prism/parse_result.rb#508
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # Returns a string representation of this warning.
+ #
+ # source://prism//lib/prism/parse_result.rb#513
+ sig { returns(String) }
+ def inspect; end
+
+ # The level of this warning.
+ #
+ # source://prism//lib/prism/parse_result.rb#497
+ sig { returns(Symbol) }
+ def level; end
+
+ # A Location object representing the location of this warning in the source.
+ #
+ # source://prism//lib/prism/parse_result.rb#494
+ sig { returns(Prism::Location) }
+ def location; end
+
+ # The message associated with this warning.
+ #
+ # source://prism//lib/prism/parse_result.rb#491
+ sig { returns(String) }
+ def message; end
+
+ # The type of warning. This is an _internal_ symbol that is used for
+ # communicating with translation layers. It is not meant to be public API.
+ #
+ # source://prism//lib/prism/parse_result.rb#488
+ sig { returns(Symbol) }
+ def type; end
+end
+
+# A pattern is an object that wraps a Ruby pattern matching expression. The
+# expression would normally be passed to an `in` clause within a `case`
+# expression or a rightward assignment expression. For example, in the
+# following snippet:
+#
+# case node
+# in ConstantPathNode[ConstantReadNode[name: :Prism], ConstantReadNode[name: :Pattern]]
+# end
+#
+# the pattern is the ConstantPathNode[...] expression.
+#
+# The pattern gets compiled into an object that responds to #call by running
+# the #compile method. This method itself will run back through Prism to
+# parse the expression into a tree, then walk the tree to generate the
+# necessary callable objects. For example, if you wanted to compile the
+# expression above into a callable, you would:
+#
+# callable = Prism::Pattern.new("ConstantPathNode[ConstantReadNode[name: :Prism], ConstantReadNode[name: :Pattern]]").compile
+# callable.call(node)
+#
+# The callable object returned by #compile is guaranteed to respond to #call
+# with a single argument, which is the node to match against. It also is
+# guaranteed to respond to #===, which means it itself can be used in a `case`
+# expression, as in:
+#
+# case node
+# when callable
+# end
+#
+# If the query given to the initializer cannot be compiled into a valid
+# matcher (either because of a syntax error or because it is using syntax we
+# do not yet support) then a Prism::Pattern::CompilationError will be
+# raised.
+#
+# source://prism//lib/prism/pattern.rb#37
+class Prism::Pattern
+ # Create a new pattern with the given query. The query should be a string
+ # containing a Ruby pattern matching expression.
+ #
+ # @return [Pattern] a new instance of Pattern
+ #
+ # source://prism//lib/prism/pattern.rb#63
+ def initialize(query); end
+
+ # Compile the query into a callable object that can be used to match against
+ # nodes.
+ #
+ # @raise [CompilationError]
+ #
+ # source://prism//lib/prism/pattern.rb#70
+ def compile; end
+
+ # The query that this pattern was initialized with.
+ #
+ # source://prism//lib/prism/pattern.rb#59
+ def query; end
+
+ # Scan the given node and all of its children for nodes that match the
+ # pattern. If a block is given, it will be called with each node that
+ # matches the pattern. If no block is given, an enumerator will be returned
+ # that will yield each node that matches the pattern.
+ #
+ # source://prism//lib/prism/pattern.rb#86
+ def scan(root); end
+
+ private
+
+ # Shortcut for combining two procs into one that returns true if both return
+ # true.
+ #
+ # source://prism//lib/prism/pattern.rb#102
+ def combine_and(left, right); end
+
+ # Shortcut for combining two procs into one that returns true if either
+ # returns true.
+ #
+ # source://prism//lib/prism/pattern.rb#108
+ def combine_or(left, right); end
+
+ # in foo | bar
+ #
+ # source://prism//lib/prism/pattern.rb#143
+ def compile_alternation_pattern_node(node); end
+
+ # in [foo, bar, baz]
+ #
+ # source://prism//lib/prism/pattern.rb#118
+ def compile_array_pattern_node(node); end
+
+ # Compile a name associated with a constant.
+ #
+ # source://prism//lib/prism/pattern.rb#168
+ def compile_constant_name(node, name); end
+
+ # in Prism::ConstantReadNode
+ #
+ # source://prism//lib/prism/pattern.rb#148
+ def compile_constant_path_node(node); end
+
+ # in ConstantReadNode
+ # in String
+ #
+ # source://prism//lib/prism/pattern.rb#163
+ def compile_constant_read_node(node); end
+
+ # Raise an error because the given node is not supported.
+ #
+ # @raise [CompilationError]
+ #
+ # source://prism//lib/prism/pattern.rb#113
+ def compile_error(node); end
+
+ # in InstanceVariableReadNode[name: Symbol]
+ # in { name: Symbol }
+ #
+ # source://prism//lib/prism/pattern.rb#184
+ def compile_hash_pattern_node(node); end
+
+ # in nil
+ #
+ # source://prism//lib/prism/pattern.rb#214
+ def compile_nil_node(node); end
+
+ # Compile any kind of node. Dispatch out to the individual compilation
+ # methods based on the type of node.
+ #
+ # source://prism//lib/prism/pattern.rb#243
+ def compile_node(node); end
+
+ # in /foo/
+ #
+ # source://prism//lib/prism/pattern.rb#219
+ def compile_regular_expression_node(node); end
+
+ # in ""
+ # in "foo"
+ #
+ # source://prism//lib/prism/pattern.rb#227
+ def compile_string_node(node); end
+
+ # in :+
+ # in :foo
+ #
+ # source://prism//lib/prism/pattern.rb#235
+ def compile_symbol_node(node); end
+end
+
+# Raised when the query given to a pattern is either invalid Ruby syntax or
+# is using syntax that we don't yet support.
+#
+# source://prism//lib/prism/pattern.rb#40
+class Prism::Pattern::CompilationError < ::StandardError
+ # Create a new CompilationError with the given representation of the node
+ # that caused the error.
+ #
+ # @return [CompilationError] a new instance of CompilationError
+ #
+ # source://prism//lib/prism/pattern.rb#43
+ def initialize(repr); end
+end
+
+# Represents the use of the `^` operator for pinning an expression in a pattern matching expression.
+#
+# foo in ^(bar)
+# ^^^^^^
+#
+# source://prism//lib/prism/node.rb#14793
+class Prism::PinnedExpressionNode < ::Prism::Node
+ # def initialize: (Prism::node expression, Location operator_loc, Location lparen_loc, Location rparen_loc, Location location) -> void
+ #
+ # @return [PinnedExpressionNode] a new instance of PinnedExpressionNode
+ #
+ # source://prism//lib/prism/node.rb#14795
+ sig do
+ params(
+ source: Prism::Source,
+ expression: Prism::Node,
+ operator_loc: Prism::Location,
+ lparen_loc: Prism::Location,
+ rparen_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, expression, operator_loc, lparen_loc, rparen_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#14911
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#14805
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14810
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#14820
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#14815
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?expression: Prism::node, ?operator_loc: Location, ?lparen_loc: Location, ?rparen_loc: Location, ?location: Location) -> PinnedExpressionNode
+ #
+ # source://prism//lib/prism/node.rb#14825
+ sig do
+ params(
+ expression: Prism::Node,
+ operator_loc: Prism::Location,
+ lparen_loc: Prism::Location,
+ rparen_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::PinnedExpressionNode)
+ end
+ def copy(expression: T.unsafe(nil), operator_loc: T.unsafe(nil), lparen_loc: T.unsafe(nil), rparen_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14810
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { expression: Prism::node, operator_loc: Location, lparen_loc: Location, rparen_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#14833
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader expression: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#14838
+ sig { returns(Prism::Node) }
+ def expression; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#14877
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def lparen: () -> String
+ #
+ # source://prism//lib/prism/node.rb#14867
+ sig { returns(String) }
+ def lparen; end
+
+ # attr_reader lparen_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#14848
+ sig { returns(Prism::Location) }
+ def lparen_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#14862
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#14841
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # def rparen: () -> String
+ #
+ # source://prism//lib/prism/node.rb#14872
+ sig { returns(String) }
+ def rparen; end
+
+ # attr_reader rparen_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#14855
+ sig { returns(Prism::Location) }
+ def rparen_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14895
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#14905
+ def type; end
+ end
+end
+
+# Represents the use of the `^` operator for pinning a variable in a pattern matching expression.
+#
+# foo in ^bar
+# ^^^^
+#
+# source://prism//lib/prism/node.rb#14924
+class Prism::PinnedVariableNode < ::Prism::Node
+ # def initialize: (Prism::node variable, Location operator_loc, Location location) -> void
+ #
+ # @return [PinnedVariableNode] a new instance of PinnedVariableNode
+ #
+ # source://prism//lib/prism/node.rb#14926
+ sig do
+ params(
+ source: Prism::Source,
+ variable: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, variable, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#15016
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#14934
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14939
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#14949
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#14944
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?variable: Prism::node, ?operator_loc: Location, ?location: Location) -> PinnedVariableNode
+ #
+ # source://prism//lib/prism/node.rb#14954
+ sig do
+ params(
+ variable: Prism::Node,
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::PinnedVariableNode)
+ end
+ def copy(variable: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#14939
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { variable: Prism::node, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#14962
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#14982
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#14977
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#14970
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15000
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader variable: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#14967
+ sig { returns(Prism::Node) }
+ def variable; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15010
+ def type; end
+ end
+end
+
+# Represents the use of the `END` keyword.
+#
+# END { foo }
+# ^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#15027
+class Prism::PostExecutionNode < ::Prism::Node
+ # def initialize: (StatementsNode? statements, Location keyword_loc, Location opening_loc, Location closing_loc, Location location) -> void
+ #
+ # @return [PostExecutionNode] a new instance of PostExecutionNode
+ #
+ # source://prism//lib/prism/node.rb#15029
+ sig do
+ params(
+ source: Prism::Source,
+ statements: T.nilable(Prism::StatementsNode),
+ keyword_loc: Prism::Location,
+ opening_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, statements, keyword_loc, opening_loc, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#15147
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#15039
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15044
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#15108
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#15091
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#15056
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#15049
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?statements: StatementsNode?, ?keyword_loc: Location, ?opening_loc: Location, ?closing_loc: Location, ?location: Location) -> PostExecutionNode
+ #
+ # source://prism//lib/prism/node.rb#15061
+ sig do
+ params(
+ statements: T.nilable(Prism::StatementsNode),
+ keyword_loc: Prism::Location,
+ opening_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::PostExecutionNode)
+ end
+ def copy(statements: T.unsafe(nil), keyword_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15044
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { statements: StatementsNode?, keyword_loc: Location, opening_loc: Location, closing_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#15069
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#15113
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#15098
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#15077
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#15103
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#15084
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # attr_reader statements: StatementsNode?
+ #
+ # source://prism//lib/prism/node.rb#15074
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15131
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15141
+ def type; end
+ end
+end
+
+# Represents the use of the `BEGIN` keyword.
+#
+# BEGIN { foo }
+# ^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#15160
+class Prism::PreExecutionNode < ::Prism::Node
+ # def initialize: (StatementsNode? statements, Location keyword_loc, Location opening_loc, Location closing_loc, Location location) -> void
+ #
+ # @return [PreExecutionNode] a new instance of PreExecutionNode
+ #
+ # source://prism//lib/prism/node.rb#15162
+ sig do
+ params(
+ source: Prism::Source,
+ statements: T.nilable(Prism::StatementsNode),
+ keyword_loc: Prism::Location,
+ opening_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, statements, keyword_loc, opening_loc, closing_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#15280
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#15172
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15177
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#15241
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#15224
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#15189
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#15182
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?statements: StatementsNode?, ?keyword_loc: Location, ?opening_loc: Location, ?closing_loc: Location, ?location: Location) -> PreExecutionNode
+ #
+ # source://prism//lib/prism/node.rb#15194
+ sig do
+ params(
+ statements: T.nilable(Prism::StatementsNode),
+ keyword_loc: Prism::Location,
+ opening_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::PreExecutionNode)
+ end
+ def copy(statements: T.unsafe(nil), keyword_loc: T.unsafe(nil), opening_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15177
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { statements: StatementsNode?, keyword_loc: Location, opening_loc: Location, closing_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#15202
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#15246
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#15231
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#15210
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#15236
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#15217
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # attr_reader statements: StatementsNode?
+ #
+ # source://prism//lib/prism/node.rb#15207
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15264
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15274
+ def type; end
+ end
+end
+
+# The top level node of any parse tree.
+#
+# source://prism//lib/prism/node.rb#15290
+class Prism::ProgramNode < ::Prism::Node
+ # def initialize: (Array[Symbol] locals, StatementsNode statements, Location location) -> void
+ #
+ # @return [ProgramNode] a new instance of ProgramNode
+ #
+ # source://prism//lib/prism/node.rb#15292
+ sig do
+ params(
+ source: Prism::Source,
+ locals: T::Array[Symbol],
+ statements: Prism::StatementsNode,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, locals, statements, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#15373
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#15300
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15305
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#15315
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#15310
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?locals: Array[Symbol], ?statements: StatementsNode, ?location: Location) -> ProgramNode
+ #
+ # source://prism//lib/prism/node.rb#15320
+ sig do
+ params(
+ locals: T::Array[Symbol],
+ statements: Prism::StatementsNode,
+ location: Prism::Location
+ ).returns(Prism::ProgramNode)
+ end
+ def copy(locals: T.unsafe(nil), statements: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15305
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], statements: StatementsNode, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#15328
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#15339
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader locals: Array[Symbol]
+ #
+ # source://prism//lib/prism/node.rb#15333
+ sig { returns(T::Array[Symbol]) }
+ def locals; end
+
+ # attr_reader statements: StatementsNode
+ #
+ # source://prism//lib/prism/node.rb#15336
+ sig { returns(Prism::StatementsNode) }
+ def statements; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15357
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15367
+ def type; end
+ end
+end
+
+# Flags for range and flip-flop nodes.
+#
+# source://prism//lib/prism/node.rb#19208
+module Prism::RangeFlags; end
+
+# ... operator
+#
+# source://prism//lib/prism/node.rb#19210
+Prism::RangeFlags::EXCLUDE_END = T.let(T.unsafe(nil), Integer)
+
+# Represents the use of the `..` or `...` operators.
+#
+# 1..2
+# ^^^^
+#
+# c if a =~ /left/ ... b =~ /right/
+# ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#15388
+class Prism::RangeNode < ::Prism::Node
+ # def initialize: (Integer flags, Prism::node? left, Prism::node? right, Location operator_loc, Location location) -> void
+ #
+ # @return [RangeNode] a new instance of RangeNode
+ #
+ # source://prism//lib/prism/node.rb#15390
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ left: T.nilable(Prism::Node),
+ right: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, left, right, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#15510
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#15400
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15405
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#15418
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#15410
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?left: Prism::node?, ?right: Prism::node?, ?operator_loc: Location, ?location: Location) -> RangeNode
+ #
+ # source://prism//lib/prism/node.rb#15423
+ sig do
+ params(
+ flags: Integer,
+ left: T.nilable(Prism::Node),
+ right: T.nilable(Prism::Node),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::RangeNode)
+ end
+ def copy(flags: T.unsafe(nil), left: T.unsafe(nil), right: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15405
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, left: Prism::node?, right: Prism::node?, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#15431
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def exclude_end?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15466
+ sig { returns(T::Boolean) }
+ def exclude_end?; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#15476
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The left-hand side of the range, if present. It can be either `nil` or any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # 1...
+ # ^
+ #
+ # hello...goodbye
+ # ^^^^^
+ #
+ # source://prism//lib/prism/node.rb#15446
+ sig { returns(T.nilable(Prism::Node)) }
+ def left; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#15471
+ sig { returns(String) }
+ def operator; end
+
+ # The location of the `..` or `...` operator.
+ #
+ # source://prism//lib/prism/node.rb#15459
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # The right-hand side of the range, if present. It can be either `nil` or any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # ..5
+ # ^
+ #
+ # 1...foo
+ # ^^^
+ # If neither right-hand or left-hand side was included, this will be a MissingNode.
+ #
+ # source://prism//lib/prism/node.rb#15456
+ sig { returns(T.nilable(Prism::Node)) }
+ def right; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15494
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#15436
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15504
+ def type; end
+ end
+end
+
+# Represents a rational number literal.
+#
+# 1.0r
+# ^^^^
+#
+# source://prism//lib/prism/node.rb#15523
+class Prism::RationalNode < ::Prism::Node
+ # def initialize: (Integer flags, Integer numerator, Integer denominator, Location location) -> void
+ #
+ # @return [RationalNode] a new instance of RationalNode
+ #
+ # source://prism//lib/prism/node.rb#15525
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ numerator: Integer,
+ denominator: Integer,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, numerator, denominator, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#15635
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#15534
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def binary?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15581
+ sig { returns(T::Boolean) }
+ def binary?; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15539
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#15549
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#15544
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?numerator: Integer, ?denominator: Integer, ?location: Location) -> RationalNode
+ #
+ # source://prism//lib/prism/node.rb#15554
+ sig do
+ params(
+ flags: Integer,
+ numerator: Integer,
+ denominator: Integer,
+ location: Prism::Location
+ ).returns(Prism::RationalNode)
+ end
+ def copy(flags: T.unsafe(nil), numerator: T.unsafe(nil), denominator: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def decimal?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15586
+ sig { returns(T::Boolean) }
+ def decimal?; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15539
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, numerator: Integer, denominator: Integer, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#15562
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # The denominator of the rational number.
+ #
+ # 1.5r # denominator 2
+ #
+ # source://prism//lib/prism/node.rb#15578
+ sig { returns(Integer) }
+ def denominator; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def hexadecimal?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15596
+ sig { returns(T::Boolean) }
+ def hexadecimal?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#15601
+ sig { override.returns(String) }
+ def inspect; end
+
+ # The numerator of the rational number.
+ #
+ # 1.5r # numerator 3
+ #
+ # source://prism//lib/prism/node.rb#15573
+ sig { returns(Integer) }
+ def numerator; end
+
+ # Returns the value of the node as an IntegerNode or a FloatNode. This
+ # method is deprecated in favor of #value or #numerator/#denominator.
+ #
+ # source://prism//lib/prism/node_ext.rb#114
+ def numeric; end
+
+ # def octal?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15591
+ sig { returns(T::Boolean) }
+ def octal?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15619
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # Returns the value of the node as a Ruby Rational.
+ #
+ # source://prism//lib/prism/node_ext.rb#108
+ sig { returns(Rational) }
+ def value; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#15567
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15629
+ def type; end
+ end
+end
+
+# Represents the use of the `redo` keyword.
+#
+# redo
+# ^^^^
+#
+# source://prism//lib/prism/node.rb#15647
+class Prism::RedoNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [RedoNode] a new instance of RedoNode
+ #
+ # source://prism//lib/prism/node.rb#15649
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#15722
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#15655
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15660
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#15670
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#15665
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> RedoNode
+ #
+ # source://prism//lib/prism/node.rb#15675
+ sig { params(location: Prism::Location).returns(Prism::RedoNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15660
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#15683
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#15688
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15706
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15716
+ def type; end
+ end
+end
+
+# The Reflection module provides the ability to reflect on the structure of
+# the syntax tree itself, as opposed to looking at a single syntax tree. This
+# is useful in metaprogramming contexts.
+#
+# source://prism//lib/prism/reflection.rb#13
+module Prism::Reflection
+ class << self
+ # Returns the fields for the given node.
+ #
+ # source://prism//lib/prism/reflection.rb#104
+ sig { params(node: T.class_of(Prism::Node)).returns(T::Array[Prism::Reflection::Field]) }
+ def fields_for(node); end
+ end
+end
+
+# A constant field represents a constant value on a node. Effectively, it
+# represents an identifier found within the source. It resolves to a symbol
+# in Ruby.
+#
+# source://prism//lib/prism/reflection.rb#45
+class Prism::Reflection::ConstantField < ::Prism::Reflection::Field; end
+
+# A constant list field represents a list of constant values on a node. It
+# resolves to an array of symbols in Ruby.
+#
+# source://prism//lib/prism/reflection.rb#55
+class Prism::Reflection::ConstantListField < ::Prism::Reflection::Field; end
+
+# A field represents a single piece of data on a node. It is the base class
+# for all other field types.
+#
+# source://prism//lib/prism/reflection.rb#16
+class Prism::Reflection::Field
+ # Initializes the field with the given name.
+ #
+ # @return [Field] a new instance of Field
+ #
+ # source://prism//lib/prism/reflection.rb#21
+ sig { params(name: Symbol).void }
+ def initialize(name); end
+
+ # The name of the field.
+ #
+ # source://prism//lib/prism/reflection.rb#18
+ sig { returns(Symbol) }
+ def name; end
+end
+
+# A flags field represents a bitset of flags on a node. It resolves to an
+# integer in Ruby. Note that the flags cannot be accessed directly on the
+# node because the integer is kept private. Instead, the various flags in
+# the bitset should be accessed through their query methods.
+#
+# source://prism//lib/prism/reflection.rb#92
+class Prism::Reflection::FlagsField < ::Prism::Reflection::Field
+ # Initializes the flags field with the given name and flags.
+ #
+ # @return [FlagsField] a new instance of FlagsField
+ #
+ # source://prism//lib/prism/reflection.rb#97
+ sig { params(name: Symbol, flags: T::Array[Symbol]).void }
+ def initialize(name, flags); end
+
+ # The names of the flags in the bitset.
+ #
+ # source://prism//lib/prism/reflection.rb#94
+ sig { returns(T::Array[Symbol]) }
+ def flags; end
+end
+
+# A float field represents a double-precision floating point value. It is
+# used exclusively to represent the value of a floating point literal. It
+# resolves to a Float in Ruby.
+#
+# source://prism//lib/prism/reflection.rb#85
+class Prism::Reflection::FloatField < ::Prism::Reflection::Field; end
+
+# An integer field represents an integer value. It is used to represent the
+# value of an integer literal, the depth of local variables, and the number
+# of a numbered reference. It resolves to an Integer in Ruby.
+#
+# source://prism//lib/prism/reflection.rb#79
+class Prism::Reflection::IntegerField < ::Prism::Reflection::Field; end
+
+# A location field represents the location of some part of the node in the
+# source code. For example, the location of a keyword or an operator. It
+# resolves to a Prism::Location in Ruby.
+#
+# source://prism//lib/prism/reflection.rb#67
+class Prism::Reflection::LocationField < ::Prism::Reflection::Field; end
+
+# A node field represents a single child node in the syntax tree. It
+# resolves to a Prism::Node in Ruby.
+#
+# source://prism//lib/prism/reflection.rb#28
+class Prism::Reflection::NodeField < ::Prism::Reflection::Field; end
+
+# A node list field represents a list of child nodes in the syntax tree. It
+# resolves to an array of Prism::Node instances in Ruby.
+#
+# source://prism//lib/prism/reflection.rb#39
+class Prism::Reflection::NodeListField < ::Prism::Reflection::Field; end
+
+# An optional constant field represents a constant value on a node that may
+# or may not be present. It resolves to either a symbol or nil in Ruby.
+#
+# source://prism//lib/prism/reflection.rb#50
+class Prism::Reflection::OptionalConstantField < ::Prism::Reflection::Field; end
+
+# An optional location field represents the location of some part of the
+# node in the source code that may or may not be present. It resolves to
+# either a Prism::Location or nil in Ruby.
+#
+# source://prism//lib/prism/reflection.rb#73
+class Prism::Reflection::OptionalLocationField < ::Prism::Reflection::Field; end
+
+# An optional node field represents a single child node in the syntax tree
+# that may or may not be present. It resolves to either a Prism::Node or nil
+# in Ruby.
+#
+# source://prism//lib/prism/reflection.rb#34
+class Prism::Reflection::OptionalNodeField < ::Prism::Reflection::Field; end
+
+# A string field represents a string value on a node. It almost always
+# represents the unescaped value of a string-like literal. It resolves to a
+# string in Ruby.
+#
+# source://prism//lib/prism/reflection.rb#61
+class Prism::Reflection::StringField < ::Prism::Reflection::Field; end
+
+# Flags for regular expression and match last line nodes.
+#
+# source://prism//lib/prism/node.rb#19214
+module Prism::RegularExpressionFlags; end
+
+# n - forces the ASCII-8BIT encoding
+#
+# source://prism//lib/prism/node.rb#19231
+Prism::RegularExpressionFlags::ASCII_8BIT = T.let(T.unsafe(nil), Integer)
+
+# e - forces the EUC-JP encoding
+#
+# source://prism//lib/prism/node.rb#19228
+Prism::RegularExpressionFlags::EUC_JP = T.let(T.unsafe(nil), Integer)
+
+# x - ignores whitespace and allows comments in regular expressions
+#
+# source://prism//lib/prism/node.rb#19219
+Prism::RegularExpressionFlags::EXTENDED = T.let(T.unsafe(nil), Integer)
+
+# internal bytes forced the encoding to binary
+#
+# source://prism//lib/prism/node.rb#19243
+Prism::RegularExpressionFlags::FORCED_BINARY_ENCODING = T.let(T.unsafe(nil), Integer)
+
+# internal bytes forced the encoding to US-ASCII
+#
+# source://prism//lib/prism/node.rb#19246
+Prism::RegularExpressionFlags::FORCED_US_ASCII_ENCODING = T.let(T.unsafe(nil), Integer)
+
+# internal bytes forced the encoding to UTF-8
+#
+# source://prism//lib/prism/node.rb#19240
+Prism::RegularExpressionFlags::FORCED_UTF8_ENCODING = T.let(T.unsafe(nil), Integer)
+
+# i - ignores the case of characters when matching
+#
+# source://prism//lib/prism/node.rb#19216
+Prism::RegularExpressionFlags::IGNORE_CASE = T.let(T.unsafe(nil), Integer)
+
+# m - allows $ to match the end of lines within strings
+#
+# source://prism//lib/prism/node.rb#19222
+Prism::RegularExpressionFlags::MULTI_LINE = T.let(T.unsafe(nil), Integer)
+
+# o - only interpolates values into the regular expression once
+#
+# source://prism//lib/prism/node.rb#19225
+Prism::RegularExpressionFlags::ONCE = T.let(T.unsafe(nil), Integer)
+
+# u - forces the UTF-8 encoding
+#
+# source://prism//lib/prism/node.rb#19237
+Prism::RegularExpressionFlags::UTF_8 = T.let(T.unsafe(nil), Integer)
+
+# s - forces the Windows-31J encoding
+#
+# source://prism//lib/prism/node.rb#19234
+Prism::RegularExpressionFlags::WINDOWS_31J = T.let(T.unsafe(nil), Integer)
+
+# Represents a regular expression literal with no interpolation.
+#
+# /foo/i
+# ^^^^^^
+#
+# source://prism//lib/prism/node.rb#15731
+class Prism::RegularExpressionNode < ::Prism::Node
+ include ::Prism::RegularExpressionOptions
+
+ # def initialize: (Integer flags, Location opening_loc, Location content_loc, Location closing_loc, String unescaped, Location location) -> void
+ #
+ # @return [RegularExpressionNode] a new instance of RegularExpressionNode
+ #
+ # source://prism//lib/prism/node.rb#15733
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ opening_loc: Prism::Location,
+ content_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ unescaped: String,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, opening_loc, content_loc, closing_loc, unescaped, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#15909
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#15744
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def ascii_8bit?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15830
+ sig { returns(T::Boolean) }
+ def ascii_8bit?; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15749
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#15870
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#15795
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#15759
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#15754
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def content: () -> String
+ #
+ # source://prism//lib/prism/node.rb#15865
+ sig { returns(String) }
+ def content; end
+
+ # attr_reader content_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#15788
+ sig { returns(Prism::Location) }
+ def content_loc; end
+
+ # def copy: (?flags: Integer, ?opening_loc: Location, ?content_loc: Location, ?closing_loc: Location, ?unescaped: String, ?location: Location) -> RegularExpressionNode
+ #
+ # source://prism//lib/prism/node.rb#15764
+ sig do
+ params(
+ flags: Integer,
+ opening_loc: Prism::Location,
+ content_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ unescaped: String,
+ location: Prism::Location
+ ).returns(Prism::RegularExpressionNode)
+ end
+ def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), content_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), unescaped: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15749
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location, content_loc: Location, closing_loc: Location, unescaped: String, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#15772
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def euc_jp?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15825
+ sig { returns(T::Boolean) }
+ def euc_jp?; end
+
+ # def extended?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15810
+ sig { returns(T::Boolean) }
+ def extended?; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def forced_binary_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15850
+ sig { returns(T::Boolean) }
+ def forced_binary_encoding?; end
+
+ # def forced_us_ascii_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15855
+ sig { returns(T::Boolean) }
+ def forced_us_ascii_encoding?; end
+
+ # def forced_utf8_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15845
+ sig { returns(T::Boolean) }
+ def forced_utf8_encoding?; end
+
+ # def ignore_case?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15805
+ sig { returns(T::Boolean) }
+ def ignore_case?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#15875
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def multi_line?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15815
+ sig { returns(T::Boolean) }
+ def multi_line?; end
+
+ # def once?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15820
+ sig { returns(T::Boolean) }
+ def once?; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#15860
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#15781
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ sig { returns(Integer) }
+ def options; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15893
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader unescaped: String
+ #
+ # source://prism//lib/prism/node.rb#15802
+ sig { returns(String) }
+ def unescaped; end
+
+ # def utf_8?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15840
+ sig { returns(T::Boolean) }
+ def utf_8?; end
+
+ # def windows_31j?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15835
+ sig { returns(T::Boolean) }
+ def windows_31j?; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#15777
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#15903
+ def type; end
+ end
+end
+
+# source://prism//lib/prism/node_ext.rb#20
+module Prism::RegularExpressionOptions
+ # Returns a numeric value that represents the flags that were used to create
+ # the regular expression.
+ #
+ # source://prism//lib/prism/node_ext.rb#23
+ def options; end
+end
+
+# Represents a required keyword parameter to a method, block, or lambda definition.
+#
+# def a(b: )
+# ^^
+# end
+#
+# source://prism//lib/prism/node.rb#15924
+class Prism::RequiredKeywordParameterNode < ::Prism::Node
+ # def initialize: (Integer flags, Symbol name, Location name_loc, Location location) -> void
+ #
+ # @return [RequiredKeywordParameterNode] a new instance of RequiredKeywordParameterNode
+ #
+ # source://prism//lib/prism/node.rb#15926
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ name: Symbol,
+ name_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, name, name_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#16021
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#15935
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15940
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#15950
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#15945
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?name: Symbol, ?name_loc: Location, ?location: Location) -> RequiredKeywordParameterNode
+ #
+ # source://prism//lib/prism/node.rb#15955
+ sig do
+ params(
+ flags: Integer,
+ name: Symbol,
+ name_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::RequiredKeywordParameterNode)
+ end
+ def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#15940
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol, name_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#15963
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#15987
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#15972
+ sig { returns(Symbol) }
+ def name; end
+
+ # attr_reader name_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#15975
+ sig { returns(Prism::Location) }
+ def name_loc; end
+
+ # def repeated_parameter?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#15982
+ sig { returns(T::Boolean) }
+ def repeated_parameter?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16005
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#15968
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16015
+ def type; end
+ end
+end
+
+# Represents a required parameter to a method, block, or lambda definition.
+#
+# def a(b)
+# ^
+# end
+#
+# source://prism//lib/prism/node.rb#16034
+class Prism::RequiredParameterNode < ::Prism::Node
+ # def initialize: (Integer flags, Symbol name, Location location) -> void
+ #
+ # @return [RequiredParameterNode] a new instance of RequiredParameterNode
+ #
+ # source://prism//lib/prism/node.rb#16036
+ sig { params(source: Prism::Source, flags: Integer, name: Symbol, location: Prism::Location).void }
+ def initialize(source, flags, name, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#16123
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#16044
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16049
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#16059
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#16054
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?name: Symbol, ?location: Location) -> RequiredParameterNode
+ #
+ # source://prism//lib/prism/node.rb#16064
+ sig { params(flags: Integer, name: Symbol, location: Prism::Location).returns(Prism::RequiredParameterNode) }
+ def copy(flags: T.unsafe(nil), name: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16049
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#16072
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#16089
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol
+ #
+ # source://prism//lib/prism/node.rb#16081
+ sig { returns(Symbol) }
+ def name; end
+
+ # def repeated_parameter?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#16084
+ sig { returns(T::Boolean) }
+ def repeated_parameter?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16107
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#16077
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16117
+ def type; end
+ end
+end
+
+# Represents an expression modified with a rescue.
+#
+# foo rescue nil
+# ^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#16134
+class Prism::RescueModifierNode < ::Prism::Node
+ # def initialize: (Prism::node expression, Location keyword_loc, Prism::node rescue_expression, Location location) -> void
+ #
+ # @return [RescueModifierNode] a new instance of RescueModifierNode
+ #
+ # source://prism//lib/prism/node.rb#16136
+ sig do
+ params(
+ source: Prism::Source,
+ expression: Prism::Node,
+ keyword_loc: Prism::Location,
+ rescue_expression: Prism::Node,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, expression, keyword_loc, rescue_expression, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#16230
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#16145
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16150
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#16160
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#16155
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?expression: Prism::node, ?keyword_loc: Location, ?rescue_expression: Prism::node, ?location: Location) -> RescueModifierNode
+ #
+ # source://prism//lib/prism/node.rb#16165
+ sig do
+ params(
+ expression: Prism::Node,
+ keyword_loc: Prism::Location,
+ rescue_expression: Prism::Node,
+ location: Prism::Location
+ ).returns(Prism::RescueModifierNode)
+ end
+ def copy(expression: T.unsafe(nil), keyword_loc: T.unsafe(nil), rescue_expression: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16150
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { expression: Prism::node, keyword_loc: Location, rescue_expression: Prism::node, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#16173
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader expression: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#16178
+ sig { returns(Prism::Node) }
+ def expression; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#16196
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#16191
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#16181
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#115
+ def newline!(lines); end
+
+ # attr_reader rescue_expression: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#16188
+ sig { returns(Prism::Node) }
+ def rescue_expression; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16214
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16224
+ def type; end
+ end
+end
+
+# Represents a rescue statement.
+#
+# begin
+# rescue Foo, *splat, Bar => ex
+# foo
+# ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+# end
+#
+# `Foo, *splat, Bar` are in the `exceptions` field. `ex` is in the `exception` field.
+#
+# source://prism//lib/prism/node.rb#16247
+class Prism::RescueNode < ::Prism::Node
+ # def initialize: (Location keyword_loc, Array[Prism::node] exceptions, Location? operator_loc, Prism::node? reference, StatementsNode? statements, RescueNode? consequent, Location location) -> void
+ #
+ # @return [RescueNode] a new instance of RescueNode
+ #
+ # source://prism//lib/prism/node.rb#16249
+ sig do
+ params(
+ source: Prism::Source,
+ keyword_loc: Prism::Location,
+ exceptions: T::Array[Prism::Node],
+ operator_loc: T.nilable(Prism::Location),
+ reference: T.nilable(Prism::Node),
+ statements: T.nilable(Prism::StatementsNode),
+ consequent: T.nilable(Prism::RescueNode),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, keyword_loc, exceptions, operator_loc, reference, statements, consequent, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#16375
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#16261
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16266
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#16281
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#16271
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # attr_reader consequent: RescueNode?
+ #
+ # source://prism//lib/prism/node.rb#16328
+ sig { returns(T.nilable(Prism::RescueNode)) }
+ def consequent; end
+
+ # def copy: (?keyword_loc: Location, ?exceptions: Array[Prism::node], ?operator_loc: Location?, ?reference: Prism::node?, ?statements: StatementsNode?, ?consequent: RescueNode?, ?location: Location) -> RescueNode
+ #
+ # source://prism//lib/prism/node.rb#16286
+ sig do
+ params(
+ keyword_loc: Prism::Location,
+ exceptions: T::Array[Prism::Node],
+ operator_loc: T.nilable(Prism::Location),
+ reference: T.nilable(Prism::Node),
+ statements: T.nilable(Prism::StatementsNode),
+ consequent: T.nilable(Prism::RescueNode),
+ location: Prism::Location
+ ).returns(Prism::RescueNode)
+ end
+ def copy(keyword_loc: T.unsafe(nil), exceptions: T.unsafe(nil), operator_loc: T.unsafe(nil), reference: T.unsafe(nil), statements: T.unsafe(nil), consequent: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16266
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { keyword_loc: Location, exceptions: Array[Prism::node], operator_loc: Location?, reference: Prism::node?, statements: StatementsNode?, consequent: RescueNode?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#16294
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader exceptions: Array[Prism::node]
+ #
+ # source://prism//lib/prism/node.rb#16306
+ sig { returns(T::Array[Prism::Node]) }
+ def exceptions; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#16341
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#16331
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#16299
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # def operator: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#16336
+ sig { returns(T.nilable(String)) }
+ def operator; end
+
+ # attr_reader operator_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#16309
+ sig { returns(T.nilable(Prism::Location)) }
+ def operator_loc; end
+
+ # attr_reader reference: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#16322
+ sig { returns(T.nilable(Prism::Node)) }
+ def reference; end
+
+ # attr_reader statements: StatementsNode?
+ #
+ # source://prism//lib/prism/node.rb#16325
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16359
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16369
+ def type; end
+ end
+end
+
+# Represents a rest parameter to a method, block, or lambda definition.
+#
+# def a(*b)
+# ^^
+# end
+#
+# source://prism//lib/prism/node.rb#16392
+class Prism::RestParameterNode < ::Prism::Node
+ # def initialize: (Integer flags, Symbol? name, Location? name_loc, Location operator_loc, Location location) -> void
+ #
+ # @return [RestParameterNode] a new instance of RestParameterNode
+ #
+ # source://prism//lib/prism/node.rb#16394
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ name: T.nilable(Symbol),
+ name_loc: T.nilable(Prism::Location),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, name, name_loc, operator_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#16508
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#16404
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16409
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#16419
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#16414
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?name: Symbol?, ?name_loc: Location?, ?operator_loc: Location, ?location: Location) -> RestParameterNode
+ #
+ # source://prism//lib/prism/node.rb#16424
+ sig do
+ params(
+ flags: Integer,
+ name: T.nilable(Symbol),
+ name_loc: T.nilable(Prism::Location),
+ operator_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::RestParameterNode)
+ end
+ def copy(flags: T.unsafe(nil), name: T.unsafe(nil), name_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16409
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, name: Symbol?, name_loc: Location?, operator_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#16432
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#16474
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader name: Symbol?
+ #
+ # source://prism//lib/prism/node.rb#16441
+ sig { returns(T.nilable(Symbol)) }
+ def name; end
+
+ # attr_reader name_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#16444
+ sig { returns(T.nilable(Prism::Location)) }
+ def name_loc; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#16469
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#16457
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # def repeated_parameter?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#16464
+ sig { returns(T::Boolean) }
+ def repeated_parameter?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16492
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#16437
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16502
+ def type; end
+ end
+end
+
+# This represents the result of a call to ::parse or ::parse_file. It contains
+# the requested structure, any comments that were encounters, and any errors
+# that were encountered.
+#
+# source://prism//lib/prism/parse_result.rb#521
+class Prism::Result
+ # Create a new result object with the given values.
+ #
+ # @return [Result] a new instance of Result
+ #
+ # source://prism//lib/prism/parse_result.rb#543
+ sig do
+ params(
+ comments: T::Array[Prism::Comment],
+ magic_comments: T::Array[Prism::MagicComment],
+ data_loc: T.nilable(Prism::Location),
+ errors: T::Array[Prism::ParseError],
+ warnings: T::Array[Prism::ParseWarning],
+ source: Prism::Source
+ ).void
+ end
+ def initialize(comments, magic_comments, data_loc, errors, warnings, source); end
+
+ # The list of comments that were encountered during parsing.
+ #
+ # source://prism//lib/prism/parse_result.rb#523
+ sig { returns(T::Array[Prism::Comment]) }
+ def comments; end
+
+ # An optional location that represents the location of the __END__ marker
+ # and the rest of the content of the file. This content is loaded into the
+ # DATA constant when the file being parsed is the main file being executed.
+ #
+ # source://prism//lib/prism/parse_result.rb#531
+ sig { returns(T.nilable(Prism::Location)) }
+ def data_loc; end
+
+ # Implement the hash pattern matching interface for Result.
+ #
+ # source://prism//lib/prism/parse_result.rb#553
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # Returns the encoding of the source code that was parsed.
+ #
+ # source://prism//lib/prism/parse_result.rb#558
+ sig { returns(Encoding) }
+ def encoding; end
+
+ # The list of errors that were generated during parsing.
+ #
+ # source://prism//lib/prism/parse_result.rb#534
+ sig { returns(T::Array[Prism::ParseError]) }
+ def errors; end
+
+ # Returns true if there were errors during parsing and false if there were
+ # not.
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/parse_result.rb#570
+ sig { returns(T::Boolean) }
+ def failure?; end
+
+ # The list of magic comments that were encountered during parsing.
+ #
+ # source://prism//lib/prism/parse_result.rb#526
+ sig { returns(T::Array[Prism::MagicComment]) }
+ def magic_comments; end
+
+ # A Source instance that represents the source code that was parsed.
+ #
+ # source://prism//lib/prism/parse_result.rb#540
+ sig { returns(Prism::Source) }
+ def source; end
+
+ # Returns true if there were no errors during parsing and false if there
+ # were.
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/parse_result.rb#564
+ sig { returns(T::Boolean) }
+ def success?; end
+
+ # The list of warnings that were generated during parsing.
+ #
+ # source://prism//lib/prism/parse_result.rb#537
+ sig { returns(T::Array[Prism::ParseWarning]) }
+ def warnings; end
+end
+
+# Represents the use of the `retry` keyword.
+#
+# retry
+# ^^^^^
+#
+# source://prism//lib/prism/node.rb#16521
+class Prism::RetryNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [RetryNode] a new instance of RetryNode
+ #
+ # source://prism//lib/prism/node.rb#16523
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#16596
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#16529
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16534
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#16544
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#16539
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> RetryNode
+ #
+ # source://prism//lib/prism/node.rb#16549
+ sig { params(location: Prism::Location).returns(Prism::RetryNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16534
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#16557
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#16562
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16580
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16590
+ def type; end
+ end
+end
+
+# Represents the use of the `return` keyword.
+#
+# return 1
+# ^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#16605
+class Prism::ReturnNode < ::Prism::Node
+ # def initialize: (Integer flags, Location keyword_loc, ArgumentsNode? arguments, Location location) -> void
+ #
+ # @return [ReturnNode] a new instance of ReturnNode
+ #
+ # source://prism//lib/prism/node.rb#16607
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ keyword_loc: Prism::Location,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, keyword_loc, arguments, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#16709
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#16616
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader arguments: ArgumentsNode?
+ #
+ # source://prism//lib/prism/node.rb#16662
+ sig { returns(T.nilable(Prism::ArgumentsNode)) }
+ def arguments; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16621
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#16633
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#16626
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?keyword_loc: Location, ?arguments: ArgumentsNode?, ?location: Location) -> ReturnNode
+ #
+ # source://prism//lib/prism/node.rb#16638
+ sig do
+ params(
+ flags: Integer,
+ keyword_loc: Prism::Location,
+ arguments: T.nilable(Prism::ArgumentsNode),
+ location: Prism::Location
+ ).returns(Prism::ReturnNode)
+ end
+ def copy(flags: T.unsafe(nil), keyword_loc: T.unsafe(nil), arguments: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16621
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, keyword_loc: Location, arguments: ArgumentsNode?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#16646
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#16675
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#16670
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#16655
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # def redundant?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#16665
+ sig { returns(T::Boolean) }
+ def redundant?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16693
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#16651
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16703
+ def type; end
+ end
+end
+
+# Flags for return nodes.
+#
+# source://prism//lib/prism/node.rb#19250
+module Prism::ReturnNodeFlags; end
+
+# a return statement that is redundant because it is the last statement in a method
+#
+# source://prism//lib/prism/node.rb#19252
+Prism::ReturnNodeFlags::REDUNDANT = T.let(T.unsafe(nil), Integer)
+
+# Represents the `self` keyword.
+#
+# self
+# ^^^^
+#
+# source://prism//lib/prism/node.rb#16721
+class Prism::SelfNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [SelfNode] a new instance of SelfNode
+ #
+ # source://prism//lib/prism/node.rb#16723
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#16796
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#16729
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16734
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#16744
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#16739
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> SelfNode
+ #
+ # source://prism//lib/prism/node.rb#16749
+ sig { params(location: Prism::Location).returns(Prism::SelfNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16734
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#16757
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#16762
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16780
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16790
+ def type; end
+ end
+end
+
+# A module responsible for deserializing parse results.
+#
+# source://prism//lib/prism/serialize.rb#14
+module Prism::Serialize
+ class << self
+ # Deserialize the AST represented by the given string into a parse result.
+ #
+ # source://prism//lib/prism/serialize.rb#28
+ def load(input, serialized); end
+
+ # Deserialize the tokens represented by the given string into a parse
+ # result.
+ #
+ # source://prism//lib/prism/serialize.rb#40
+ def load_tokens(source, serialized); end
+ end
+end
+
+# source://prism//lib/prism/serialize.rb#44
+class Prism::Serialize::Loader
+ # @return [Loader] a new instance of Loader
+ #
+ # source://prism//lib/prism/serialize.rb#80
+ def initialize(source, serialized); end
+
+ # Returns the value of attribute constant_pool.
+ #
+ # source://prism//lib/prism/serialize.rb#77
+ def constant_pool; end
+
+ # Returns the value of attribute constant_pool_offset.
+ #
+ # source://prism//lib/prism/serialize.rb#77
+ def constant_pool_offset; end
+
+ # Returns the value of attribute encoding.
+ #
+ # source://prism//lib/prism/serialize.rb#76
+ def encoding; end
+
+ # Returns the value of attribute input.
+ #
+ # source://prism//lib/prism/serialize.rb#76
+ def input; end
+
+ # Returns the value of attribute io.
+ #
+ # source://prism//lib/prism/serialize.rb#76
+ def io; end
+
+ # source://prism//lib/prism/serialize.rb#118
+ def load_comments; end
+
+ # source://prism//lib/prism/serialize.rb#104
+ def load_encoding; end
+
+ # source://prism//lib/prism/serialize.rb#95
+ def load_header; end
+
+ # source://prism//lib/prism/serialize.rb#114
+ def load_line_offsets; end
+
+ # source://prism//lib/prism/serialize.rb#438
+ def load_metadata; end
+
+ # source://prism//lib/prism/serialize.rb#472
+ def load_nodes; end
+
+ # source://prism//lib/prism/serialize.rb#486
+ def load_result; end
+
+ # source://prism//lib/prism/serialize.rb#110
+ def load_start_line; end
+
+ # source://prism//lib/prism/serialize.rb#447
+ def load_tokens; end
+
+ # source://prism//lib/prism/serialize.rb#460
+ def load_tokens_result; end
+
+ # Returns the value of attribute serialized.
+ #
+ # source://prism//lib/prism/serialize.rb#76
+ def serialized; end
+
+ # Returns the value of attribute source.
+ #
+ # source://prism//lib/prism/serialize.rb#77
+ def source; end
+
+ # Returns the value of attribute start_line.
+ #
+ # source://prism//lib/prism/serialize.rb#78
+ def start_line; end
+
+ private
+
+ # source://prism//lib/prism/serialize.rb#572
+ def load_constant(index); end
+
+ # source://prism//lib/prism/serialize.rb#525
+ def load_double; end
+
+ # source://prism//lib/prism/serialize.rb#540
+ def load_embedded_string; end
+
+ # source://prism//lib/prism/serialize.rb#602
+ def load_error_level; end
+
+ # source://prism//lib/prism/serialize.rb#514
+ def load_integer; end
+
+ # source://prism//lib/prism/serialize.rb#556
+ def load_location; end
+
+ # source://prism//lib/prism/serialize.rb#560
+ def load_location_object; end
+
+ # source://prism//lib/prism/serialize.rb#631
+ def load_node; end
+
+ # source://prism//lib/prism/serialize.rb#597
+ def load_optional_constant; end
+
+ # source://prism//lib/prism/serialize.rb#564
+ def load_optional_location; end
+
+ # source://prism//lib/prism/serialize.rb#568
+ def load_optional_location_object; end
+
+ # source://prism//lib/prism/serialize.rb#533
+ def load_optional_node; end
+
+ # source://prism//lib/prism/serialize.rb#593
+ def load_required_constant; end
+
+ # source://prism//lib/prism/serialize.rb#544
+ def load_string; end
+
+ # source://prism//lib/prism/serialize.rb#529
+ def load_uint32; end
+
+ # source://prism//lib/prism/serialize.rb#509
+ def load_varsint; end
+
+ # variable-length integer using https://en.wikipedia.org/wiki/LEB128
+ # This is also what protobuf uses: https://protobuf.dev/programming-guides/encoding/#varints
+ #
+ # source://prism//lib/prism/serialize.rb#495
+ def load_varuint; end
+
+ # source://prism//lib/prism/serialize.rb#617
+ def load_warning_level; end
+end
+
+# source://prism//lib/prism/serialize.rb#127
+Prism::Serialize::Loader::DIAGNOSTIC_TYPES = T.let(T.unsafe(nil), Array)
+
+# StringIO is synchronized and that adds a high overhead on TruffleRuby.
+#
+# source://prism//lib/prism/serialize.rb#72
+Prism::Serialize::Loader::FastStringIO = StringIO
+
+# The major version of prism that we are expecting to find in the serialized
+# strings.
+#
+# source://prism//lib/prism/serialize.rb#17
+Prism::Serialize::MAJOR_VERSION = T.let(T.unsafe(nil), Integer)
+
+# The minor version of prism that we are expecting to find in the serialized
+# strings.
+#
+# source://prism//lib/prism/serialize.rb#21
+Prism::Serialize::MINOR_VERSION = T.let(T.unsafe(nil), Integer)
+
+# The patch version of prism that we are expecting to find in the serialized
+# strings.
+#
+# source://prism//lib/prism/serialize.rb#25
+Prism::Serialize::PATCH_VERSION = T.let(T.unsafe(nil), Integer)
+
+# The token types that can be indexed by their enum values.
+#
+# source://prism//lib/prism/serialize.rb#1863
+Prism::Serialize::TOKEN_TYPES = T.let(T.unsafe(nil), Array)
+
+# This node wraps a constant write to indicate that when the value is written, it should have its shareability state modified.
+#
+# C = { a: 1 }
+# ^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#16806
+class Prism::ShareableConstantNode < ::Prism::Node
+ # def initialize: (Integer flags, ConstantWriteNode | ConstantAndWriteNode | ConstantOrWriteNode | ConstantOperatorWriteNode | ConstantPathWriteNode | ConstantPathAndWriteNode | ConstantPathOrWriteNode | ConstantPathOperatorWriteNode write, Location location) -> void
+ #
+ # @return [ShareableConstantNode] a new instance of ShareableConstantNode
+ #
+ # source://prism//lib/prism/node.rb#16808
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ write: T.any(Prism::ConstantWriteNode, Prism::ConstantAndWriteNode, Prism::ConstantOrWriteNode, Prism::ConstantOperatorWriteNode, Prism::ConstantPathWriteNode, Prism::ConstantPathAndWriteNode, Prism::ConstantPathOrWriteNode, Prism::ConstantPathOperatorWriteNode),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, write, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#16905
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#16816
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16821
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#16831
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#16826
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?write: ConstantWriteNode | ConstantAndWriteNode | ConstantOrWriteNode | ConstantOperatorWriteNode | ConstantPathWriteNode | ConstantPathAndWriteNode | ConstantPathOrWriteNode | ConstantPathOperatorWriteNode, ?location: Location) -> ShareableConstantNode
+ #
+ # source://prism//lib/prism/node.rb#16836
+ sig do
+ params(
+ flags: Integer,
+ write: T.any(Prism::ConstantWriteNode, Prism::ConstantAndWriteNode, Prism::ConstantOrWriteNode, Prism::ConstantOperatorWriteNode, Prism::ConstantPathWriteNode, Prism::ConstantPathAndWriteNode, Prism::ConstantPathOrWriteNode, Prism::ConstantPathOperatorWriteNode),
+ location: Prism::Location
+ ).returns(Prism::ShareableConstantNode)
+ end
+ def copy(flags: T.unsafe(nil), write: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16821
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, write: ConstantWriteNode | ConstantAndWriteNode | ConstantOrWriteNode | ConstantOperatorWriteNode | ConstantPathWriteNode | ConstantPathAndWriteNode | ConstantPathOrWriteNode | ConstantPathOperatorWriteNode, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#16844
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def experimental_copy?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#16866
+ sig { returns(T::Boolean) }
+ def experimental_copy?; end
+
+ # def experimental_everything?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#16861
+ sig { returns(T::Boolean) }
+ def experimental_everything?; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#16871
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def literal?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#16856
+ sig { returns(T::Boolean) }
+ def literal?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16889
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # The constant write that should be modified with the shareability state.
+ #
+ # source://prism//lib/prism/node.rb#16853
+ sig do
+ returns(T.any(Prism::ConstantWriteNode, Prism::ConstantAndWriteNode, Prism::ConstantOrWriteNode, Prism::ConstantOperatorWriteNode, Prism::ConstantPathWriteNode, Prism::ConstantPathAndWriteNode, Prism::ConstantPathOrWriteNode, Prism::ConstantPathOperatorWriteNode))
+ end
+ def write; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#16849
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#16899
+ def type; end
+ end
+end
+
+# Flags for shareable constant nodes.
+#
+# source://prism//lib/prism/node.rb#19256
+module Prism::ShareableConstantNodeFlags; end
+
+# constant writes that should be modified with shareable constant value experimental copy
+#
+# source://prism//lib/prism/node.rb#19264
+Prism::ShareableConstantNodeFlags::EXPERIMENTAL_COPY = T.let(T.unsafe(nil), Integer)
+
+# constant writes that should be modified with shareable constant value experimental everything
+#
+# source://prism//lib/prism/node.rb#19261
+Prism::ShareableConstantNodeFlags::EXPERIMENTAL_EVERYTHING = T.let(T.unsafe(nil), Integer)
+
+# constant writes that should be modified with shareable constant value literal
+#
+# source://prism//lib/prism/node.rb#19258
+Prism::ShareableConstantNodeFlags::LITERAL = T.let(T.unsafe(nil), Integer)
+
+# Represents a singleton class declaration involving the `class` keyword.
+#
+# class << self end
+# ^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#16916
+class Prism::SingletonClassNode < ::Prism::Node
+ # def initialize: (Array[Symbol] locals, Location class_keyword_loc, Location operator_loc, Prism::node expression, Prism::node? body, Location end_keyword_loc, Location location) -> void
+ #
+ # @return [SingletonClassNode] a new instance of SingletonClassNode
+ #
+ # source://prism//lib/prism/node.rb#16918
+ sig do
+ params(
+ source: Prism::Source,
+ locals: T::Array[Symbol],
+ class_keyword_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ expression: Prism::Node,
+ body: T.nilable(Prism::Node),
+ end_keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, locals, class_keyword_loc, operator_loc, expression, body, end_keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#17045
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#16930
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader body: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#16986
+ sig { returns(T.nilable(Prism::Node)) }
+ def body; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16935
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def class_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#16996
+ sig { returns(String) }
+ def class_keyword; end
+
+ # attr_reader class_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#16969
+ sig { returns(Prism::Location) }
+ def class_keyword_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#16948
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#16940
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?locals: Array[Symbol], ?class_keyword_loc: Location, ?operator_loc: Location, ?expression: Prism::node, ?body: Prism::node?, ?end_keyword_loc: Location, ?location: Location) -> SingletonClassNode
+ #
+ # source://prism//lib/prism/node.rb#16953
+ sig do
+ params(
+ locals: T::Array[Symbol],
+ class_keyword_loc: Prism::Location,
+ operator_loc: Prism::Location,
+ expression: Prism::Node,
+ body: T.nilable(Prism::Node),
+ end_keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::SingletonClassNode)
+ end
+ def copy(locals: T.unsafe(nil), class_keyword_loc: T.unsafe(nil), operator_loc: T.unsafe(nil), expression: T.unsafe(nil), body: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#16935
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { locals: Array[Symbol], class_keyword_loc: Location, operator_loc: Location, expression: Prism::node, body: Prism::node?, end_keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#16961
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def end_keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#17006
+ sig { returns(String) }
+ def end_keyword; end
+
+ # attr_reader end_keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#16989
+ sig { returns(Prism::Location) }
+ def end_keyword_loc; end
+
+ # attr_reader expression: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#16983
+ sig { returns(Prism::Node) }
+ def expression; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#17011
+ sig { override.returns(String) }
+ def inspect; end
+
+ # attr_reader locals: Array[Symbol]
+ #
+ # source://prism//lib/prism/node.rb#16966
+ sig { returns(T::Array[Symbol]) }
+ def locals; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#17001
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#16976
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17029
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17039
+ def type; end
+ end
+end
+
+# This represents a source of Ruby code that has been parsed. It is used in
+# conjunction with locations to allow them to resolve line numbers and source
+# ranges.
+#
+# source://prism//lib/prism/parse_result.rb#7
+class Prism::Source
+ # Create a new source object with the given source code.
+ #
+ # @return [Source] a new instance of Source
+ #
+ # source://prism//lib/prism/parse_result.rb#26
+ sig { params(source: String, start_line: Integer, offsets: T::Array[Integer]).void }
+ def initialize(source, start_line = T.unsafe(nil), offsets = T.unsafe(nil)); end
+
+ # Return the column number in characters for the given byte offset.
+ #
+ # source://prism//lib/prism/parse_result.rb#78
+ sig { params(byte_offset: Integer).returns(Integer) }
+ def character_column(byte_offset); end
+
+ # Return the character offset for the given byte offset.
+ #
+ # source://prism//lib/prism/parse_result.rb#73
+ sig { params(byte_offset: Integer).returns(Integer) }
+ def character_offset(byte_offset); end
+
+ # Returns the column number in code units for the given encoding for the
+ # given byte offset.
+ #
+ # source://prism//lib/prism/parse_result.rb#95
+ sig { params(byte_offset: Integer, encoding: Encoding).returns(Integer) }
+ def code_units_column(byte_offset, encoding); end
+
+ # Returns the offset from the start of the file for the given byte offset
+ # counting in code units for the given encoding.
+ #
+ # This method is tested with UTF-8, UTF-16, and UTF-32. If there is the
+ # concept of code units that differs from the number of characters in other
+ # encodings, it is not captured here.
+ #
+ # source://prism//lib/prism/parse_result.rb#88
+ sig { params(byte_offset: Integer, encoding: Encoding).returns(Integer) }
+ def code_units_offset(byte_offset, encoding); end
+
+ # Return the column number for the given byte offset.
+ #
+ # source://prism//lib/prism/parse_result.rb#68
+ sig { params(byte_offset: Integer).returns(Integer) }
+ def column(byte_offset); end
+
+ # Returns the encoding of the source code, which is set by parameters to the
+ # parser or by the encoding magic comment.
+ #
+ # source://prism//lib/prism/parse_result.rb#34
+ sig { returns(Encoding) }
+ def encoding; end
+
+ # Binary search through the offsets to find the line number for the given
+ # byte offset.
+ #
+ # source://prism//lib/prism/parse_result.rb#51
+ sig { params(byte_offset: Integer).returns(Integer) }
+ def line(byte_offset); end
+
+ # Returns the byte offset of the end of the line corresponding to the given
+ # byte offset.
+ #
+ # source://prism//lib/prism/parse_result.rb#63
+ def line_end(byte_offset); end
+
+ # Return the byte offset of the start of the line corresponding to the given
+ # byte offset.
+ #
+ # source://prism//lib/prism/parse_result.rb#57
+ sig { params(byte_offset: Integer).returns(Integer) }
+ def line_start(byte_offset); end
+
+ # Returns the lines of the source code as an array of strings.
+ #
+ # source://prism//lib/prism/parse_result.rb#39
+ sig { returns(T::Array[String]) }
+ def lines; end
+
+ # The list of newline byte offsets in the source code.
+ #
+ # source://prism//lib/prism/parse_result.rb#23
+ sig { returns(T::Array[Integer]) }
+ def offsets; end
+
+ # Perform a byteslice on the source code using the given byte offset and
+ # byte length.
+ #
+ # source://prism//lib/prism/parse_result.rb#45
+ sig { params(byte_offset: Integer, length: Integer).returns(String) }
+ def slice(byte_offset, length); end
+
+ # The source code that this source object represents.
+ #
+ # source://prism//lib/prism/parse_result.rb#17
+ sig { returns(String) }
+ def source; end
+
+ # The line number where this source starts.
+ #
+ # source://prism//lib/prism/parse_result.rb#20
+ sig { returns(Integer) }
+ def start_line; end
+
+ private
+
+ # Binary search through the offsets to find the line number for the given
+ # byte offset.
+ #
+ # source://prism//lib/prism/parse_result.rb#103
+ def find_line(byte_offset); end
+
+ class << self
+ # Create a new source object with the given source code. This method should
+ # be used instead of `new` and it will return either a `Source` or a
+ # specialized and more performant `ASCIISource` if no multibyte characters
+ # are present in the source code.
+ #
+ # source://prism//lib/prism/parse_result.rb#12
+ def for(source, start_line = T.unsafe(nil), offsets = T.unsafe(nil)); end
+ end
+end
+
+# Represents the use of the `__ENCODING__` keyword.
+#
+# __ENCODING__
+# ^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#17061
+class Prism::SourceEncodingNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [SourceEncodingNode] a new instance of SourceEncodingNode
+ #
+ # source://prism//lib/prism/node.rb#17063
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#17136
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#17069
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17074
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#17084
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#17079
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> SourceEncodingNode
+ #
+ # source://prism//lib/prism/node.rb#17089
+ sig { params(location: Prism::Location).returns(Prism::SourceEncodingNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17074
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#17097
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#17102
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17120
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17130
+ def type; end
+ end
+end
+
+# Represents the use of the `__FILE__` keyword.
+#
+# __FILE__
+# ^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#17145
+class Prism::SourceFileNode < ::Prism::Node
+ # def initialize: (Integer flags, String filepath, Location location) -> void
+ #
+ # @return [SourceFileNode] a new instance of SourceFileNode
+ #
+ # source://prism//lib/prism/node.rb#17147
+ sig { params(source: Prism::Source, flags: Integer, filepath: String, location: Prism::Location).void }
+ def initialize(source, flags, filepath, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#17249
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#17155
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17160
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#17170
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#17165
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?filepath: String, ?location: Location) -> SourceFileNode
+ #
+ # source://prism//lib/prism/node.rb#17175
+ sig { params(flags: Integer, filepath: String, location: Prism::Location).returns(Prism::SourceFileNode) }
+ def copy(flags: T.unsafe(nil), filepath: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17160
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, filepath: String, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#17183
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # Represents the file path being parsed. This corresponds directly to the `filepath` option given to the various `Prism::parse*` APIs.
+ #
+ # source://prism//lib/prism/node.rb#17192
+ sig { returns(String) }
+ def filepath; end
+
+ # def forced_binary_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#17200
+ sig { returns(T::Boolean) }
+ def forced_binary_encoding?; end
+
+ # def forced_utf8_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#17195
+ sig { returns(T::Boolean) }
+ def forced_utf8_encoding?; end
+
+ # def frozen?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#17205
+ sig { returns(T::Boolean) }
+ def frozen?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#17215
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def mutable?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#17210
+ sig { returns(T::Boolean) }
+ def mutable?; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17233
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#17188
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17243
+ def type; end
+ end
+end
+
+# Represents the use of the `__LINE__` keyword.
+#
+# __LINE__
+# ^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#17260
+class Prism::SourceLineNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [SourceLineNode] a new instance of SourceLineNode
+ #
+ # source://prism//lib/prism/node.rb#17262
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#17335
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#17268
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17273
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#17283
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#17278
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> SourceLineNode
+ #
+ # source://prism//lib/prism/node.rb#17288
+ sig { params(location: Prism::Location).returns(Prism::SourceLineNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17273
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#17296
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#17301
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17319
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17329
+ def type; end
+ end
+end
+
+# Represents the use of the splat operator.
+#
+# [*a]
+# ^^
+#
+# source://prism//lib/prism/node.rb#17344
+class Prism::SplatNode < ::Prism::Node
+ # def initialize: (Location operator_loc, Prism::node? expression, Location location) -> void
+ #
+ # @return [SplatNode] a new instance of SplatNode
+ #
+ # source://prism//lib/prism/node.rb#17346
+ sig do
+ params(
+ source: Prism::Source,
+ operator_loc: Prism::Location,
+ expression: T.nilable(Prism::Node),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, operator_loc, expression, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#17438
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#17354
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17359
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#17371
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#17364
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?operator_loc: Location, ?expression: Prism::node?, ?location: Location) -> SplatNode
+ #
+ # source://prism//lib/prism/node.rb#17376
+ sig do
+ params(
+ operator_loc: Prism::Location,
+ expression: T.nilable(Prism::Node),
+ location: Prism::Location
+ ).returns(Prism::SplatNode)
+ end
+ def copy(operator_loc: T.unsafe(nil), expression: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17359
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { operator_loc: Location, expression: Prism::node?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#17384
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # attr_reader expression: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#17396
+ sig { returns(T.nilable(Prism::Node)) }
+ def expression; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#17404
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def operator: () -> String
+ #
+ # source://prism//lib/prism/node.rb#17399
+ sig { returns(String) }
+ def operator; end
+
+ # attr_reader operator_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#17389
+ sig { returns(Prism::Location) }
+ def operator_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17422
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17432
+ def type; end
+ end
+end
+
+# Represents a set of statements contained within some scope.
+#
+# foo; bar; baz
+# ^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#17449
+class Prism::StatementsNode < ::Prism::Node
+ # def initialize: (Array[Prism::node] body, Location location) -> void
+ #
+ # @return [StatementsNode] a new instance of StatementsNode
+ #
+ # source://prism//lib/prism/node.rb#17451
+ sig { params(source: Prism::Source, body: T::Array[Prism::Node], location: Prism::Location).void }
+ def initialize(source, body, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#17528
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#17458
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader body: Array[Prism::node]
+ #
+ # source://prism//lib/prism/node.rb#17491
+ sig { returns(T::Array[Prism::Node]) }
+ def body; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17463
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#17473
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#17468
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?body: Array[Prism::node], ?location: Location) -> StatementsNode
+ #
+ # source://prism//lib/prism/node.rb#17478
+ sig { params(body: T::Array[Prism::Node], location: Prism::Location).returns(Prism::StatementsNode) }
+ def copy(body: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17463
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { body: Array[Prism::node], location: Location }
+ #
+ # source://prism//lib/prism/node.rb#17486
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#17494
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17512
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17522
+ def type; end
+ end
+end
+
+# Flags for string nodes.
+#
+# source://prism//lib/prism/node.rb#19268
+module Prism::StringFlags; end
+
+# internal bytes forced the encoding to binary
+#
+# source://prism//lib/prism/node.rb#19273
+Prism::StringFlags::FORCED_BINARY_ENCODING = T.let(T.unsafe(nil), Integer)
+
+# internal bytes forced the encoding to UTF-8
+#
+# source://prism//lib/prism/node.rb#19270
+Prism::StringFlags::FORCED_UTF8_ENCODING = T.let(T.unsafe(nil), Integer)
+
+# source://prism//lib/prism/node.rb#19276
+Prism::StringFlags::FROZEN = T.let(T.unsafe(nil), Integer)
+
+# source://prism//lib/prism/node.rb#19279
+Prism::StringFlags::MUTABLE = T.let(T.unsafe(nil), Integer)
+
+# Represents a string literal, a string contained within a `%w` list, or plain string content within an interpolated string.
+#
+# "foo"
+# ^^^^^
+#
+# %w[foo]
+# ^^^
+#
+# "foo #{bar} baz"
+# ^^^^ ^^^^
+#
+# source://prism//lib/prism/node.rb#17545
+class Prism::StringNode < ::Prism::Node
+ include ::Prism::HeredocQuery
+
+ # def initialize: (Integer flags, Location? opening_loc, Location content_loc, Location? closing_loc, String unescaped, Location location) -> void
+ #
+ # @return [StringNode] a new instance of StringNode
+ #
+ # source://prism//lib/prism/node.rb#17547
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ opening_loc: T.nilable(Prism::Location),
+ content_loc: Prism::Location,
+ closing_loc: T.nilable(Prism::Location),
+ unescaped: String,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, opening_loc, content_loc, closing_loc, unescaped, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#17700
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#17558
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17563
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#17661
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # attr_reader closing_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#17615
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#17573
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#17568
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def content: () -> String
+ #
+ # source://prism//lib/prism/node.rb#17656
+ sig { returns(String) }
+ def content; end
+
+ # attr_reader content_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#17608
+ sig { returns(Prism::Location) }
+ def content_loc; end
+
+ # def copy: (?flags: Integer, ?opening_loc: Location?, ?content_loc: Location, ?closing_loc: Location?, ?unescaped: String, ?location: Location) -> StringNode
+ #
+ # source://prism//lib/prism/node.rb#17578
+ sig do
+ params(
+ flags: Integer,
+ opening_loc: T.nilable(Prism::Location),
+ content_loc: Prism::Location,
+ closing_loc: T.nilable(Prism::Location),
+ unescaped: String,
+ location: Prism::Location
+ ).returns(Prism::StringNode)
+ end
+ def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), content_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), unescaped: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17563
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location?, content_loc: Location, closing_loc: Location?, unescaped: String, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#17586
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def forced_binary_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#17636
+ sig { returns(T::Boolean) }
+ def forced_binary_encoding?; end
+
+ # def forced_utf8_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#17631
+ sig { returns(T::Boolean) }
+ def forced_utf8_encoding?; end
+
+ # def frozen?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#17641
+ sig { returns(T::Boolean) }
+ def frozen?; end
+
+ sig { returns(T::Boolean) }
+ def heredoc?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#17666
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def mutable?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#17646
+ sig { returns(T::Boolean) }
+ def mutable?; end
+
+ # def opening: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#17651
+ sig { returns(T.nilable(String)) }
+ def opening; end
+
+ # attr_reader opening_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#17595
+ sig { returns(T.nilable(Prism::Location)) }
+ def opening_loc; end
+
+ # Occasionally it's helpful to treat a string as if it were interpolated so
+ # that there's a consistent interface for working with strings.
+ #
+ # source://prism//lib/prism/node_ext.rb#69
+ sig { returns(Prism::InterpolatedStringNode) }
+ def to_interpolated; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17684
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader unescaped: String
+ #
+ # source://prism//lib/prism/node.rb#17628
+ sig { returns(String) }
+ def unescaped; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#17591
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17694
+ def type; end
+ end
+end
+
+# Represents the use of the `super` keyword with parentheses or arguments.
+#
+# super()
+# ^^^^^^^
+#
+# super foo, bar
+# ^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#17717
+class Prism::SuperNode < ::Prism::Node
+ # def initialize: (Location keyword_loc, Location? lparen_loc, ArgumentsNode? arguments, Location? rparen_loc, Prism::node? block, Location location) -> void
+ #
+ # @return [SuperNode] a new instance of SuperNode
+ #
+ # source://prism//lib/prism/node.rb#17719
+ sig do
+ params(
+ source: Prism::Source,
+ keyword_loc: Prism::Location,
+ lparen_loc: T.nilable(Prism::Location),
+ arguments: T.nilable(Prism::ArgumentsNode),
+ rparen_loc: T.nilable(Prism::Location),
+ block: T.nilable(Prism::Node),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, keyword_loc, lparen_loc, arguments, rparen_loc, block, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#17854
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#17730
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader arguments: ArgumentsNode?
+ #
+ # source://prism//lib/prism/node.rb#17786
+ sig { returns(T.nilable(Prism::ArgumentsNode)) }
+ def arguments; end
+
+ # attr_reader block: Prism::node?
+ #
+ # source://prism//lib/prism/node.rb#17802
+ sig { returns(T.nilable(Prism::Node)) }
+ def block; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17735
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#17748
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#17740
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?keyword_loc: Location, ?lparen_loc: Location?, ?arguments: ArgumentsNode?, ?rparen_loc: Location?, ?block: Prism::node?, ?location: Location) -> SuperNode
+ #
+ # source://prism//lib/prism/node.rb#17753
+ sig do
+ params(
+ keyword_loc: Prism::Location,
+ lparen_loc: T.nilable(Prism::Location),
+ arguments: T.nilable(Prism::ArgumentsNode),
+ rparen_loc: T.nilable(Prism::Location),
+ block: T.nilable(Prism::Node),
+ location: Prism::Location
+ ).returns(Prism::SuperNode)
+ end
+ def copy(keyword_loc: T.unsafe(nil), lparen_loc: T.unsafe(nil), arguments: T.unsafe(nil), rparen_loc: T.unsafe(nil), block: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17735
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { keyword_loc: Location, lparen_loc: Location?, arguments: ArgumentsNode?, rparen_loc: Location?, block: Prism::node?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#17761
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#17820
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#17805
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#17766
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # def lparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#17810
+ sig { returns(T.nilable(String)) }
+ def lparen; end
+
+ # attr_reader lparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#17773
+ sig { returns(T.nilable(Prism::Location)) }
+ def lparen_loc; end
+
+ # def rparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#17815
+ sig { returns(T.nilable(String)) }
+ def rparen; end
+
+ # attr_reader rparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#17789
+ sig { returns(T.nilable(Prism::Location)) }
+ def rparen_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17838
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#17848
+ def type; end
+ end
+end
+
+# Flags for symbol nodes.
+#
+# source://prism//lib/prism/node.rb#19283
+module Prism::SymbolFlags; end
+
+# internal bytes forced the encoding to binary
+#
+# source://prism//lib/prism/node.rb#19288
+Prism::SymbolFlags::FORCED_BINARY_ENCODING = T.let(T.unsafe(nil), Integer)
+
+# internal bytes forced the encoding to US-ASCII
+#
+# source://prism//lib/prism/node.rb#19291
+Prism::SymbolFlags::FORCED_US_ASCII_ENCODING = T.let(T.unsafe(nil), Integer)
+
+# internal bytes forced the encoding to UTF-8
+#
+# source://prism//lib/prism/node.rb#19285
+Prism::SymbolFlags::FORCED_UTF8_ENCODING = T.let(T.unsafe(nil), Integer)
+
+# Represents a symbol literal or a symbol contained within a `%i` list.
+#
+# :foo
+# ^^^^
+#
+# %i[foo]
+# ^^^
+#
+# source://prism//lib/prism/node.rb#17871
+class Prism::SymbolNode < ::Prism::Node
+ # def initialize: (Integer flags, Location? opening_loc, Location? value_loc, Location? closing_loc, String unescaped, Location location) -> void
+ #
+ # @return [SymbolNode] a new instance of SymbolNode
+ #
+ # source://prism//lib/prism/node.rb#17873
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ opening_loc: T.nilable(Prism::Location),
+ value_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ unescaped: String,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, opening_loc, value_loc, closing_loc, unescaped, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#18027
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#17884
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17889
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#17988
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # attr_reader closing_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#17947
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#17899
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#17894
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?opening_loc: Location?, ?value_loc: Location?, ?closing_loc: Location?, ?unescaped: String, ?location: Location) -> SymbolNode
+ #
+ # source://prism//lib/prism/node.rb#17904
+ sig do
+ params(
+ flags: Integer,
+ opening_loc: T.nilable(Prism::Location),
+ value_loc: T.nilable(Prism::Location),
+ closing_loc: T.nilable(Prism::Location),
+ unescaped: String,
+ location: Prism::Location
+ ).returns(Prism::SymbolNode)
+ end
+ def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), value_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), unescaped: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#17889
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location?, value_loc: Location?, closing_loc: Location?, unescaped: String, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#17912
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def forced_binary_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#17968
+ sig { returns(T::Boolean) }
+ def forced_binary_encoding?; end
+
+ # def forced_us_ascii_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#17973
+ sig { returns(T::Boolean) }
+ def forced_us_ascii_encoding?; end
+
+ # def forced_utf8_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#17963
+ sig { returns(T::Boolean) }
+ def forced_utf8_encoding?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#17993
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def opening: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#17978
+ sig { returns(T.nilable(String)) }
+ def opening; end
+
+ # attr_reader opening_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#17921
+ sig { returns(T.nilable(Prism::Location)) }
+ def opening_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18011
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader unescaped: String
+ #
+ # source://prism//lib/prism/node.rb#17960
+ sig { returns(String) }
+ def unescaped; end
+
+ # def value: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#17983
+ sig { returns(T.nilable(String)) }
+ def value; end
+
+ # attr_reader value_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#17934
+ sig { returns(T.nilable(Prism::Location)) }
+ def value_loc; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#17917
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18021
+ def type; end
+ end
+end
+
+# This represents a token from the Ruby source.
+#
+# source://prism//lib/prism/parse_result.rb#645
+class Prism::Token
+ # Create a new token object with the given type, value, and location.
+ #
+ # @return [Token] a new instance of Token
+ #
+ # source://prism//lib/prism/parse_result.rb#657
+ sig { params(source: Prism::Source, type: Symbol, value: String, location: T.any(Integer, Prism::Location)).void }
+ def initialize(source, type, value, location); end
+
+ # Returns true if the given other token is equal to this token.
+ #
+ # source://prism//lib/prism/parse_result.rb#692
+ sig { params(other: T.untyped).returns(T::Boolean) }
+ def ==(other); end
+
+ # Implement the hash pattern matching interface for Token.
+ #
+ # source://prism//lib/prism/parse_result.rb#665
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # A Location object representing the location of this token in the source.
+ #
+ # source://prism//lib/prism/parse_result.rb#670
+ sig { returns(Prism::Location) }
+ def location; end
+
+ # Implement the pretty print interface for Token.
+ #
+ # source://prism//lib/prism/parse_result.rb#677
+ sig { params(q: T.untyped).void }
+ def pretty_print(q); end
+
+ # The type of token that this token is.
+ #
+ # source://prism//lib/prism/parse_result.rb#651
+ sig { returns(Symbol) }
+ def type; end
+
+ # A byteslice of the source that this token represents.
+ #
+ # source://prism//lib/prism/parse_result.rb#654
+ sig { returns(String) }
+ def value; end
+
+ private
+
+ # The Source object that represents the source this token came from.
+ #
+ # source://prism//lib/prism/parse_result.rb#647
+ sig { returns(Prism::Source) }
+ def source; end
+end
+
+# This module is responsible for converting the prism syntax tree into other
+# syntax trees.
+#
+# source://prism//lib/prism/translation.rb#6
+module Prism::Translation; end
+
+class Prism::Translation::Parser < Parser::Base
+ sig { overridable.returns(Integer) }
+ def version; end
+end
+
+class Prism::Translation::Parser33 < Prism::Translation::Parser
+ sig { override.returns(Integer) }
+ def version; end
+end
+
+class Prism::Translation::Parser34 < Prism::Translation::Parser
+ sig { override.returns(Integer) }
+ def version; end
+end
+
+# This class provides a compatibility layer between prism and Ripper. It
+# functions by parsing the entire tree first and then walking it and
+# executing each of the Ripper callbacks as it goes. To use this class, you
+# treat `Prism::Translation::Ripper` effectively as you would treat the
+# `Ripper` class.
+#
+# Note that this class will serve the most common use cases, but Ripper's
+# API is extensive and undocumented. It relies on reporting the state of the
+# parser at any given time. We do our best to replicate that here, but
+# because it is a different architecture it is not possible to perfectly
+# replicate the behavior of Ripper.
+#
+# The main known difference is that we may omit dispatching some events in
+# some cases. This impacts the following events:
+#
+# - on_assign_error
+# - on_comma
+# - on_ignored_nl
+# - on_ignored_sp
+# - on_kw
+# - on_label_end
+# - on_lbrace
+# - on_lbracket
+# - on_lparen
+# - on_nl
+# - on_op
+# - on_operator_ambiguous
+# - on_rbrace
+# - on_rbracket
+# - on_rparen
+# - on_semicolon
+# - on_sp
+# - on_symbeg
+# - on_tstring_beg
+# - on_tstring_end
+#
+# source://prism//lib/prism/translation/ripper.rb#43
+class Prism::Translation::Ripper < ::Prism::Compiler
+ # Create a new Translation::Ripper object with the given source.
+ #
+ # @return [Ripper] a new instance of Ripper
+ #
+ # source://prism//lib/prism/translation/ripper.rb#444
+ def initialize(source, filename = T.unsafe(nil), lineno = T.unsafe(nil)); end
+
+ # The current column number of the parser.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#441
+ def column; end
+
+ # True if the parser encountered an error during parsing.
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/translation/ripper.rb#457
+ sig { returns(T::Boolean) }
+ def error?; end
+
+ # The filename of the source being parsed.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#435
+ def filename; end
+
+ # The current line number of the parser.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#438
+ def lineno; end
+
+ # Parse the source and return the result.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#462
+ sig { returns(T.untyped) }
+ def parse; end
+
+ # The source that is being parsed.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#432
+ def source; end
+
+ # alias $foo $bar
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#561
+ def visit_alias_global_variable_node(node); end
+
+ # alias foo bar
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#551
+ def visit_alias_method_node(node); end
+
+ # foo => bar | baz
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#585
+ def visit_alternation_pattern_node(node); end
+
+ # a and b
+ # ^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#605
+ def visit_and_node(node); end
+
+ # foo(bar)
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#796
+ def visit_arguments_node(node); end
+
+ # []
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#615
+ def visit_array_node(node); end
+
+ # foo => [bar]
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#775
+ def visit_array_pattern_node(node); end
+
+ # { a: 1 }
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#803
+ def visit_assoc_node(node); end
+
+ # def foo(**); bar(**); end
+ # ^^
+ #
+ # { **foo }
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#816
+ def visit_assoc_splat_node(node); end
+
+ # $+
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#825
+ def visit_back_reference_read_node(node); end
+
+ # begin end
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#832
+ def visit_begin_node(node); end
+
+ # foo(&bar)
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#896
+ def visit_block_argument_node(node); end
+
+ # foo { |; bar| }
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#902
+ def visit_block_local_variable_node(node); end
+
+ # Visit a BlockNode.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#908
+ def visit_block_node(node); end
+
+ # def foo(&bar); end
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#944
+ def visit_block_parameter_node(node); end
+
+ # A block's parameters.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#958
+ def visit_block_parameters_node(node); end
+
+ # break
+ # ^^^^^
+ #
+ # break foo
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#982
+ def visit_break_node(node); end
+
+ # foo.bar &&= baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1194
+ def visit_call_and_write_node(node); end
+
+ # foo
+ # ^^^
+ #
+ # foo.bar
+ # ^^^^^^^
+ #
+ # foo.bar() {}
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1002
+ def visit_call_node(node); end
+
+ # foo.bar += baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1172
+ def visit_call_operator_write_node(node); end
+
+ # foo.bar ||= baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1216
+ def visit_call_or_write_node(node); end
+
+ # foo.bar, = 1
+ # ^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1238
+ def visit_call_target_node(node); end
+
+ # foo => bar => baz
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1263
+ def visit_capture_pattern_node(node); end
+
+ # case foo; in bar; end
+ # ^^^^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1286
+ def visit_case_match_node(node); end
+
+ # case foo; when bar; end
+ # ^^^^^^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1273
+ def visit_case_node(node); end
+
+ # class Foo; end
+ # ^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1299
+ def visit_class_node(node); end
+
+ # @@foo &&= bar
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1352
+ def visit_class_variable_and_write_node(node); end
+
+ # @@foo += bar
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1338
+ def visit_class_variable_operator_write_node(node); end
+
+ # @@foo ||= bar
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1366
+ def visit_class_variable_or_write_node(node); end
+
+ # @@foo
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1317
+ def visit_class_variable_read_node(node); end
+
+ # @@foo, = bar
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1380
+ def visit_class_variable_target_node(node); end
+
+ # @@foo = 1
+ # ^^^^^^^^^
+ #
+ # @@foo, @@bar = 1
+ # ^^^^^ ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1327
+ def visit_class_variable_write_node(node); end
+
+ # Foo &&= bar
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1422
+ def visit_constant_and_write_node(node); end
+
+ # Foo += bar
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1408
+ def visit_constant_operator_write_node(node); end
+
+ # Foo ||= bar
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1436
+ def visit_constant_or_write_node(node); end
+
+ # Foo::Bar &&= baz
+ # ^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1523
+ def visit_constant_path_and_write_node(node); end
+
+ # Foo::Bar
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1457
+ def visit_constant_path_node(node); end
+
+ # Foo::Bar += baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1509
+ def visit_constant_path_operator_write_node(node); end
+
+ # Foo::Bar ||= baz
+ # ^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1537
+ def visit_constant_path_or_write_node(node); end
+
+ # Foo::Bar, = baz
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1551
+ def visit_constant_path_target_node(node); end
+
+ # Foo::Bar = 1
+ # ^^^^^^^^^^^^
+ #
+ # Foo::Foo, Bar::Bar = 1
+ # ^^^^^^^^ ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1480
+ def visit_constant_path_write_node(node); end
+
+ # Foo
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1387
+ def visit_constant_read_node(node); end
+
+ # Foo, = bar
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1450
+ def visit_constant_target_node(node); end
+
+ # Foo = 1
+ # ^^^^^^^
+ #
+ # Foo, Bar = 1
+ # ^^^ ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1397
+ def visit_constant_write_node(node); end
+
+ # def foo; end
+ # ^^^^^^^^^^^^
+ #
+ # def self.foo; end
+ # ^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1560
+ def visit_def_node(node); end
+
+ # defined? a
+ # ^^^^^^^^^^
+ #
+ # defined?(a)
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1607
+ def visit_defined_node(node); end
+
+ # if foo then bar else baz end
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1614
+ def visit_else_node(node); end
+
+ # "foo #{bar}"
+ # ^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1630
+ def visit_embedded_statements_node(node); end
+
+ # "foo #@bar"
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1651
+ def visit_embedded_variable_node(node); end
+
+ # Visit an EnsureNode node.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1662
+ def visit_ensure_node(node); end
+
+ # false
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1680
+ def visit_false_node(node); end
+
+ # foo => [*, bar, *]
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1687
+ def visit_find_pattern_node(node); end
+
+ # if foo .. bar; end
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1712
+ def visit_flip_flop_node(node); end
+
+ # 1.0
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1726
+ def visit_float_node(node); end
+
+ # for foo in bar do end
+ # ^^^^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1732
+ def visit_for_node(node); end
+
+ # def foo(...); bar(...); end
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1749
+ def visit_forwarding_arguments_node(node); end
+
+ # def foo(...); end
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1756
+ def visit_forwarding_parameter_node(node); end
+
+ # super
+ # ^^^^^
+ #
+ # super {}
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1766
+ def visit_forwarding_super_node(node); end
+
+ # $foo &&= bar
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1815
+ def visit_global_variable_and_write_node(node); end
+
+ # $foo += bar
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1801
+ def visit_global_variable_operator_write_node(node); end
+
+ # $foo ||= bar
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1829
+ def visit_global_variable_or_write_node(node); end
+
+ # $foo
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1780
+ def visit_global_variable_read_node(node); end
+
+ # $foo, = bar
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1843
+ def visit_global_variable_target_node(node); end
+
+ # $foo = 1
+ # ^^^^^^^^
+ #
+ # $foo, $bar = 1
+ # ^^^^ ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1790
+ def visit_global_variable_write_node(node); end
+
+ # {}
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1850
+ def visit_hash_node(node); end
+
+ # foo => {}
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1865
+ def visit_hash_pattern_node(node); end
+
+ # if foo then bar end
+ # ^^^^^^^^^^^^^^^^^^^
+ #
+ # bar if foo
+ # ^^^^^^^^^^
+ #
+ # foo ? bar : baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1907
+ def visit_if_node(node); end
+
+ # 1i
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1943
+ def visit_imaginary_node(node); end
+
+ # { foo: }
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1949
+ def visit_implicit_node(node); end
+
+ # foo { |bar,| }
+ # ^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1954
+ def visit_implicit_rest_node(node); end
+
+ # case foo; in bar; end
+ # ^^^^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1961
+ def visit_in_node(node); end
+
+ # foo[bar] &&= baz
+ # ^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1996
+ def visit_index_and_write_node(node); end
+
+ # foo[bar] += baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1979
+ def visit_index_operator_write_node(node); end
+
+ # foo[bar] ||= baz
+ # ^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2013
+ def visit_index_or_write_node(node); end
+
+ # foo[bar], = 1
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2030
+ def visit_index_target_node(node); end
+
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2072
+ def visit_instance_variable_and_write_node(node); end
+
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2058
+ def visit_instance_variable_operator_write_node(node); end
+
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2086
+ def visit_instance_variable_or_write_node(node); end
+
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2040
+ def visit_instance_variable_read_node(node); end
+
+ # @foo, = bar
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2100
+ def visit_instance_variable_target_node(node); end
+
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2047
+ def visit_instance_variable_write_node(node); end
+
+ # 1
+ # ^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2107
+ def visit_integer_node(node); end
+
+ # if /foo #{bar}/ then end
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2113
+ def visit_interpolated_match_last_line_node(node); end
+
+ # /foo #{bar}/
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2132
+ def visit_interpolated_regular_expression_node(node); end
+
+ # "foo #{bar}"
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2151
+ def visit_interpolated_string_node(node); end
+
+ # :"foo #{bar}"
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2179
+ def visit_interpolated_symbol_node(node); end
+
+ # `foo #{bar}`
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2192
+ def visit_interpolated_x_string_node(node); end
+
+ # -> { it }
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2222
+ def visit_it_local_variable_read_node(node); end
+
+ # -> { it }
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2229
+ def visit_it_parameters_node(node); end
+
+ # foo(bar: baz)
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2234
+ def visit_keyword_hash_node(node); end
+
+ # def foo(**bar); end
+ # ^^^^^
+ #
+ # def foo(**); end
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2246
+ def visit_keyword_rest_parameter_node(node); end
+
+ # -> {}
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2260
+ def visit_lambda_node(node); end
+
+ # foo &&= bar
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2352
+ def visit_local_variable_and_write_node(node); end
+
+ # foo += bar
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2338
+ def visit_local_variable_operator_write_node(node); end
+
+ # foo ||= bar
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2366
+ def visit_local_variable_or_write_node(node); end
+
+ # foo
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2320
+ def visit_local_variable_read_node(node); end
+
+ # foo, = bar
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2380
+ def visit_local_variable_target_node(node); end
+
+ # foo = 1
+ # ^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2327
+ def visit_local_variable_write_node(node); end
+
+ # if /foo/ then end
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2387
+ def visit_match_last_line_node(node); end
+
+ # foo in bar
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2402
+ def visit_match_predicate_node(node); end
+
+ # foo => bar
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2411
+ def visit_match_required_node(node); end
+
+ # /(?foo)/ =~ bar
+ # ^^^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2420
+ def visit_match_write_node(node); end
+
+ # A node that is missing from the syntax tree. This is only used in the
+ # case of a syntax error.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2426
+ def visit_missing_node(node); end
+
+ # module Foo; end
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2432
+ def visit_module_node(node); end
+
+ # (foo, bar), bar = qux
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2449
+ def visit_multi_target_node(node); end
+
+ # foo, bar = baz
+ # ^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2503
+ def visit_multi_write_node(node); end
+
+ # next
+ # ^^^^
+ #
+ # next foo
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2523
+ def visit_next_node(node); end
+
+ # nil
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2537
+ def visit_nil_node(node); end
+
+ # def foo(**nil); end
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2544
+ def visit_no_keywords_parameter_node(node); end
+
+ # -> { _1 + _2 }
+ # ^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2553
+ def visit_numbered_parameters_node(node); end
+
+ # $1
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2558
+ def visit_numbered_reference_read_node(node); end
+
+ # def foo(bar: baz); end
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2565
+ def visit_optional_keyword_parameter_node(node); end
+
+ # def foo(bar = 1); end
+ # ^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2575
+ def visit_optional_parameter_node(node); end
+
+ # a or b
+ # ^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2585
+ def visit_or_node(node); end
+
+ # def foo(bar, *baz); end
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2595
+ def visit_parameters_node(node); end
+
+ # ()
+ # ^^
+ #
+ # (1)
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2622
+ def visit_parentheses_node(node); end
+
+ # foo => ^(bar)
+ # ^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2636
+ def visit_pinned_expression_node(node); end
+
+ # foo = 1 and bar => ^foo
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2645
+ def visit_pinned_variable_node(node); end
+
+ # END {}
+ # ^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2651
+ def visit_post_execution_node(node); end
+
+ # BEGIN {}
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2666
+ def visit_pre_execution_node(node); end
+
+ # The top-level program node.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2680
+ def visit_program_node(node); end
+
+ # 0..5
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2691
+ def visit_range_node(node); end
+
+ # 1r
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2705
+ def visit_rational_node(node); end
+
+ # redo
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2711
+ def visit_redo_node(node); end
+
+ # /foo/
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2718
+ def visit_regular_expression_node(node); end
+
+ # def foo(bar:); end
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2740
+ def visit_required_keyword_parameter_node(node); end
+
+ # def foo(bar); end
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2747
+ def visit_required_parameter_node(node); end
+
+ # foo rescue bar
+ # ^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2754
+ def visit_rescue_modifier_node(node); end
+
+ # begin; rescue; end
+ # ^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2764
+ def visit_rescue_node(node); end
+
+ # def foo(*bar); end
+ # ^^^^
+ #
+ # def foo(*); end
+ # ^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2822
+ def visit_rest_parameter_node(node); end
+
+ # retry
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2834
+ def visit_retry_node(node); end
+
+ # return
+ # ^^^^^^
+ #
+ # return 1
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2844
+ def visit_return_node(node); end
+
+ # self
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2858
+ def visit_self_node(node); end
+
+ # A shareable constant.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2864
+ def visit_shareable_constant_node(node); end
+
+ # class << self; end
+ # ^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2870
+ def visit_singleton_class_node(node); end
+
+ # __ENCODING__
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2880
+ def visit_source_encoding_node(node); end
+
+ # __FILE__
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2887
+ def visit_source_file_node(node); end
+
+ # __LINE__
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2894
+ def visit_source_line_node(node); end
+
+ # foo(*bar)
+ # ^^^^
+ #
+ # def foo((bar, *baz)); end
+ # ^^^^
+ #
+ # def foo(*); bar(*); end
+ # ^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2907
+ def visit_splat_node(node); end
+
+ # A list of statements.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2912
+ def visit_statements_node(node); end
+
+ # "foo"
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2929
+ def visit_string_node(node); end
+
+ # super(foo)
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3061
+ def visit_super_node(node); end
+
+ # :foo
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3082
+ def visit_symbol_node(node); end
+
+ # true
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3106
+ def visit_true_node(node); end
+
+ # undef foo
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3113
+ def visit_undef_node(node); end
+
+ # unless foo; bar end
+ # ^^^^^^^^^^^^^^^^^^^
+ #
+ # bar unless foo
+ # ^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3125
+ def visit_unless_node(node); end
+
+ # until foo; bar end
+ # ^^^^^^^^^^^^^^^^^
+ #
+ # bar until foo
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3153
+ def visit_until_node(node); end
+
+ # case foo; when bar; end
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3177
+ def visit_when_node(node); end
+
+ # while foo; bar end
+ # ^^^^^^^^^^^^^^^^^^
+ #
+ # bar while foo
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3198
+ def visit_while_node(node); end
+
+ # `foo`
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3222
+ def visit_x_string_node(node); end
+
+ # yield
+ # ^^^^^
+ #
+ # yield 1
+ # ^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3245
+ def visit_yield_node(node); end
+
+ private
+
+ # :stopdoc:
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def _dispatch_0; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def _dispatch_1(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def _dispatch_2(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def _dispatch_3(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3393
+ def _dispatch_4(_, _, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3394
+ def _dispatch_5(_, _, _, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3395
+ def _dispatch_7(_, _, _, _, _, _, _); end
+
+ # This method is responsible for updating lineno and column information
+ # to reflect the current node.
+ #
+ # This method could be drastically improved with some caching on the start
+ # of every line, but for now it's good enough.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3379
+ def bounds(location); end
+
+ # Returns true if the given node is a command node.
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1163
+ def command?(node); end
+
+ # This method is called when the parser found syntax error.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3417
+ def compile_error(msg); end
+
+ # This method is provided by the Ripper C extension. It is called when a
+ # string needs to be dedented because of a tilde heredoc. It is expected
+ # that it will modify the string in place and return the number of bytes
+ # that were removed.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3432
+ def dedent_string(string, width); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_BEGIN(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_CHAR(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_END(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on___end__(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_alias(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_alias_error(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_aref(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_aref_field(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_arg_ambiguous(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_arg_paren(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_args_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_args_add_block(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_args_add_star(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_args_forward; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_args_new; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_array(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3393
+ def on_aryptn(_, _, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_assign(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_assign_error(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_assoc_new(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_assoc_splat(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_assoclist_from_args(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_backref(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_backtick(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_bare_assoc_hash(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_begin(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_binary(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_block_var(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_blockarg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3393
+ def on_bodystmt(_, _, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_brace_block(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_break(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_call(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_case(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_class(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_class_name_error(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_comma(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_command(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3393
+ def on_command_call(_, _, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_comment(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_const(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_const_path_field(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_const_path_ref(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_const_ref(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_cvar(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_def(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_defined(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3394
+ def on_defs(_, _, _, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_do_block(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_dot2(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_dot3(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_dyna_symbol(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_else(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_elsif(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_embdoc(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_embdoc_beg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_embdoc_end(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_embexpr_beg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_embexpr_end(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_embvar(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_ensure(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_excessed_comma; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_fcall(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_field(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_float(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3393
+ def on_fndptn(_, _, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_for(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_gvar(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_hash(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_heredoc_beg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_heredoc_dedent(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_heredoc_end(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_hshptn(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_ident(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_if(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_if_mod(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_ifop(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_ignored_nl(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_ignored_sp(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_imaginary(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_in(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_int(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_ivar(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_kw(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_kwrest_param(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_label(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_label_end(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_lambda(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_lbrace(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_lbracket(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_lparen(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_magic_comment(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_massign(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_method_add_arg(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_method_add_block(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_mlhs_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_mlhs_add_post(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_mlhs_add_star(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_mlhs_new; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_mlhs_paren(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_module(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_mrhs_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_mrhs_add_star(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_mrhs_new; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_mrhs_new_from_args(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_next(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_nl(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_nokw_param(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_op(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_opassign(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_operator_ambiguous(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_param_error(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3395
+ def on_params(_, _, _, _, _, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_paren(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_parse_error(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_period(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_program(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_qsymbols_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_qsymbols_beg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_qsymbols_new; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_qwords_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_qwords_beg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_qwords_new; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_rational(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_rbrace(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_rbracket(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_redo; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_regexp_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_regexp_beg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_regexp_end(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_regexp_literal(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_regexp_new; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3393
+ def on_rescue(_, _, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_rescue_mod(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_rest_param(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_retry; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_return(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_return0; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_rparen(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_sclass(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_semicolon(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_sp(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_stmts_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_stmts_new; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_string_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_string_concat(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_string_content; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_string_dvar(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_string_embexpr(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_string_literal(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_super(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_symbeg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_symbol(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_symbol_literal(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_symbols_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_symbols_beg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_symbols_new; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_tlambda(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_tlambeg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_top_const_field(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_top_const_ref(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_tstring_beg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_tstring_content(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_tstring_end(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_unary(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_undef(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_unless(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_unless_mod(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_until(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_until_mod(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_var_alias(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_var_field(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_var_ref(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_vcall(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_void_stmt; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3392
+ def on_when(_, _, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_while(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_while_mod(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_word_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_word_new; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_words_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_words_beg(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_words_new; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_words_sep(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3391
+ def on_xstring_add(_, _); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_xstring_literal(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_xstring_new; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3390
+ def on_yield(_); end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_yield0; end
+
+ # source://prism//lib/prism/translation/ripper.rb#3389
+ def on_zsuper; end
+
+ # Lazily initialize the parse result.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3271
+ def result; end
+
+ # Returns true if there is a comma between the two locations.
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3284
+ def trailing_comma?(left, right); end
+
+ # Visit one side of an alias global variable node.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#570
+ def visit_alias_global_variable_node_value(node); end
+
+ # Visit a list of elements, like the elements of an array or arguments.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#756
+ def visit_arguments(elements); end
+
+ # Visit the clauses of a begin node to form an on_bodystmt call.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#840
+ def visit_begin_node_clauses(location, node, allow_newline); end
+
+ # Visit the body of a structure that can have either a set of statements
+ # or statements wrapped in rescue/else/ensure.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#875
+ def visit_body_node(location, node, allow_newline = T.unsafe(nil)); end
+
+ # Visit the arguments and block of a call node and return the arguments
+ # and block as they should be used.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1136
+ def visit_call_node_arguments(arguments_node, block_node, trailing_comma); end
+
+ # Visit a constant path that is part of a write node.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#1489
+ def visit_constant_path_write_node_target(node); end
+
+ # Visit a destructured positional parameter node.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2609
+ def visit_destructured_parameter_node(node); end
+
+ # Visit a string that is expressed using a <<~ heredoc.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2980
+ def visit_heredoc_node(parts, base); end
+
+ # Ripper gives back the escaped string content but strips out the common
+ # leading whitespace. Prism gives back the unescaped string content and
+ # a location for the escaped string content. Unfortunately these don't
+ # work well together, so here we need to re-derive the common leading
+ # whitespace.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2955
+ def visit_heredoc_node_whitespace(parts); end
+
+ # Visit a heredoc node that is representing a string.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3026
+ def visit_heredoc_string_node(node); end
+
+ # Visit a heredoc node that is representing an xstring.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3043
+ def visit_heredoc_x_string_node(node); end
+
+ # Visit the targets of a multi-target node.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2462
+ def visit_multi_target_node_targets(lefts, rest, rights, skippable); end
+
+ # Visit a node that represents a number. We need to explicitly handle the
+ # unary - operator.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3323
+ def visit_number_node(node); end
+
+ # Visit a pattern within a pattern match. This is used to bypass the
+ # parenthesis node that can be used to wrap patterns.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#595
+ def visit_pattern_node(node); end
+
+ # Visit the list of statements of a statements node. We support nil
+ # statements in the list. This would normally not be allowed by the
+ # structure of the prism parse tree, but we manually add them here so that
+ # we can mirror Ripper's void stmt.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2921
+ def visit_statements_node_body(body); end
+
+ # Visit an individual part of a string-like node.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#2211
+ def visit_string_content(part); end
+
+ # Visit the string content of a particular node. This method is used to
+ # split into the various token types.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3296
+ def visit_token(token, allow_keywords = T.unsafe(nil)); end
+
+ # Dispatch a words_sep event that contains the space between the elements
+ # of list literals.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#745
+ def visit_words_sep(opening_loc, previous, current); end
+
+ # Visit a node that represents a write value. This is used to handle the
+ # special case of an implicit array that is generated without brackets.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3341
+ def visit_write_value(node); end
+
+ # Returns true if there is a semicolon between the two locations.
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3289
+ def void_stmt?(left, right, allow_newline); end
+
+ # This method is called when weak warning is produced by the parser.
+ # +fmt+ and +args+ is printf style.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3408
+ def warn(fmt, *args); end
+
+ # This method is called when strong warning is produced by the parser.
+ # +fmt+ and +args+ is printf style.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#3413
+ def warning(fmt, *args); end
+
+ class << self
+ # Tokenizes the Ruby program and returns an array of an array,
+ # which is formatted like
+ # [[lineno, column], type, token, state].
+ # The +filename+ argument is mostly ignored.
+ # By default, this method does not handle syntax errors in +src+,
+ # use the +raise_errors+ keyword to raise a SyntaxError for an error in +src+.
+ #
+ # require "ripper"
+ # require "pp"
+ #
+ # pp Ripper.lex("def m(a) nil end")
+ # #=> [[[1, 0], :on_kw, "def", FNAME ],
+ # [[1, 3], :on_sp, " ", FNAME ],
+ # [[1, 4], :on_ident, "m", ENDFN ],
+ # [[1, 5], :on_lparen, "(", BEG|LABEL],
+ # [[1, 6], :on_ident, "a", ARG ],
+ # [[1, 7], :on_rparen, ")", ENDFN ],
+ # [[1, 8], :on_sp, " ", BEG ],
+ # [[1, 9], :on_kw, "nil", END ],
+ # [[1, 12], :on_sp, " ", END ],
+ # [[1, 13], :on_kw, "end", END ]]
+ #
+ # source://prism//lib/prism/translation/ripper.rb#72
+ def lex(src, filename = T.unsafe(nil), lineno = T.unsafe(nil), raise_errors: T.unsafe(nil)); end
+
+ # Parses the given Ruby program read from +src+.
+ # +src+ must be a String or an IO or a object with a #gets method.
+ #
+ # source://prism//lib/prism/translation/ripper.rb#46
+ def parse(src, filename = T.unsafe(nil), lineno = T.unsafe(nil)); end
+
+ # Parses +src+ and create S-exp tree.
+ # Returns more readable tree rather than Ripper.sexp_raw.
+ # This method is mainly for developer use.
+ # The +filename+ argument is mostly ignored.
+ # By default, this method does not handle syntax errors in +src+,
+ # returning +nil+ in such cases. Use the +raise_errors+ keyword
+ # to raise a SyntaxError for an error in +src+.
+ #
+ # require "ripper"
+ # require "pp"
+ #
+ # pp Ripper.sexp("def m(a) nil end")
+ # #=> [:program,
+ # [[:def,
+ # [:@ident, "m", [1, 4]],
+ # [:paren, [:params, [[:@ident, "a", [1, 6]]], nil, nil, nil, nil, nil, nil]],
+ # [:bodystmt, [[:var_ref, [:@kw, "nil", [1, 9]]]], nil, nil, nil]]]]
+ #
+ # source://prism//lib/prism/translation/ripper.rb#381
+ def sexp(src, filename = T.unsafe(nil), lineno = T.unsafe(nil), raise_errors: T.unsafe(nil)); end
+
+ # Parses +src+ and create S-exp tree.
+ # This method is mainly for developer use.
+ # The +filename+ argument is mostly ignored.
+ # By default, this method does not handle syntax errors in +src+,
+ # returning +nil+ in such cases. Use the +raise_errors+ keyword
+ # to raise a SyntaxError for an error in +src+.
+ #
+ # require "ripper"
+ # require "pp"
+ #
+ # pp Ripper.sexp_raw("def m(a) nil end")
+ # #=> [:program,
+ # [:stmts_add,
+ # [:stmts_new],
+ # [:def,
+ # [:@ident, "m", [1, 4]],
+ # [:paren, [:params, [[:@ident, "a", [1, 6]]], nil, nil, nil]],
+ # [:bodystmt,
+ # [:stmts_add, [:stmts_new], [:var_ref, [:@kw, "nil", [1, 9]]]],
+ # nil,
+ # nil,
+ # nil]]]]
+ #
+ # source://prism//lib/prism/translation/ripper.rb#416
+ def sexp_raw(src, filename = T.unsafe(nil), lineno = T.unsafe(nil), raise_errors: T.unsafe(nil)); end
+ end
+end
+
+# A list of all of the Ruby binary operators.
+#
+# source://prism//lib/prism/translation/ripper.rb#337
+Prism::Translation::Ripper::BINARY_OPERATORS = T.let(T.unsafe(nil), Array)
+
+# This array contains name of all ripper events.
+#
+# source://prism//lib/prism/translation/ripper.rb#289
+Prism::Translation::Ripper::EVENTS = T.let(T.unsafe(nil), Array)
+
+# A list of all of the Ruby keywords.
+#
+# source://prism//lib/prism/translation/ripper.rb#292
+Prism::Translation::Ripper::KEYWORDS = T.let(T.unsafe(nil), Array)
+
+# This array contains name of parser events.
+#
+# source://prism//lib/prism/translation/ripper.rb#283
+Prism::Translation::Ripper::PARSER_EVENTS = T.let(T.unsafe(nil), Array)
+
+# This contains a table of all of the parser events and their
+# corresponding arity.
+#
+# source://prism//lib/prism/translation/ripper.rb#84
+Prism::Translation::Ripper::PARSER_EVENT_TABLE = T.let(T.unsafe(nil), Hash)
+
+# This array contains name of scanner events.
+#
+# source://prism//lib/prism/translation/ripper.rb#286
+Prism::Translation::Ripper::SCANNER_EVENTS = T.let(T.unsafe(nil), Array)
+
+# This contains a table of all of the scanner events and their
+# corresponding arity.
+#
+# source://prism//lib/prism/translation/ripper.rb#227
+Prism::Translation::Ripper::SCANNER_EVENT_TABLE = T.let(T.unsafe(nil), Hash)
+
+# This class mirrors the ::Ripper::SexpBuilder subclass of ::Ripper that
+# returns the arrays of [type, *children].
+#
+# source://prism//lib/prism/translation/ripper/sexp.rb#10
+class Prism::Translation::Ripper::SexpBuilder < ::Prism::Translation::Ripper
+ # :stopdoc:
+ #
+ # source://prism//lib/prism/translation/ripper/sexp.rb#13
+ def error; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_BEGIN(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_CHAR(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_END(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on___end__(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_alias(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_alias_error(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_aref(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_aref_field(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_arg_ambiguous(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_arg_paren(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_args_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_args_add_block(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_args_add_star(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_args_forward(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_args_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_array(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_aryptn(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_assign(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_assign_error(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_assoc_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_assoc_splat(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_assoclist_from_args(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_backref(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_backtick(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_bare_assoc_hash(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_begin(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_binary(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_block_var(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_blockarg(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_bodystmt(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_brace_block(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_break(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_call(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_case(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_class(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_class_name_error(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_comma(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_command(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_command_call(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_comment(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_const(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_const_path_field(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_const_path_ref(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_const_ref(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_cvar(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_def(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_defined(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_defs(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_do_block(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_dot2(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_dot3(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_dyna_symbol(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_else(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_elsif(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_embdoc(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_embdoc_beg(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_embdoc_end(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_embexpr_beg(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_embexpr_end(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_embvar(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_ensure(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_excessed_comma(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_fcall(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_field(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_float(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_fndptn(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_for(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_gvar(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_hash(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_heredoc_beg(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_heredoc_end(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_hshptn(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_ident(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_if(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_if_mod(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_ifop(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_ignored_nl(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_ignored_sp(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_imaginary(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_in(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_int(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_ivar(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_kw(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_kwrest_param(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_label(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_label_end(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_lambda(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_lbrace(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_lbracket(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_lparen(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_magic_comment(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_massign(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_method_add_arg(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_method_add_block(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_mlhs_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_mlhs_add_post(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_mlhs_add_star(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_mlhs_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_mlhs_paren(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_module(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_mrhs_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_mrhs_add_star(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_mrhs_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_mrhs_new_from_args(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_next(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_nl(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_nokw_param(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_op(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_opassign(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_operator_ambiguous(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_param_error(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_params(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_paren(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_period(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_program(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_qsymbols_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_qsymbols_beg(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_qsymbols_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_qwords_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_qwords_beg(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_qwords_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_rational(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_rbrace(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_rbracket(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_redo(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_regexp_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_regexp_beg(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_regexp_end(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_regexp_literal(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_regexp_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_rescue(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_rescue_mod(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_rest_param(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_retry(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_return(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_return0(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_rparen(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_sclass(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_semicolon(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_sp(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_stmts_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_stmts_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_string_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_string_concat(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_string_content(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_string_dvar(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_string_embexpr(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_string_literal(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_super(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_symbeg(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_symbol(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_symbol_literal(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_symbols_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_symbols_beg(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_symbols_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_tlambda(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_tlambeg(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_top_const_field(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_top_const_ref(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_tstring_beg(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_tstring_content(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_tstring_end(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_unary(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_undef(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_unless(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_unless_mod(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_until(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_until_mod(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_var_alias(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_var_field(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_var_ref(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_vcall(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_void_stmt(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_when(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_while(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_while_mod(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_word_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_word_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_words_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_words_beg(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_words_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#55
+ def on_words_sep(tok); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_xstring_add(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_xstring_literal(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_xstring_new(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_yield(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_yield0(*args); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#47
+ def on_zsuper(*args); end
+
+ private
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#61
+ def compile_error(mesg); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#17
+ def dedent_element(e, width); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#61
+ def on_error(mesg); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#24
+ def on_heredoc_dedent(val, width); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#61
+ def on_parse_error(mesg); end
+end
+
+# This class mirrors the ::Ripper::SexpBuilderPP subclass of ::Ripper that
+# returns the same values as ::Ripper::SexpBuilder except with a couple of
+# niceties that flatten linked lists into arrays.
+#
+# source://prism//lib/prism/translation/ripper/sexp.rb#74
+class Prism::Translation::Ripper::SexpBuilderPP < ::Prism::Translation::Ripper::SexpBuilder
+ private
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def _dispatch_event_new; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def _dispatch_event_push(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_args_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def on_args_new; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#79
+ def on_heredoc_dedent(val, width); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_mlhs_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#109
+ def on_mlhs_add_post(list, post); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#105
+ def on_mlhs_add_star(list, star); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def on_mlhs_new; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#101
+ def on_mlhs_paren(list); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_mrhs_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def on_mrhs_new; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_qsymbols_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def on_qsymbols_new; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_qwords_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def on_qwords_new; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_regexp_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def on_regexp_new; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_stmts_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def on_stmts_new; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_string_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_symbols_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def on_symbols_new; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_word_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def on_word_new; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_words_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def on_words_new; end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#96
+ def on_xstring_add(list, item); end
+
+ # source://prism//lib/prism/translation/ripper/sexp.rb#92
+ def on_xstring_new; end
+end
+
+# This module is the entry-point for converting a prism syntax tree into the
+# seattlerb/ruby_parser gem's syntax tree.
+#
+# source://prism//lib/prism/translation/ruby_parser.rb#14
+class Prism::Translation::RubyParser
+ # Parse the given source and translate it into the seattlerb/ruby_parser
+ # gem's Sexp format.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1556
+ def parse(source, filepath = T.unsafe(nil)); end
+
+ # Parse the given file and translate it into the seattlerb/ruby_parser
+ # gem's Sexp format.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1562
+ def parse_file(filepath); end
+
+ private
+
+ # Translate the given parse result and filepath into the
+ # seattlerb/ruby_parser gem's Sexp format.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1584
+ def translate(result, filepath); end
+
+ class << self
+ # Parse the given source and translate it into the seattlerb/ruby_parser
+ # gem's Sexp format.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1569
+ def parse(source, filepath = T.unsafe(nil)); end
+
+ # Parse the given file and translate it into the seattlerb/ruby_parser
+ # gem's Sexp format.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1575
+ def parse_file(filepath); end
+ end
+end
+
+# A prism visitor that builds Sexp objects.
+#
+# source://prism//lib/prism/translation/ruby_parser.rb#16
+class Prism::Translation::RubyParser::Compiler < ::Prism::Compiler
+ # Initialize a new compiler with the given file name.
+ #
+ # @return [Compiler] a new instance of Compiler
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#31
+ def initialize(file, in_def: T.unsafe(nil), in_pattern: T.unsafe(nil)); end
+
+ # This is the name of the file that we are compiling. We set it on every
+ # Sexp object that is generated, and also use it to compile __FILE__
+ # nodes.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#20
+ def file; end
+
+ # Class variables will change their type based on if they are inside of
+ # a method definition or not, so we need to track that state.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#24
+ def in_def; end
+
+ # Some nodes will change their representation if they are inside of a
+ # pattern, so we need to track that state.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#28
+ def in_pattern; end
+
+ # alias $foo $bar
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#45
+ def visit_alias_global_variable_node(node); end
+
+ # alias foo bar
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#39
+ def visit_alias_method_node(node); end
+
+ # foo => bar | baz
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#51
+ def visit_alternation_pattern_node(node); end
+
+ # a and b
+ # ^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#57
+ def visit_and_node(node); end
+
+ # foo(bar)
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#96
+ def visit_arguments_node(node); end
+
+ # []
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#63
+ def visit_array_node(node); end
+
+ # foo => [bar]
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#73
+ def visit_array_pattern_node(node); end
+
+ # { a: 1 }
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#102
+ def visit_assoc_node(node); end
+
+ # def foo(**); bar(**); end
+ # ^^
+ #
+ # { **foo }
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#111
+ def visit_assoc_splat_node(node); end
+
+ # $+
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#121
+ def visit_back_reference_read_node(node); end
+
+ # begin end
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#127
+ def visit_begin_node(node); end
+
+ # foo(&bar)
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#160
+ def visit_block_argument_node(node); end
+
+ # foo { |; bar| }
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#168
+ def visit_block_local_variable_node(node); end
+
+ # A block on a keyword or method call.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#173
+ def visit_block_node(node); end
+
+ # def foo(&bar); end
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#179
+ def visit_block_parameter_node(node); end
+
+ # A block's parameters.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#184
+ def visit_block_parameters_node(node); end
+
+ # break
+ # ^^^^^
+ #
+ # break foo
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#224
+ def visit_break_node(node); end
+
+ # foo.bar &&= baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#287
+ def visit_call_and_write_node(node); end
+
+ # foo
+ # ^^^
+ #
+ # foo.bar
+ # ^^^^^^^
+ #
+ # foo.bar() {}
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#242
+ def visit_call_node(node); end
+
+ # foo.bar += baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#277
+ def visit_call_operator_write_node(node); end
+
+ # foo.bar ||= baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#297
+ def visit_call_or_write_node(node); end
+
+ # foo.bar, = 1
+ # ^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#320
+ def visit_call_target_node(node); end
+
+ # foo => bar => baz
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#326
+ def visit_capture_pattern_node(node); end
+
+ # case foo; in bar; end
+ # ^^^^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#338
+ def visit_case_match_node(node); end
+
+ # case foo; when bar; end
+ # ^^^^^^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#332
+ def visit_case_node(node); end
+
+ # class Foo; end
+ # ^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#344
+ def visit_class_node(node); end
+
+ # @@foo &&= bar
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#385
+ def visit_class_variable_and_write_node(node); end
+
+ # @@foo += bar
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#379
+ def visit_class_variable_operator_write_node(node); end
+
+ # @@foo ||= bar
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#391
+ def visit_class_variable_or_write_node(node); end
+
+ # @@foo
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#364
+ def visit_class_variable_read_node(node); end
+
+ # @@foo, = bar
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#397
+ def visit_class_variable_target_node(node); end
+
+ # @@foo = 1
+ # ^^^^^^^^^
+ #
+ # @@foo, @@bar = 1
+ # ^^^^^ ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#373
+ def visit_class_variable_write_node(node); end
+
+ # Foo &&= bar
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#430
+ def visit_constant_and_write_node(node); end
+
+ # Foo += bar
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#424
+ def visit_constant_operator_write_node(node); end
+
+ # Foo ||= bar
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#436
+ def visit_constant_or_write_node(node); end
+
+ # Foo::Bar &&= baz
+ # ^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#473
+ def visit_constant_path_and_write_node(node); end
+
+ # Foo::Bar
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#448
+ def visit_constant_path_node(node); end
+
+ # Foo::Bar += baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#467
+ def visit_constant_path_operator_write_node(node); end
+
+ # Foo::Bar ||= baz
+ # ^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#479
+ def visit_constant_path_or_write_node(node); end
+
+ # Foo::Bar, = baz
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#485
+ def visit_constant_path_target_node(node); end
+
+ # Foo::Bar = 1
+ # ^^^^^^^^^^^^
+ #
+ # Foo::Foo, Bar::Bar = 1
+ # ^^^^^^^^ ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#461
+ def visit_constant_path_write_node(node); end
+
+ # Foo
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#409
+ def visit_constant_read_node(node); end
+
+ # Foo, = bar
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#442
+ def visit_constant_target_node(node); end
+
+ # Foo = 1
+ # ^^^^^^^
+ #
+ # Foo, Bar = 1
+ # ^^^ ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#418
+ def visit_constant_write_node(node); end
+
+ # def foo; end
+ # ^^^^^^^^^^^^
+ #
+ # def self.foo; end
+ # ^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#501
+ def visit_def_node(node); end
+
+ # defined? a
+ # ^^^^^^^^^^
+ #
+ # defined?(a)
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#532
+ def visit_defined_node(node); end
+
+ # if foo then bar else baz end
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#538
+ def visit_else_node(node); end
+
+ # "foo #{bar}"
+ # ^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#544
+ def visit_embedded_statements_node(node); end
+
+ # "foo #@bar"
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#552
+ def visit_embedded_variable_node(node); end
+
+ # begin; foo; ensure; bar; end
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#558
+ def visit_ensure_node(node); end
+
+ # false
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#564
+ def visit_false_node(node); end
+
+ # foo => [*, bar, *]
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#570
+ def visit_find_pattern_node(node); end
+
+ # if foo .. bar; end
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#576
+ def visit_flip_flop_node(node); end
+
+ # 1.0
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#586
+ def visit_float_node(node); end
+
+ # for foo in bar do end
+ # ^^^^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#592
+ def visit_for_node(node); end
+
+ # def foo(...); bar(...); end
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#598
+ def visit_forwarding_arguments_node(node); end
+
+ # def foo(...); end
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#604
+ def visit_forwarding_parameter_node(node); end
+
+ # super
+ # ^^^^^
+ #
+ # super {}
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#613
+ def visit_forwarding_super_node(node); end
+
+ # $foo &&= bar
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#640
+ def visit_global_variable_and_write_node(node); end
+
+ # $foo += bar
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#634
+ def visit_global_variable_operator_write_node(node); end
+
+ # $foo ||= bar
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#646
+ def visit_global_variable_or_write_node(node); end
+
+ # $foo
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#619
+ def visit_global_variable_read_node(node); end
+
+ # $foo, = bar
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#652
+ def visit_global_variable_target_node(node); end
+
+ # $foo = 1
+ # ^^^^^^^^
+ #
+ # $foo, $bar = 1
+ # ^^^^ ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#628
+ def visit_global_variable_write_node(node); end
+
+ # {}
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#658
+ def visit_hash_node(node); end
+
+ # foo => {}
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#664
+ def visit_hash_pattern_node(node); end
+
+ # if foo then bar end
+ # ^^^^^^^^^^^^^^^^^^^
+ #
+ # bar if foo
+ # ^^^^^^^^^^
+ #
+ # foo ? bar : baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#685
+ def visit_if_node(node); end
+
+ # 1i
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#690
+ def visit_imaginary_node(node); end
+
+ # { foo: }
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#696
+ def visit_implicit_node(node); end
+
+ # foo { |bar,| }
+ # ^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#701
+ def visit_implicit_rest_node(node); end
+
+ # case foo; in bar; end
+ # ^^^^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#706
+ def visit_in_node(node); end
+
+ # foo[bar] &&= baz
+ # ^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#732
+ def visit_index_and_write_node(node); end
+
+ # foo[bar] += baz
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#719
+ def visit_index_operator_write_node(node); end
+
+ # foo[bar] ||= baz
+ # ^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#745
+ def visit_index_or_write_node(node); end
+
+ # foo[bar], = 1
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#758
+ def visit_index_target_node(node); end
+
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#788
+ def visit_instance_variable_and_write_node(node); end
+
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#782
+ def visit_instance_variable_operator_write_node(node); end
+
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#794
+ def visit_instance_variable_or_write_node(node); end
+
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#767
+ def visit_instance_variable_read_node(node); end
+
+ # @foo, = bar
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#800
+ def visit_instance_variable_target_node(node); end
+
+ # ^^^^^^^^
+ #
+ # @foo, @bar = 1
+ # ^^^^ ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#776
+ def visit_instance_variable_write_node(node); end
+
+ # 1
+ # ^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#806
+ def visit_integer_node(node); end
+
+ # if /foo #{bar}/ then end
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#812
+ def visit_interpolated_match_last_line_node(node); end
+
+ # /foo #{bar}/
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#829
+ def visit_interpolated_regular_expression_node(node); end
+
+ # "foo #{bar}"
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#844
+ def visit_interpolated_string_node(node); end
+
+ # :"foo #{bar}"
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#851
+ def visit_interpolated_symbol_node(node); end
+
+ # `foo #{bar}`
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#858
+ def visit_interpolated_x_string_node(node); end
+
+ # -> { it }
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#923
+ def visit_it_local_variable_read_node(node); end
+
+ # foo(bar: baz)
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#929
+ def visit_keyword_hash_node(node); end
+
+ # def foo(**bar); end
+ # ^^^^^
+ #
+ # def foo(**); end
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#938
+ def visit_keyword_rest_parameter_node(node); end
+
+ # -> {}
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#943
+ def visit_lambda_node(node); end
+
+ # foo &&= bar
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#986
+ def visit_local_variable_and_write_node(node); end
+
+ # foo += bar
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#980
+ def visit_local_variable_operator_write_node(node); end
+
+ # foo ||= bar
+ # ^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#992
+ def visit_local_variable_or_write_node(node); end
+
+ # foo
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#961
+ def visit_local_variable_read_node(node); end
+
+ # foo, = bar
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#998
+ def visit_local_variable_target_node(node); end
+
+ # foo = 1
+ # ^^^^^^^
+ #
+ # foo, bar = 1
+ # ^^^ ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#974
+ def visit_local_variable_write_node(node); end
+
+ # if /foo/ then end
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1004
+ def visit_match_last_line_node(node); end
+
+ # foo in bar
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1010
+ def visit_match_predicate_node(node); end
+
+ # foo => bar
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1016
+ def visit_match_required_node(node); end
+
+ # /(?foo)/ =~ bar
+ # ^^^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1022
+ def visit_match_write_node(node); end
+
+ # A node that is missing from the syntax tree. This is only used in the
+ # case of a syntax error. The parser gem doesn't have such a concept, so
+ # we invent our own here.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1029
+ def visit_missing_node(node); end
+
+ # module Foo; end
+ # ^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1035
+ def visit_module_node(node); end
+
+ # foo, bar = baz
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1055
+ def visit_multi_target_node(node); end
+
+ # foo, bar = baz
+ # ^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1065
+ def visit_multi_write_node(node); end
+
+ # next
+ # ^^^^
+ #
+ # next foo
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1089
+ def visit_next_node(node); end
+
+ # nil
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1102
+ def visit_nil_node(node); end
+
+ # def foo(**nil); end
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1108
+ def visit_no_keywords_parameter_node(node); end
+
+ # -> { _1 + _2 }
+ # ^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1114
+ def visit_numbered_parameters_node(node); end
+
+ # $1
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1120
+ def visit_numbered_reference_read_node(node); end
+
+ # def foo(bar: baz); end
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1126
+ def visit_optional_keyword_parameter_node(node); end
+
+ # def foo(bar = 1); end
+ # ^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1132
+ def visit_optional_parameter_node(node); end
+
+ # a or b
+ # ^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1138
+ def visit_or_node(node); end
+
+ # def foo(bar, *baz); end
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1144
+ def visit_parameters_node(node); end
+
+ # ()
+ # ^^
+ #
+ # (1)
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1182
+ def visit_parentheses_node(node); end
+
+ # foo => ^(bar)
+ # ^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1192
+ def visit_pinned_expression_node(node); end
+
+ # foo = 1 and bar => ^foo
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1198
+ def visit_pinned_variable_node(node); end
+
+ # END {}
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1207
+ def visit_post_execution_node(node); end
+
+ # BEGIN {}
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1212
+ def visit_pre_execution_node(node); end
+
+ # The top-level program node.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1217
+ def visit_program_node(node); end
+
+ # 0..5
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1223
+ def visit_range_node(node); end
+
+ # 1r
+ # ^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1245
+ def visit_rational_node(node); end
+
+ # redo
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1251
+ def visit_redo_node(node); end
+
+ # /foo/
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1257
+ def visit_regular_expression_node(node); end
+
+ # def foo(bar:); end
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1263
+ def visit_required_keyword_parameter_node(node); end
+
+ # def foo(bar); end
+ # ^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1269
+ def visit_required_parameter_node(node); end
+
+ # foo rescue bar
+ # ^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1275
+ def visit_rescue_modifier_node(node); end
+
+ # begin; rescue; end
+ # ^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1281
+ def visit_rescue_node(node); end
+
+ # def foo(*bar); end
+ # ^^^^
+ #
+ # def foo(*); end
+ # ^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1301
+ def visit_rest_parameter_node(node); end
+
+ # retry
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1307
+ def visit_retry_node(node); end
+
+ # return
+ # ^^^^^^
+ #
+ # return 1
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1316
+ def visit_return_node(node); end
+
+ # self
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1329
+ def visit_self_node(node); end
+
+ # A shareable constant.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1334
+ def visit_shareable_constant_node(node); end
+
+ # class << self; end
+ # ^^^^^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1340
+ def visit_singleton_class_node(node); end
+
+ # __ENCODING__
+ # ^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1348
+ def visit_source_encoding_node(node); end
+
+ # __FILE__
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1355
+ def visit_source_file_node(node); end
+
+ # __LINE__
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1361
+ def visit_source_line_node(node); end
+
+ # foo(*bar)
+ # ^^^^
+ #
+ # def foo((bar, *baz)); end
+ # ^^^^
+ #
+ # def foo(*); bar(*); end
+ # ^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1373
+ def visit_splat_node(node); end
+
+ # A list of statements.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1382
+ def visit_statements_node(node); end
+
+ # "foo"
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1394
+ def visit_string_node(node); end
+
+ # super(foo)
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1400
+ def visit_super_node(node); end
+
+ # :foo
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1414
+ def visit_symbol_node(node); end
+
+ # true
+ # ^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1420
+ def visit_true_node(node); end
+
+ # undef foo
+ # ^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1426
+ def visit_undef_node(node); end
+
+ # unless foo; bar end
+ # ^^^^^^^^^^^^^^^^^^^
+ #
+ # bar unless foo
+ # ^^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1436
+ def visit_unless_node(node); end
+
+ # until foo; bar end
+ # ^^^^^^^^^^^^^^^^^
+ #
+ # bar until foo
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1445
+ def visit_until_node(node); end
+
+ # case foo; when bar; end
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1451
+ def visit_when_node(node); end
+
+ # while foo; bar end
+ # ^^^^^^^^^^^^^^^^^^
+ #
+ # bar while foo
+ # ^^^^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1460
+ def visit_while_node(node); end
+
+ # `foo`
+ # ^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1466
+ def visit_x_string_node(node); end
+
+ # yield
+ # ^^^^^
+ #
+ # yield 1
+ # ^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1482
+ def visit_yield_node(node); end
+
+ private
+
+ # If a class variable is written within a method definition, it has a
+ # different type than everywhere else.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#403
+ def class_variable_write_type; end
+
+ # Create a new compiler with the given options.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1489
+ def copy_compiler(in_def: T.unsafe(nil), in_pattern: T.unsafe(nil)); end
+
+ # Call nodes with operators following them will either be op_asgn or
+ # op_asgn2 nodes. That is determined by their call operator and their
+ # right-hand side.
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#308
+ def op_asgn?(node); end
+
+ # Call nodes with operators following them can use &. as an operator,
+ # which changes their type by prefixing "safe_".
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#314
+ def op_asgn_type(node, type); end
+
+ # Create a new Sexp object from the given prism node and arguments.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1494
+ def s(node, *arguments); end
+
+ # Visit a block node, which will modify the AST by wrapping the given
+ # visited node in an iter node.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1504
+ def visit_block(node, sexp, block); end
+
+ # def foo((bar, baz)); end
+ # ^^^^^^^^^^
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1159
+ def visit_destructured_parameter(node); end
+
+ # Visit the interpolated content of the string-like node.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#865
+ def visit_interpolated_parts(parts); end
+
+ # Pattern constants get wrapped in another layer of :const.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1525
+ def visit_pattern_constant(node); end
+
+ # If the bounds of a range node are empty parentheses, then they do not
+ # get replaced by their usual s(:nil), but instead are s(:begin).
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1235
+ def visit_range_bounds_node(node); end
+
+ # Visit the value of a write, which will be on the right-hand side of
+ # a write operator. Because implicit arrays can have splats, those could
+ # potentially be wrapped in an svalue node.
+ #
+ # source://prism//lib/prism/translation/ruby_parser.rb#1539
+ def visit_write_value(node); end
+end
+
+# Represents the use of the literal `true` keyword.
+#
+# true
+# ^^^^
+#
+# source://prism//lib/prism/node.rb#18041
+class Prism::TrueNode < ::Prism::Node
+ # def initialize: (Location location) -> void
+ #
+ # @return [TrueNode] a new instance of TrueNode
+ #
+ # source://prism//lib/prism/node.rb#18043
+ sig { params(source: Prism::Source, location: Prism::Location).void }
+ def initialize(source, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#18116
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#18049
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18054
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#18064
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#18059
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?location: Location) -> TrueNode
+ #
+ # source://prism//lib/prism/node.rb#18069
+ sig { params(location: Prism::Location).returns(Prism::TrueNode) }
+ def copy(location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18054
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { location: Location }
+ #
+ # source://prism//lib/prism/node.rb#18077
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#18082
+ sig { override.returns(String) }
+ def inspect; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18100
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18110
+ def type; end
+ end
+end
+
+# Represents the use of the `undef` keyword.
+#
+# undef :foo, :bar, :baz
+# ^^^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#18125
+class Prism::UndefNode < ::Prism::Node
+ # def initialize: (Array[SymbolNode | InterpolatedSymbolNode] names, Location keyword_loc, Location location) -> void
+ #
+ # @return [UndefNode] a new instance of UndefNode
+ #
+ # source://prism//lib/prism/node.rb#18127
+ sig do
+ params(
+ source: Prism::Source,
+ names: T::Array[T.any(Prism::SymbolNode, Prism::InterpolatedSymbolNode)],
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, names, keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#18217
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#18135
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18140
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#18150
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#18145
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?names: Array[SymbolNode | InterpolatedSymbolNode], ?keyword_loc: Location, ?location: Location) -> UndefNode
+ #
+ # source://prism//lib/prism/node.rb#18155
+ sig do
+ params(
+ names: T::Array[T.any(Prism::SymbolNode, Prism::InterpolatedSymbolNode)],
+ keyword_loc: Prism::Location,
+ location: Prism::Location
+ ).returns(Prism::UndefNode)
+ end
+ def copy(names: T.unsafe(nil), keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18140
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { names: Array[SymbolNode | InterpolatedSymbolNode], keyword_loc: Location, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#18163
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#18183
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#18178
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#18171
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # attr_reader names: Array[SymbolNode | InterpolatedSymbolNode]
+ #
+ # source://prism//lib/prism/node.rb#18168
+ sig { returns(T::Array[T.any(Prism::SymbolNode, Prism::InterpolatedSymbolNode)]) }
+ def names; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18201
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18211
+ def type; end
+ end
+end
+
+# Represents the use of the `unless` keyword, either in the block form or the modifier form.
+#
+# bar unless foo
+# ^^^^^^^^^^^^^^
+#
+# unless foo then bar end
+# ^^^^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#18232
+class Prism::UnlessNode < ::Prism::Node
+ # def initialize: (Location keyword_loc, Prism::node predicate, Location? then_keyword_loc, StatementsNode? statements, ElseNode? consequent, Location? end_keyword_loc, Location location) -> void
+ #
+ # @return [UnlessNode] a new instance of UnlessNode
+ #
+ # source://prism//lib/prism/node.rb#18234
+ sig do
+ params(
+ source: Prism::Source,
+ keyword_loc: Prism::Location,
+ predicate: Prism::Node,
+ then_keyword_loc: T.nilable(Prism::Location),
+ statements: T.nilable(Prism::StatementsNode),
+ consequent: T.nilable(Prism::ElseNode),
+ end_keyword_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, keyword_loc, predicate, then_keyword_loc, statements, consequent, end_keyword_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#18399
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#18246
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18251
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#18265
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#18256
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # The else clause of the unless expression, if present.
+ #
+ # unless cond then bar else baz end
+ # ^^^^^^^^
+ #
+ # source://prism//lib/prism/node.rb#18331
+ sig { returns(T.nilable(Prism::ElseNode)) }
+ def consequent; end
+
+ # def copy: (?keyword_loc: Location, ?predicate: Prism::node, ?then_keyword_loc: Location?, ?statements: StatementsNode?, ?consequent: ElseNode?, ?end_keyword_loc: Location?, ?location: Location) -> UnlessNode
+ #
+ # source://prism//lib/prism/node.rb#18270
+ sig do
+ params(
+ keyword_loc: Prism::Location,
+ predicate: Prism::Node,
+ then_keyword_loc: T.nilable(Prism::Location),
+ statements: T.nilable(Prism::StatementsNode),
+ consequent: T.nilable(Prism::ElseNode),
+ end_keyword_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::UnlessNode)
+ end
+ def copy(keyword_loc: T.unsafe(nil), predicate: T.unsafe(nil), then_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), consequent: T.unsafe(nil), end_keyword_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18251
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { keyword_loc: Location, predicate: Prism::node, then_keyword_loc: Location?, statements: StatementsNode?, consequent: ElseNode?, end_keyword_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#18278
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ # def end_keyword: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#18360
+ sig { returns(T.nilable(String)) }
+ def end_keyword; end
+
+ # The location of the `end` keyword, if present.
+ #
+ # unless cond then bar end
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#18337
+ sig { returns(T.nilable(Prism::Location)) }
+ def end_keyword_loc; end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#18365
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#18350
+ sig { returns(String) }
+ def keyword; end
+
+ # The location of the `unless` keyword.
+ #
+ # unless cond then bar end
+ # ^^^^^^
+ #
+ # bar unless cond
+ # ^^^^^^
+ #
+ # source://prism//lib/prism/node.rb#18289
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#97
+ def newline!(lines); end
+
+ # The condition to be evaluated for the unless expression. It can be any [non-void expression](https://github.com/ruby/prism/blob/main/docs/parsing_rules.md#non-void-expression).
+ #
+ # unless cond then bar end
+ # ^^^^
+ #
+ # bar unless cond
+ # ^^^^
+ #
+ # source://prism//lib/prism/node.rb#18302
+ sig { returns(Prism::Node) }
+ def predicate; end
+
+ # The body of statements that will executed if the unless condition is
+ # falsey. Will be `nil` if no body is provided.
+ #
+ # unless cond then bar end
+ # ^^^
+ #
+ # source://prism//lib/prism/node.rb#18325
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # def then_keyword: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#18355
+ sig { returns(T.nilable(String)) }
+ def then_keyword; end
+
+ # The location of the `then` keyword, if present.
+ #
+ # unless cond then bar end
+ # ^^^^
+ #
+ # source://prism//lib/prism/node.rb#18308
+ sig { returns(T.nilable(Prism::Location)) }
+ def then_keyword_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18383
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18393
+ def type; end
+ end
+end
+
+# Represents the use of the `until` keyword, either in the block form or the modifier form.
+#
+# bar until foo
+# ^^^^^^^^^^^^^
+#
+# until foo do bar end
+# ^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#18417
+class Prism::UntilNode < ::Prism::Node
+ # def initialize: (Integer flags, Location keyword_loc, Location? closing_loc, Prism::node predicate, StatementsNode? statements, Location location) -> void
+ #
+ # @return [UntilNode] a new instance of UntilNode
+ #
+ # source://prism//lib/prism/node.rb#18419
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ keyword_loc: Prism::Location,
+ closing_loc: T.nilable(Prism::Location),
+ predicate: Prism::Node,
+ statements: T.nilable(Prism::StatementsNode),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, keyword_loc, closing_loc, predicate, statements, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#18545
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#18430
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def begin_modifier?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#18496
+ sig { returns(T::Boolean) }
+ def begin_modifier?; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18435
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#18506
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # attr_reader closing_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#18477
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#18448
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#18440
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?keyword_loc: Location, ?closing_loc: Location?, ?predicate: Prism::node, ?statements: StatementsNode?, ?location: Location) -> UntilNode
+ #
+ # source://prism//lib/prism/node.rb#18453
+ sig do
+ params(
+ flags: Integer,
+ keyword_loc: Prism::Location,
+ closing_loc: T.nilable(Prism::Location),
+ predicate: Prism::Node,
+ statements: T.nilable(Prism::StatementsNode),
+ location: Prism::Location
+ ).returns(Prism::UntilNode)
+ end
+ def copy(flags: T.unsafe(nil), keyword_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), predicate: T.unsafe(nil), statements: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18435
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, keyword_loc: Location, closing_loc: Location?, predicate: Prism::node, statements: StatementsNode?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#18461
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#18511
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#18501
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#18470
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#103
+ def newline!(lines); end
+
+ # attr_reader predicate: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#18490
+ sig { returns(Prism::Node) }
+ def predicate; end
+
+ # attr_reader statements: StatementsNode?
+ #
+ # source://prism//lib/prism/node.rb#18493
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18529
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#18466
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18539
+ def type; end
+ end
+end
+
+# The version constant is set by reading the result of calling pm_version.
+Prism::VERSION = T.let(T.unsafe(nil), String)
+
+# A visitor is a class that provides a default implementation for every accept
+# method defined on the nodes. This means it can walk a tree without the
+# caller needing to define any special handling. This allows you to handle a
+# subset of the tree, while still walking the whole tree.
+#
+# For example, to find all of the method calls that call the `foo` method, you
+# could write:
+#
+# class FooCalls < Prism::Visitor
+# def visit_call_node(node)
+# if node.name == "foo"
+# # Do something with the node
+# end
+#
+# # Call super so that the visitor continues walking the tree
+# super
+# end
+# end
+#
+# source://prism//lib/prism/visitor.rb#54
+class Prism::Visitor < ::Prism::BasicVisitor
+ # Visit a AliasGlobalVariableNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::AliasGlobalVariableNode).void }
+ def visit_alias_global_variable_node(node); end
+
+ # Visit a AliasMethodNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::AliasMethodNode).void }
+ def visit_alias_method_node(node); end
+
+ # Visit a AlternationPatternNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::AlternationPatternNode).void }
+ def visit_alternation_pattern_node(node); end
+
+ # Visit a AndNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::AndNode).void }
+ def visit_and_node(node); end
+
+ # Visit a ArgumentsNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ArgumentsNode).void }
+ def visit_arguments_node(node); end
+
+ # Visit a ArrayNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ArrayNode).void }
+ def visit_array_node(node); end
+
+ # Visit a ArrayPatternNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ArrayPatternNode).void }
+ def visit_array_pattern_node(node); end
+
+ # Visit a AssocNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::AssocNode).void }
+ def visit_assoc_node(node); end
+
+ # Visit a AssocSplatNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::AssocSplatNode).void }
+ def visit_assoc_splat_node(node); end
+
+ # Visit a BackReferenceReadNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::BackReferenceReadNode).void }
+ def visit_back_reference_read_node(node); end
+
+ # Visit a BeginNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::BeginNode).void }
+ def visit_begin_node(node); end
+
+ # Visit a BlockArgumentNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::BlockArgumentNode).void }
+ def visit_block_argument_node(node); end
+
+ # Visit a BlockLocalVariableNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::BlockLocalVariableNode).void }
+ def visit_block_local_variable_node(node); end
+
+ # Visit a BlockNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::BlockNode).void }
+ def visit_block_node(node); end
+
+ # Visit a BlockParameterNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::BlockParameterNode).void }
+ def visit_block_parameter_node(node); end
+
+ # Visit a BlockParametersNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::BlockParametersNode).void }
+ def visit_block_parameters_node(node); end
+
+ # Visit a BreakNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::BreakNode).void }
+ def visit_break_node(node); end
+
+ # Visit a CallAndWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::CallAndWriteNode).void }
+ def visit_call_and_write_node(node); end
+
+ # Visit a CallNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::CallNode).void }
+ def visit_call_node(node); end
+
+ # Visit a CallOperatorWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::CallOperatorWriteNode).void }
+ def visit_call_operator_write_node(node); end
+
+ # Visit a CallOrWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::CallOrWriteNode).void }
+ def visit_call_or_write_node(node); end
+
+ # Visit a CallTargetNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::CallTargetNode).void }
+ def visit_call_target_node(node); end
+
+ # Visit a CapturePatternNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::CapturePatternNode).void }
+ def visit_capture_pattern_node(node); end
+
+ # Visit a CaseMatchNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::CaseMatchNode).void }
+ def visit_case_match_node(node); end
+
+ # Visit a CaseNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::CaseNode).void }
+ def visit_case_node(node); end
+
+ # Visit a ClassNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ClassNode).void }
+ def visit_class_node(node); end
+
+ # Visit a ClassVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ClassVariableAndWriteNode).void }
+ def visit_class_variable_and_write_node(node); end
+
+ # Visit a ClassVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ClassVariableOperatorWriteNode).void }
+ def visit_class_variable_operator_write_node(node); end
+
+ # Visit a ClassVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ClassVariableOrWriteNode).void }
+ def visit_class_variable_or_write_node(node); end
+
+ # Visit a ClassVariableReadNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ClassVariableReadNode).void }
+ def visit_class_variable_read_node(node); end
+
+ # Visit a ClassVariableTargetNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ClassVariableTargetNode).void }
+ def visit_class_variable_target_node(node); end
+
+ # Visit a ClassVariableWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ClassVariableWriteNode).void }
+ def visit_class_variable_write_node(node); end
+
+ # Visit a ConstantAndWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantAndWriteNode).void }
+ def visit_constant_and_write_node(node); end
+
+ # Visit a ConstantOperatorWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantOperatorWriteNode).void }
+ def visit_constant_operator_write_node(node); end
+
+ # Visit a ConstantOrWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantOrWriteNode).void }
+ def visit_constant_or_write_node(node); end
+
+ # Visit a ConstantPathAndWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantPathAndWriteNode).void }
+ def visit_constant_path_and_write_node(node); end
+
+ # Visit a ConstantPathNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantPathNode).void }
+ def visit_constant_path_node(node); end
+
+ # Visit a ConstantPathOperatorWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantPathOperatorWriteNode).void }
+ def visit_constant_path_operator_write_node(node); end
+
+ # Visit a ConstantPathOrWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantPathOrWriteNode).void }
+ def visit_constant_path_or_write_node(node); end
+
+ # Visit a ConstantPathTargetNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantPathTargetNode).void }
+ def visit_constant_path_target_node(node); end
+
+ # Visit a ConstantPathWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantPathWriteNode).void }
+ def visit_constant_path_write_node(node); end
+
+ # Visit a ConstantReadNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantReadNode).void }
+ def visit_constant_read_node(node); end
+
+ # Visit a ConstantTargetNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantTargetNode).void }
+ def visit_constant_target_node(node); end
+
+ # Visit a ConstantWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ConstantWriteNode).void }
+ def visit_constant_write_node(node); end
+
+ # Visit a DefNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::DefNode).void }
+ def visit_def_node(node); end
+
+ # Visit a DefinedNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::DefinedNode).void }
+ def visit_defined_node(node); end
+
+ # Visit a ElseNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ElseNode).void }
+ def visit_else_node(node); end
+
+ # Visit a EmbeddedStatementsNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::EmbeddedStatementsNode).void }
+ def visit_embedded_statements_node(node); end
+
+ # Visit a EmbeddedVariableNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::EmbeddedVariableNode).void }
+ def visit_embedded_variable_node(node); end
+
+ # Visit a EnsureNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::EnsureNode).void }
+ def visit_ensure_node(node); end
+
+ # Visit a FalseNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::FalseNode).void }
+ def visit_false_node(node); end
+
+ # Visit a FindPatternNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::FindPatternNode).void }
+ def visit_find_pattern_node(node); end
+
+ # Visit a FlipFlopNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::FlipFlopNode).void }
+ def visit_flip_flop_node(node); end
+
+ # Visit a FloatNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::FloatNode).void }
+ def visit_float_node(node); end
+
+ # Visit a ForNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ForNode).void }
+ def visit_for_node(node); end
+
+ # Visit a ForwardingArgumentsNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ForwardingArgumentsNode).void }
+ def visit_forwarding_arguments_node(node); end
+
+ # Visit a ForwardingParameterNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ForwardingParameterNode).void }
+ def visit_forwarding_parameter_node(node); end
+
+ # Visit a ForwardingSuperNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ForwardingSuperNode).void }
+ def visit_forwarding_super_node(node); end
+
+ # Visit a GlobalVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::GlobalVariableAndWriteNode).void }
+ def visit_global_variable_and_write_node(node); end
+
+ # Visit a GlobalVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::GlobalVariableOperatorWriteNode).void }
+ def visit_global_variable_operator_write_node(node); end
+
+ # Visit a GlobalVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::GlobalVariableOrWriteNode).void }
+ def visit_global_variable_or_write_node(node); end
+
+ # Visit a GlobalVariableReadNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::GlobalVariableReadNode).void }
+ def visit_global_variable_read_node(node); end
+
+ # Visit a GlobalVariableTargetNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::GlobalVariableTargetNode).void }
+ def visit_global_variable_target_node(node); end
+
+ # Visit a GlobalVariableWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::GlobalVariableWriteNode).void }
+ def visit_global_variable_write_node(node); end
+
+ # Visit a HashNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::HashNode).void }
+ def visit_hash_node(node); end
+
+ # Visit a HashPatternNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::HashPatternNode).void }
+ def visit_hash_pattern_node(node); end
+
+ # Visit a IfNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::IfNode).void }
+ def visit_if_node(node); end
+
+ # Visit a ImaginaryNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ImaginaryNode).void }
+ def visit_imaginary_node(node); end
+
+ # Visit a ImplicitNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ImplicitNode).void }
+ def visit_implicit_node(node); end
+
+ # Visit a ImplicitRestNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ImplicitRestNode).void }
+ def visit_implicit_rest_node(node); end
+
+ # Visit a InNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InNode).void }
+ def visit_in_node(node); end
+
+ # Visit a IndexAndWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::IndexAndWriteNode).void }
+ def visit_index_and_write_node(node); end
+
+ # Visit a IndexOperatorWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::IndexOperatorWriteNode).void }
+ def visit_index_operator_write_node(node); end
+
+ # Visit a IndexOrWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::IndexOrWriteNode).void }
+ def visit_index_or_write_node(node); end
+
+ # Visit a IndexTargetNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::IndexTargetNode).void }
+ def visit_index_target_node(node); end
+
+ # Visit a InstanceVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InstanceVariableAndWriteNode).void }
+ def visit_instance_variable_and_write_node(node); end
+
+ # Visit a InstanceVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InstanceVariableOperatorWriteNode).void }
+ def visit_instance_variable_operator_write_node(node); end
+
+ # Visit a InstanceVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InstanceVariableOrWriteNode).void }
+ def visit_instance_variable_or_write_node(node); end
+
+ # Visit a InstanceVariableReadNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InstanceVariableReadNode).void }
+ def visit_instance_variable_read_node(node); end
+
+ # Visit a InstanceVariableTargetNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InstanceVariableTargetNode).void }
+ def visit_instance_variable_target_node(node); end
+
+ # Visit a InstanceVariableWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InstanceVariableWriteNode).void }
+ def visit_instance_variable_write_node(node); end
+
+ # Visit a IntegerNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::IntegerNode).void }
+ def visit_integer_node(node); end
+
+ # Visit a InterpolatedMatchLastLineNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InterpolatedMatchLastLineNode).void }
+ def visit_interpolated_match_last_line_node(node); end
+
+ # Visit a InterpolatedRegularExpressionNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InterpolatedRegularExpressionNode).void }
+ def visit_interpolated_regular_expression_node(node); end
+
+ # Visit a InterpolatedStringNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InterpolatedStringNode).void }
+ def visit_interpolated_string_node(node); end
+
+ # Visit a InterpolatedSymbolNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InterpolatedSymbolNode).void }
+ def visit_interpolated_symbol_node(node); end
+
+ # Visit a InterpolatedXStringNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::InterpolatedXStringNode).void }
+ def visit_interpolated_x_string_node(node); end
+
+ # Visit a ItLocalVariableReadNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ItLocalVariableReadNode).void }
+ def visit_it_local_variable_read_node(node); end
+
+ # Visit a ItParametersNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ItParametersNode).void }
+ def visit_it_parameters_node(node); end
+
+ # Visit a KeywordHashNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::KeywordHashNode).void }
+ def visit_keyword_hash_node(node); end
+
+ # Visit a KeywordRestParameterNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::KeywordRestParameterNode).void }
+ def visit_keyword_rest_parameter_node(node); end
+
+ # Visit a LambdaNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::LambdaNode).void }
+ def visit_lambda_node(node); end
+
+ # Visit a LocalVariableAndWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::LocalVariableAndWriteNode).void }
+ def visit_local_variable_and_write_node(node); end
+
+ # Visit a LocalVariableOperatorWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::LocalVariableOperatorWriteNode).void }
+ def visit_local_variable_operator_write_node(node); end
+
+ # Visit a LocalVariableOrWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::LocalVariableOrWriteNode).void }
+ def visit_local_variable_or_write_node(node); end
+
+ # Visit a LocalVariableReadNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::LocalVariableReadNode).void }
+ def visit_local_variable_read_node(node); end
+
+ # Visit a LocalVariableTargetNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::LocalVariableTargetNode).void }
+ def visit_local_variable_target_node(node); end
+
+ # Visit a LocalVariableWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::LocalVariableWriteNode).void }
+ def visit_local_variable_write_node(node); end
+
+ # Visit a MatchLastLineNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::MatchLastLineNode).void }
+ def visit_match_last_line_node(node); end
+
+ # Visit a MatchPredicateNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::MatchPredicateNode).void }
+ def visit_match_predicate_node(node); end
+
+ # Visit a MatchRequiredNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::MatchRequiredNode).void }
+ def visit_match_required_node(node); end
+
+ # Visit a MatchWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::MatchWriteNode).void }
+ def visit_match_write_node(node); end
+
+ # Visit a MissingNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::MissingNode).void }
+ def visit_missing_node(node); end
+
+ # Visit a ModuleNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ModuleNode).void }
+ def visit_module_node(node); end
+
+ # Visit a MultiTargetNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::MultiTargetNode).void }
+ def visit_multi_target_node(node); end
+
+ # Visit a MultiWriteNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::MultiWriteNode).void }
+ def visit_multi_write_node(node); end
+
+ # Visit a NextNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::NextNode).void }
+ def visit_next_node(node); end
+
+ # Visit a NilNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::NilNode).void }
+ def visit_nil_node(node); end
+
+ # Visit a NoKeywordsParameterNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::NoKeywordsParameterNode).void }
+ def visit_no_keywords_parameter_node(node); end
+
+ # Visit a NumberedParametersNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::NumberedParametersNode).void }
+ def visit_numbered_parameters_node(node); end
+
+ # Visit a NumberedReferenceReadNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::NumberedReferenceReadNode).void }
+ def visit_numbered_reference_read_node(node); end
+
+ # Visit a OptionalKeywordParameterNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::OptionalKeywordParameterNode).void }
+ def visit_optional_keyword_parameter_node(node); end
+
+ # Visit a OptionalParameterNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::OptionalParameterNode).void }
+ def visit_optional_parameter_node(node); end
+
+ # Visit a OrNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::OrNode).void }
+ def visit_or_node(node); end
+
+ # Visit a ParametersNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ParametersNode).void }
+ def visit_parameters_node(node); end
+
+ # Visit a ParenthesesNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ParenthesesNode).void }
+ def visit_parentheses_node(node); end
+
+ # Visit a PinnedExpressionNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::PinnedExpressionNode).void }
+ def visit_pinned_expression_node(node); end
+
+ # Visit a PinnedVariableNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::PinnedVariableNode).void }
+ def visit_pinned_variable_node(node); end
+
+ # Visit a PostExecutionNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::PostExecutionNode).void }
+ def visit_post_execution_node(node); end
+
+ # Visit a PreExecutionNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::PreExecutionNode).void }
+ def visit_pre_execution_node(node); end
+
+ # Visit a ProgramNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ProgramNode).void }
+ def visit_program_node(node); end
+
+ # Visit a RangeNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::RangeNode).void }
+ def visit_range_node(node); end
+
+ # Visit a RationalNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::RationalNode).void }
+ def visit_rational_node(node); end
+
+ # Visit a RedoNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::RedoNode).void }
+ def visit_redo_node(node); end
+
+ # Visit a RegularExpressionNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::RegularExpressionNode).void }
+ def visit_regular_expression_node(node); end
+
+ # Visit a RequiredKeywordParameterNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::RequiredKeywordParameterNode).void }
+ def visit_required_keyword_parameter_node(node); end
+
+ # Visit a RequiredParameterNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::RequiredParameterNode).void }
+ def visit_required_parameter_node(node); end
+
+ # Visit a RescueModifierNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::RescueModifierNode).void }
+ def visit_rescue_modifier_node(node); end
+
+ # Visit a RescueNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::RescueNode).void }
+ def visit_rescue_node(node); end
+
+ # Visit a RestParameterNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::RestParameterNode).void }
+ def visit_rest_parameter_node(node); end
+
+ # Visit a RetryNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::RetryNode).void }
+ def visit_retry_node(node); end
+
+ # Visit a ReturnNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ReturnNode).void }
+ def visit_return_node(node); end
+
+ # Visit a SelfNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::SelfNode).void }
+ def visit_self_node(node); end
+
+ # Visit a ShareableConstantNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::ShareableConstantNode).void }
+ def visit_shareable_constant_node(node); end
+
+ # Visit a SingletonClassNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::SingletonClassNode).void }
+ def visit_singleton_class_node(node); end
+
+ # Visit a SourceEncodingNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::SourceEncodingNode).void }
+ def visit_source_encoding_node(node); end
+
+ # Visit a SourceFileNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::SourceFileNode).void }
+ def visit_source_file_node(node); end
+
+ # Visit a SourceLineNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::SourceLineNode).void }
+ def visit_source_line_node(node); end
+
+ # Visit a SplatNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::SplatNode).void }
+ def visit_splat_node(node); end
+
+ # Visit a StatementsNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::StatementsNode).void }
+ def visit_statements_node(node); end
+
+ # Visit a StringNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::StringNode).void }
+ def visit_string_node(node); end
+
+ # Visit a SuperNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::SuperNode).void }
+ def visit_super_node(node); end
+
+ # Visit a SymbolNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::SymbolNode).void }
+ def visit_symbol_node(node); end
+
+ # Visit a TrueNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::TrueNode).void }
+ def visit_true_node(node); end
+
+ # Visit a UndefNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::UndefNode).void }
+ def visit_undef_node(node); end
+
+ # Visit a UnlessNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::UnlessNode).void }
+ def visit_unless_node(node); end
+
+ # Visit a UntilNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::UntilNode).void }
+ def visit_until_node(node); end
+
+ # Visit a WhenNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::WhenNode).void }
+ def visit_when_node(node); end
+
+ # Visit a WhileNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::WhileNode).void }
+ def visit_while_node(node); end
+
+ # Visit a XStringNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::XStringNode).void }
+ def visit_x_string_node(node); end
+
+ # Visit a YieldNode node
+ #
+ # source://prism//lib/prism/visitor.rb#29
+ sig { params(node: Prism::YieldNode).void }
+ def visit_yield_node(node); end
+end
+
+# Represents the use of the `when` keyword within a case statement.
+#
+# case true
+# when true
+# ^^^^^^^^^
+# end
+#
+# source://prism//lib/prism/node.rb#18561
+class Prism::WhenNode < ::Prism::Node
+ # def initialize: (Location keyword_loc, Array[Prism::node] conditions, Location? then_keyword_loc, StatementsNode? statements, Location location) -> void
+ #
+ # @return [WhenNode] a new instance of WhenNode
+ #
+ # source://prism//lib/prism/node.rb#18563
+ sig do
+ params(
+ source: Prism::Source,
+ keyword_loc: Prism::Location,
+ conditions: T::Array[Prism::Node],
+ then_keyword_loc: T.nilable(Prism::Location),
+ statements: T.nilable(Prism::StatementsNode),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, keyword_loc, conditions, then_keyword_loc, statements, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#18679
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#18573
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18578
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#18591
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#18583
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # attr_reader conditions: Array[Prism::node]
+ #
+ # source://prism//lib/prism/node.rb#18616
+ sig { returns(T::Array[Prism::Node]) }
+ def conditions; end
+
+ # def copy: (?keyword_loc: Location, ?conditions: Array[Prism::node], ?then_keyword_loc: Location?, ?statements: StatementsNode?, ?location: Location) -> WhenNode
+ #
+ # source://prism//lib/prism/node.rb#18596
+ sig do
+ params(
+ keyword_loc: Prism::Location,
+ conditions: T::Array[Prism::Node],
+ then_keyword_loc: T.nilable(Prism::Location),
+ statements: T.nilable(Prism::StatementsNode),
+ location: Prism::Location
+ ).returns(Prism::WhenNode)
+ end
+ def copy(keyword_loc: T.unsafe(nil), conditions: T.unsafe(nil), then_keyword_loc: T.unsafe(nil), statements: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18578
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { keyword_loc: Location, conditions: Array[Prism::node], then_keyword_loc: Location?, statements: StatementsNode?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#18604
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#18645
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#18635
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#18609
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # attr_reader statements: StatementsNode?
+ #
+ # source://prism//lib/prism/node.rb#18632
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # def then_keyword: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#18640
+ sig { returns(T.nilable(String)) }
+ def then_keyword; end
+
+ # attr_reader then_keyword_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#18619
+ sig { returns(T.nilable(Prism::Location)) }
+ def then_keyword_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18663
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18673
+ def type; end
+ end
+end
+
+# Represents the use of the `while` keyword, either in the block form or the modifier form.
+#
+# bar while foo
+# ^^^^^^^^^^^^^
+#
+# while foo do bar end
+# ^^^^^^^^^^^^^^^^^^^^
+#
+# source://prism//lib/prism/node.rb#18696
+class Prism::WhileNode < ::Prism::Node
+ # def initialize: (Integer flags, Location keyword_loc, Location? closing_loc, Prism::node predicate, StatementsNode? statements, Location location) -> void
+ #
+ # @return [WhileNode] a new instance of WhileNode
+ #
+ # source://prism//lib/prism/node.rb#18698
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ keyword_loc: Prism::Location,
+ closing_loc: T.nilable(Prism::Location),
+ predicate: Prism::Node,
+ statements: T.nilable(Prism::StatementsNode),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, keyword_loc, closing_loc, predicate, statements, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#18824
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#18709
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def begin_modifier?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#18775
+ sig { returns(T::Boolean) }
+ def begin_modifier?; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18714
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#18785
+ sig { returns(T.nilable(String)) }
+ def closing; end
+
+ # attr_reader closing_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#18756
+ sig { returns(T.nilable(Prism::Location)) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#18727
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#18719
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?flags: Integer, ?keyword_loc: Location, ?closing_loc: Location?, ?predicate: Prism::node, ?statements: StatementsNode?, ?location: Location) -> WhileNode
+ #
+ # source://prism//lib/prism/node.rb#18732
+ sig do
+ params(
+ flags: Integer,
+ keyword_loc: Prism::Location,
+ closing_loc: T.nilable(Prism::Location),
+ predicate: Prism::Node,
+ statements: T.nilable(Prism::StatementsNode),
+ location: Prism::Location
+ ).returns(Prism::WhileNode)
+ end
+ def copy(flags: T.unsafe(nil), keyword_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), predicate: T.unsafe(nil), statements: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18714
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, keyword_loc: Location, closing_loc: Location?, predicate: Prism::node, statements: StatementsNode?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#18740
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#18790
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#18780
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#18749
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # source://prism//lib/prism/parse_result/newlines.rb#109
+ def newline!(lines); end
+
+ # attr_reader predicate: Prism::node
+ #
+ # source://prism//lib/prism/node.rb#18769
+ sig { returns(Prism::Node) }
+ def predicate; end
+
+ # attr_reader statements: StatementsNode?
+ #
+ # source://prism//lib/prism/node.rb#18772
+ sig { returns(T.nilable(Prism::StatementsNode)) }
+ def statements; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18808
+ sig { override.returns(Symbol) }
+ def type; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#18745
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18818
+ def type; end
+ end
+end
+
+# Represents an xstring literal with no interpolation.
+#
+# `foo`
+# ^^^^^
+#
+# source://prism//lib/prism/node.rb#18838
+class Prism::XStringNode < ::Prism::Node
+ include ::Prism::HeredocQuery
+
+ # def initialize: (Integer flags, Location opening_loc, Location content_loc, Location closing_loc, String unescaped, Location location) -> void
+ #
+ # @return [XStringNode] a new instance of XStringNode
+ #
+ # source://prism//lib/prism/node.rb#18840
+ sig do
+ params(
+ source: Prism::Source,
+ flags: Integer,
+ opening_loc: Prism::Location,
+ content_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ unescaped: String,
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, flags, opening_loc, content_loc, closing_loc, unescaped, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#18971
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#18851
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18856
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def closing: () -> String
+ #
+ # source://prism//lib/prism/node.rb#18932
+ sig { returns(String) }
+ def closing; end
+
+ # attr_reader closing_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#18902
+ sig { returns(Prism::Location) }
+ def closing_loc; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#18866
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#18861
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def content: () -> String
+ #
+ # source://prism//lib/prism/node.rb#18927
+ sig { returns(String) }
+ def content; end
+
+ # attr_reader content_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#18895
+ sig { returns(Prism::Location) }
+ def content_loc; end
+
+ # def copy: (?flags: Integer, ?opening_loc: Location, ?content_loc: Location, ?closing_loc: Location, ?unescaped: String, ?location: Location) -> XStringNode
+ #
+ # source://prism//lib/prism/node.rb#18871
+ sig do
+ params(
+ flags: Integer,
+ opening_loc: Prism::Location,
+ content_loc: Prism::Location,
+ closing_loc: Prism::Location,
+ unescaped: String,
+ location: Prism::Location
+ ).returns(Prism::XStringNode)
+ end
+ def copy(flags: T.unsafe(nil), opening_loc: T.unsafe(nil), content_loc: T.unsafe(nil), closing_loc: T.unsafe(nil), unescaped: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#18856
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { flags: Integer, opening_loc: Location, content_loc: Location, closing_loc: Location, unescaped: String, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#18879
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def forced_binary_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#18917
+ sig { returns(T::Boolean) }
+ def forced_binary_encoding?; end
+
+ # def forced_utf8_encoding?: () -> bool
+ #
+ # @return [Boolean]
+ #
+ # source://prism//lib/prism/node.rb#18912
+ sig { returns(T::Boolean) }
+ def forced_utf8_encoding?; end
+
+ sig { returns(T::Boolean) }
+ def heredoc?; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#18937
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def opening: () -> String
+ #
+ # source://prism//lib/prism/node.rb#18922
+ sig { returns(String) }
+ def opening; end
+
+ # attr_reader opening_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#18888
+ sig { returns(Prism::Location) }
+ def opening_loc; end
+
+ # Occasionally it's helpful to treat a string as if it were interpolated so
+ # that there's a consistent interface for working with strings.
+ #
+ # source://prism//lib/prism/node_ext.rb#86
+ sig { returns(Prism::InterpolatedXStringNode) }
+ def to_interpolated; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18955
+ sig { override.returns(Symbol) }
+ def type; end
+
+ # attr_reader unescaped: String
+ #
+ # source://prism//lib/prism/node.rb#18909
+ sig { returns(String) }
+ def unescaped; end
+
+ protected
+
+ # protected attr_reader flags: Integer
+ #
+ # source://prism//lib/prism/node.rb#18884
+ sig { returns(Integer) }
+ def flags; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#18965
+ def type; end
+ end
+end
+
+# Represents the use of the `yield` keyword.
+#
+# yield 1
+# ^^^^^^^
+#
+# source://prism//lib/prism/node.rb#18985
+class Prism::YieldNode < ::Prism::Node
+ # def initialize: (Location keyword_loc, Location? lparen_loc, ArgumentsNode? arguments, Location? rparen_loc, Location location) -> void
+ #
+ # @return [YieldNode] a new instance of YieldNode
+ #
+ # source://prism//lib/prism/node.rb#18987
+ sig do
+ params(
+ source: Prism::Source,
+ keyword_loc: Prism::Location,
+ lparen_loc: T.nilable(Prism::Location),
+ arguments: T.nilable(Prism::ArgumentsNode),
+ rparen_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).void
+ end
+ def initialize(source, keyword_loc, lparen_loc, arguments, rparen_loc, location); end
+
+ # Implements case-equality for the node. This is effectively == but without
+ # comparing the value of locations. Locations are checked only for presence.
+ #
+ # source://prism//lib/prism/node.rb#19117
+ def ===(other); end
+
+ # def accept: (Visitor visitor) -> void
+ #
+ # source://prism//lib/prism/node.rb#18997
+ sig { override.params(visitor: Prism::Visitor).returns(T.untyped) }
+ def accept(visitor); end
+
+ # attr_reader arguments: ArgumentsNode?
+ #
+ # source://prism//lib/prism/node.rb#19052
+ sig { returns(T.nilable(Prism::ArgumentsNode)) }
+ def arguments; end
+
+ # def child_nodes: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#19002
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def child_nodes; end
+
+ # def comment_targets: () -> Array[Node | Location]
+ #
+ # source://prism//lib/prism/node.rb#19014
+ sig { override.returns(T::Array[T.any(Prism::Node, Prism::Location)]) }
+ def comment_targets; end
+
+ # def compact_child_nodes: () -> Array[Node]
+ #
+ # source://prism//lib/prism/node.rb#19007
+ sig { override.returns(T::Array[Prism::Node]) }
+ def compact_child_nodes; end
+
+ # def copy: (?keyword_loc: Location, ?lparen_loc: Location?, ?arguments: ArgumentsNode?, ?rparen_loc: Location?, ?location: Location) -> YieldNode
+ #
+ # source://prism//lib/prism/node.rb#19019
+ sig do
+ params(
+ keyword_loc: Prism::Location,
+ lparen_loc: T.nilable(Prism::Location),
+ arguments: T.nilable(Prism::ArgumentsNode),
+ rparen_loc: T.nilable(Prism::Location),
+ location: Prism::Location
+ ).returns(Prism::YieldNode)
+ end
+ def copy(keyword_loc: T.unsafe(nil), lparen_loc: T.unsafe(nil), arguments: T.unsafe(nil), rparen_loc: T.unsafe(nil), location: T.unsafe(nil)); end
+
+ # def child_nodes: () -> Array[nil | Node]
+ # def deconstruct: () -> Array[nil | Node]
+ #
+ # source://prism//lib/prism/node.rb#19002
+ sig { override.returns(T::Array[T.nilable(Prism::Node)]) }
+ def deconstruct; end
+
+ # def deconstruct_keys: (Array[Symbol] keys) -> { keyword_loc: Location, lparen_loc: Location?, arguments: ArgumentsNode?, rparen_loc: Location?, location: Location }
+ #
+ # source://prism//lib/prism/node.rb#19027
+ sig { params(keys: T.nilable(T::Array[Symbol])).returns(T::Hash[Symbol, T.untyped]) }
+ def deconstruct_keys(keys); end
+
+ sig { override.returns(T::Array[Prism::Reflection::Field]) }
+ def fields; end
+
+ # def inspect -> String
+ #
+ # source://prism//lib/prism/node.rb#19083
+ sig { override.returns(String) }
+ def inspect; end
+
+ # def keyword: () -> String
+ #
+ # source://prism//lib/prism/node.rb#19068
+ sig { returns(String) }
+ def keyword; end
+
+ # attr_reader keyword_loc: Location
+ #
+ # source://prism//lib/prism/node.rb#19032
+ sig { returns(Prism::Location) }
+ def keyword_loc; end
+
+ # def lparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#19073
+ sig { returns(T.nilable(String)) }
+ def lparen; end
+
+ # attr_reader lparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#19039
+ sig { returns(T.nilable(Prism::Location)) }
+ def lparen_loc; end
+
+ # def rparen: () -> String?
+ #
+ # source://prism//lib/prism/node.rb#19078
+ sig { returns(T.nilable(String)) }
+ def rparen; end
+
+ # attr_reader rparen_loc: Location?
+ #
+ # source://prism//lib/prism/node.rb#19055
+ sig { returns(T.nilable(Prism::Location)) }
+ def rparen_loc; end
+
+ # Sometimes you want to check an instance of a node against a list of
+ # classes to see what kind of behavior to perform. Usually this is done by
+ # calling `[cls1, cls2].include?(node.class)` or putting the node into a
+ # case statement and doing `case node; when cls1; when cls2; end`. Both of
+ # these approaches are relatively slow because of the constant lookups,
+ # method calls, and/or array allocations.
+ #
+ # Instead, you can call #type, which will return to you a symbol that you
+ # can use for comparison. This is faster than the other approaches because
+ # it uses a single integer comparison, but also because if you're on CRuby
+ # you can take advantage of the fact that case statements with all symbol
+ # keys will use a jump table.
+ #
+ # def type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#19101
+ sig { override.returns(Symbol) }
+ def type; end
+
+ class << self
+ # Similar to #type, this method returns a symbol that you can use for
+ # splitting on the type of the node without having to do a long === chain.
+ # Note that like #type, it will still be slower than using == for a single
+ # class, but should be faster in a case statement or an array comparison.
+ #
+ # def self.type: () -> Symbol
+ #
+ # source://prism//lib/prism/node.rb#19111
+ def type; end
+ end
+end
diff --git a/sorbet/rbi/gems/rbi@0.1.13.rbi b/sorbet/rbi/gems/rbi@0.1.13.rbi
new file mode 100644
index 0000000..f307314
--- /dev/null
+++ b/sorbet/rbi/gems/rbi@0.1.13.rbi
@@ -0,0 +1,3078 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `rbi` gem.
+# Please instead update this file by running `bin/tapioca gem rbi`.
+
+
+# source://rbi//lib/rbi/loc.rb#4
+module RBI; end
+
+# source://rbi//lib/rbi/model.rb#1041
+class RBI::Arg < ::RBI::Node
+ # source://rbi//lib/rbi/model.rb#1053
+ sig { params(value: ::String, loc: T.nilable(::RBI::Loc)).void }
+ def initialize(value, loc: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/model.rb#1059
+ sig { params(other: T.nilable(::Object)).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#613
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/model.rb#1064
+ sig { returns(::String) }
+ def to_s; end
+
+ # source://rbi//lib/rbi/model.rb#1045
+ sig { returns(::String) }
+ def value; end
+end
+
+# Attributes
+#
+# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below.
+#
+# source://rbi//lib/rbi/model.rb#349
+class RBI::Attr < ::RBI::NodeWithComments
+ include ::RBI::Indexable
+
+ abstract!
+
+ # source://rbi//lib/rbi/model.rb#374
+ sig do
+ params(
+ name: ::Symbol,
+ names: T::Array[::Symbol],
+ visibility: ::RBI::Visibility,
+ sigs: T::Array[::RBI::Sig],
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment]
+ ).void
+ end
+ def initialize(name, names, visibility: T.unsafe(nil), sigs: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/printer.rb#348
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#412
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # @abstract
+ #
+ # source://rbi//lib/rbi/model.rb#382
+ sig { abstract.returns(T::Array[::String]) }
+ def fully_qualified_names; end
+
+ # source://rbi//lib/rbi/index.rb#113
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#420
+ sig { override.params(other: ::RBI::Node).void }
+ def merge_with(other); end
+
+ # source://rbi//lib/rbi/model.rb#356
+ sig { returns(T::Array[::Symbol]) }
+ def names; end
+
+ # source://rbi//lib/rbi/printer.rb#375
+ sig { override.returns(T::Boolean) }
+ def oneline?; end
+
+ # source://rbi//lib/rbi/model.rb#362
+ sig { returns(T::Array[::RBI::Sig]) }
+ def sigs; end
+
+ # source://rbi//lib/rbi/model.rb#359
+ sig { returns(::RBI::Visibility) }
+ def visibility; end
+
+ # @return [Visibility]
+ #
+ # source://rbi//lib/rbi/model.rb#359
+ def visibility=(_arg0); end
+end
+
+# source://rbi//lib/rbi/model.rb#385
+class RBI::AttrAccessor < ::RBI::Attr
+ # source://rbi//lib/rbi/model.rb#399
+ sig do
+ params(
+ name: ::Symbol,
+ names: ::Symbol,
+ visibility: ::RBI::Visibility,
+ sigs: T::Array[::RBI::Sig],
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::AttrAccessor).void)
+ ).void
+ end
+ def initialize(name, *names, visibility: T.unsafe(nil), sigs: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#452
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#405
+ sig { override.returns(T::Array[::String]) }
+ def fully_qualified_names; end
+
+ # source://rbi//lib/rbi/model.rb#411
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/model.rb#417
+class RBI::AttrReader < ::RBI::Attr
+ # source://rbi//lib/rbi/model.rb#431
+ sig do
+ params(
+ name: ::Symbol,
+ names: ::Symbol,
+ visibility: ::RBI::Visibility,
+ sigs: T::Array[::RBI::Sig],
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::AttrReader).void)
+ ).void
+ end
+ def initialize(name, *names, visibility: T.unsafe(nil), sigs: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#434
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#437
+ sig { override.returns(T::Array[::String]) }
+ def fully_qualified_names; end
+
+ # source://rbi//lib/rbi/model.rb#443
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/model.rb#449
+class RBI::AttrWriter < ::RBI::Attr
+ # source://rbi//lib/rbi/model.rb#463
+ sig do
+ params(
+ name: ::Symbol,
+ names: ::Symbol,
+ visibility: ::RBI::Visibility,
+ sigs: T::Array[::RBI::Sig],
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::AttrWriter).void)
+ ).void
+ end
+ def initialize(name, *names, visibility: T.unsafe(nil), sigs: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#443
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#469
+ sig { override.returns(T::Array[::String]) }
+ def fully_qualified_names; end
+
+ # source://rbi//lib/rbi/model.rb#475
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# An arbitrary blank line that can be added both in trees and comments
+#
+# source://rbi//lib/rbi/model.rb#74
+class RBI::BlankLine < ::RBI::Comment
+ # source://rbi//lib/rbi/model.rb#78
+ sig { params(loc: T.nilable(::RBI::Loc)).void }
+ def initialize(loc: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/printer.rb#217
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+end
+
+# source://rbi//lib/rbi/model.rb#814
+class RBI::BlockParam < ::RBI::Param
+ # source://rbi//lib/rbi/model.rb#825
+ sig do
+ params(
+ name: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::BlockParam).void)
+ ).void
+ end
+ def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#836
+ sig { params(other: T.nilable(::Object)).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#543
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/printer.rb#548
+ sig { override.params(v: ::RBI::Printer, last: T::Boolean).void }
+ def print_comment_leading_space(v, last:); end
+
+ # source://rbi//lib/rbi/model.rb#831
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/model.rb#218
+class RBI::Class < ::RBI::Scope
+ # source://rbi//lib/rbi/model.rb#236
+ sig do
+ params(
+ name: ::String,
+ superclass_name: T.nilable(::String),
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Class).void)
+ ).void
+ end
+ def initialize(name, superclass_name: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#376
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#244
+ sig { override.returns(::String) }
+ def fully_qualified_name; end
+
+ # source://rbi//lib/rbi/model.rb#222
+ sig { returns(::String) }
+ def name; end
+
+ # @return [String]
+ #
+ # source://rbi//lib/rbi/model.rb#222
+ def name=(_arg0); end
+
+ # source://rbi//lib/rbi/printer.rb#284
+ sig { override.params(v: ::RBI::Printer).void }
+ def print_header(v); end
+
+ # source://rbi//lib/rbi/model.rb#225
+ sig { returns(T.nilable(::String)) }
+ def superclass_name; end
+
+ # @return [String, nil]
+ #
+ # source://rbi//lib/rbi/model.rb#225
+ def superclass_name=(_arg0); end
+end
+
+# source://rbi//lib/rbi/model.rb#53
+class RBI::Comment < ::RBI::Node
+ # source://rbi//lib/rbi/model.rb#60
+ sig { params(text: ::String, loc: T.nilable(::RBI::Loc)).void }
+ def initialize(text, loc: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/model.rb#66
+ sig { params(other: ::Object).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#197
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/model.rb#57
+ sig { returns(::String) }
+ def text; end
+
+ # @return [String]
+ #
+ # source://rbi//lib/rbi/model.rb#57
+ def text=(_arg0); end
+end
+
+# A tree showing incompatibles nodes
+#
+# Is rendered as a merge conflict between `left` and` right`:
+# ~~~rb
+# class Foo
+# <<<<<<< left
+# def m1; end
+# def m2(a); end
+# =======
+# def m1(a); end
+# def m2; end
+# >>>>>>> right
+# end
+# ~~~
+#
+# source://rbi//lib/rbi/rewriters/merge_trees.rb#589
+class RBI::ConflictTree < ::RBI::Tree
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#596
+ sig { params(left_name: ::String, right_name: ::String).void }
+ def initialize(left_name: T.unsafe(nil), right_name: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#607
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#593
+ sig { returns(::RBI::Tree) }
+ def left; end
+
+ # @return [Tree]
+ #
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#593
+ def right; end
+end
+
+# Consts
+#
+# source://rbi//lib/rbi/model.rb#312
+class RBI::Const < ::RBI::NodeWithComments
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#327
+ sig do
+ params(
+ name: ::String,
+ value: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Const).void)
+ ).void
+ end
+ def initialize(name, value, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/printer.rb#335
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#403
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#335
+ sig { returns(::String) }
+ def fully_qualified_name; end
+
+ # source://rbi//lib/rbi/index.rb#103
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/model.rb#316
+ sig { returns(::String) }
+ def name; end
+
+ # source://rbi//lib/rbi/model.rb#342
+ sig { override.returns(::String) }
+ def to_s; end
+
+ # @return [String]
+ #
+ # source://rbi//lib/rbi/model.rb#316
+ def value; end
+end
+
+# source://rbi//lib/rbi/model.rb#889
+class RBI::Extend < ::RBI::Mixin
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#901
+ sig do
+ params(
+ name: ::String,
+ names: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Extend).void)
+ ).void
+ end
+ def initialize(name, *names, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#502
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/index.rb#143
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/model.rb#907
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/model.rb#137
+class RBI::File
+ # source://rbi//lib/rbi/model.rb#156
+ sig do
+ params(
+ strictness: T.nilable(::String),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(file: ::RBI::File).void)
+ ).void
+ end
+ def initialize(strictness: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#164
+ sig { params(node: ::RBI::Node).void }
+ def <<(node); end
+
+ # source://rbi//lib/rbi/printer.rb#105
+ sig { params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/model.rb#147
+ sig { returns(T::Array[::RBI::Comment]) }
+ def comments; end
+
+ # @return [Array]
+ #
+ # source://rbi//lib/rbi/model.rb#147
+ def comments=(_arg0); end
+
+ # source://rbi//lib/rbi/model.rb#169
+ sig { returns(T::Boolean) }
+ def empty?; end
+
+ # source://rbi//lib/rbi/printer.rb#129
+ sig do
+ params(
+ out: T.any(::IO, ::StringIO),
+ indent: ::Integer,
+ print_locs: T::Boolean,
+ max_line_length: T.nilable(::Integer)
+ ).void
+ end
+ def print(out: T.unsafe(nil), indent: T.unsafe(nil), print_locs: T.unsafe(nil), max_line_length: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/model.rb#141
+ sig { returns(::RBI::Tree) }
+ def root; end
+
+ # @return [Tree]
+ #
+ # source://rbi//lib/rbi/model.rb#141
+ def root=(_arg0); end
+
+ # source://rbi//lib/rbi/model.rb#144
+ sig { returns(T.nilable(::String)) }
+ def strictness; end
+
+ # @return [String, nil]
+ #
+ # source://rbi//lib/rbi/model.rb#144
+ def strictness=(_arg0); end
+
+ # source://rbi//lib/rbi/printer.rb#135
+ sig { params(indent: ::Integer, print_locs: T::Boolean, max_line_length: T.nilable(::Integer)).returns(::String) }
+ def string(indent: T.unsafe(nil), print_locs: T.unsafe(nil), max_line_length: T.unsafe(nil)); end
+end
+
+# source://rbi//lib/rbi/formatter.rb#5
+class RBI::Formatter
+ # source://rbi//lib/rbi/formatter.rb#36
+ sig do
+ params(
+ add_sig_templates: T::Boolean,
+ group_nodes: T::Boolean,
+ max_line_length: T.nilable(::Integer),
+ nest_singleton_methods: T::Boolean,
+ nest_non_public_methods: T::Boolean,
+ sort_nodes: T::Boolean
+ ).void
+ end
+ def initialize(add_sig_templates: T.unsafe(nil), group_nodes: T.unsafe(nil), max_line_length: T.unsafe(nil), nest_singleton_methods: T.unsafe(nil), nest_non_public_methods: T.unsafe(nil), sort_nodes: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/formatter.rb#15
+ sig { params(add_sig_templates: T::Boolean).returns(T::Boolean) }
+ def add_sig_templates=(add_sig_templates); end
+
+ # source://rbi//lib/rbi/formatter.rb#59
+ sig { params(file: ::RBI::File).void }
+ def format_file(file); end
+
+ # source://rbi//lib/rbi/formatter.rb#64
+ sig { params(tree: ::RBI::Tree).void }
+ def format_tree(tree); end
+
+ # source://rbi//lib/rbi/formatter.rb#18
+ sig { params(group_nodes: T::Boolean).returns(T::Boolean) }
+ def group_nodes=(group_nodes); end
+
+ # source://rbi//lib/rbi/formatter.rb#24
+ sig { returns(T.nilable(::Integer)) }
+ def max_line_length; end
+
+ # @return [Integer, nil]
+ #
+ # source://rbi//lib/rbi/formatter.rb#24
+ def max_line_length=(_arg0); end
+
+ # source://rbi//lib/rbi/formatter.rb#21
+ sig { params(nest_non_public_methods: T::Boolean).returns(T::Boolean) }
+ def nest_non_public_methods=(nest_non_public_methods); end
+
+ # source://rbi//lib/rbi/formatter.rb#12
+ sig { params(nest_singleton_methods: T::Boolean).returns(T::Boolean) }
+ def nest_singleton_methods=(nest_singleton_methods); end
+
+ # source://rbi//lib/rbi/formatter.rb#53
+ sig { params(file: ::RBI::File).returns(::String) }
+ def print_file(file); end
+
+ # source://rbi//lib/rbi/formatter.rb#9
+ sig { params(sort_nodes: T::Boolean).returns(T::Boolean) }
+ def sort_nodes=(sort_nodes); end
+end
+
+# source://rbi//lib/rbi/rewriters/group_nodes.rb#88
+class RBI::Group < ::RBI::Tree
+ # source://rbi//lib/rbi/rewriters/group_nodes.rb#95
+ sig { params(kind: ::RBI::Group::Kind).void }
+ def initialize(kind); end
+
+ # source://rbi//lib/rbi/printer.rb#838
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/rewriters/group_nodes.rb#92
+ sig { returns(::RBI::Group::Kind) }
+ def kind; end
+end
+
+# source://rbi//lib/rbi/rewriters/group_nodes.rb#100
+class RBI::Group::Kind < ::T::Enum
+ enums do
+ Mixins = new
+ RequiredAncestors = new
+ Helpers = new
+ TypeMembers = new
+ MixesInClassMethods = new
+ Sends = new
+ Attrs = new
+ TStructFields = new
+ TEnums = new
+ Inits = new
+ Methods = new
+ SingletonClasses = new
+ Consts = new
+ end
+end
+
+# Sorbet's misc.
+#
+# source://rbi//lib/rbi/model.rb#1372
+class RBI::Helper < ::RBI::NodeWithComments
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#1386
+ sig do
+ params(
+ name: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Helper).void)
+ ).void
+ end
+ def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/printer.rb#825
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#520
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/index.rb#173
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/model.rb#1376
+ sig { returns(::String) }
+ def name; end
+
+ # source://rbi//lib/rbi/model.rb#1393
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/model.rb#866
+class RBI::Include < ::RBI::Mixin
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#878
+ sig do
+ params(
+ name: ::String,
+ names: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Include).void)
+ ).void
+ end
+ def initialize(name, *names, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#493
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/index.rb#133
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/model.rb#884
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/index.rb#5
+class RBI::Index < ::RBI::Visitor
+ # source://rbi//lib/rbi/index.rb#21
+ sig { void }
+ def initialize; end
+
+ # source://rbi//lib/rbi/index.rb#32
+ sig { params(id: ::String).returns(T::Array[::RBI::Node]) }
+ def [](id); end
+
+ # source://rbi//lib/rbi/index.rb#37
+ sig { params(nodes: ::RBI::Node).void }
+ def index(*nodes); end
+
+ # source://rbi//lib/rbi/index.rb#27
+ sig { returns(T::Array[::String]) }
+ def keys; end
+
+ # source://rbi//lib/rbi/index.rb#42
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+
+ private
+
+ # source://rbi//lib/rbi/index.rb#59
+ sig { params(node: T.all(::RBI::Indexable, ::RBI::Node)).void }
+ def index_node(node); end
+
+ class << self
+ # source://rbi//lib/rbi/index.rb#13
+ sig { params(node: ::RBI::Node).returns(::RBI::Index) }
+ def index(*node); end
+ end
+end
+
+# A Node that can be referred to by a unique ID inside an index
+#
+# @abstract Subclasses must implement the `abstract` methods below.
+#
+# source://rbi//lib/rbi/index.rb#74
+module RBI::Indexable
+ interface!
+
+ # Unique IDs that refer to this node.
+ #
+ # Some nodes can have multiple ids, for example an attribute accessor matches the ID of the
+ # getter and the setter.
+ #
+ # @abstract
+ #
+ # source://rbi//lib/rbi/index.rb#85
+ sig { abstract.returns(T::Array[::String]) }
+ def index_ids; end
+end
+
+# source://rbi//lib/rbi/model.rb#1069
+class RBI::KwArg < ::RBI::Arg
+ # source://rbi//lib/rbi/model.rb#1082
+ sig { params(keyword: ::String, value: ::String, loc: T.nilable(::RBI::Loc)).void }
+ def initialize(keyword, value, loc: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/model.rb#1088
+ sig { params(other: T.nilable(::Object)).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#622
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/model.rb#1073
+ sig { returns(::String) }
+ def keyword; end
+
+ # source://rbi//lib/rbi/model.rb#1093
+ sig { returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/model.rb#755
+class RBI::KwOptParam < ::RBI::Param
+ # source://rbi//lib/rbi/model.rb#770
+ sig do
+ params(
+ name: ::String,
+ value: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::KwOptParam).void)
+ ).void
+ end
+ def initialize(name, value, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#782
+ sig { params(other: T.nilable(::Object)).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#513
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/printer.rb#518
+ sig { override.params(v: ::RBI::Printer, last: T::Boolean).void }
+ def print_comment_leading_space(v, last:); end
+
+ # source://rbi//lib/rbi/model.rb#777
+ sig { override.returns(::String) }
+ def to_s; end
+
+ # source://rbi//lib/rbi/model.rb#759
+ sig { returns(::String) }
+ def value; end
+end
+
+# source://rbi//lib/rbi/model.rb#728
+class RBI::KwParam < ::RBI::Param
+ # source://rbi//lib/rbi/model.rb#739
+ sig do
+ params(
+ name: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::KwParam).void)
+ ).void
+ end
+ def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#750
+ sig { params(other: T.nilable(::Object)).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#498
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/printer.rb#503
+ sig { override.params(v: ::RBI::Printer, last: T::Boolean).void }
+ def print_comment_leading_space(v, last:); end
+
+ # source://rbi//lib/rbi/model.rb#745
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/model.rb#787
+class RBI::KwRestParam < ::RBI::Param
+ # source://rbi//lib/rbi/model.rb#798
+ sig do
+ params(
+ name: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::KwRestParam).void)
+ ).void
+ end
+ def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#809
+ sig { params(other: T.nilable(::Object)).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#528
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/printer.rb#533
+ sig { override.params(v: ::RBI::Printer, last: T::Boolean).void }
+ def print_comment_leading_space(v, last:); end
+
+ # source://rbi//lib/rbi/model.rb#804
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/loc.rb#5
+class RBI::Loc
+ # source://rbi//lib/rbi/loc.rb#38
+ sig do
+ params(
+ file: T.nilable(::String),
+ begin_line: T.nilable(::Integer),
+ end_line: T.nilable(::Integer),
+ begin_column: T.nilable(::Integer),
+ end_column: T.nilable(::Integer)
+ ).void
+ end
+ def initialize(file: T.unsafe(nil), begin_line: T.unsafe(nil), end_line: T.unsafe(nil), begin_column: T.unsafe(nil), end_column: T.unsafe(nil)); end
+
+ # @return [Integer, nil]
+ #
+ # source://rbi//lib/rbi/loc.rb#27
+ def begin_column; end
+
+ # source://rbi//lib/rbi/loc.rb#27
+ sig { returns(T.nilable(::Integer)) }
+ def begin_line; end
+
+ # @return [Integer, nil]
+ #
+ # source://rbi//lib/rbi/loc.rb#27
+ def end_column; end
+
+ # @return [Integer, nil]
+ #
+ # source://rbi//lib/rbi/loc.rb#27
+ def end_line; end
+
+ # source://rbi//lib/rbi/loc.rb#24
+ sig { returns(T.nilable(::String)) }
+ def file; end
+
+ # source://rbi//lib/rbi/loc.rb#56
+ sig { returns(T.nilable(::String)) }
+ def source; end
+
+ # source://rbi//lib/rbi/loc.rb#47
+ sig { returns(::String) }
+ def to_s; end
+
+ class << self
+ # source://rbi//lib/rbi/loc.rb#12
+ sig { params(file: ::String, prism_location: ::Prism::Location).returns(::RBI::Loc) }
+ def from_prism(file, prism_location); end
+ end
+end
+
+# A tree that _might_ contain conflicts
+#
+# source://rbi//lib/rbi/rewriters/merge_trees.rb#330
+class RBI::MergeTree < ::RBI::Tree
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#344
+ sig do
+ params(
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ conflicts: T::Array[::RBI::Rewriters::Merge::Conflict],
+ block: T.nilable(T.proc.params(node: ::RBI::Tree).void)
+ ).void
+ end
+ def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), conflicts: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#334
+ sig { returns(T::Array[::RBI::Rewriters::Merge::Conflict]) }
+ def conflicts; end
+end
+
+# Methods and args
+#
+# source://rbi//lib/rbi/model.rb#483
+class RBI::Method < ::RBI::NodeWithComments
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#513
+ sig do
+ params(
+ name: ::String,
+ params: T::Array[::RBI::Param],
+ is_singleton: T::Boolean,
+ visibility: ::RBI::Visibility,
+ sigs: T::Array[::RBI::Sig],
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Method).void)
+ ).void
+ end
+ def initialize(name, params: T.unsafe(nil), is_singleton: T.unsafe(nil), visibility: T.unsafe(nil), sigs: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#533
+ sig { params(param: ::RBI::Param).void }
+ def <<(param); end
+
+ # source://rbi//lib/rbi/printer.rb#384
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/model.rb#568
+ sig { params(name: ::String).void }
+ def add_block_param(name); end
+
+ # source://rbi//lib/rbi/model.rb#558
+ sig { params(name: ::String, default_value: ::String).void }
+ def add_kw_opt_param(name, default_value); end
+
+ # source://rbi//lib/rbi/model.rb#553
+ sig { params(name: ::String).void }
+ def add_kw_param(name); end
+
+ # source://rbi//lib/rbi/model.rb#563
+ sig { params(name: ::String).void }
+ def add_kw_rest_param(name); end
+
+ # source://rbi//lib/rbi/model.rb#543
+ sig { params(name: ::String, default_value: ::String).void }
+ def add_opt_param(name, default_value); end
+
+ # source://rbi//lib/rbi/model.rb#538
+ sig { params(name: ::String).void }
+ def add_param(name); end
+
+ # source://rbi//lib/rbi/model.rb#548
+ sig { params(name: ::String).void }
+ def add_rest_param(name); end
+
+ # source://rbi//lib/rbi/model.rb#585
+ sig do
+ params(
+ params: T::Array[::RBI::SigParam],
+ return_type: T.nilable(::String),
+ is_abstract: T::Boolean,
+ is_override: T::Boolean,
+ is_overridable: T::Boolean,
+ is_final: T::Boolean,
+ type_params: T::Array[::String],
+ checked: T.nilable(::Symbol),
+ block: T.proc.params(node: ::RBI::Sig).void
+ ).void
+ end
+ def add_sig(params: T.unsafe(nil), return_type: T.unsafe(nil), is_abstract: T.unsafe(nil), is_override: T.unsafe(nil), is_overridable: T.unsafe(nil), is_final: T.unsafe(nil), type_params: T.unsafe(nil), checked: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#461
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#611
+ sig { returns(::String) }
+ def fully_qualified_name; end
+
+ # source://rbi//lib/rbi/index.rb#123
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/printer.rb#437
+ sig { returns(T::Boolean) }
+ def inline_params?; end
+
+ # source://rbi//lib/rbi/model.rb#493
+ sig { returns(T::Boolean) }
+ def is_singleton; end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/model.rb#493
+ def is_singleton=(_arg0); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#470
+ sig { override.params(other: ::RBI::Node).void }
+ def merge_with(other); end
+
+ # source://rbi//lib/rbi/model.rb#487
+ sig { returns(::String) }
+ def name; end
+
+ # @return [String]
+ #
+ # source://rbi//lib/rbi/model.rb#487
+ def name=(_arg0); end
+
+ # source://rbi//lib/rbi/printer.rb#432
+ sig { override.returns(T::Boolean) }
+ def oneline?; end
+
+ # source://rbi//lib/rbi/model.rb#490
+ sig { returns(T::Array[::RBI::Param]) }
+ def params; end
+
+ # source://rbi//lib/rbi/model.rb#499
+ sig { returns(T::Array[::RBI::Sig]) }
+ def sigs; end
+
+ # @return [Array]
+ #
+ # source://rbi//lib/rbi/model.rb#499
+ def sigs=(_arg0); end
+
+ # source://rbi//lib/rbi/model.rb#620
+ sig { override.returns(::String) }
+ def to_s; end
+
+ # source://rbi//lib/rbi/model.rb#496
+ sig { returns(::RBI::Visibility) }
+ def visibility; end
+
+ # @return [Visibility]
+ #
+ # source://rbi//lib/rbi/model.rb#496
+ def visibility=(_arg0); end
+end
+
+# source://rbi//lib/rbi/model.rb#1433
+class RBI::MixesInClassMethods < ::RBI::Mixin
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#1445
+ sig do
+ params(
+ name: ::String,
+ names: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::MixesInClassMethods).void)
+ ).void
+ end
+ def initialize(name, *names, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#511
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/index.rb#153
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/model.rb#1451
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# Mixins
+#
+# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below.
+#
+# source://rbi//lib/rbi/model.rb#843
+class RBI::Mixin < ::RBI::NodeWithComments
+ abstract!
+
+ # source://rbi//lib/rbi/model.rb#860
+ sig do
+ params(
+ name: ::String,
+ names: T::Array[::String],
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment]
+ ).void
+ end
+ def initialize(name, names, loc: T.unsafe(nil), comments: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/printer.rb#558
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#484
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#850
+ sig { returns(T::Array[::String]) }
+ def names; end
+end
+
+# source://rbi//lib/rbi/model.rb#190
+class RBI::Module < ::RBI::Scope
+ # source://rbi//lib/rbi/model.rb#204
+ sig do
+ params(
+ name: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Module).void)
+ ).void
+ end
+ def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#385
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#211
+ sig { override.returns(::String) }
+ def fully_qualified_name; end
+
+ # source://rbi//lib/rbi/model.rb#194
+ sig { returns(::String) }
+ def name; end
+
+ # @return [String]
+ #
+ # source://rbi//lib/rbi/model.rb#194
+ def name=(_arg0); end
+
+ # source://rbi//lib/rbi/printer.rb#270
+ sig { override.params(v: ::RBI::Printer).void }
+ def print_header(v); end
+end
+
+# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below.
+#
+# source://rbi//lib/rbi/model.rb#5
+class RBI::Node
+ abstract!
+
+ # source://rbi//lib/rbi/model.rb#18
+ sig { params(loc: T.nilable(::RBI::Loc)).void }
+ def initialize(loc: T.unsafe(nil)); end
+
+ # @abstract
+ #
+ # source://rbi//lib/rbi/printer.rb#146
+ sig { abstract.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # Can `self` and `_other` be merged into a single definition?
+ #
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#287
+ sig { params(_other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(_other); end
+
+ # source://rbi//lib/rbi/model.rb#24
+ sig { void }
+ def detach; end
+
+ # source://rbi//lib/rbi/rewriters/group_nodes.rb#48
+ sig { returns(::RBI::Group::Kind) }
+ def group_kind; end
+
+ # source://rbi//lib/rbi/model.rb#15
+ sig { returns(T.nilable(::RBI::Loc)) }
+ def loc; end
+
+ # @return [Loc, nil]
+ #
+ # source://rbi//lib/rbi/model.rb#15
+ def loc=(_arg0); end
+
+ # Merge `self` and `other` into a single definition
+ #
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#293
+ sig { params(other: ::RBI::Node).void }
+ def merge_with(other); end
+
+ # source://rbi//lib/rbi/printer.rb#179
+ sig { returns(T::Boolean) }
+ def oneline?; end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#296
+ sig { returns(T.nilable(::RBI::ConflictTree)) }
+ def parent_conflict_tree; end
+
+ # source://rbi//lib/rbi/model.rb#46
+ sig { returns(T.nilable(::RBI::Scope)) }
+ def parent_scope; end
+
+ # source://rbi//lib/rbi/model.rb#12
+ sig { returns(T.nilable(::RBI::Tree)) }
+ def parent_tree; end
+
+ # @return [Tree, nil]
+ #
+ # source://rbi//lib/rbi/model.rb#12
+ def parent_tree=(_arg0); end
+
+ # source://rbi//lib/rbi/printer.rb#156
+ sig do
+ params(
+ out: T.any(::IO, ::StringIO),
+ indent: ::Integer,
+ print_locs: T::Boolean,
+ max_line_length: T.nilable(::Integer)
+ ).void
+ end
+ def print(out: T.unsafe(nil), indent: T.unsafe(nil), print_locs: T.unsafe(nil), max_line_length: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/printer.rb#169
+ sig { params(v: ::RBI::Printer).void }
+ def print_blank_line_before(v); end
+
+ # source://rbi//lib/rbi/model.rb#33
+ sig { params(node: ::RBI::Node).void }
+ def replace(node); end
+
+ # source://rbi//lib/rbi/rewriters/filter_versions.rb#94
+ sig { params(version: ::Gem::Version).returns(T::Boolean) }
+ def satisfies_version?(version); end
+
+ # source://rbi//lib/rbi/printer.rb#162
+ sig { params(indent: ::Integer, print_locs: T::Boolean, max_line_length: T.nilable(::Integer)).returns(::String) }
+ def string(indent: T.unsafe(nil), print_locs: T.unsafe(nil), max_line_length: T.unsafe(nil)); end
+end
+
+# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below.
+#
+# source://rbi//lib/rbi/model.rb#83
+class RBI::NodeWithComments < ::RBI::Node
+ abstract!
+
+ # source://rbi//lib/rbi/model.rb#93
+ sig { params(loc: T.nilable(::RBI::Loc), comments: T::Array[::RBI::Comment]).void }
+ def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/model.rb#99
+ sig { returns(T::Array[::String]) }
+ def annotations; end
+
+ # source://rbi//lib/rbi/model.rb#90
+ sig { returns(T::Array[::RBI::Comment]) }
+ def comments; end
+
+ # @return [Array]
+ #
+ # source://rbi//lib/rbi/model.rb#90
+ def comments=(_arg0); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#311
+ sig { override.params(other: ::RBI::Node).void }
+ def merge_with(other); end
+
+ # source://rbi//lib/rbi/printer.rb#188
+ sig { override.returns(T::Boolean) }
+ def oneline?; end
+
+ # source://rbi//lib/rbi/rewriters/filter_versions.rb#104
+ sig { returns(T::Array[::Gem::Requirement]) }
+ def version_requirements; end
+end
+
+# source://rbi//lib/rbi/model.rb#674
+class RBI::OptParam < ::RBI::Param
+ # source://rbi//lib/rbi/model.rb#689
+ sig do
+ params(
+ name: ::String,
+ value: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::OptParam).void)
+ ).void
+ end
+ def initialize(name, value, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#696
+ sig { params(other: T.nilable(::Object)).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#468
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/printer.rb#473
+ sig { override.params(v: ::RBI::Printer, last: T::Boolean).void }
+ def print_comment_leading_space(v, last:); end
+
+ # source://rbi//lib/rbi/model.rb#678
+ sig { returns(::String) }
+ def value; end
+end
+
+# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below.
+#
+# source://rbi//lib/rbi/model.rb#625
+class RBI::Param < ::RBI::NodeWithComments
+ abstract!
+
+ # source://rbi//lib/rbi/model.rb#641
+ sig { params(name: ::String, loc: T.nilable(::RBI::Loc), comments: T::Array[::RBI::Comment]).void }
+ def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/printer.rb#446
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/printer.rb#459
+ sig { returns(T::Array[::String]) }
+ def comments_lines; end
+
+ # source://rbi//lib/rbi/model.rb#632
+ sig { returns(::String) }
+ def name; end
+
+ # source://rbi//lib/rbi/printer.rb#451
+ sig { params(v: ::RBI::Printer, last: T::Boolean).void }
+ def print_comment_leading_space(v, last:); end
+
+ # source://rbi//lib/rbi/model.rb#647
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/parser.rb#7
+class RBI::ParseError < ::StandardError
+ # source://rbi//lib/rbi/parser.rb#14
+ sig { params(message: ::String, location: ::RBI::Loc).void }
+ def initialize(message, location); end
+
+ # source://rbi//lib/rbi/parser.rb#11
+ sig { returns(::RBI::Loc) }
+ def location; end
+end
+
+# source://rbi//lib/rbi/parser.rb#53
+class RBI::Parser
+ # source://rbi//lib/rbi/parser.rb#88
+ sig { params(path: ::String).returns(::RBI::Tree) }
+ def parse_file(path); end
+
+ # source://rbi//lib/rbi/parser.rb#83
+ sig { params(string: ::String).returns(::RBI::Tree) }
+ def parse_string(string); end
+
+ private
+
+ # source://rbi//lib/rbi/parser.rb#95
+ sig { params(source: ::String, file: ::String).returns(::RBI::Tree) }
+ def parse(source, file:); end
+
+ class << self
+ # source://rbi//lib/rbi/parser.rb#65
+ sig { params(path: ::String).returns(::RBI::Tree) }
+ def parse_file(path); end
+
+ # source://rbi//lib/rbi/parser.rb#70
+ sig { params(paths: T::Array[::String]).returns(T::Array[::RBI::Tree]) }
+ def parse_files(paths); end
+
+ # source://rbi//lib/rbi/parser.rb#60
+ sig { params(string: ::String).returns(::RBI::Tree) }
+ def parse_string(string); end
+
+ # source://rbi//lib/rbi/parser.rb#76
+ sig { params(strings: T::Array[::String]).returns(T::Array[::RBI::Tree]) }
+ def parse_strings(strings); end
+ end
+end
+
+# source://rbi//lib/rbi/parser.rb#791
+class RBI::Parser::SigBuilder < ::RBI::Parser::Visitor
+ # source://rbi//lib/rbi/parser.rb#798
+ sig { params(content: ::String, file: ::String).void }
+ def initialize(content, file:); end
+
+ # source://rbi//lib/rbi/parser.rb#795
+ sig { returns(::RBI::Sig) }
+ def current; end
+
+ # source://rbi//lib/rbi/parser.rb#850
+ sig { override.params(node: ::Prism::AssocNode).void }
+ def visit_assoc_node(node); end
+
+ # source://rbi//lib/rbi/parser.rb#805
+ sig { override.params(node: ::Prism::CallNode).void }
+ def visit_call_node(node); end
+end
+
+# source://rbi//lib/rbi/parser.rb#153
+class RBI::Parser::TreeBuilder < ::RBI::Parser::Visitor
+ # source://rbi//lib/rbi/parser.rb#163
+ sig { params(source: ::String, comments: T::Array[::Prism::Comment], file: ::String).void }
+ def initialize(source, comments:, file:); end
+
+ # source://rbi//lib/rbi/parser.rb#160
+ sig { returns(T.nilable(::Prism::Node)) }
+ def last_node; end
+
+ # source://rbi//lib/rbi/parser.rb#157
+ sig { returns(::RBI::Tree) }
+ def tree; end
+
+ # source://rbi//lib/rbi/parser.rb#299
+ sig { params(node: ::Prism::CallNode).void }
+ def visit_call_node(node); end
+
+ # source://rbi//lib/rbi/parser.rb#176
+ sig { override.params(node: ::Prism::ClassNode).void }
+ def visit_class_node(node); end
+
+ # source://rbi//lib/rbi/parser.rb#208
+ sig { params(node: T.any(::Prism::ConstantPathWriteNode, ::Prism::ConstantWriteNode)).void }
+ def visit_constant_assign(node); end
+
+ # source://rbi//lib/rbi/parser.rb#201
+ sig { override.params(node: ::Prism::ConstantPathWriteNode).void }
+ def visit_constant_path_write_node(node); end
+
+ # source://rbi//lib/rbi/parser.rb#194
+ sig { override.params(node: ::Prism::ConstantWriteNode).void }
+ def visit_constant_write_node(node); end
+
+ # source://rbi//lib/rbi/parser.rb#241
+ sig { override.params(node: ::Prism::DefNode).void }
+ def visit_def_node(node); end
+
+ # source://rbi//lib/rbi/parser.rb#255
+ sig { override.params(node: ::Prism::ModuleNode).void }
+ def visit_module_node(node); end
+
+ # source://rbi//lib/rbi/parser.rb#272
+ sig { override.params(node: ::Prism::ProgramNode).void }
+ def visit_program_node(node); end
+
+ # source://rbi//lib/rbi/parser.rb#283
+ sig { override.params(node: ::Prism::SingletonClassNode).void }
+ def visit_singleton_class_node(node); end
+
+ private
+
+ # Collect all the remaining comments within a node
+ #
+ # source://rbi//lib/rbi/parser.rb#467
+ sig { params(node: ::Prism::Node).void }
+ def collect_dangling_comments(node); end
+
+ # Collect all the remaining comments after visiting the tree
+ #
+ # source://rbi//lib/rbi/parser.rb#485
+ sig { void }
+ def collect_orphan_comments; end
+
+ # source://rbi//lib/rbi/parser.rb#508
+ sig { returns(::RBI::Tree) }
+ def current_scope; end
+
+ # source://rbi//lib/rbi/parser.rb#513
+ sig { returns(T::Array[::RBI::Sig]) }
+ def current_sigs; end
+
+ # source://rbi//lib/rbi/parser.rb#520
+ sig { returns(T::Array[::RBI::Comment]) }
+ def current_sigs_comments; end
+
+ # source://rbi//lib/rbi/parser.rb#527
+ sig { params(node: ::Prism::Node).returns(T::Array[::RBI::Comment]) }
+ def node_comments(node); end
+
+ # source://rbi//lib/rbi/parser.rb#545
+ sig { params(node: ::Prism::Comment).returns(::RBI::Comment) }
+ def parse_comment(node); end
+
+ # source://rbi//lib/rbi/parser.rb#574
+ sig { params(node: T.nilable(::Prism::Node)).returns(T::Array[::RBI::Param]) }
+ def parse_params(node); end
+
+ # source://rbi//lib/rbi/parser.rb#550
+ sig { params(node: T.nilable(::Prism::Node)).returns(T::Array[::RBI::Arg]) }
+ def parse_send_args(node); end
+
+ # source://rbi//lib/rbi/parser.rb#648
+ sig { params(node: ::Prism::CallNode).returns(::RBI::Sig) }
+ def parse_sig(node); end
+
+ # source://rbi//lib/rbi/parser.rb#658
+ sig do
+ params(
+ node: T.any(::Prism::ConstantPathWriteNode, ::Prism::ConstantWriteNode)
+ ).returns(T.nilable(::RBI::Struct))
+ end
+ def parse_struct(node); end
+
+ # source://rbi//lib/rbi/parser.rb#708
+ sig { params(send: ::Prism::CallNode).void }
+ def parse_tstruct_field(send); end
+
+ # source://rbi//lib/rbi/parser.rb#745
+ sig { params(name: ::String, node: ::Prism::Node).returns(::RBI::Visibility) }
+ def parse_visibility(name, node); end
+
+ # source://rbi//lib/rbi/parser.rb#759
+ sig { void }
+ def separate_header_comments; end
+
+ # source://rbi//lib/rbi/parser.rb#769
+ sig { void }
+ def set_root_tree_loc; end
+
+ # source://rbi//lib/rbi/parser.rb#783
+ sig { params(node: T.nilable(::Prism::Node)).returns(T::Boolean) }
+ def type_variable_definition?(node); end
+end
+
+# source://rbi//lib/rbi/parser.rb#122
+class RBI::Parser::Visitor < ::Prism::Visitor
+ # source://rbi//lib/rbi/parser.rb#126
+ sig { params(source: ::String, file: ::String).void }
+ def initialize(source, file:); end
+
+ private
+
+ # source://rbi//lib/rbi/parser.rb#136
+ sig { params(node: ::Prism::Node).returns(::RBI::Loc) }
+ def node_loc(node); end
+
+ # source://rbi//lib/rbi/parser.rb#141
+ sig { params(node: T.nilable(::Prism::Node)).returns(T.nilable(::String)) }
+ def node_string(node); end
+
+ # source://rbi//lib/rbi/parser.rb#148
+ sig { params(node: ::Prism::Node).returns(::String) }
+ def node_string!(node); end
+end
+
+# source://rbi//lib/rbi/printer.rb#5
+class RBI::Printer < ::RBI::Visitor
+ # source://rbi//lib/rbi/printer.rb#28
+ sig do
+ params(
+ out: T.any(::IO, ::StringIO),
+ indent: ::Integer,
+ print_locs: T::Boolean,
+ max_line_length: T.nilable(::Integer)
+ ).void
+ end
+ def initialize(out: T.unsafe(nil), indent: T.unsafe(nil), print_locs: T.unsafe(nil), max_line_length: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/printer.rb#15
+ sig { returns(::Integer) }
+ def current_indent; end
+
+ # source://rbi//lib/rbi/printer.rb#46
+ sig { void }
+ def dedent; end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/printer.rb#9
+ def in_visibility_group; end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/printer.rb#9
+ def in_visibility_group=(_arg0); end
+
+ # Printing
+ #
+ # source://rbi//lib/rbi/printer.rb#41
+ sig { void }
+ def indent; end
+
+ # source://rbi//lib/rbi/printer.rb#18
+ sig { returns(T.nilable(::Integer)) }
+ def max_line_length; end
+
+ # source://rbi//lib/rbi/printer.rb#12
+ sig { returns(T.nilable(::RBI::Node)) }
+ def previous_node; end
+
+ # Print a string without indentation nor `\n` at the end.
+ #
+ # source://rbi//lib/rbi/printer.rb#52
+ sig { params(string: ::String).void }
+ def print(string); end
+
+ # source://rbi//lib/rbi/printer.rb#9
+ sig { returns(T::Boolean) }
+ def print_locs; end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/printer.rb#9
+ def print_locs=(_arg0); end
+
+ # Print a string with indentation and `\n` at the end.
+ #
+ # source://rbi//lib/rbi/printer.rb#72
+ sig { params(string: ::String).void }
+ def printl(string); end
+
+ # Print a string without indentation but with a `\n` at the end.
+ #
+ # source://rbi//lib/rbi/printer.rb#58
+ sig { params(string: T.nilable(::String)).void }
+ def printn(string = T.unsafe(nil)); end
+
+ # Print a string with indentation but without a `\n` at the end.
+ #
+ # source://rbi//lib/rbi/printer.rb#65
+ sig { params(string: T.nilable(::String)).void }
+ def printt(string = T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/printer.rb#83
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+
+ # source://rbi//lib/rbi/printer.rb#90
+ sig { override.params(nodes: T::Array[::RBI::Node]).void }
+ def visit_all(nodes); end
+
+ # source://rbi//lib/rbi/printer.rb#78
+ sig { params(file: ::RBI::File).void }
+ def visit_file(file); end
+end
+
+# source://rbi//lib/rbi/model.rb#982
+class RBI::Private < ::RBI::Visibility
+ # source://rbi//lib/rbi/model.rb#992
+ sig do
+ params(
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Private).void)
+ ).void
+ end
+ def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+end
+
+# source://rbi//lib/rbi/model.rb#966
+class RBI::Protected < ::RBI::Visibility
+ # source://rbi//lib/rbi/model.rb#976
+ sig do
+ params(
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Protected).void)
+ ).void
+ end
+ def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+end
+
+# source://rbi//lib/rbi/model.rb#950
+class RBI::Public < ::RBI::Visibility
+ # source://rbi//lib/rbi/model.rb#960
+ sig do
+ params(
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Public).void)
+ ).void
+ end
+ def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+end
+
+# source://rbi//lib/rbi/model.rb#652
+class RBI::ReqParam < ::RBI::Param
+ # source://rbi//lib/rbi/model.rb#663
+ sig do
+ params(
+ name: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::ReqParam).void)
+ ).void
+ end
+ def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#669
+ sig { params(other: T.nilable(::Object)).returns(T::Boolean) }
+ def ==(other); end
+end
+
+# source://rbi//lib/rbi/model.rb#1456
+class RBI::RequiresAncestor < ::RBI::NodeWithComments
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#1469
+ sig { params(name: ::String, loc: T.nilable(::RBI::Loc), comments: T::Array[::RBI::Comment]).void }
+ def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/printer.rb#870
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/index.rb#163
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/model.rb#1460
+ sig { returns(::String) }
+ def name; end
+
+ # source://rbi//lib/rbi/model.rb#1475
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/model.rb#701
+class RBI::RestParam < ::RBI::Param
+ # source://rbi//lib/rbi/model.rb#712
+ sig do
+ params(
+ name: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::RestParam).void)
+ ).void
+ end
+ def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#723
+ sig { params(other: T.nilable(::Object)).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#483
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/printer.rb#488
+ sig { override.params(v: ::RBI::Printer, last: T::Boolean).void }
+ def print_comment_leading_space(v, last:); end
+
+ # source://rbi//lib/rbi/model.rb#718
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/rewriters/add_sig_templates.rb#5
+module RBI::Rewriters; end
+
+# source://rbi//lib/rbi/rewriters/add_sig_templates.rb#6
+class RBI::Rewriters::AddSigTemplates < ::RBI::Visitor
+ # source://rbi//lib/rbi/rewriters/add_sig_templates.rb#10
+ sig { params(with_todo_comment: T::Boolean).void }
+ def initialize(with_todo_comment: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/rewriters/add_sig_templates.rb#16
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+
+ private
+
+ # source://rbi//lib/rbi/rewriters/add_sig_templates.rb#30
+ sig { params(attr: ::RBI::Attr).void }
+ def add_attr_sig(attr); end
+
+ # source://rbi//lib/rbi/rewriters/add_sig_templates.rb#45
+ sig { params(method: ::RBI::Method).void }
+ def add_method_sig(method); end
+
+ # source://rbi//lib/rbi/rewriters/add_sig_templates.rb#56
+ sig { params(node: ::RBI::NodeWithComments).void }
+ def add_todo_comment(node); end
+end
+
+# source://rbi//lib/rbi/rewriters/annotate.rb#6
+class RBI::Rewriters::Annotate < ::RBI::Visitor
+ # source://rbi//lib/rbi/rewriters/annotate.rb#10
+ sig { params(annotation: ::String, annotate_scopes: T::Boolean, annotate_properties: T::Boolean).void }
+ def initialize(annotation, annotate_scopes: T.unsafe(nil), annotate_properties: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/rewriters/annotate.rb#18
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+
+ private
+
+ # source://rbi//lib/rbi/rewriters/annotate.rb#31
+ sig { params(node: ::RBI::NodeWithComments).void }
+ def annotate_node(node); end
+
+ # source://rbi//lib/rbi/rewriters/annotate.rb#38
+ sig { params(node: ::RBI::Node).returns(T::Boolean) }
+ def root?(node); end
+end
+
+# source://rbi//lib/rbi/rewriters/deannotate.rb#6
+class RBI::Rewriters::Deannotate < ::RBI::Visitor
+ # source://rbi//lib/rbi/rewriters/deannotate.rb#10
+ sig { params(annotation: ::String).void }
+ def initialize(annotation); end
+
+ # source://rbi//lib/rbi/rewriters/deannotate.rb#16
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+
+ private
+
+ # source://rbi//lib/rbi/rewriters/deannotate.rb#27
+ sig { params(node: ::RBI::NodeWithComments).void }
+ def deannotate_node(node); end
+end
+
+# Take a gem version and filter out all RBI that is not relevant to that version based on @version annotations
+# in comments. As an example:
+#
+# ~~~rb
+# tree = Parser.parse_string(<<~RBI)
+# class Foo
+# # @version > 0.3.0
+# def bar
+# end
+#
+# # @version <= 0.3.0
+# def bar(arg1)
+# end
+# end
+# RBI
+#
+# Rewriters::FilterVersions.filter(tree, Gem::Version.new("0.3.1"))
+#
+# assert_equal(<<~RBI, tree.string)
+# class Foo
+# # @version > 0.3.0
+# def bar
+# end
+# end
+# RBI
+# ~~~
+#
+# Supported operators:
+# - equals `=`
+# - not equals `!=`
+# - greater than `>`
+# - greater than or equal to `>=`
+# - less than `<`
+# - less than or equal to `<=`
+# - pessimistic or twiddle-wakka`~>`
+#
+# And/or logic:
+# - "And" logic: put multiple versions on the same line
+# - e.g. `@version > 0.3.0, <1.0.0` means version must be greater than 0.3.0 AND less than 1.0.0
+# - "Or" logic: put multiple versions on subsequent lines
+# - e.g. the following means version must be less than 0.3.0 OR greater than 1.0.0
+# ```
+# # @version < 0.3.0
+# # @version > 1.0.0
+# ```
+# Prerelease versions:
+# - Prerelease versions are considered less than their non-prerelease counterparts
+# - e.g. `0.4.0-prerelease` is less than `0.4.0`
+#
+# RBI with no versions:
+# - RBI with no version annotations are automatically counted towards ALL versions
+#
+# source://rbi//lib/rbi/rewriters/filter_versions.rb#57
+class RBI::Rewriters::FilterVersions < ::RBI::Visitor
+ # source://rbi//lib/rbi/rewriters/filter_versions.rb#73
+ sig { params(version: ::Gem::Version).void }
+ def initialize(version); end
+
+ # source://rbi//lib/rbi/rewriters/filter_versions.rb#79
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+
+ class << self
+ # source://rbi//lib/rbi/rewriters/filter_versions.rb#66
+ sig { params(tree: ::RBI::Tree, version: ::Gem::Version).void }
+ def filter(tree, version); end
+ end
+end
+
+# source://rbi//lib/rbi/rewriters/filter_versions.rb#60
+RBI::Rewriters::FilterVersions::VERSION_PREFIX = T.let(T.unsafe(nil), String)
+
+# source://rbi//lib/rbi/rewriters/group_nodes.rb#6
+class RBI::Rewriters::GroupNodes < ::RBI::Visitor
+ # source://rbi//lib/rbi/rewriters/group_nodes.rb#10
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+end
+
+# Merge two RBI trees together
+#
+# Be this `Tree`:
+# ~~~rb
+# class Foo
+# attr_accessor :a
+# def m; end
+# C = 10
+# end
+# ~~~
+#
+# Merged with this one:
+# ~~~rb
+# class Foo
+# attr_reader :a
+# def m(x); end
+# C = 10
+# end
+# ~~~
+#
+# Compatible definitions are merged together while incompatible definitions are moved into a `ConflictTree`:
+# ~~~rb
+# class Foo
+# <<<<<<< left
+# attr_accessor :a
+# def m; end
+# =======
+# attr_reader :a
+# def m(x); end
+# >>>>>>> right
+# C = 10
+# end
+# ~~~
+#
+# source://rbi//lib/rbi/rewriters/merge_trees.rb#39
+class RBI::Rewriters::Merge
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#70
+ sig { params(left_name: ::String, right_name: ::String, keep: ::RBI::Rewriters::Merge::Keep).void }
+ def initialize(left_name: T.unsafe(nil), right_name: T.unsafe(nil), keep: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#79
+ sig { params(tree: ::RBI::Tree).void }
+ def merge(tree); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#67
+ sig { returns(::RBI::MergeTree) }
+ def tree; end
+
+ class << self
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#54
+ sig do
+ params(
+ left: ::RBI::Tree,
+ right: ::RBI::Tree,
+ left_name: ::String,
+ right_name: ::String,
+ keep: ::RBI::Rewriters::Merge::Keep
+ ).returns(::RBI::MergeTree)
+ end
+ def merge_trees(left, right, left_name: T.unsafe(nil), right_name: T.unsafe(nil), keep: T.unsafe(nil)); end
+ end
+end
+
+# Used for logging / error displaying purpose
+#
+# source://rbi//lib/rbi/rewriters/merge_trees.rb#86
+class RBI::Rewriters::Merge::Conflict < ::T::Struct
+ const :left, ::RBI::Node
+ const :right, ::RBI::Node
+ const :left_name, ::String
+ const :right_name, ::String
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#95
+ sig { returns(::String) }
+ def to_s; end
+
+ class << self
+ # source://sorbet-runtime/0.5.11531/lib/types/struct.rb#13
+ def inherited(s); end
+ end
+end
+
+# Merge adjacent conflict trees
+#
+# Transform this:
+# ~~~rb
+# class Foo
+# <<<<<<< left
+# def m1; end
+# =======
+# def m1(a); end
+# >>>>>>> right
+# <<<<<<< left
+# def m2(a); end
+# =======
+# def m2; end
+# >>>>>>> right
+# end
+# ~~~
+#
+# Into this:
+# ~~~rb
+# class Foo
+# <<<<<<< left
+# def m1; end
+# def m2(a); end
+# =======
+# def m1(a); end
+# def m2; end
+# >>>>>>> right
+# end
+# ~~~
+#
+# source://rbi//lib/rbi/rewriters/merge_trees.rb#245
+class RBI::Rewriters::Merge::ConflictTreeMerger < ::RBI::Visitor
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#247
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#252
+ sig { override.params(nodes: T::Array[::RBI::Node]).void }
+ def visit_all(nodes); end
+
+ private
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#273
+ sig { params(left: ::RBI::Tree, right: ::RBI::Tree).void }
+ def merge_conflict_trees(left, right); end
+end
+
+# source://rbi//lib/rbi/rewriters/merge_trees.rb#42
+class RBI::Rewriters::Merge::Keep < ::T::Enum
+ enums do
+ NONE = new
+ LEFT = new
+ RIGHT = new
+ end
+end
+
+# source://rbi//lib/rbi/rewriters/merge_trees.rb#100
+class RBI::Rewriters::Merge::TreeMerger < ::RBI::Visitor
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#107
+ sig do
+ params(
+ output: ::RBI::Tree,
+ left_name: ::String,
+ right_name: ::String,
+ keep: ::RBI::Rewriters::Merge::Keep
+ ).void
+ end
+ def initialize(output, left_name: T.unsafe(nil), right_name: T.unsafe(nil), keep: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#104
+ sig { returns(T::Array[::RBI::Rewriters::Merge::Conflict]) }
+ def conflicts; end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#119
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+
+ private
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#168
+ sig { returns(::RBI::Tree) }
+ def current_scope; end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#185
+ sig { params(left: ::RBI::Scope, right: ::RBI::Scope).void }
+ def make_conflict_scope(left, right); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#192
+ sig { params(left: ::RBI::Node, right: ::RBI::Node).void }
+ def make_conflict_tree(left, right); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#173
+ sig { params(node: ::RBI::Node).returns(T.nilable(::RBI::Node)) }
+ def previous_definition(node); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#204
+ sig { params(left: ::RBI::Scope, right: ::RBI::Scope).returns(::RBI::Scope) }
+ def replace_scope_header(left, right); end
+end
+
+# source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#6
+class RBI::Rewriters::NestNonPublicMethods < ::RBI::Visitor
+ # source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#10
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+end
+
+# source://rbi//lib/rbi/rewriters/nest_singleton_methods.rb#6
+class RBI::Rewriters::NestSingletonMethods < ::RBI::Visitor
+ # source://rbi//lib/rbi/rewriters/nest_singleton_methods.rb#10
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+end
+
+# Remove all definitions existing in the index from the current tree
+#
+# Let's create an `Index` from two different `Tree`s:
+# ~~~rb
+# tree1 = Parse.parse_string(<<~RBI)
+# class Foo
+# def foo; end
+# end
+# RBI
+#
+# tree2 = Parse.parse_string(<<~RBI)
+# FOO = 10
+# RBI
+#
+# index = Index.index(tree1, tree2)
+# ~~~
+#
+# We can use `RemoveKnownDefinitions` to remove the definitions found in the `index` from the `Tree` to clean:
+# ~~~rb
+# tree_to_clean = Parser.parse_string(<<~RBI)
+# class Foo
+# def foo; end
+# def bar; end
+# end
+# FOO = 10
+# BAR = 42
+# RBI
+#
+# cleaned_tree, operations = RemoveKnownDefinitions.remove(tree_to_clean, index)
+#
+# assert_equal(<<~RBI, cleaned_tree)
+# class Foo
+# def bar; end
+# end
+# BAR = 42
+# RBI
+#
+# assert_equal(<<~OPERATIONS, operations.join("\n"))
+# Deleted ::Foo#foo at -:2:2-2-16 (duplicate from -:2:2-2:16)
+# Deleted ::FOO at -:5:0-5:8 (duplicate from -:1:0-1:8)
+# OPERATIONS
+# ~~~
+#
+# source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#48
+class RBI::Rewriters::RemoveKnownDefinitions < ::RBI::Visitor
+ # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#55
+ sig { params(index: ::RBI::Index).void }
+ def initialize(index); end
+
+ # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#52
+ sig { returns(T::Array[::RBI::Rewriters::RemoveKnownDefinitions::Operation]) }
+ def operations; end
+
+ # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#83
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+
+ # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#78
+ sig { params(nodes: T::Array[::RBI::Node]).void }
+ def visit_all(nodes); end
+
+ private
+
+ # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#111
+ sig { params(node: ::RBI::Node, previous: ::RBI::Node).returns(T::Boolean) }
+ def can_delete_node?(node, previous); end
+
+ # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#129
+ sig { params(node: ::RBI::Node, previous: ::RBI::Node).void }
+ def delete_node(node, previous); end
+
+ # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#102
+ sig { params(node: ::RBI::Indexable).returns(T.nilable(::RBI::Node)) }
+ def previous_definition_for(node); end
+
+ class << self
+ # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#70
+ sig do
+ params(
+ tree: ::RBI::Tree,
+ index: ::RBI::Index
+ ).returns([::RBI::Tree, T::Array[::RBI::Rewriters::RemoveKnownDefinitions::Operation]])
+ end
+ def remove(tree, index); end
+ end
+end
+
+# source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#134
+class RBI::Rewriters::RemoveKnownDefinitions::Operation < ::T::Struct
+ const :deleted_node, ::RBI::Node
+ const :duplicate_of, ::RBI::Node
+
+ # source://rbi//lib/rbi/rewriters/remove_known_definitions.rb#141
+ sig { returns(::String) }
+ def to_s; end
+
+ class << self
+ # source://sorbet-runtime/0.5.11531/lib/types/struct.rb#13
+ def inherited(s); end
+ end
+end
+
+# source://rbi//lib/rbi/rewriters/sort_nodes.rb#6
+class RBI::Rewriters::SortNodes < ::RBI::Visitor
+ # source://rbi//lib/rbi/rewriters/sort_nodes.rb#10
+ sig { override.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+
+ private
+
+ # source://rbi//lib/rbi/rewriters/sort_nodes.rb#73
+ sig { params(kind: ::RBI::Group::Kind).returns(::Integer) }
+ def group_rank(kind); end
+
+ # source://rbi//lib/rbi/rewriters/sort_nodes.rb#94
+ sig { params(node: ::RBI::Node).returns(T.nilable(::String)) }
+ def node_name(node); end
+
+ # source://rbi//lib/rbi/rewriters/sort_nodes.rb#45
+ sig { params(node: ::RBI::Node).returns(::Integer) }
+ def node_rank(node); end
+
+ # source://rbi//lib/rbi/rewriters/sort_nodes.rb#106
+ sig { params(node: ::RBI::Node).void }
+ def sort_node_names!(node); end
+end
+
+# Scopes
+#
+# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below.
+#
+# source://rbi//lib/rbi/model.rb#176
+class RBI::Scope < ::RBI::Tree
+ include ::RBI::Indexable
+
+ abstract!
+
+ # source://rbi//lib/rbi/printer.rb#242
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # Duplicate `self` scope without its body
+ #
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#356
+ sig { returns(T.self_type) }
+ def dup_empty; end
+
+ # @abstract
+ #
+ # source://rbi//lib/rbi/model.rb#182
+ sig { abstract.returns(::String) }
+ def fully_qualified_name; end
+
+ # source://rbi//lib/rbi/index.rb#93
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/printer.rb#256
+ sig { params(v: ::RBI::Printer).void }
+ def print_body(v); end
+
+ # @abstract
+ #
+ # source://rbi//lib/rbi/printer.rb#253
+ sig { abstract.params(v: ::RBI::Printer).void }
+ def print_header(v); end
+
+ # source://rbi//lib/rbi/model.rb#185
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# A conflict between two scope headers
+#
+# Is rendered as a merge conflict between `left` and` right` for scope definitions:
+# ~~~rb
+# <<<<<<< left
+# class Foo
+# =======
+# module Foo
+# >>>>>>> right
+# def m1; end
+# end
+# ~~~
+#
+# source://rbi//lib/rbi/rewriters/merge_trees.rb#628
+class RBI::ScopeConflict < ::RBI::Tree
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#642
+ sig { params(left: ::RBI::Scope, right: ::RBI::Scope, left_name: ::String, right_name: ::String).void }
+ def initialize(left:, right:, left_name: T.unsafe(nil), right_name: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#651
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#632
+ sig { returns(::RBI::Scope) }
+ def left; end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#667
+ sig { override.returns(T::Boolean) }
+ def oneline?; end
+
+ # @return [Scope]
+ #
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#632
+ def right; end
+end
+
+# Sends
+#
+# source://rbi//lib/rbi/model.rb#1000
+class RBI::Send < ::RBI::NodeWithComments
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#1018
+ sig do
+ params(
+ method: ::String,
+ args: T::Array[::RBI::Arg],
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Send).void)
+ ).void
+ end
+ def initialize(method, args = T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#1026
+ sig { params(arg: ::RBI::Arg).void }
+ def <<(arg); end
+
+ # source://rbi//lib/rbi/model.rb#1031
+ sig { params(other: T.nilable(::Object)).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#592
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/model.rb#1007
+ sig { returns(T::Array[::RBI::Arg]) }
+ def args; end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#529
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/index.rb#193
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/model.rb#1004
+ sig { returns(::String) }
+ def method; end
+
+ # source://rbi//lib/rbi/model.rb#1036
+ sig { returns(::String) }
+ def to_s; end
+end
+
+# Sorbet's sigs
+#
+# source://rbi//lib/rbi/model.rb#1100
+class RBI::Sig < ::RBI::Node
+ # source://rbi//lib/rbi/model.rb#1132
+ sig do
+ params(
+ params: T::Array[::RBI::SigParam],
+ return_type: T.nilable(::String),
+ is_abstract: T::Boolean,
+ is_override: T::Boolean,
+ is_overridable: T::Boolean,
+ is_final: T::Boolean,
+ type_params: T::Array[::String],
+ checked: T.nilable(::Symbol),
+ loc: T.nilable(::RBI::Loc),
+ block: T.nilable(T.proc.params(node: ::RBI::Sig).void)
+ ).void
+ end
+ def initialize(params: T.unsafe(nil), return_type: T.unsafe(nil), is_abstract: T.unsafe(nil), is_override: T.unsafe(nil), is_overridable: T.unsafe(nil), is_final: T.unsafe(nil), type_params: T.unsafe(nil), checked: T.unsafe(nil), loc: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#1157
+ sig { params(param: ::RBI::SigParam).void }
+ def <<(param); end
+
+ # source://rbi//lib/rbi/model.rb#1167
+ sig { params(other: ::Object).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#633
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/model.rb#1162
+ sig { params(name: ::String, type: ::String).void }
+ def add_param(name, type); end
+
+ # source://rbi//lib/rbi/model.rb#1116
+ sig { returns(T.nilable(::Symbol)) }
+ def checked; end
+
+ # @return [Symbol, nil]
+ #
+ # source://rbi//lib/rbi/model.rb#1116
+ def checked=(_arg0); end
+
+ # source://rbi//lib/rbi/printer.rb#656
+ sig { returns(T::Boolean) }
+ def inline_params?; end
+
+ # source://rbi//lib/rbi/model.rb#1110
+ sig { returns(T::Boolean) }
+ def is_abstract; end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/model.rb#1110
+ def is_abstract=(_arg0); end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/model.rb#1110
+ def is_final; end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/model.rb#1110
+ def is_final=(_arg0); end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/model.rb#1110
+ def is_overridable; end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/model.rb#1110
+ def is_overridable=(_arg0); end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/model.rb#1110
+ def is_override; end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/model.rb#1110
+ def is_override=(_arg0); end
+
+ # source://rbi//lib/rbi/printer.rb#651
+ sig { override.returns(T::Boolean) }
+ def oneline?; end
+
+ # source://rbi//lib/rbi/model.rb#1104
+ sig { returns(T::Array[::RBI::SigParam]) }
+ def params; end
+
+ # source://rbi//lib/rbi/model.rb#1107
+ sig { returns(T.nilable(::String)) }
+ def return_type; end
+
+ # @return [String, nil]
+ #
+ # source://rbi//lib/rbi/model.rb#1107
+ def return_type=(_arg0); end
+
+ # source://rbi//lib/rbi/model.rb#1113
+ sig { returns(T::Array[::String]) }
+ def type_params; end
+
+ private
+
+ # source://rbi//lib/rbi/printer.rb#698
+ sig { params(v: ::RBI::Printer).void }
+ def print_as_block(v); end
+
+ # source://rbi//lib/rbi/printer.rb#674
+ sig { params(v: ::RBI::Printer).void }
+ def print_as_line(v); end
+
+ # source://rbi//lib/rbi/printer.rb#663
+ sig { returns(T::Array[::String]) }
+ def sig_modifiers; end
+end
+
+# source://rbi//lib/rbi/model.rb#1176
+class RBI::SigParam < ::RBI::NodeWithComments
+ # source://rbi//lib/rbi/model.rb#1191
+ sig do
+ params(
+ name: ::String,
+ type: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::SigParam).void)
+ ).void
+ end
+ def initialize(name, type, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#1199
+ sig { params(other: ::Object).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#751
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/printer.rb#764
+ sig { returns(T::Array[::String]) }
+ def comments_lines; end
+
+ # source://rbi//lib/rbi/model.rb#1180
+ sig { returns(::String) }
+ def name; end
+
+ # source://rbi//lib/rbi/printer.rb#756
+ sig { params(v: ::RBI::Printer, last: T::Boolean).void }
+ def print_comment_leading_space(v, last:); end
+
+ # @return [String]
+ #
+ # source://rbi//lib/rbi/model.rb#1180
+ def type; end
+end
+
+# source://rbi//lib/rbi/model.rb#251
+class RBI::SingletonClass < ::RBI::Scope
+ # source://rbi//lib/rbi/model.rb#261
+ sig do
+ params(
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::SingletonClass).void)
+ ).void
+ end
+ def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#267
+ sig { override.returns(::String) }
+ def fully_qualified_name; end
+
+ # source://rbi//lib/rbi/printer.rb#321
+ sig { override.params(v: ::RBI::Printer).void }
+ def print_header(v); end
+end
+
+# source://rbi//lib/rbi/model.rb#272
+class RBI::Struct < ::RBI::Scope
+ # source://rbi//lib/rbi/model.rb#294
+ sig do
+ params(
+ name: ::String,
+ members: T::Array[::Symbol],
+ keyword_init: T::Boolean,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(struct: ::RBI::Struct).void)
+ ).void
+ end
+ def initialize(name, members: T.unsafe(nil), keyword_init: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#394
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#303
+ sig { override.returns(::String) }
+ def fully_qualified_name; end
+
+ # source://rbi//lib/rbi/model.rb#282
+ sig { returns(T::Boolean) }
+ def keyword_init; end
+
+ # @return [Boolean]
+ #
+ # source://rbi//lib/rbi/model.rb#282
+ def keyword_init=(_arg0); end
+
+ # source://rbi//lib/rbi/model.rb#279
+ sig { returns(T::Array[::Symbol]) }
+ def members; end
+
+ # @return [Array]
+ #
+ # source://rbi//lib/rbi/model.rb#279
+ def members=(_arg0); end
+
+ # source://rbi//lib/rbi/model.rb#276
+ sig { returns(::String) }
+ def name; end
+
+ # @return [String]
+ #
+ # source://rbi//lib/rbi/model.rb#276
+ def name=(_arg0); end
+
+ # source://rbi//lib/rbi/printer.rb#300
+ sig { override.params(v: ::RBI::Printer).void }
+ def print_header(v); end
+end
+
+# Sorbet's T::Enum
+#
+# source://rbi//lib/rbi/model.rb#1317
+class RBI::TEnum < ::RBI::Class
+ # source://rbi//lib/rbi/model.rb#1328
+ sig do
+ params(
+ name: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(klass: ::RBI::TEnum).void)
+ ).void
+ end
+ def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+end
+
+# source://rbi//lib/rbi/model.rb#1334
+class RBI::TEnumBlock < ::RBI::NodeWithComments
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#1348
+ sig do
+ params(
+ names: T::Array[::String],
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::TEnumBlock).void)
+ ).void
+ end
+ def initialize(names = T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#1360
+ sig { params(name: ::String).void }
+ def <<(name); end
+
+ # source://rbi//lib/rbi/printer.rb#795
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/model.rb#1355
+ sig { returns(T::Boolean) }
+ def empty?; end
+
+ # source://rbi//lib/rbi/index.rb#223
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#556
+ sig { override.params(other: ::RBI::Node).void }
+ def merge_with(other); end
+
+ # source://rbi//lib/rbi/model.rb#1338
+ sig { returns(T::Array[::String]) }
+ def names; end
+
+ # source://rbi//lib/rbi/model.rb#1365
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# Sorbet's T::Struct
+#
+# source://rbi//lib/rbi/model.rb#1206
+class RBI::TStruct < ::RBI::Class
+ # source://rbi//lib/rbi/model.rb#1217
+ sig do
+ params(
+ name: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(klass: ::RBI::TStruct).void)
+ ).void
+ end
+ def initialize(name, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+end
+
+# source://rbi//lib/rbi/model.rb#1255
+class RBI::TStructConst < ::RBI::TStructField
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#1268
+ sig do
+ params(
+ name: ::String,
+ type: ::String,
+ default: T.nilable(::String),
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::TStructConst).void)
+ ).void
+ end
+ def initialize(name, type, default: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#547
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#1274
+ sig { override.returns(T::Array[::String]) }
+ def fully_qualified_names; end
+
+ # source://rbi//lib/rbi/index.rb#203
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/model.rb#1280
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below.
+#
+# source://rbi//lib/rbi/model.rb#1223
+class RBI::TStructField < ::RBI::NodeWithComments
+ abstract!
+
+ # source://rbi//lib/rbi/model.rb#1244
+ sig do
+ params(
+ name: ::String,
+ type: ::String,
+ default: T.nilable(::String),
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment]
+ ).void
+ end
+ def initialize(name, type, default: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/printer.rb#773
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#538
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#1233
+ sig { returns(T.nilable(::String)) }
+ def default; end
+
+ # @return [String, nil]
+ #
+ # source://rbi//lib/rbi/model.rb#1233
+ def default=(_arg0); end
+
+ # @abstract
+ #
+ # source://rbi//lib/rbi/model.rb#1252
+ sig { abstract.returns(T::Array[::String]) }
+ def fully_qualified_names; end
+
+ # source://rbi//lib/rbi/model.rb#1230
+ sig { returns(::String) }
+ def name; end
+
+ # @return [String]
+ #
+ # source://rbi//lib/rbi/model.rb#1230
+ def name=(_arg0); end
+
+ # @return [String]
+ #
+ # source://rbi//lib/rbi/model.rb#1230
+ def type; end
+
+ # @return [String]
+ #
+ # source://rbi//lib/rbi/model.rb#1230
+ def type=(_arg0); end
+end
+
+# source://rbi//lib/rbi/model.rb#1285
+class RBI::TStructProp < ::RBI::TStructField
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#1298
+ sig do
+ params(
+ name: ::String,
+ type: ::String,
+ default: T.nilable(::String),
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::TStructProp).void)
+ ).void
+ end
+ def initialize(name, type, default: T.unsafe(nil), loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#570
+ sig { override.params(other: ::RBI::Node).returns(T::Boolean) }
+ def compatible_with?(other); end
+
+ # source://rbi//lib/rbi/model.rb#1304
+ sig { override.returns(T::Array[::String]) }
+ def fully_qualified_names; end
+
+ # source://rbi//lib/rbi/index.rb#213
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/model.rb#1310
+ sig { override.returns(::String) }
+ def to_s; end
+end
+
+# source://rbi//lib/rbi/model.rb#106
+class RBI::Tree < ::RBI::NodeWithComments
+ # source://rbi//lib/rbi/model.rb#119
+ sig do
+ params(
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::Tree).void)
+ ).void
+ end
+ def initialize(loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/model.rb#126
+ sig { params(node: ::RBI::Node).void }
+ def <<(node); end
+
+ # source://rbi//lib/rbi/printer.rb#226
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/rewriters/add_sig_templates.rb#66
+ sig { params(with_todo_comment: T::Boolean).void }
+ def add_sig_templates!(with_todo_comment: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/rewriters/annotate.rb#49
+ sig { params(annotation: ::String, annotate_scopes: T::Boolean, annotate_properties: T::Boolean).void }
+ def annotate!(annotation, annotate_scopes: T.unsafe(nil), annotate_properties: T.unsafe(nil)); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#38
+ sig do
+ params(
+ name: ::String,
+ superclass_name: T.nilable(::String),
+ block: T.nilable(T.proc.params(scope: ::RBI::Scope).void)
+ ).returns(::RBI::Scope)
+ end
+ def create_class(name, superclass_name: T.unsafe(nil), &block); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#45
+ sig { params(name: ::String, value: ::String).void }
+ def create_constant(name, value:); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#55
+ sig { params(name: ::String).void }
+ def create_extend(name); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#50
+ sig { params(name: ::String).void }
+ def create_include(name); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#89
+ sig do
+ params(
+ name: ::String,
+ parameters: T::Array[::RBI::TypedParam],
+ return_type: ::String,
+ class_method: T::Boolean,
+ visibility: ::RBI::Visibility,
+ comments: T::Array[::RBI::Comment]
+ ).void
+ end
+ def create_method(name, parameters: T.unsafe(nil), return_type: T.unsafe(nil), class_method: T.unsafe(nil), visibility: T.unsafe(nil), comments: T.unsafe(nil)); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#113
+ sig do
+ params(
+ name: ::String,
+ sigs: T::Array[::RBI::Sig],
+ parameters: T::Array[::RBI::Param],
+ class_method: T::Boolean,
+ visibility: ::RBI::Visibility,
+ comments: T::Array[::RBI::Comment]
+ ).void
+ end
+ def create_method_with_sigs(name, sigs:, parameters: T.unsafe(nil), class_method: T.unsafe(nil), visibility: T.unsafe(nil), comments: T.unsafe(nil)); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#60
+ sig { params(name: ::String).void }
+ def create_mixes_in_class_methods(name); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#25
+ sig { params(name: ::String, block: T.nilable(T.proc.params(scope: ::RBI::Scope).void)).returns(::RBI::Scope) }
+ def create_module(name, &block); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#9
+ sig { params(constant: ::Module, block: T.nilable(T.proc.params(scope: ::RBI::Scope).void)).returns(::RBI::Scope) }
+ def create_path(constant, &block); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#135
+ sig do
+ params(
+ parameters: T::Hash[T.any(::String, ::Symbol), ::String],
+ type_parameters: T::Array[::String],
+ return_type: ::String
+ ).returns(::RBI::Sig)
+ end
+ def create_sig(parameters:, type_parameters: T.unsafe(nil), return_type: T.unsafe(nil)); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#74
+ sig do
+ params(
+ name: ::String,
+ type: ::String,
+ variance: ::Symbol,
+ fixed: T.nilable(::String),
+ upper: T.nilable(::String),
+ lower: T.nilable(::String)
+ ).void
+ end
+ def create_type_variable(name, type:, variance: T.unsafe(nil), fixed: T.unsafe(nil), upper: T.unsafe(nil), lower: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/rewriters/deannotate.rb#41
+ sig { params(annotation: ::String).void }
+ def deannotate!(annotation); end
+
+ # source://rbi//lib/rbi/model.rb#132
+ sig { returns(T::Boolean) }
+ def empty?; end
+
+ # source://rbi//lib/rbi/rewriters/filter_versions.rb#118
+ sig { params(version: ::Gem::Version).void }
+ def filter_versions!(version); end
+
+ # source://rbi//lib/rbi/rewriters/group_nodes.rb#38
+ sig { void }
+ def group_nodes!; end
+
+ # source://rbi//lib/rbi/index.rb#68
+ sig { returns(::RBI::Index) }
+ def index; end
+
+ # source://rbi//lib/rbi/rewriters/merge_trees.rb#324
+ sig do
+ params(
+ other: ::RBI::Tree,
+ left_name: ::String,
+ right_name: ::String,
+ keep: ::RBI::Rewriters::Merge::Keep
+ ).returns(::RBI::MergeTree)
+ end
+ def merge(other, left_name: T.unsafe(nil), right_name: T.unsafe(nil), keep: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#46
+ sig { void }
+ def nest_non_public_methods!; end
+
+ # source://rbi//lib/rbi/rewriters/nest_singleton_methods.rb#36
+ sig { void }
+ def nest_singleton_methods!; end
+
+ # source://rbi//lib/rbi/model.rb#110
+ sig { returns(T::Array[::RBI::Node]) }
+ def nodes; end
+
+ # source://rbi//lib/rbi/printer.rb#233
+ sig { override.returns(T::Boolean) }
+ def oneline?; end
+
+ # source://rbi//lib/rbi/rewriters/sort_nodes.rb#119
+ sig { void }
+ def sort_nodes!; end
+
+ private
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#150
+ sig { params(node: ::RBI::Node).returns(::RBI::Node) }
+ def create_node(node); end
+
+ # source://tapioca/0.15.1/lib/tapioca/rbi_ext/model.rb#145
+ sig { returns(T::Hash[::String, ::RBI::Node]) }
+ def nodes_cache; end
+end
+
+# source://rbi//lib/rbi/model.rb#1398
+class RBI::TypeMember < ::RBI::NodeWithComments
+ include ::RBI::Indexable
+
+ # source://rbi//lib/rbi/model.rb#1413
+ sig do
+ params(
+ name: ::String,
+ value: ::String,
+ loc: T.nilable(::RBI::Loc),
+ comments: T::Array[::RBI::Comment],
+ block: T.nilable(T.proc.params(node: ::RBI::TypeMember).void)
+ ).void
+ end
+ def initialize(name, value, loc: T.unsafe(nil), comments: T.unsafe(nil), &block); end
+
+ # source://rbi//lib/rbi/printer.rb#812
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/model.rb#1421
+ sig { returns(::String) }
+ def fully_qualified_name; end
+
+ # source://rbi//lib/rbi/index.rb#183
+ sig { override.returns(T::Array[::String]) }
+ def index_ids; end
+
+ # source://rbi//lib/rbi/model.rb#1402
+ sig { returns(::String) }
+ def name; end
+
+ # source://rbi//lib/rbi/model.rb#1428
+ sig { override.returns(::String) }
+ def to_s; end
+
+ # @return [String]
+ #
+ # source://rbi//lib/rbi/model.rb#1402
+ def value; end
+end
+
+# source://rbi//lib/rbi/parser.rb#20
+class RBI::UnexpectedParserError < ::StandardError
+ # source://rbi//lib/rbi/parser.rb#27
+ sig { params(parent_exception: ::Exception, last_location: ::RBI::Loc).void }
+ def initialize(parent_exception, last_location); end
+
+ # source://rbi//lib/rbi/parser.rb#24
+ sig { returns(::RBI::Loc) }
+ def last_location; end
+
+ # source://rbi//lib/rbi/parser.rb#34
+ sig { params(io: T.any(::IO, ::StringIO)).void }
+ def print_debug(io: T.unsafe(nil)); end
+end
+
+# source://rbi//lib/rbi/version.rb#5
+RBI::VERSION = T.let(T.unsafe(nil), String)
+
+# Visibility
+#
+# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below.
+#
+# source://rbi//lib/rbi/model.rb#914
+class RBI::Visibility < ::RBI::NodeWithComments
+ abstract!
+
+ # source://rbi//lib/rbi/model.rb#924
+ sig { params(visibility: ::Symbol, loc: T.nilable(::RBI::Loc), comments: T::Array[::RBI::Comment]).void }
+ def initialize(visibility, loc: T.unsafe(nil), comments: T.unsafe(nil)); end
+
+ # source://rbi//lib/rbi/model.rb#930
+ sig { params(other: ::RBI::Visibility).returns(T::Boolean) }
+ def ==(other); end
+
+ # source://rbi//lib/rbi/printer.rb#579
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/model.rb#945
+ sig { returns(T::Boolean) }
+ def private?; end
+
+ # source://rbi//lib/rbi/model.rb#940
+ sig { returns(T::Boolean) }
+ def protected?; end
+
+ # source://rbi//lib/rbi/model.rb#935
+ sig { returns(T::Boolean) }
+ def public?; end
+
+ # source://rbi//lib/rbi/model.rb#921
+ sig { returns(::Symbol) }
+ def visibility; end
+end
+
+# source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#52
+class RBI::VisibilityGroup < ::RBI::Tree
+ # source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#59
+ sig { params(visibility: ::RBI::Visibility).void }
+ def initialize(visibility); end
+
+ # source://rbi//lib/rbi/printer.rb#848
+ sig { override.params(v: ::RBI::Printer).void }
+ def accept_printer(v); end
+
+ # source://rbi//lib/rbi/printer.rb#861
+ sig { override.returns(T::Boolean) }
+ def oneline?; end
+
+ # source://rbi//lib/rbi/rewriters/nest_non_public_methods.rb#56
+ sig { returns(::RBI::Visibility) }
+ def visibility; end
+end
+
+# @abstract It cannot be directly instantiated. Subclasses must implement the `abstract` methods below.
+#
+# source://rbi//lib/rbi/visitor.rb#5
+class RBI::Visitor
+ abstract!
+
+ # @abstract
+ #
+ # source://rbi//lib/rbi/visitor.rb#12
+ sig { abstract.params(node: T.nilable(::RBI::Node)).void }
+ def visit(node); end
+
+ # source://rbi//lib/rbi/visitor.rb#15
+ sig { params(nodes: T::Array[::RBI::Node]).void }
+ def visit_all(nodes); end
+end
diff --git a/sorbet/rbi/gems/rspec-core@3.13.0.rbi b/sorbet/rbi/gems/rspec-core@3.13.0.rbi
new file mode 100644
index 0000000..2503560
--- /dev/null
+++ b/sorbet/rbi/gems/rspec-core@3.13.0.rbi
@@ -0,0 +1,10883 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `rspec-core` gem.
+# Please instead update this file by running `bin/tapioca gem rspec-core`.
+
+
+module ERB::Escape
+ private
+
+ def html_escape(_arg0); end
+
+ class << self
+ def html_escape(_arg0); end
+ end
+end
+
+# Namespace for all core RSpec code.
+#
+# source://rspec-core//lib/rspec/core/version.rb#1
+module RSpec
+ extend ::RSpec::Core::Warnings
+
+ class << self
+ # Used to ensure examples get reloaded between multiple runs in the same
+ # process and ensures user configuration is persisted.
+ #
+ # Users must invoke this if they want to clear all examples but preserve
+ # current configuration when they use the runner multiple times within the
+ # same process.
+ #
+ # source://rspec-core//lib/rspec/core.rb#70
+ def clear_examples; end
+
+ # Returns the global [Configuration](RSpec/Core/Configuration) object. While
+ # you _can_ use this method to access the configuration, the more common
+ # convention is to use [RSpec.configure](RSpec#configure-class_method).
+ #
+ # @example
+ # RSpec.configuration.drb_port = 1234
+ # @see RSpec.configure
+ # @see Core::Configuration
+ #
+ # source://rspec-core//lib/rspec/core.rb#85
+ def configuration; end
+
+ # Setters for shared global objects
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core.rb#49
+ def configuration=(_arg0); end
+
+ # Yields the global configuration to a block.
+ #
+ # @example
+ # RSpec.configure do |config|
+ # config.add_formatter 'documentation'
+ # end
+ # @see Core::Configuration
+ # @yield [Configuration] global configuration
+ #
+ # source://rspec-core//lib/rspec/core.rb#97
+ def configure; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core.rb#194
+ def const_missing(name); end
+
+ # source://rspec-core//lib/rspec/core/dsl.rb#42
+ def context(*args, &example_group_block); end
+
+ # The example being executed.
+ #
+ # The primary audience for this method is library authors who need access
+ # to the example currently being executed and also want to support all
+ # versions of RSpec 2 and 3.
+ #
+ # @example
+ #
+ # RSpec.configure do |c|
+ # # context.example is deprecated, but RSpec.current_example is not
+ # # available until RSpec 3.0.
+ # fetch_current_example = RSpec.respond_to?(:current_example) ?
+ # proc { RSpec.current_example } : proc { |context| context.example }
+ #
+ # c.before(:example) do
+ # example = fetch_current_example.call(self)
+ #
+ # # ...
+ # end
+ # end
+ #
+ # source://rspec-core//lib/rspec/core.rb#122
+ def current_example; end
+
+ # Set the current example being executed.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core.rb#128
+ def current_example=(example); end
+
+ # Get the current RSpec execution scope
+ #
+ # Returns (in order of lifecycle):
+ # * `:suite` as an initial value, this is outside of the test lifecycle.
+ # * `:before_suite_hook` during `before(:suite)` hooks.
+ # * `:before_context_hook` during `before(:context)` hooks.
+ # * `:before_example_hook` during `before(:example)` hooks and `around(:example)` before `example.run`.
+ # * `:example` within the example run.
+ # * `:after_example_hook` during `after(:example)` hooks and `around(:example)` after `example.run`.
+ # * `:after_context_hook` during `after(:context)` hooks.
+ # * `:after_suite_hook` during `after(:suite)` hooks.
+ # * `:suite` as a final value, again this is outside of the test lifecycle.
+ #
+ # Reminder, `:context` hooks have `:all` alias and `:example` hooks have `:each` alias.
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core.rb#154
+ def current_scope; end
+
+ # Set the current scope rspec is executing in
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core.rb#134
+ def current_scope=(scope); end
+
+ # source://rspec-core//lib/rspec/core/dsl.rb#42
+ def describe(*args, &example_group_block); end
+
+ # source://rspec-core//lib/rspec/core/dsl.rb#42
+ def example_group(*args, &example_group_block); end
+
+ # source://rspec-core//lib/rspec/core/dsl.rb#42
+ def fcontext(*args, &example_group_block); end
+
+ # source://rspec-core//lib/rspec/core/dsl.rb#42
+ def fdescribe(*args, &example_group_block); end
+
+ # Used to ensure examples get reloaded and user configuration gets reset to
+ # defaults between multiple runs in the same process.
+ #
+ # Users must invoke this if they want to have the configuration reset when
+ # they use the runner multiple times within the same process. Users must deal
+ # themselves with re-configuration of RSpec before run.
+ #
+ # source://rspec-core//lib/rspec/core.rb#58
+ def reset; end
+
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#110
+ def shared_context(name, *args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#110
+ def shared_examples(name, *args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#110
+ def shared_examples_for(name, *args, &block); end
+
+ # Internal container for global non-configuration data.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core.rb#160
+ def world; end
+
+ # Setters for shared global objects
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core.rb#49
+ def world=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/dsl.rb#42
+ def xcontext(*args, &example_group_block); end
+
+ # source://rspec-core//lib/rspec/core/dsl.rb#42
+ def xdescribe(*args, &example_group_block); end
+ end
+end
+
+# Namespace for the rspec-core code.
+#
+# source://rspec-core//lib/rspec/core/version.rb#2
+module RSpec::Core
+ class << self
+ # @private path to executable file.
+ #
+ # source://rspec-core//lib/rspec/core.rb#181
+ def path_to_executable; end
+ end
+end
+
+# Unnamed example group used by `SuiteHookContext`.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/example_group.rb#775
+class RSpec::Core::AnonymousExampleGroup < ::RSpec::Core::ExampleGroup
+ class << self
+ # source://rspec-core//lib/rspec/core/example_group.rb#776
+ def metadata; end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/backtrace_formatter.rb#4
+class RSpec::Core::BacktraceFormatter
+ # @return [BacktraceFormatter] a new instance of BacktraceFormatter
+ #
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#8
+ def initialize; end
+
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#49
+ def backtrace_line(line); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#53
+ def exclude?(line); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#6
+ def exclusion_patterns; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#6
+ def exclusion_patterns=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#28
+ def filter_gem(gem_name); end
+
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#33
+ def format_backtrace(backtrace, options = T.unsafe(nil)); end
+
+ # Sets the attribute full_backtrace
+ #
+ # @param value the value to set the attribute full_backtrace to.
+ #
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#22
+ def full_backtrace=(_arg0); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#24
+ def full_backtrace?; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#6
+ def inclusion_patterns; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#6
+ def inclusion_patterns=(_arg0); end
+
+ private
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/backtrace_formatter.rb#60
+ def matches?(patterns, line); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/bisect/utilities.rb#3
+module RSpec::Core::Bisect; end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/bisect/utilities.rb#8
+class RSpec::Core::Bisect::BisectFailedError < ::StandardError
+ class << self
+ # source://rspec-core//lib/rspec/core/bisect/utilities.rb#9
+ def for_failed_spec_run(spec_output); end
+ end
+end
+
+# Wraps a pipe to support sending objects between a child and
+# parent process. Where supported, encoding is explicitly
+# set to ensure binary data is able to pass from child to
+# parent.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/bisect/utilities.rb#36
+class RSpec::Core::Bisect::Channel
+ # @return [Channel] a new instance of Channel
+ #
+ # source://rspec-core//lib/rspec/core/bisect/utilities.rb#41
+ def initialize; end
+
+ # source://rspec-core//lib/rspec/core/bisect/utilities.rb#62
+ def close; end
+
+ # source://rspec-core//lib/rspec/core/bisect/utilities.rb#56
+ def receive; end
+
+ # source://rspec-core//lib/rspec/core/bisect/utilities.rb#50
+ def send(message); end
+end
+
+# source://rspec-core//lib/rspec/core/bisect/utilities.rb#38
+RSpec::Core::Bisect::Channel::MARSHAL_DUMP_ENCODING = T.let(T.unsafe(nil), Encoding)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/bisect/utilities.rb#5
+class RSpec::Core::Bisect::ExampleSetDescriptor < ::Struct
+ # Returns the value of attribute all_example_ids
+ #
+ # @return [Object] the current value of all_example_ids
+ def all_example_ids; end
+
+ # Sets the attribute all_example_ids
+ #
+ # @param value [Object] the value to set the attribute all_example_ids to.
+ # @return [Object] the newly set value
+ def all_example_ids=(_); end
+
+ # Returns the value of attribute failed_example_ids
+ #
+ # @return [Object] the current value of failed_example_ids
+ def failed_example_ids; end
+
+ # Sets the attribute failed_example_ids
+ #
+ # @param value [Object] the value to set the attribute failed_example_ids to.
+ # @return [Object] the newly set value
+ def failed_example_ids=(_); end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# Wraps a `formatter` providing a simple means to notify it in place
+# of an `RSpec::Core::Reporter`, without involving configuration in
+# any way.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/bisect/utilities.rb#19
+class RSpec::Core::Bisect::Notifier
+ # @return [Notifier] a new instance of Notifier
+ #
+ # source://rspec-core//lib/rspec/core/bisect/utilities.rb#20
+ def initialize(formatter); end
+
+ # source://rspec-core//lib/rspec/core/bisect/utilities.rb#24
+ def publish(event, *args); end
+end
+
+# Stores runtime configuration information.
+#
+# Configuration options are loaded from multiple files and joined together
+# with command-line switches and the `SPEC_OPTS` environment variable.
+#
+# Precedence order (where later entries overwrite earlier entries on
+# conflicts):
+#
+# * Global (`$XDG_CONFIG_HOME/rspec/options`, or `~/.rspec` if it does
+# not exist)
+# * Project-specific (`./.rspec`)
+# * Local (`./.rspec-local`)
+# * Command-line options
+# * `SPEC_OPTS`
+#
+# For example, an option set in the local file will override an option set
+# in your global file.
+#
+# The global, project-specific and local files can all be overridden with a
+# separate custom file using the --options command-line parameter.
+#
+# @example Standard settings
+# RSpec.configure do |c|
+# c.drb = true
+# c.drb_port = 1234
+# c.default_path = 'behavior'
+# end
+# @example Hooks
+# RSpec.configure do |c|
+# c.before(:suite) { establish_connection }
+# c.before(:example) { log_in_as :authorized }
+# c.around(:example) { |ex| Database.transaction(&ex) }
+# end
+# @see RSpec.configure
+# @see Hooks
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#47
+class RSpec::Core::Configuration
+ include ::RSpec::Core::Hooks
+ include ::RSpec::Core::Configuration::Readers
+
+ # Build an object to store runtime configuration options and set defaults
+ #
+ # @return [Configuration] a new instance of Configuration
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#528
+ def initialize; end
+
+ # Adds a formatter to the set RSpec will use for this run.
+ #
+ # @overload add_formatter
+ # @overload add_formatter
+ # @param formatter [Class, String, Object] formatter to use. Can be any of the
+ # string values supported from the CLI (`p`/`progress`,
+ # `d`/`doc`/`documentation`, `h`/`html`, or `j`/`json`), any
+ # class that implements the formatter protocol and has registered
+ # itself with RSpec as a formatter, or a formatter instance.
+ # @param output [String, IO] where the formatter will write its output.
+ # Can be an IO object or a string path to a file. If not provided,
+ # the configured `output_stream` (`$stdout`, by default) will be used.
+ # @see RSpec::Core::Formatters::Protocol
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#996
+ def add_formatter(formatter, output = T.unsafe(nil)); end
+
+ # Adds a custom setting to the RSpec.configuration object.
+ #
+ # RSpec.configuration.add_setting :foo
+ #
+ # Used internally and by extension frameworks like rspec-rails, so they
+ # can add config settings that are domain specific. For example:
+ #
+ # RSpec.configure do |c|
+ # c.add_setting :use_transactional_fixtures,
+ # :default => true,
+ # :alias_with => :use_transactional_examples
+ # end
+ #
+ # `add_setting` creates three methods on the configuration object, a
+ # setter, a getter, and a predicate:
+ #
+ # RSpec.configuration.foo=(value)
+ # RSpec.configuration.foo
+ # RSpec.configuration.foo? # Returns true if foo returns anything but nil or false.
+ #
+ # @option opts
+ # @option opts
+ # @overload add_setting
+ # @overload add_setting
+ # @param opts [Hash] a customizable set of options
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#659
+ def add_setting(name, opts = T.unsafe(nil)); end
+
+ # Defines a `after` hook. See {Hooks#after} for full docs.
+ #
+ # This method differs from {Hooks#after} in only one way: it supports
+ # the `:suite` scope. Hooks with the `:suite` scope will be run once after
+ # the last example of the entire suite is executed. Conditions passed along
+ # with `:suite` are effectively ignored.
+ #
+ # @see #append_after
+ # @see #before
+ # @see #prepend_before
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2025
+ def after(scope = T.unsafe(nil), *meta, &block); end
+
+ # Creates a method that defines an example group with the provided
+ # metadata. Can be used to define example group/metadata shortcuts.
+ #
+ # @example
+ # RSpec.configure do |config|
+ # config.alias_example_group_to :describe_model, :type => :model
+ # end
+ #
+ # shared_context_for "model tests", :type => :model do
+ # # define common model test helper methods, `let` declarations, etc
+ # end
+ #
+ # # This lets you do this:
+ #
+ # RSpec.describe_model User do
+ # end
+ #
+ # # ... which is the equivalent of
+ #
+ # RSpec.describe User, :type => :model do
+ # end
+ # @note The defined aliased will also be added to the top level
+ # (e.g. `main` and from within modules) if
+ # `expose_dsl_globally` is set to true.
+ # @see #alias_example_to
+ # @see #expose_dsl_globally=
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1209
+ def alias_example_group_to(new_name, *args); end
+
+ # Creates a method that delegates to `example` including the submitted
+ # `args`. Used internally to add variants of `example` like `pending`:
+ #
+ # @example
+ # RSpec.configure do |config|
+ # config.alias_example_to :pending, :pending => true
+ # end
+ #
+ # # This lets you do this:
+ #
+ # RSpec.describe Thing do
+ # pending "does something" do
+ # thing = Thing.new
+ # end
+ # end
+ #
+ # # ... which is the equivalent of
+ #
+ # RSpec.describe Thing do
+ # it "does something", :pending => true do
+ # thing = Thing.new
+ # end
+ # end
+ # @note The specific example alias below (`pending`) is already
+ # defined for you.
+ # @note Use with caution. This extends the language used in your
+ # specs, but does not add any additional documentation. We use this
+ # in RSpec to define methods like `focus` and `xit`, but we also add
+ # docs for those methods.
+ # @param name [String] example name alias
+ # @param args [Array, Hash] metadata for the generated example
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1177
+ def alias_example_to(name, *args); end
+
+ # Define an alias for it_should_behave_like that allows different
+ # language (like "it_has_behavior" or "it_behaves_like") to be
+ # employed when including shared examples.
+ #
+ # @example
+ # RSpec.configure do |config|
+ # config.alias_it_behaves_like_to(:it_has_behavior, 'has behavior:')
+ # end
+ #
+ # # allows the user to include a shared example group like:
+ #
+ # RSpec.describe Entity do
+ # it_has_behavior 'sortability' do
+ # let(:sortable) { Entity.new }
+ # end
+ # end
+ #
+ # # which is reported in the output as:
+ # # Entity
+ # # has behavior: sortability
+ # # ...sortability examples here
+ # @note Use with caution. This extends the language used in your
+ # specs, but does not add any additional documentation. We use this
+ # in RSpec to define `it_should_behave_like` (for backward
+ # compatibility), but we also add docs for that method.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1240
+ def alias_it_behaves_like_to(new_name, report_label = T.unsafe(nil)); end
+
+ # Define an alias for it_should_behave_like that allows different
+ # language (like "it_has_behavior" or "it_behaves_like") to be
+ # employed when including shared examples.
+ #
+ # @example
+ # RSpec.configure do |config|
+ # config.alias_it_behaves_like_to(:it_has_behavior, 'has behavior:')
+ # end
+ #
+ # # allows the user to include a shared example group like:
+ #
+ # RSpec.describe Entity do
+ # it_has_behavior 'sortability' do
+ # let(:sortable) { Entity.new }
+ # end
+ # end
+ #
+ # # which is reported in the output as:
+ # # Entity
+ # # has behavior: sortability
+ # # ...sortability examples here
+ # @note Use with caution. This extends the language used in your
+ # specs, but does not add any additional documentation. We use this
+ # in RSpec to define `it_should_behave_like` (for backward
+ # compatibility), but we also add docs for that method.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1240
+ def alias_it_should_behave_like_to(new_name, report_label = T.unsafe(nil)); end
+
+ # Adds `block` to the end of the list of `after` blocks in the same
+ # scope (`:example`, `:context`, or `:suite`), in contrast to {#after},
+ # which adds the hook to the start of the list.
+ #
+ # See {Hooks#after} for full `after` hook docs.
+ #
+ # This method differs from {Hooks#append_after} in only one way: it supports
+ # the `:suite` scope. Hooks with the `:suite` scope will be run once after
+ # the last example of the entire suite is executed. Conditions passed along
+ # with `:suite` are effectively ignored.
+ #
+ # @see #append_after
+ # @see #before
+ # @see #prepend_before
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2055
+ def append_after(scope = T.unsafe(nil), *meta, &block); end
+
+ # Defines a `before` hook. See {Hooks#before} for full docs.
+ #
+ # This method differs from {Hooks#before} in only one way: it supports
+ # the `:suite` scope. Hooks with the `:suite` scope will be run once before
+ # the first example of the entire suite is executed. Conditions passed along
+ # with `:suite` are effectively ignored.
+ #
+ # @see #prepend_before
+ # @see #after
+ # @see #append_after
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1970
+ def append_before(scope = T.unsafe(nil), *meta, &block); end
+
+ # @private
+ # @raise [SystemStackError]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1935
+ def apply_derived_metadata_to(metadata); end
+
+ # Registers `block` as an `around` hook.
+ #
+ # See {Hooks#around} for full `around` hook docs.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2073
+ def around(scope = T.unsafe(nil), *meta, &block); end
+
+ # Regexps used to exclude lines from backtraces.
+ #
+ # Excludes lines from ruby (and jruby) source, installed gems, anything
+ # in any "bin" directory, and any of the RSpec libs (outside gem
+ # installs) by default.
+ #
+ # You can modify the list via the getter, or replace it with the setter.
+ #
+ # To override this behaviour and display a full backtrace, use
+ # `--backtrace` on the command line, in a `.rspec` file, or in the
+ # `rspec_options` attribute of RSpec's rake task.
+ #
+ # @return [Array]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#697
+ def backtrace_exclusion_patterns; end
+
+ # Set regular expressions used to exclude lines in backtrace.
+ #
+ # @param patterns [Array] set backtrace_formatter exclusion_patterns
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#703
+ def backtrace_exclusion_patterns=(patterns); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#522
+ def backtrace_formatter; end
+
+ # Regexps used to include lines in backtraces.
+ #
+ # Defaults to [Regexp.new Dir.getwd].
+ #
+ # Lines that match an exclusion _and_ an inclusion pattern
+ # will be included.
+ #
+ # You can modify the list via the getter, or replace it with the setter.
+ #
+ # @return [Array]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#716
+ def backtrace_inclusion_patterns; end
+
+ # Set regular expressions used to include lines in backtrace.
+ #
+ # @attr patterns [Array] set backtrace_formatter inclusion_patterns
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#722
+ def backtrace_inclusion_patterns=(patterns); end
+
+ # Defines a `before` hook. See {Hooks#before} for full docs.
+ #
+ # This method differs from {Hooks#before} in only one way: it supports
+ # the `:suite` scope. Hooks with the `:suite` scope will be run once before
+ # the first example of the entire suite is executed. Conditions passed along
+ # with `:suite` are effectively ignored.
+ #
+ # @see #prepend_before
+ # @see #after
+ # @see #append_after
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1970
+ def before(scope = T.unsafe(nil), *meta, &block); end
+
+ # Determines which bisect runner implementation gets used to run subsets
+ # of the suite during a bisection. Your choices are:
+ #
+ # - `:shell`: Performs a spec run by shelling out, booting RSpec and your
+ # application environment each time. This runner is the most widely
+ # compatible runner, but is not as fast. On platforms that do not
+ # support forking, this is the default.
+ # - `:fork`: Pre-boots RSpec and your application environment in a parent
+ # process, and then forks a child process for each spec run. This runner
+ # tends to be significantly faster than the `:shell` runner but cannot
+ # be used in some situations. On platforms that support forking, this
+ # is the default. If you use this runner, you should ensure that all
+ # of your one-time setup logic goes in a `before(:suite)` hook instead
+ # of getting run at the top-level of a file loaded by `--require`.
+ #
+ # @note This option will only be used by `--bisect` if you set it in a file
+ # loaded via `--require`.
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#499
+ def bisect_runner; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#500
+ def bisect_runner=(value); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2119
+ def bisect_runner_class; end
+
+ # Enables color output if the output is a TTY. As of RSpec 3.6, this is
+ # the default behavior and this option is retained only for backwards
+ # compatibility.
+ #
+ # @deprecated No longer recommended because of complex behavior. Instead,
+ # rely on the fact that TTYs will display color by default, or set
+ # {#color_mode} to :on to display color on a non-TTY output.
+ # @return [Boolean]
+ # @see color_mode
+ # @see color_enabled?
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#922
+ def color; end
+
+ # Toggle output color.
+ #
+ # @deprecated No longer recommended because of complex behavior. Instead,
+ # rely on the fact that TTYs will display color by default, or set
+ # {:color_mode} to :on to display color on a non-TTY output.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#960
+ def color=(_arg0); end
+
+ # Check if color is enabled for a particular output.
+ #
+ # @param output [IO] an output stream to use, defaults to the current
+ # `output_stream`
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#943
+ def color_enabled?(output = T.unsafe(nil)); end
+
+ # The mode for determining whether to display output in color. One of:
+ #
+ # - :automatic - the output will be in color if the output is a TTY (the
+ # default)
+ # - :on - the output will be in color, whether or not the output is a TTY
+ # - :off - the output will not be in color
+ #
+ # @return [Boolean]
+ # @see color_enabled?
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#935
+ def color_mode; end
+
+ # Set the color mode.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#953
+ def color_mode=(_arg0); end
+
+ # Used internally to extend the singleton class of a single example's
+ # example group instance with modules using `include` and/or `extend`.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1577
+ def configure_example(example, example_hooks); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1617
+ def configure_expectation_framework; end
+
+ # Used internally to extend a group with modules using `include`, `prepend` and/or
+ # `extend`.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1565
+ def configure_group(group); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1611
+ def configure_mock_framework; end
+
+ # The default output color. Defaults to `:white` but can be set to one of
+ # the following: `[:black, :white, :red, :green, :yellow, :blue,
+ # :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def default_color; end
+
+ # The default output color. Defaults to `:white` but can be set to one of
+ # the following: `[:black, :white, :red, :green, :yellow, :blue,
+ # :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def default_color=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def default_color?; end
+
+ # The formatter that will be used if no formatter has been set.
+ # Defaults to 'progress'.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1003
+ def default_formatter; end
+
+ # Sets a fallback formatter to use if none other has been set.
+ #
+ # @example
+ #
+ # RSpec.configure do |rspec|
+ # rspec.default_formatter = 'doc'
+ # end
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1014
+ def default_formatter=(value); end
+
+ # Path to use if no path is provided to the `rspec` command (default:
+ # `"spec"`). Allows you to just type `rspec` instead of `rspec spec` to
+ # run all the examples in the `spec` directory.
+ #
+ # @note Other scripts invoking `rspec` indirectly will ignore this
+ # setting.
+ # @return [String]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def default_path; end
+
+ # Path to use if no path is provided to the `rspec` command (default:
+ # `"spec"`). Allows you to just type `rspec` instead of `rspec spec` to
+ # run all the examples in the `spec` directory.
+ #
+ # @note Other scripts invoking `rspec` indirectly will ignore this
+ # setting.
+ # @return [String]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#121
+ def default_path=(path); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def default_path?; end
+
+ # Defines a callback that can assign derived metadata values.
+ #
+ # @example
+ # RSpec.configure do |config|
+ # # Tag all groups and examples in the spec/unit directory with
+ # # :type => :unit
+ # config.define_derived_metadata(:file_path => %r{/spec/unit/}) do |metadata|
+ # metadata[:type] = :unit
+ # end
+ # end
+ # @param filters [Array, Hash] metadata filters that determine
+ # which example or group metadata hashes the callback will be triggered
+ # for. If none are given, the callback will be run against the metadata
+ # hashes of all groups and examples.
+ # @yieldparam metadata [Hash] original metadata hash from an example or
+ # group. Mutate this in your block as needed.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1894
+ def define_derived_metadata(*filters, &block); end
+
+ # Determines where deprecation warnings are printed.
+ # Defaults to `$stderr`.
+ #
+ # @return [IO, String] IO or filename to write to
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def deprecation_stream; end
+
+ # Determines where deprecation warnings are printed.
+ #
+ # @param value [IO, String] IO to write to or filename to write to
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#168
+ def deprecation_stream=(value); end
+
+ # Color used to print details. Defaults to `:cyan` but can be set to one
+ # of the following: `[:black, :white, :red, :green, :yellow, :blue,
+ # :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def detail_color; end
+
+ # Color used to print details. Defaults to `:cyan` but can be set to one
+ # of the following: `[:black, :white, :red, :green, :yellow, :blue,
+ # :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def detail_color=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def detail_color?; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1875
+ def disable_monkey_patching; end
+
+ # Enables zero monkey patching mode for RSpec. It removes monkey
+ # patching of the top-level DSL methods (`describe`,
+ # `shared_examples_for`, etc) onto `main` and `Module`, instead
+ # requiring you to prefix these methods with `RSpec.`. It enables
+ # expect-only syntax for rspec-mocks and rspec-expectations. It
+ # simply disables monkey patching on whatever pieces of RSpec
+ # the user is using.
+ #
+ # @example
+ #
+ # # It disables all monkey patching.
+ # RSpec.configure do |config|
+ # config.disable_monkey_patching!
+ # end
+ #
+ # # Is an equivalent to
+ # RSpec.configure do |config|
+ # config.expose_dsl_globally = false
+ #
+ # config.mock_with :rspec do |mocks|
+ # mocks.syntax = :expect
+ # mocks.patch_marshal_to_support_partial_doubles = false
+ # end
+ #
+ # config.expect_with :rspec do |expectations|
+ # expectations.syntax = :expect
+ # end
+ # end
+ # @note It configures rspec-mocks and rspec-expectations only
+ # if the user is using those (either explicitly or implicitly
+ # by not setting `mock_with` or `expect_with` to anything else).
+ # @note If the user uses this options with `mock_with :mocha`
+ # (or similar) they will still have monkey patching active
+ # in their test environment from mocha.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1867
+ def disable_monkey_patching!; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1875
+ def disable_monkey_patching=(_arg0); end
+
+ # Run examples over DRb (default: `false`). RSpec doesn't supply the DRb
+ # server, but you can use tools like spork.
+ #
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def drb; end
+
+ # Run examples over DRb (default: `false`). RSpec doesn't supply the DRb
+ # server, but you can use tools like spork.
+ #
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def drb=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def drb?; end
+
+ # The drb_port (default: nil).
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def drb_port; end
+
+ # The drb_port (default: nil).
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def drb_port=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def drb_port?; end
+
+ # Prints the formatter output of your suite without running any
+ # examples or hooks.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def dry_run; end
+
+ # Prints the formatter output of your suite without running any
+ # examples or hooks.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def dry_run=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def dry_run?; end
+
+ # The exit code to return if there are any errors outside examples (default: failure_exit_code)
+ #
+ # @return [Integer]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def error_exit_code; end
+
+ # The exit code to return if there are any errors outside examples (default: failure_exit_code)
+ #
+ # @return [Integer]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def error_exit_code=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def error_exit_code?; end
+
+ # Default: `$stderr`.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def error_stream; end
+
+ # Default: `$stderr`.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def error_stream=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def error_stream?; end
+
+ # The file path to use for persisting example statuses. Necessary for the
+ # `--only-failures` and `--next-failure` CLI options.
+ #
+ # @overload example_status_persistence_file_path
+ # @overload example_status_persistence_file_path=
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def example_status_persistence_file_path; end
+
+ # Sets the file path to use for persisting example statuses. Necessary for the
+ # `--only-failures` and `--next-failure` CLI options.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#192
+ def example_status_persistence_file_path=(value); end
+
+ # Exclude files matching this pattern.
+ #
+ # @return [String]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def exclude_pattern; end
+
+ # Set pattern to match files to exclude.
+ #
+ # @attr value [String] the filename pattern to exclude spec files by
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#304
+ def exclude_pattern=(value); end
+
+ # Returns the `exclusion_filter`. If none has been set, returns an empty
+ # hash.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1369
+ def exclusion_filter; end
+
+ # Clears and reassigns the `exclusion_filter`. Set to `nil` if you don't
+ # want any exclusion filter at all.
+ #
+ # ### Warning
+ #
+ # This overrides any exclusion filters/tags set on the command line or in
+ # configuration files.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1362
+ def exclusion_filter=(filter); end
+
+ # Sets the expectation framework module(s) to be included in each example
+ # group.
+ #
+ # `frameworks` can be `:rspec`, `:test_unit`, `:minitest`, a custom
+ # module, or any combination thereof:
+ #
+ # config.expect_with :rspec
+ # config.expect_with :test_unit
+ # config.expect_with :minitest
+ # config.expect_with :rspec, :minitest
+ # config.expect_with OtherExpectationFramework
+ #
+ # RSpec will translate `:rspec`, `:minitest`, and `:test_unit` into the
+ # appropriate modules.
+ #
+ # ## Configuration
+ #
+ # If the module responds to `configuration`, `expect_with` will
+ # yield the `configuration` object if given a block:
+ #
+ # config.expect_with OtherExpectationFramework do |custom_config|
+ # custom_config.custom_setting = true
+ # end
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#858
+ def expect_with(*frameworks); end
+
+ # Delegates to expect_with(framework).
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#831
+ def expectation_framework=(framework); end
+
+ # Returns the configured expectation framework adapter module(s)
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#819
+ def expectation_frameworks; end
+
+ # Exposes the current running example via the named
+ # helper method. RSpec 2.x exposed this via `example`,
+ # but in RSpec 3.0, the example is instead exposed via
+ # an arg yielded to `it`, `before`, `let`, etc. However,
+ # some extension gems (such as Capybara) depend on the
+ # RSpec 2.x's `example` method, so this config option
+ # can be used to maintain compatibility.
+ #
+ # @example
+ #
+ # RSpec.configure do |rspec|
+ # rspec.expose_current_running_example_as :example
+ # end
+ #
+ # RSpec.describe MyClass do
+ # before do
+ # # `example` can be used here because of the above config.
+ # do_something if example.metadata[:type] == "foo"
+ # end
+ # end
+ # @param method_name [Symbol] the name of the helper method
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1805
+ def expose_current_running_example_as(method_name); end
+
+ # Use this to expose the core RSpec DSL via `Module` and the `main`
+ # object. It will be set automatically but you can override it to
+ # remove the DSL.
+ # Default: true
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#151
+ def expose_dsl_globally=(value); end
+
+ # Indicates if the DSL has been exposed off of modules and `main`.
+ # Default: true
+ #
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#143
+ def expose_dsl_globally?; end
+
+ # Tells RSpec to extend example groups with `mod`. Methods defined in
+ # `mod` are exposed to example groups (not examples). Use `filters` to
+ # constrain the groups to extend.
+ #
+ # Similar to `include`, but behavior is added to example groups, which
+ # are classes, rather than the examples, which are instances of those
+ # classes.
+ #
+ # @example
+ #
+ # module UiHelpers
+ # def run_in_browser
+ # # ...
+ # end
+ # end
+ #
+ # module PermissionHelpers
+ # def define_permissions
+ # # ...
+ # end
+ # end
+ #
+ # RSpec.configure do |config|
+ # config.extend(UiHelpers, :type => :request)
+ # config.extend(PermissionHelpers, :with_permissions, :type => :request)
+ # end
+ #
+ # describe "edit profile", :with_permissions, :type => :request do
+ # run_in_browser
+ # define_permissions
+ #
+ # it "does stuff in the client" do
+ # # ...
+ # end
+ # end
+ # @see #include
+ # @see #prepend
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1515
+ def extend(mod, *filters); end
+
+ # If specified, indicates the number of failures required before cleaning
+ # up and exit (default: `nil`). Can also be `true` to fail and exit on first
+ # failure
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def fail_fast; end
+
+ # @see fail_fast
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#214
+ def fail_fast=(value); end
+
+ # Whether or not to fail when there are no RSpec examples (default: false).
+ #
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def fail_if_no_examples; end
+
+ # Whether or not to fail when there are no RSpec examples (default: false).
+ #
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def fail_if_no_examples=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def fail_if_no_examples?; end
+
+ # Color to use to indicate failure. Defaults to `:red` but can be set to
+ # one of the following: `[:black, :white, :red, :green, :yellow, :blue,
+ # :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def failure_color; end
+
+ # Color to use to indicate failure. Defaults to `:red` but can be set to
+ # one of the following: `[:black, :white, :red, :green, :yellow, :blue,
+ # :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def failure_color=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def failure_color?; end
+
+ # The exit code to return if there are any failures (default: 1).
+ #
+ # @return [Integer]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def failure_exit_code; end
+
+ # The exit code to return if there are any failures (default: 1).
+ #
+ # @return [Integer]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def failure_exit_code=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def failure_exit_code?; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1083
+ def files_or_directories_to_run=(*files); end
+
+ # The spec files RSpec will run.
+ #
+ # @return [Array] specified files about to run
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1096
+ def files_to_run; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#516
+ def files_to_run=(_arg0); end
+
+ # Returns the `inclusion_filter`. If none has been set, returns an empty
+ # hash.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1313
+ def filter; end
+
+ # Clears and reassigns the `inclusion_filter`. Set to `nil` if you don't
+ # want any inclusion filter at all.
+ #
+ # ### Warning
+ #
+ # This overrides any inclusion filters/tags set on the command line or in
+ # configuration files.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1304
+ def filter=(filter); end
+
+ # Adds {#backtrace_exclusion_patterns} that will filter lines from
+ # the named gems from backtraces.
+ #
+ # @example
+ # RSpec.configure do |config|
+ # config.filter_gems_from_backtrace "rack", "rake"
+ # end
+ # @note The patterns this adds will match the named gems in their common
+ # locations (e.g. system gems, vendored with bundler, installed as a
+ # :git dependency with bundler, etc) but is not guaranteed to work for
+ # all possible gem locations. For example, if you have the gem source
+ # in a directory with a completely unrelated name, and use bundler's
+ # :path option, this will not filter it.
+ # @param gem_names [Array] Names of the gems to filter
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#742
+ def filter_gems_from_backtrace(*gem_names); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#518
+ def filter_manager; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#518
+ def filter_manager=(_arg0); end
+
+ # Adds key/value pairs to the `inclusion_filter`. If `args`
+ # includes any symbols that are not part of the hash, each symbol
+ # is treated as a key in the hash with the value `true`.
+ #
+ # ### Note
+ #
+ # Filters set using this method can be overridden from the command line
+ # or config files (e.g. `.rspec`).
+ #
+ # @example
+ # # Given this declaration.
+ # describe "something", :foo => 'bar' do
+ # # ...
+ # end
+ #
+ # # Any of the following will include that group.
+ # config.filter_run_including :foo => 'bar'
+ # config.filter_run_including :foo => /^ba/
+ # config.filter_run_including :foo => lambda {|v| v == 'bar'}
+ # config.filter_run_including :foo => lambda {|v,m| m[:foo] == 'bar'}
+ #
+ # # Given a proc with an arity of 1, the lambda is passed the value
+ # # related to the key, e.g.
+ # config.filter_run_including :foo => lambda {|v| v == 'bar'}
+ #
+ # # Given a proc with an arity of 2, the lambda is passed the value
+ # # related to the key, and the metadata itself e.g.
+ # config.filter_run_including :foo => lambda {|v,m| m[:foo] == 'bar'}
+ #
+ # filter_run_including :foo # same as filter_run_including :foo => true
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1275
+ def filter_run(*args); end
+
+ # Adds key/value pairs to the `exclusion_filter`. If `args`
+ # includes any symbols that are not part of the hash, each symbol
+ # is treated as a key in the hash with the value `true`.
+ #
+ # ### Note
+ #
+ # Filters set using this method can be overridden from the command line
+ # or config files (e.g. `.rspec`).
+ #
+ # @example
+ # # Given this declaration.
+ # describe "something", :foo => 'bar' do
+ # # ...
+ # end
+ #
+ # # Any of the following will exclude that group.
+ # config.filter_run_excluding :foo => 'bar'
+ # config.filter_run_excluding :foo => /^ba/
+ # config.filter_run_excluding :foo => lambda {|v| v == 'bar'}
+ # config.filter_run_excluding :foo => lambda {|v,m| m[:foo] == 'bar'}
+ #
+ # # Given a proc with an arity of 1, the lambda is passed the value
+ # # related to the key, e.g.
+ # config.filter_run_excluding :foo => lambda {|v| v == 'bar'}
+ #
+ # # Given a proc with an arity of 2, the lambda is passed the value
+ # # related to the key, and the metadata itself e.g.
+ # config.filter_run_excluding :foo => lambda {|v,m| m[:foo] == 'bar'}
+ #
+ # filter_run_excluding :foo # same as filter_run_excluding :foo => true
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1349
+ def filter_run_excluding(*args); end
+
+ # Adds key/value pairs to the `inclusion_filter`. If `args`
+ # includes any symbols that are not part of the hash, each symbol
+ # is treated as a key in the hash with the value `true`.
+ #
+ # ### Note
+ #
+ # Filters set using this method can be overridden from the command line
+ # or config files (e.g. `.rspec`).
+ #
+ # @example
+ # # Given this declaration.
+ # describe "something", :foo => 'bar' do
+ # # ...
+ # end
+ #
+ # # Any of the following will include that group.
+ # config.filter_run_including :foo => 'bar'
+ # config.filter_run_including :foo => /^ba/
+ # config.filter_run_including :foo => lambda {|v| v == 'bar'}
+ # config.filter_run_including :foo => lambda {|v,m| m[:foo] == 'bar'}
+ #
+ # # Given a proc with an arity of 1, the lambda is passed the value
+ # # related to the key, e.g.
+ # config.filter_run_including :foo => lambda {|v| v == 'bar'}
+ #
+ # # Given a proc with an arity of 2, the lambda is passed the value
+ # # related to the key, and the metadata itself e.g.
+ # config.filter_run_including :foo => lambda {|v,m| m[:foo] == 'bar'}
+ #
+ # filter_run_including :foo # same as filter_run_including :foo => true
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1275
+ def filter_run_including(*args); end
+
+ # Applies the provided filter only if any of examples match, in constrast
+ # to {#filter_run}, which always applies even if no examples match, in
+ # which case no examples will be run. This allows you to leave configured
+ # filters in place that are intended only for temporary use. The most common
+ # example is focus filtering: `config.filter_run_when_matching :focus`.
+ # With that configured, you can temporarily focus an example or group
+ # by tagging it with `:focus` metadata, or prefixing it with an `f`
+ # (as in `fdescribe`, `fcontext` and `fit`) since those are aliases for
+ # `describe`/`context`/`it` with `:focus` metadata.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1291
+ def filter_run_when_matching(*args); end
+
+ # Color used when a pending example is fixed. Defaults to `:blue` but can
+ # be set to one of the following: `[:black, :white, :red, :green,
+ # :yellow, :blue, :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def fixed_color; end
+
+ # Color used when a pending example is fixed. Defaults to `:blue` but can
+ # be set to one of the following: `[:black, :white, :red, :green,
+ # :yellow, :blue, :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def fixed_color=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def fixed_color?; end
+
+ # Used to set higher priority option values from the command line.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#592
+ def force(hash); end
+
+ # Formats the docstring output using the block provided.
+ #
+ # @example
+ # # This will strip the descriptions of both examples and example
+ # # groups.
+ # RSpec.configure do |config|
+ # config.format_docstrings { |s| s.strip }
+ # end
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1656
+ def format_docstrings(&block); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1661
+ def format_docstrings_block; end
+
+ # Adds a formatter to the set RSpec will use for this run.
+ #
+ # @overload add_formatter
+ # @overload add_formatter
+ # @param formatter [Class, String, Object] formatter to use. Can be any of the
+ # string values supported from the CLI (`p`/`progress`,
+ # `d`/`doc`/`documentation`, `h`/`html`, or `j`/`json`), any
+ # class that implements the formatter protocol and has registered
+ # itself with RSpec as a formatter, or a formatter instance.
+ # @param output [String, IO] where the formatter will write its output.
+ # Can be an IO object or a string path to a file. If not provided,
+ # the configured `output_stream` (`$stdout`, by default) will be used.
+ # @see RSpec::Core::Formatters::Protocol
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#996
+ def formatter=(formatter, output = T.unsafe(nil)); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1029
+ def formatter_loader; end
+
+ # Returns a duplicate of the formatters currently loaded in
+ # the `FormatterLoader` for introspection.
+ #
+ # Note as this is a duplicate, any mutations will be disregarded.
+ #
+ # @return [Array] the formatters currently loaded
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1024
+ def formatters; end
+
+ # Toggle full backtrace.
+ #
+ # @attr true_or_false [Boolean] toggle full backtrace display
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#908
+ def full_backtrace=(true_or_false); end
+
+ # Check if full backtrace is enabled.
+ #
+ # @return [Boolean] is full backtrace enabled
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#902
+ def full_backtrace?; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def full_cause_backtrace; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def full_cause_backtrace=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def full_cause_backtrace?; end
+
+ # @return [Array] full description filter
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#977
+ def full_description; end
+
+ # Run examples matching on `description` in all files to run.
+ #
+ # @param description [String, Regexp] the pattern to filter on
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#972
+ def full_description=(description); end
+
+ # Holds the various registered hooks. Here we use a FilterableItemRepository
+ # implementation that is specifically optimized for the read/write patterns
+ # of the config object.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2103
+ def hooks; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1602
+ def in_project_source_dir_regex; end
+
+ # Tells RSpec to include `mod` in example groups. Methods defined in
+ # `mod` are exposed to examples (not example groups). Use `filters` to
+ # constrain the groups or examples in which to include the module.
+ #
+ # @example
+ #
+ # module AuthenticationHelpers
+ # def login_as(user)
+ # # ...
+ # end
+ # end
+ #
+ # module PreferencesHelpers
+ # def preferences(user, preferences = {})
+ # # ...
+ # end
+ # end
+ #
+ # module UserHelpers
+ # def users(username)
+ # # ...
+ # end
+ # end
+ #
+ # RSpec.configure do |config|
+ # config.include(UserHelpers) # included in all groups
+ #
+ # # included in examples with `:preferences` metadata
+ # config.include(PreferenceHelpers, :preferences)
+ #
+ # # included in examples with `:type => :request` metadata
+ # config.include(AuthenticationHelpers, :type => :request)
+ # end
+ #
+ # describe "edit profile", :preferences, :type => :request do
+ # it "can be viewed by owning user" do
+ # login_as preferences(users(:jdoe), :lang => 'es')
+ # get "/profiles/jdoe"
+ # assert_select ".username", :text => 'jdoe'
+ # end
+ # end
+ # @note Filtered module inclusions can also be applied to
+ # individual examples that have matching metadata. Just like
+ # Ruby's object model is that every object has a singleton class
+ # which has only a single instance, RSpec's model is that every
+ # example has a singleton example group containing just the one
+ # example.
+ # @see #include_context
+ # @see #extend
+ # @see #prepend
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1425
+ def include(mod, *filters); end
+
+ # Tells RSpec to include the named shared example group in example groups.
+ # Use `filters` to constrain the groups or examples in which to include
+ # the example group.
+ #
+ # @example
+ #
+ # RSpec.shared_context "example admin user" do
+ # let(:admin_user) { create_user(:admin) }
+ # end
+ #
+ # RSpec.shared_context "example guest user" do
+ # let(:guest_user) { create_user(:guest) }
+ # end
+ #
+ # RSpec.configure do |config|
+ # config.include_context "example guest user", :type => :request
+ # config.include_context "example admin user", :admin, :type => :request
+ # end
+ #
+ # RSpec.describe "The admin page", :type => :request do
+ # it "can be viewed by admins", :admin do
+ # login_with admin_user
+ # get "/admin"
+ # expect(response).to be_ok
+ # end
+ #
+ # it "cannot be viewed by guests" do
+ # login_with guest_user
+ # get "/admin"
+ # expect(response).to be_forbidden
+ # end
+ # end
+ # @note Filtered context inclusions can also be applied to
+ # individual examples that have matching metadata. Just like
+ # Ruby's object model is that every object has a singleton class
+ # which has only a single instance, RSpec's model is that every
+ # example has a singleton example group containing just the one
+ # example.
+ # @see #include
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1472
+ def include_context(shared_group_name, *filters); end
+
+ # Returns the `inclusion_filter`. If none has been set, returns an empty
+ # hash.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1313
+ def inclusion_filter; end
+
+ # Clears and reassigns the `inclusion_filter`. Set to `nil` if you don't
+ # want any inclusion filter at all.
+ #
+ # ### Warning
+ #
+ # This overrides any inclusion filters/tags set on the command line or in
+ # configuration files.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1304
+ def inclusion_filter=(filter); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1101
+ def last_run_statuses; end
+
+ # Returns dirs that have been prepended to the load path by the `-I`
+ # command line option.
+ #
+ # @return [Array]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def libs; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#963
+ def libs=(libs); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1625
+ def load_spec_files; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#522
+ def loaded_spec_files; end
+
+ # Maximum count of failed source lines to display in the failure reports
+ # (defaults to `10`).
+ # return [Integer]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def max_displayed_failure_line_count; end
+
+ # Maximum count of failed source lines to display in the failure reports
+ # (defaults to `10`).
+ # return [Integer]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def max_displayed_failure_line_count=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def max_displayed_failure_line_count?; end
+
+ # Returns the configured mock framework adapter module.
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#669
+ def mock_framework; end
+
+ # Delegates to mock_framework=(framework).
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#681
+ def mock_framework=(framework); end
+
+ # Sets the mock framework adapter module.
+ #
+ # `framework` can be a Symbol or a Module.
+ #
+ # Given any of `:rspec`, `:mocha`, `:flexmock`, or `:rr`, configures the
+ # named framework.
+ #
+ # Given `:nothing`, configures no framework. Use this if you don't use
+ # any mocking framework to save a little bit of overhead.
+ #
+ # Given a Module, includes that module in every example group. The module
+ # should adhere to RSpec's mock framework adapter API:
+ #
+ # setup_mocks_for_rspec
+ # - called before each example
+ #
+ # verify_mocks_for_rspec
+ # - called after each example if the example hasn't yet failed.
+ # Framework should raise an exception when expectations fail
+ #
+ # teardown_mocks_for_rspec
+ # - called after verify_mocks_for_rspec (even if there are errors)
+ #
+ # If the module responds to `configuration` and `mock_with` receives a
+ # block, it will yield the configuration object to the block e.g.
+ #
+ # config.mock_with OtherMockFrameworkAdapter do |mod_config|
+ # mod_config.custom_setting = true
+ # end
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#786
+ def mock_with(framework); end
+
+ # Invokes block before defining an example group
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2108
+ def on_example_group_definition(&block); end
+
+ # Returns an array of blocks to call before defining an example group
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2114
+ def on_example_group_definition_callbacks; end
+
+ # Indicates if the `--only-failures` (or `--next-failure`) flag is being used.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def only_failures; end
+
+ # Indicates if the `--only-failures` (or `--next-failure`) flag is being used.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def only_failures?; end
+
+ # @private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#203
+ def only_failures_but_not_configured?; end
+
+ # Sets the default global ordering strategy. By default this can be one
+ # of `:defined`, `:random`, but is customizable through the
+ # `register_ordering` API. If order is set to `'rand:'`,
+ # the seed will also be set.
+ #
+ # @see #register_ordering
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1668
+ def order=(*args, &block); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#522
+ def ordering_manager; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#1668
+ def ordering_registry(*args, &block); end
+
+ # Determines where RSpec will send its output.
+ # Default: `$stdout`.
+ #
+ # @return [IO, String]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def output_stream; end
+
+ # Set the output stream for reporter.
+ #
+ # @attr value [IO, String] IO to write to or filename to write to, defaults to $stdout
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#274
+ def output_stream=(value); end
+
+ # Load files matching this pattern (default: `'**{,/*/**}/*_spec.rb'`).
+ #
+ # @return [String]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def pattern; end
+
+ # Set pattern to match files to load.
+ #
+ # @attr value [String] the filename pattern to filter spec files by
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#293
+ def pattern=(value); end
+
+ # Color to use to print pending examples. Defaults to `:yellow` but can
+ # be set to one of the following: `[:black, :white, :red, :green,
+ # :yellow, :blue, :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def pending_color; end
+
+ # Color to use to print pending examples. Defaults to `:yellow` but can
+ # be set to one of the following: `[:black, :white, :red, :green,
+ # :yellow, :blue, :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def pending_color=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def pending_color?; end
+
+ # Format the output for pending examples. Can be set to:
+ # - :full (default) - pending examples appear similarly to failures
+ # - :no_backtrace - same as above, but with no backtrace
+ # - :skip - do not show the section at all
+ # return [Symbol]
+ #
+ # @raise [ArgumentError]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def pending_failure_output; end
+
+ # Format the output for pending examples. Can be set to:
+ # - :full (default) - pending examples appear similarly to failures
+ # - :no_backtrace - same as above, but with no backtrace
+ # - :skip - do not show the section at all
+ # return [Symbol]
+ #
+ # @raise [ArgumentError]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#473
+ def pending_failure_output=(mode); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def pending_failure_output?; end
+
+ # Tells RSpec to prepend example groups with `mod`. Methods defined in
+ # `mod` are exposed to examples (not example groups). Use `filters` to
+ # constrain the groups in which to prepend the module.
+ #
+ # Similar to `include`, but module is included before the example group's class
+ # in the ancestor chain.
+ #
+ # @example
+ #
+ # module OverrideMod
+ # def override_me
+ # "overridden"
+ # end
+ # end
+ #
+ # RSpec.configure do |config|
+ # config.prepend(OverrideMod, :method => :prepend)
+ # end
+ #
+ # describe "overriding example's class", :method => :prepend do
+ # it "finds the user" do
+ # self.class.class_eval do
+ # def override_me
+ # end
+ # end
+ # override_me # => "overridden"
+ # # ...
+ # end
+ # end
+ # @see #include
+ # @see #extend
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1554
+ def prepend(mod, *filters); end
+
+ # Defines a `after` hook. See {Hooks#after} for full docs.
+ #
+ # This method differs from {Hooks#after} in only one way: it supports
+ # the `:suite` scope. Hooks with the `:suite` scope will be run once after
+ # the last example of the entire suite is executed. Conditions passed along
+ # with `:suite` are effectively ignored.
+ #
+ # @see #append_after
+ # @see #before
+ # @see #prepend_before
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2025
+ def prepend_after(scope = T.unsafe(nil), *meta, &block); end
+
+ # Adds `block` to the start of the list of `before` blocks in the same
+ # scope (`:example`, `:context`, or `:suite`), in contrast to {#before},
+ # which adds the hook to the end of the list.
+ #
+ # See {Hooks#before} for full `before` hook docs.
+ #
+ # This method differs from {Hooks#prepend_before} in only one way: it supports
+ # the `:suite` scope. Hooks with the `:suite` scope will be run once before
+ # the first example of the entire suite is executed. Conditions passed along
+ # with `:suite` are effectively ignored.
+ #
+ # @see #before
+ # @see #after
+ # @see #append_after
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2000
+ def prepend_before(scope = T.unsafe(nil), *meta, &block); end
+
+ # Defaults `profile_examples` to 10 examples when `@profile_examples` is
+ # `true`.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1073
+ def profile_examples; end
+
+ # Report the times for the slowest examples (default: `false`).
+ # Use this to specify the number of examples to include in the profile.
+ #
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#322
+ def profile_examples=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def profile_examples?; end
+
+ # Specifies which directories contain the source code for your project.
+ # When a failure occurs, RSpec looks through the backtrace to find a
+ # a line of source to print. It first looks for a line coming from
+ # one of the project source directories so that, for example, it prints
+ # the expectation or assertion call rather than the source code from
+ # the expectation or assertion framework.
+ #
+ # @return [Array]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def project_source_dirs; end
+
+ # Specifies which directories contain the source code for your project.
+ # When a failure occurs, RSpec looks through the backtrace to find a
+ # a line of source to print. It first looks for a line coming from
+ # one of the project source directories so that, for example, it prints
+ # the expectation or assertion call rather than the source code from
+ # the expectation or assertion framework.
+ #
+ # @return [Array]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def project_source_dirs=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def project_source_dirs?; end
+
+ # Turns deprecation warnings into errors, in order to surface
+ # the full backtrace of the call site. This can be useful when
+ # you need more context to address a deprecation than the
+ # single-line call site normally provided.
+ #
+ # @example
+ #
+ # RSpec.configure do |rspec|
+ # rspec.raise_errors_for_deprecations!
+ # end
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1827
+ def raise_errors_for_deprecations!; end
+
+ # Turns warnings into errors. This can be useful when
+ # you want RSpec to run in a 'strict' no warning situation.
+ #
+ # @example
+ #
+ # RSpec.configure do |rspec|
+ # rspec.raise_on_warning = true
+ # end
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1775
+ def raise_on_warning=(value); end
+
+ # Registers a named ordering strategy that can later be
+ # used to order an example group's subgroups by adding
+ # `:order => ` metadata to the example group.
+ #
+ # @example
+ # RSpec.configure do |rspec|
+ # rspec.register_ordering :reverse do |list|
+ # list.reverse
+ # end
+ # end
+ #
+ # RSpec.describe 'MyClass', :order => :reverse do
+ # # ...
+ # end
+ # @example
+ # RSpec.configure do |rspec|
+ # rspec.register_ordering :global do |examples|
+ # acceptance, other = examples.partition do |example|
+ # example.metadata[:type] == :acceptance
+ # end
+ # other + acceptance
+ # end
+ # end
+ #
+ # RSpec.describe 'MyClass', :type => :acceptance do
+ # # will run last
+ # end
+ #
+ # RSpec.describe 'MyClass' do
+ # # will run first
+ # end
+ # @note Pass the symbol `:global` to set the ordering strategy that
+ # will be used to order the top-level example groups and any example
+ # groups that do not have declared `:order` metadata.
+ # @param name [Symbol] The name of the ordering.
+ # @yield Block that will order the given examples or example groups
+ # @yieldparam list [Array, Array] The examples or groups to order
+ # @yieldreturn [Array, Array] The re-ordered examples or groups
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1668
+ def register_ordering(*args, &block); end
+
+ # @return [RSpec::Core::Reporter] the currently configured reporter
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1056
+ def reporter; end
+
+ # Indicates files configured to be required.
+ #
+ # @return [Array]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def requires; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1594
+ def requires=(paths); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#601
+ def reset; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#614
+ def reset_filters; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#607
+ def reset_reporter; end
+
+ # Run all examples if none match the configured filters
+ # (default: `false`).
+ #
+ # @deprecated Use {#filter_run_when_matching} instead for the specific
+ # filters that you want to be ignored if none match.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def run_all_when_everything_filtered; end
+
+ # Run all examples if none match the configured filters
+ # (default: `false`).
+ #
+ # @deprecated Use {#filter_run_when_matching} instead for the specific
+ # filters that you want to be ignored if none match.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def run_all_when_everything_filtered=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def run_all_when_everything_filtered?; end
+
+ # Seed for random ordering (default: generated randomly each run).
+ #
+ # When you run specs with `--order random`, RSpec generates a random seed
+ # for the randomization and prints it to the `output_stream` (assuming
+ # you're using RSpec's built-in formatters). If you discover an ordering
+ # dependency (i.e. examples fail intermittently depending on order), set
+ # this (on Configuration or on the command line with `--seed`) to run
+ # using the same seed while you debug the issue.
+ #
+ # We recommend, actually, that you use the command line approach so you
+ # don't accidentally leave the seed encoded.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1668
+ def seed(*args, &block); end
+
+ # Sets the seed value and sets the default global ordering to random.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1668
+ def seed=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#1668
+ def seed_used?(*args, &block); end
+
+ # Configures how RSpec treats metadata passed as part of a shared example
+ # group definition. For example, given this shared example group definition:
+ #
+ # RSpec.shared_context "uses DB", :db => true do
+ # around(:example) do |ex|
+ # MyORM.transaction(:rollback => true, &ex)
+ # end
+ # end
+ #
+ # ...there are two ways RSpec can treat the `:db => true` metadata, each
+ # of which has a corresponding config option:
+ #
+ # 1. `:trigger_inclusion`: this shared context will be implicitly included
+ # in any groups (or examples) that have `:db => true` metadata.
+ # 2. `:apply_to_host_groups`: the metadata will be inherited by the metadata
+ # hash of all host groups and examples.
+ #
+ # `:trigger_inclusion` is the legacy behavior from before RSpec 3.5 but should
+ # be considered deprecated. Instead, you can explicitly include a group with
+ # `include_context`:
+ #
+ # RSpec.describe "My model" do
+ # include_context "uses DB"
+ # end
+ #
+ # ...or you can configure RSpec to include the context based on matching metadata
+ # using an API that mirrors configured module inclusion:
+ #
+ # RSpec.configure do |rspec|
+ # rspec.include_context "uses DB", :db => true
+ # end
+ #
+ # `:apply_to_host_groups` is a new feature of RSpec 3.5 and will be the only
+ # supported behavior in RSpec 4.
+ #
+ # @overload shared_context_metadata_behavior
+ # @overload shared_context_metadata_behavior=
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def shared_context_metadata_behavior; end
+
+ # @see shared_context_metadata_behavior
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#434
+ def shared_context_metadata_behavior=(value); end
+
+ # Don't print filter info i.e. "Run options: include {:focus=>true}"
+ # (default `false`).
+ # return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def silence_filter_announcements; end
+
+ # Don't print filter info i.e. "Run options: include {:focus=>true}"
+ # (default `false`).
+ # return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def silence_filter_announcements=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def silence_filter_announcements?; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1138
+ def spec_files_with_failures; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def start_time; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def start_time=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def start_time?; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#520
+ def static_config_filter_manager; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#520
+ def static_config_filter_manager=(_arg0); end
+
+ # Color to use to indicate success. Defaults to `:green` but can be set
+ # to one of the following: `[:black, :white, :red, :green, :yellow,
+ # :blue, :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def success_color; end
+
+ # Color to use to indicate success. Defaults to `:green` but can be set
+ # to one of the following: `[:black, :white, :red, :green, :yellow,
+ # :blue, :magenta, :cyan]`
+ #
+ # @return [Symbol]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def success_color=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def success_color?; end
+
+ # Use threadsafe options where available.
+ # Currently this will place a mutex around memoized values such as let blocks.
+ # return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def threadsafe; end
+
+ # Use threadsafe options where available.
+ # Currently this will place a mutex around memoized values such as let blocks.
+ # return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def threadsafe=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def threadsafe?; end
+
+ # @deprecated This config option was added in RSpec 2 to pave the way
+ # for this being the default behavior in RSpec 3. Now this option is
+ # a no-op.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#383
+ def treat_symbols_as_metadata_keys_with_true_values=(_value); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#66
+ def tty; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#89
+ def tty=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#78
+ def tty?; end
+
+ # Set Ruby warnings on or off.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1755
+ def warnings=(value); end
+
+ # @return [Boolean] Whether or not ruby warnings are enabled.
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1760
+ def warnings?; end
+
+ # Defines a callback that runs after the first example with matching
+ # metadata is defined. If no examples are defined with matching metadata,
+ # it will not get called at all.
+ #
+ # This can be used to ensure some setup is performed (such as bootstrapping
+ # a DB or loading a specific file that adds significantly to the boot time)
+ # if needed (as indicated by the presence of an example with matching metadata)
+ # but avoided otherwise.
+ #
+ # @example
+ # RSpec.configure do |config|
+ # config.when_first_matching_example_defined(:db) do
+ # # Load a support file that does some heavyweight setup,
+ # # including bootstrapping the DB, but only if we have loaded
+ # # any examples tagged with `:db`.
+ # require 'support/db'
+ # end
+ # end
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1917
+ def when_first_matching_example_defined(*filters); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2085
+ def with_suite_hooks; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#518
+ def world; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#518
+ def world=(_arg0); end
+
+ private
+
+ # :nocov:
+ #
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2248
+ def absolute_pattern?(pattern); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2349
+ def add_hook_to_existing_matching_groups(meta, scope, &block); end
+
+ # @raise [MustBeConfiguredBeforeExampleGroupsError]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2288
+ def assert_no_example_groups_defined(config_option); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2338
+ def clear_values_derived_from_example_status_persistence_file_path; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2270
+ def command; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2314
+ def conditionally_disable_expectations_monkey_patching; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2305
+ def conditionally_disable_mocks_monkey_patching; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2343
+ def configure_group_with(group, module_list, application_method); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2278
+ def define_built_in_hooks; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2401
+ def define_mixed_in_module(mod, filters, mod_list, config_method, &block); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2253
+ def extract_location(path); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2230
+ def file_glob_from(path, pattern); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2219
+ def gather_directories(path); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2198
+ def get_files_to_run(paths); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2225
+ def get_matching_files(path, pattern); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2165
+ def handle_suite_hook(scope, meta); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2137
+ def load_file_handling_errors(method, file); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2371
+ def metadata_applies_to_group?(meta, group); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2363
+ def on_existing_matching_groups(meta); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2301
+ def output_to_tty?(output = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2297
+ def output_wrapper; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2210
+ def paths_to_check(paths); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2215
+ def pattern_might_load_specs_from_vendored_dirs?; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2324
+ def rspec_expectations_loaded?; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2320
+ def rspec_mocks_loaded?; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2180
+ def run_suite_hooks(hook_description, hooks); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2386
+ def safe_extend(mod, host); end
+
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#2382
+ def safe_include(mod, host); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2376
+ def safe_prepend(mod, host); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2328
+ def update_pattern_attr(name, value); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#2274
+ def value_for(key); end
+
+ class << self
+ # As `add_setting` but only add the reader.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#100
+ def add_read_only_setting(name, opts = T.unsafe(nil)); end
+
+ # Invoked by the `add_setting` instance method. Use that method on a
+ # `Configuration` instance rather than this class method.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#87
+ def add_setting(name, opts = T.unsafe(nil)); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#70
+ def define_alias(name, alias_name); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#77
+ def define_predicate(name); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#60
+ def define_reader(name); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1666
+ def delegate_to_ordering_manager(*methods); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#1646
+RSpec::Core::Configuration::DEFAULT_FORMATTER = T.let(T.unsafe(nil), Proc)
+
+# This buffer is used to capture all messages sent to the reporter during
+# reporter initialization. It can then replay those messages after the
+# formatter is correctly initialized. Otherwise, deprecation warnings
+# during formatter initialization can cause an infinite loop.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#1039
+class RSpec::Core::Configuration::DeprecationReporterBuffer
+ # @return [DeprecationReporterBuffer] a new instance of DeprecationReporterBuffer
+ #
+ # source://rspec-core//lib/rspec/core/configuration.rb#1040
+ def initialize; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#1044
+ def deprecation(*args); end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#1048
+ def play_onto(reporter); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#1815
+module RSpec::Core::Configuration::ExposeCurrentExample; end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#1126
+RSpec::Core::Configuration::FAILED_STATUS = T.let(T.unsafe(nil), String)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#749
+RSpec::Core::Configuration::MOCKING_ADAPTERS = T.let(T.unsafe(nil), Hash)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#57
+class RSpec::Core::Configuration::MustBeConfiguredBeforeExampleGroupsError < ::StandardError; end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#1129
+RSpec::Core::Configuration::PASSED_STATUS = T.let(T.unsafe(nil), String)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#1132
+RSpec::Core::Configuration::PENDING_STATUS = T.let(T.unsafe(nil), String)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#1765
+RSpec::Core::Configuration::RAISE_ERROR_WARNING_NOTIFIER = T.let(T.unsafe(nil), Proc)
+
+# Module that holds `attr_reader` declarations. It's in a separate
+# module to allow us to override those methods and use `super`.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#53
+module RSpec::Core::Configuration::Readers
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def default_color; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def default_path; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def deprecation_stream; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def detail_color; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def drb; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def drb_port; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def dry_run; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def error_exit_code; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def error_stream; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def example_status_persistence_file_path; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def exclude_pattern; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def fail_fast; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def fail_if_no_examples; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def failure_color; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def failure_exit_code; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def fixed_color; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def full_cause_backtrace; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def libs; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def max_displayed_failure_line_count; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def only_failures; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def output_stream; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def pattern; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def pending_color; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def pending_failure_output; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def project_source_dirs; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def requires; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def run_all_when_everything_filtered; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def shared_context_metadata_behavior; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def silence_filter_announcements; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def start_time; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def success_color; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def threadsafe; end
+
+ # source://rspec-core//lib/rspec/core/configuration.rb#63
+ def tty; end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#1123
+RSpec::Core::Configuration::UNKNOWN_STATUS = T.let(T.unsafe(nil), String)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/configuration.rb#1135
+RSpec::Core::Configuration::VALID_STATUSES = T.let(T.unsafe(nil), Array)
+
+# Responsible for utilizing externally provided configuration options,
+# whether via the command line, `.rspec`, `~/.rspec`,
+# `$XDG_CONFIG_HOME/rspec/options`, `.rspec-local` or a custom options
+# file.
+#
+# source://rspec-core//lib/rspec/core/configuration_options.rb#10
+class RSpec::Core::ConfigurationOptions
+ # @param args [Array] command line arguments
+ # @return [ConfigurationOptions] a new instance of ConfigurationOptions
+ #
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#12
+ def initialize(args); end
+
+ # @return [Array] the original command-line arguments
+ #
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#40
+ def args; end
+
+ # Updates the provided {Configuration} instance based on the provided
+ # external configuration options.
+ #
+ # @param config [Configuration] the configuration instance to update
+ #
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#21
+ def configure(config); end
+
+ # Updates the provided {FilterManager} based on the filter options.
+ #
+ # @api private
+ # @param filter_manager [FilterManager] instance to update
+ #
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#30
+ def configure_filter_manager(filter_manager); end
+
+ # @return [Hash] the final merged options, drawn from all external sources
+ #
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#37
+ def options; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#173
+ def args_from_options_file(path); end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#142
+ def command_line_options; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#146
+ def custom_options; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#188
+ def custom_options_file; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#133
+ def env_options; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#125
+ def file_options; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#66
+ def force?(key); end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#158
+ def global_options; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#200
+ def global_options_file; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#211
+ def home_options_file_path; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#121
+ def load_formatters_into(config); end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#150
+ def local_options; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#196
+ def local_options_file; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#180
+ def options_file_as_erb_string(path); end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#162
+ def options_from(path); end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#70
+ def order(keys); end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#44
+ def organize_options; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#167
+ def parse_args_ignoring_files_or_dirs_to_run(args, source); end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#113
+ def process_options_into(config); end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#154
+ def project_options; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#192
+ def project_options_file; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#227
+ def resolve_xdg_config_home; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#204
+ def xdg_options_file_if_exists; end
+
+ # source://rspec-core//lib/rspec/core/configuration_options.rb#220
+ def xdg_options_file_path; end
+end
+
+# source://rspec-core//lib/rspec/core/configuration_options.rb#77
+RSpec::Core::ConfigurationOptions::OPTIONS_ORDER = T.let(T.unsafe(nil), Array)
+
+# source://rspec-core//lib/rspec/core/configuration_options.rb#59
+RSpec::Core::ConfigurationOptions::UNFORCED_OPTIONS = T.let(T.unsafe(nil), RSpec::Core::Set)
+
+# source://rspec-core//lib/rspec/core/configuration_options.rb#64
+RSpec::Core::ConfigurationOptions::UNPROCESSABLE_OPTIONS = T.let(T.unsafe(nil), RSpec::Core::Set)
+
+# DSL defines methods to group examples, most notably `describe`,
+# and exposes them as class methods of {RSpec}. They can also be
+# exposed globally (on `main` and instances of `Module`) through
+# the {Configuration} option `expose_dsl_globally`.
+#
+# By default the methods `describe`, `context` and `example_group`
+# are exposed. These methods define a named context for one or
+# more examples. The given block is evaluated in the context of
+# a generated subclass of {RSpec::Core::ExampleGroup}.
+#
+# ## Examples:
+#
+# RSpec.describe "something" do
+# context "when something is a certain way" do
+# it "does something" do
+# # example code goes here
+# end
+# end
+# end
+#
+# @see ExampleGroup
+# @see ExampleGroup.example_group
+#
+# source://rspec-core//lib/rspec/core/dsl.rb#25
+module RSpec::Core::DSL
+ class << self
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/dsl.rb#89
+ def change_global_dsl(&changes); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/dsl.rb#27
+ def example_group_aliases; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/dsl.rb#37
+ def expose_example_group_alias(name); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/dsl.rb#81
+ def expose_example_group_alias_globally(method_name); end
+
+ # Adds the describe method to Module and the top level binding.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/dsl.rb#58
+ def expose_globally!; end
+
+ # @private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/dsl.rb#32
+ def exposed_globally?; end
+
+ # Removes the describe method from Module and the top level binding.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/dsl.rb#70
+ def remove_globally!; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/dsl.rb#53
+ def top_level; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/dsl.rb#53
+ def top_level=(_arg0); end
+ end
+end
+
+# Deprecation Error.
+#
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#221
+class RSpec::Core::DeprecationError < ::StandardError; end
+
+# Wrapper around Ruby's `DidYouMean::SpellChecker` when available to provide file name suggestions.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/did_you_mean.rb#5
+class RSpec::Core::DidYouMean
+ # @return [DidYouMean] a new instance of DidYouMean
+ #
+ # source://rspec-core//lib/rspec/core/did_you_mean.rb#8
+ def initialize(relative_file_name); end
+
+ # return a hint if API for ::DidYouMean::SpellChecker not supported
+ #
+ # source://rspec-core//lib/rspec/core/did_you_mean.rb#14
+ def call; end
+
+ # Returns the value of attribute relative_file_name.
+ #
+ # source://rspec-core//lib/rspec/core/did_you_mean.rb#6
+ def relative_file_name; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/did_you_mean.rb#30
+ def formats(probables); end
+
+ # source://rspec-core//lib/rspec/core/did_you_mean.rb#40
+ def red_font(mytext); end
+
+ # source://rspec-core//lib/rspec/core/did_you_mean.rb#35
+ def top_and_tail(rspec_format); end
+end
+
+# Wrapper for an instance of a subclass of {ExampleGroup}. An instance of
+# `RSpec::Core::Example` is returned by example definition methods
+# such as {ExampleGroup.it it} and is yielded to the {ExampleGroup.it it},
+# {Hooks#before before}, {Hooks#after after}, {Hooks#around around},
+# {MemoizedHelpers::ClassMethods#let let} and
+# {MemoizedHelpers::ClassMethods#subject subject} blocks.
+#
+# This allows us to provide rich metadata about each individual
+# example without adding tons of methods directly to the ExampleGroup
+# that users may inadvertently redefine.
+#
+# Useful for configuring logging and/or taking some action based
+# on the state of an example's metadata.
+#
+# @example
+#
+# RSpec.configure do |config|
+# config.before do |example|
+# log example.description
+# end
+#
+# config.after do |example|
+# log example.description
+# end
+#
+# config.around do |example|
+# log example.description
+# example.run
+# end
+# end
+#
+# shared_examples "auditable" do
+# it "does something" do
+# log "#{example.full_description}: #{auditable.inspect}"
+# auditable.should do_something
+# end
+# end
+# @note Example blocks are evaluated in the context of an instance
+# of an `ExampleGroup`, not in the context of an instance of `Example`.
+# @see ExampleGroup
+#
+# source://rspec-core//lib/rspec/core/example.rb#44
+class RSpec::Core::Example
+ # Creates a new instance of Example.
+ #
+ # @api private
+ # @param example_group_class [Class] the subclass of ExampleGroup in which
+ # this Example is declared
+ # @param description [String] the String passed to the `it` method (or
+ # alias)
+ # @param user_metadata [Hash] additional args passed to `it` to be used as
+ # metadata
+ # @param example_block [Proc] the block of code that represents the
+ # example
+ # @return [Example] a new instance of Example
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#186
+ def initialize(example_group_class, description, user_metadata, example_block = T.unsafe(nil)); end
+
+ # @attr
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#174
+ def clock; end
+
+ # @attr
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#174
+ def clock=(_arg0); end
+
+ # Returns the string submitted to `example` or its aliases (e.g.
+ # `specify`, `it`, etc). If no string is submitted (e.g.
+ # `it { is_expected.to do_something }`) it returns the message generated
+ # by the matcher if there is one, otherwise returns a message including
+ # the location of the example.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#76
+ def description; end
+
+ # The exception that will be displayed to the user -- either the failure of
+ # the example or the `pending_exception` if the example is pending.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#388
+ def display_exception; end
+
+ # Assigns the exception that will be displayed to the user -- either the failure of
+ # the example or the `pending_exception` if the example is pending.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#396
+ def display_exception=(ex); end
+
+ # Duplicates the example and overrides metadata with the provided
+ # hash.
+ #
+ # @param metadata_overrides [Hash] the hash to override the example metadata
+ # @return [Example] a duplicate of the example with modified metadata
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#132
+ def duplicate_with(metadata_overrides = T.unsafe(nil)); end
+
+ # Returns the example group class that provides the context for running
+ # this example.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#230
+ def example_group; end
+
+ # Returns the example_group_instance that provides the context for
+ # running this example.
+ #
+ # @attr_reader
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#170
+ def example_group_instance; end
+
+ # Returns the first exception raised in the context of running this
+ # example (nil if no exception is raised).
+ #
+ # @attr_reader
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#158
+ def exception; end
+
+ # @return [ExecutionResult] represents the result of running this example.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#49
+ def execution_result; end
+
+ # Used internally to set an exception and fail without actually executing
+ # the example when an exception is raised in before(:context).
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#439
+ def fail_with_exception(reporter, exception); end
+
+ # @return [String] the relative path to the file where this example was
+ # defined.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#49
+ def file_path; end
+
+ # @return [String] the full description (including the docstrings of
+ # all parent example groups).
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#49
+ def full_description; end
+
+ # @return [String] the unique id of this example. Pass
+ # this at the command line to re-run this exact example.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#117
+ def id; end
+
+ # Provide a human-readable representation of this class
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#220
+ def inspect; end
+
+ # Returns a description of the example that always includes the location.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#87
+ def inspect_output; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#456
+ def instance_exec(*args, &block); end
+
+ # @return [String] the exact source location of this example in a form
+ # like `./path/to/spec.rb:17`
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#49
+ def location; end
+
+ # Returns the location-based argument that can be passed to the `rspec` command to rerun this example.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#96
+ def location_rerun_argument; end
+
+ # Returns the metadata object associated with this example.
+ #
+ # @attr_reader
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#163
+ def metadata; end
+
+ # @return [Boolean] flag that indicates that the example is not expected
+ # to pass. It will be run and will either have a pending result (if a
+ # failure occurs) or a failed result (if no failure occurs).
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#49
+ def pending; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#234
+ def pending?; end
+
+ # @return [RSpec::Core::Reporter] the current reporter for the example
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#226
+ def reporter; end
+
+ # Returns the location-based argument that can be passed to the `rspec` command to rerun this example.
+ #
+ # @deprecated Use {#location_rerun_argument} instead.
+ # @note If there are multiple examples identified by this location, they will use {#id}
+ # to rerun instead, but this method will still return the location (that's why it is deprecated!).
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#111
+ def rerun_argument; end
+
+ # instance_execs the block passed to the constructor in the context of
+ # the instance of {ExampleGroup}.
+ #
+ # @api private
+ # @param example_group_instance the instance of an ExampleGroup subclass
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#246
+ def run(example_group_instance, reporter); end
+
+ # Used to set the exception when `aggregate_failures` fails.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#425
+ def set_aggregate_failures_exception(exception); end
+
+ # Used internally to set an exception in an after hook, which
+ # captures the exception but doesn't raise it.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#412
+ def set_exception(exception); end
+
+ # @return [Boolean] flag that will cause the example to not run.
+ # The {ExecutionResult} status will be `:pending`.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#49
+ def skip; end
+
+ # Used internally to skip without actually executing the example when
+ # skip is used in before(:context).
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#449
+ def skip_with_exception(reporter, exception); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#238
+ def skipped?; end
+
+ # Provide a human-readable representation of this class
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#220
+ def to_s; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#148
+ def update_inherited_metadata(updates); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/example.rb#534
+ def assign_generated_description; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#478
+ def finish(reporter); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#543
+ def generate_description; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#462
+ def hooks; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#550
+ def location_description; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#530
+ def mocks_need_verification?; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#498
+ def record_finished(status, reporter); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#516
+ def run_after_example; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#503
+ def run_before_example; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#473
+ def start(reporter); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#524
+ def verify_mocks; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#508
+ def with_around_and_singleton_context_hooks; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#466
+ def with_around_example_hooks; end
+
+ class << self
+ # Used to define methods that delegate to this example's metadata.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#48
+ def delegate_to_metadata(key); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#122
+ def parse_id(id); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/example.rb#310
+RSpec::Core::Example::AllExceptionsExcludingDangerousOnesOnRubiesThatAllowIt = RSpec::Support::AllExceptionsExceptOnesWeMustNotRescue
+
+# Represents the result of executing an example.
+# Behaves like a hash for backwards compatibility.
+#
+# source://rspec-core//lib/rspec/core/example.rb#556
+class RSpec::Core::Example::ExecutionResult
+ include ::RSpec::Core::HashImitatable
+ extend ::RSpec::Core::HashImitatable::ClassMethods
+
+ # Populates finished_at and run_time if it has not yet been set
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#610
+ def ensure_timing_set(clock); end
+
+ # @return [Boolean] Indicates if the example was completely skipped
+ # (typically done via `:skip` metadata or the `skip` method). Skipped examples
+ # will have a `:pending` result. A `:pending` result can also come from examples
+ # that were marked as `:pending`, which causes them to be run, and produces a
+ # `:failed` result if the example passes.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#597
+ def example_skipped?; end
+
+ # @return [Exception, nil] The failure, if there was one.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def exception; end
+
+ # @return [Exception, nil] The failure, if there was one.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def exception=(_arg0); end
+
+ # @return [Time] When the example finished.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def finished_at; end
+
+ # @return [Time] When the example finished.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def finished_at=(_arg0); end
+
+ # @return [Exception, nil] The exception triggered while
+ # executing the pending example. If no exception was triggered
+ # it would no longer get a status of `:pending` unless it was
+ # tagged with `:skip`.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def pending_exception; end
+
+ # @return [Exception, nil] The exception triggered while
+ # executing the pending example. If no exception was triggered
+ # it would no longer get a status of `:pending` unless it was
+ # tagged with `:skip`.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def pending_exception=(_arg0); end
+
+ # @return [Boolean] For examples tagged with `:pending`,
+ # this indicates whether or not it now passes.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def pending_fixed; end
+
+ # @return [Boolean] For examples tagged with `:pending`,
+ # this indicates whether or not it now passes.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def pending_fixed=(_arg0); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#588
+ def pending_fixed?; end
+
+ # @return [String, nil] The reason the example was pending,
+ # or nil if the example was not pending.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def pending_message; end
+
+ # @return [String, nil] The reason the example was pending,
+ # or nil if the example was not pending.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def pending_message=(_arg0); end
+
+ # Records the finished status of the example.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#603
+ def record_finished(status, finished_at); end
+
+ # @return [Float] How long the example took in seconds.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def run_time; end
+
+ # @return [Float] How long the example took in seconds.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def run_time=(_arg0); end
+
+ # @return [Time] When the example started.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def started_at; end
+
+ # @return [Time] When the example started.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def started_at=(_arg0); end
+
+ # @return [Symbol] `:passed`, `:failed` or `:pending`.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def status; end
+
+ # @return [Symbol] `:passed`, `:failed` or `:pending`.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#442
+ def status=(_arg0); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/example.rb#616
+ def calculate_run_time(finished_at); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#634
+ def get_value(name); end
+
+ # For backwards compatibility we present `status` as a string
+ # when presenting the legacy hash interface.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#623
+ def hash_for_delegation; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#642
+ def issue_deprecation(_method_name, *_args); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#629
+ def set_value(name, value); end
+end
+
+# Wraps both a `Proc` and an {Example} for use in {Hooks#around
+# around} hooks. In around hooks we need to yield this special
+# kind of object (rather than the raw {Example}) because when
+# there are multiple `around` hooks we have to wrap them recursively.
+#
+# @example
+#
+# RSpec.configure do |c|
+# c.around do |ex| # Procsy which wraps the example
+# if ex.metadata[:key] == :some_value && some_global_condition
+# raise "some message"
+# end
+# ex.run # run delegates to ex.call.
+# end
+# end
+# @note This class also exposes the instance methods of {Example},
+# proxying them through to the wrapped {Example} instance.
+#
+# source://rspec-core//lib/rspec/core/example.rb#331
+class RSpec::Core::Example::Procsy
+ # @return [Procsy] a new instance of Procsy
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#362
+ def initialize(example, &block); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def <<(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def ==(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def ===(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def >>(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def [](*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def arity(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def binding(*a, &b); end
+
+ # Calls the proc and notes that the example has been executed.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#350
+ def call(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def clock(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def clock=(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def clone(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def curry(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def description(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def dup(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def duplicate_with(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def eql?(*a, &b); end
+
+ # The {Example} instance.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#333
+ def example; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def example_group(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def example_group_instance(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def exception(*a, &b); end
+
+ # Indicates whether or not the around hook has executed the example.
+ #
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#374
+ def executed?; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def execution_result(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def file_path(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def full_description(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def hash(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def id(*a, &b); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#379
+ def inspect; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def inspect_output(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def lambda?(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def location(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def location_rerun_argument(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def metadata(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def parameters(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def pending(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def pending?(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def reporter(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def rerun_argument(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def ruby2_keywords(*a, &b); end
+
+ # Calls the proc and notes that the example has been executed.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#350
+ def run(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def skip(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def skipped?(*a, &b); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def source_location(*a, &b); end
+
+ # Provides a wrapped proc that will update our `executed?` state when
+ # executed.
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#358
+ def to_proc; end
+
+ # source://rspec-core//lib/rspec/core/example.rb#339
+ def update_inherited_metadata(*a, &b); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#369
+ def wrap(&block); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#346
+ def yield(*a, &b); end
+end
+
+# ExampleGroup and {Example} are the main structural elements of
+# rspec-core. Consider this example:
+#
+# RSpec.describe Thing do
+# it "does something" do
+# end
+# end
+#
+# The object returned by `describe Thing` is a subclass of ExampleGroup.
+# The object returned by `it "does something"` is an instance of Example,
+# which serves as a wrapper for an instance of the ExampleGroup in which it
+# is declared.
+#
+# Example group bodies (e.g. `describe` or `context` blocks) are evaluated
+# in the context of a new subclass of ExampleGroup. Individual examples are
+# evaluated in the context of an instance of the specific ExampleGroup
+# subclass to which they belong.
+#
+# Besides the class methods defined here, there are other interesting macros
+# defined in {Hooks}, {MemoizedHelpers::ClassMethods} and
+# {SharedExampleGroup}. There are additional instance methods available to
+# your examples defined in {MemoizedHelpers} and {Pending}.
+#
+# source://rspec-core//lib/rspec/core/example_group.rb#29
+class RSpec::Core::ExampleGroup
+ include ::RSpec::Core::MemoizedHelpers
+ include ::RSpec::Core::Pending
+ extend ::RSpec::Core::Hooks
+ extend ::RSpec::Core::MemoizedHelpers::ClassMethods
+ extend ::RSpec::Core::SharedExampleGroup
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#707
+ def initialize(inspect_output = T.unsafe(nil)); end
+
+ # Returns the class or module passed to the `describe` method (or alias).
+ # Returns nil if the subject is not a class or module.
+ #
+ # @example
+ # RSpec.describe Thing do
+ # it "does something" do
+ # described_class == Thing
+ # end
+ # end
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#99
+ def described_class; end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#713
+ def inspect; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#758
+ def method_missing(name, *args, **_arg2); end
+
+ class << self
+ # Adds an example to the example group
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#367
+ def add_example(example); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#529
+ def before_context_ivars; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#466
+ def children; end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#247
+ def context(*args, &example_group_block); end
+
+ # Returns true if a `before(:context)` or `after(:context)`
+ # hook is currently executing.
+ #
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#542
+ def currently_executing_a_context_hook?; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#667
+ def declaration_locations; end
+
+ # @private
+ # @see DSL#describe
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#246
+ def define_example_group_method(name, metadata = T.unsafe(nil)); end
+
+ # @example
+ # $1 "does something", :slow, :load_factor => 100 do
+ # end
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#145
+ def define_example_method(name, extra_options = T.unsafe(nil)); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#317
+ def define_nested_shared_group_method(new_name, report_label = T.unsafe(nil)); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#76
+ def delegate_to_metadata(*names); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#460
+ def descendant_filtered_examples; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#503
+ def descendants; end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#247
+ def describe(*args, &example_group_block); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#78
+ def described_class; end
+
+ # @return [String] the current example group description
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#85
+ def description; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#700
+ def each_instance_variable_for_example(group); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#518
+ def ensure_example_groups_are_configured; end
+
+ # Defines an example within a group.
+ #
+ # @example
+ # example do
+ # end
+ #
+ # example "does something" do
+ # end
+ #
+ # example "does something", :slow, :uses_js do
+ # end
+ #
+ # example "does something", :with => 'additional metadata' do
+ # end
+ #
+ # example "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload example
+ # @overload example
+ # @overload example
+ # @overload example
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def example(*all_args, &block); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#247
+ def example_group(*args, &example_group_block); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#450
+ def examples; end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#247
+ def fcontext(*args, &example_group_block); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#247
+ def fdescribe(*args, &example_group_block); end
+
+ # Shortcut to define an example with `:focus => true`.
+ #
+ # @example
+ # fexample do
+ # end
+ #
+ # fexample "does something" do
+ # end
+ #
+ # fexample "does something", :slow, :uses_js do
+ # end
+ #
+ # fexample "does something", :with => 'additional metadata' do
+ # end
+ #
+ # fexample "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload fexample
+ # @overload fexample
+ # @overload fexample
+ # @overload fexample
+ # @see example
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def fexample(*all_args, &block); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#78
+ def file_path; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#455
+ def filtered_examples; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#379
+ def find_and_eval_shared(label, name, inclusion_location, *args, &customization_block); end
+
+ # Shortcut to define an example with `:focus => true`.
+ #
+ # @example
+ # fit do
+ # end
+ #
+ # fit "does something" do
+ # end
+ #
+ # fit "does something", :slow, :uses_js do
+ # end
+ #
+ # fit "does something", :with => 'additional metadata' do
+ # end
+ #
+ # fit "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload fit
+ # @overload fit
+ # @overload fit
+ # @overload fit
+ # @see example
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def fit(*all_args, &block); end
+
+ # Shortcut to define an example with `:focus => true`.
+ #
+ # @example
+ # focus do
+ # end
+ #
+ # focus "does something" do
+ # end
+ #
+ # focus "does something", :slow, :uses_js do
+ # end
+ #
+ # focus "does something", :with => 'additional metadata' do
+ # end
+ #
+ # focus "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload focus
+ # @overload focus
+ # @overload focus
+ # @overload focus
+ # @see example
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def focus(*all_args, &block); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#655
+ def for_filtered_examples(reporter, &block); end
+
+ # Shortcut to define an example with `:focus => true`.
+ #
+ # @example
+ # fspecify do
+ # end
+ #
+ # fspecify "does something" do
+ # end
+ #
+ # fspecify "does something", :slow, :uses_js do
+ # end
+ #
+ # fspecify "does something", :with => 'additional metadata' do
+ # end
+ #
+ # fspecify "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload fspecify
+ # @overload fspecify
+ # @overload fspecify
+ # @overload fspecify
+ # @see example
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def fspecify(*all_args, &block); end
+
+ # @return [String] the unique id of this example group. Pass
+ # this at the command line to re-run this exact example group.
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#675
+ def id; end
+
+ # Define a singleton method for the singleton class (remove the method if
+ # it's already been defined).
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#40
+ def idempotently_define_singleton_method(name, &definition); end
+
+ # Includes shared content mapped to `name` directly in the group in which
+ # it is declared, as opposed to `it_behaves_like`, which creates a nested
+ # group. If given a block, that block is also eval'd in the current
+ # context.
+ #
+ # @see SharedExampleGroup
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#343
+ def include_context(name, *args, &block); end
+
+ # Includes shared content mapped to `name` directly in the group in which
+ # it is declared, as opposed to `it_behaves_like`, which creates a nested
+ # group. If given a block, that block is also eval'd in the current
+ # context.
+ #
+ # @see SharedExampleGroup
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#353
+ def include_examples(name, *args, &block); end
+
+ # Defines an example within a group.
+ # This is the primary API to define a code example.
+ #
+ # @example
+ # it do
+ # end
+ #
+ # it "does something" do
+ # end
+ #
+ # it "does something", :slow, :uses_js do
+ # end
+ #
+ # it "does something", :with => 'additional metadata' do
+ # end
+ #
+ # it "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload it
+ # @overload it
+ # @overload it
+ # @overload it
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def it(*all_args, &block); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#318
+ def it_behaves_like(name, *args, &customization_block); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#318
+ def it_should_behave_like(name, *args, &customization_block); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#78
+ def location; end
+
+ # The [Metadata](Metadata) object associated with this group.
+ #
+ # @see Metadata
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#51
+ def metadata; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#485
+ def next_runnable_index_for(file); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#625
+ def ordering_strategy; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#508
+ def parent_groups; end
+
+ # Shortcut to define an example with `:pending => true`
+ #
+ # @example
+ # pending do
+ # end
+ #
+ # pending "does something" do
+ # end
+ #
+ # pending "does something", :slow, :uses_js do
+ # end
+ #
+ # pending "does something", :with => 'additional metadata' do
+ # end
+ #
+ # pending "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload pending
+ # @overload pending
+ # @overload pending
+ # @overload pending
+ # @see example
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def pending(*all_args, &block); end
+
+ # Removes an example from the example group
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#373
+ def remove_example(example); end
+
+ # Clear memoized values when adding/removing examples
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#359
+ def reset_memoized; end
+
+ # Runs all the examples in this group.
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#599
+ def run(reporter = T.unsafe(nil)); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#585
+ def run_after_context_hooks(example_group_instance); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#547
+ def run_before_context_hooks(example_group_instance); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#641
+ def run_examples(reporter); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#410
+ def set_it_up(description, args, registration_collection, &example_group_block); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#685
+ def set_ivars(instance, ivars); end
+
+ # Shortcut to define an example with `:skip => true`
+ #
+ # @example
+ # skip do
+ # end
+ #
+ # skip "does something" do
+ # end
+ #
+ # skip "does something", :slow, :uses_js do
+ # end
+ #
+ # skip "does something", :with => 'additional metadata' do
+ # end
+ #
+ # skip "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload skip
+ # @overload skip
+ # @overload skip
+ # @overload skip
+ # @see example
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def skip(*all_args, &block); end
+
+ # Defines an example within a group.
+ # Useful for when your docstring does not read well off of `it`.
+ #
+ # @example
+ # RSpec.describe MyClass do
+ # specify "#do_something is deprecated" do
+ # # ...
+ # end
+ # end
+ # @example
+ # specify do
+ # end
+ #
+ # specify "does something" do
+ # end
+ #
+ # specify "does something", :slow, :uses_js do
+ # end
+ #
+ # specify "does something", :with => 'additional metadata' do
+ # end
+ #
+ # specify "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload specify
+ # @overload specify
+ # @overload specify
+ # @overload specify
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def specify(*all_args, &block); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#534
+ def store_before_context_ivars(example_group_instance); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#395
+ def subclass(parent, description, args, registration_collection, &example_group_block); end
+
+ # :nocov:
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#562
+ def superclass_before_context_ivars; end
+
+ # @private
+ # @return [Metadata] belonging to the parent of a nested {ExampleGroup}
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#71
+ def superclass_metadata; end
+
+ # @private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#513
+ def top_level?; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#680
+ def top_level_description; end
+
+ # Traverses the tree of groups, starting with `self`, then the children, recursively.
+ # Halts the traversal of a branch of the tree as soon as the passed block returns true.
+ # Note that siblings groups and their sub-trees will continue to be explored.
+ # This is intended to make it easy to find the top-most group that satisfies some
+ # condition.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#476
+ def traverse_tree_until(&block); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#727
+ def update_inherited_metadata(updates); end
+
+ # Temporarily replace the provided metadata.
+ # Intended primarily to allow an example group's singleton class
+ # to return the metadata of the example that it exists for. This
+ # is necessary for shared example group inclusion to work properly
+ # with singleton example groups.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#61
+ def with_replaced_metadata(meta); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#247
+ def xcontext(*args, &example_group_block); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#247
+ def xdescribe(*args, &example_group_block); end
+
+ # Shortcut to define an example with `:skip => 'Temporarily skipped with xexample'`.
+ #
+ # @example
+ # xexample do
+ # end
+ #
+ # xexample "does something" do
+ # end
+ #
+ # xexample "does something", :slow, :uses_js do
+ # end
+ #
+ # xexample "does something", :with => 'additional metadata' do
+ # end
+ #
+ # xexample "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload xexample
+ # @overload xexample
+ # @overload xexample
+ # @overload xexample
+ # @see example
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def xexample(*all_args, &block); end
+
+ # Shortcut to define an example with `:skip => 'Temporarily skipped with xit'`.
+ #
+ # @example
+ # xit do
+ # end
+ #
+ # xit "does something" do
+ # end
+ #
+ # xit "does something", :slow, :uses_js do
+ # end
+ #
+ # xit "does something", :with => 'additional metadata' do
+ # end
+ #
+ # xit "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload xit
+ # @overload xit
+ # @overload xit
+ # @overload xit
+ # @see example
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def xit(*all_args, &block); end
+
+ # Shortcut to define an example with `:skip => 'Temporarily skipped with xspecify'`.
+ #
+ # @example
+ # xspecify do
+ # end
+ #
+ # xspecify "does something" do
+ # end
+ #
+ # xspecify "does something", :slow, :uses_js do
+ # end
+ #
+ # xspecify "does something", :with => 'additional metadata' do
+ # end
+ #
+ # xspecify "does something" do |ex|
+ # # ex is the Example object that contains metadata about the example
+ # end
+ # @overload xspecify
+ # @overload xspecify
+ # @overload xspecify
+ # @overload xspecify
+ # @see example
+ # @yield [Example] the example object
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#146
+ def xspecify(*all_args, &block); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#742
+ def method_missing(name, *args); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/example_group.rb#696
+RSpec::Core::ExampleGroup::INSTANCE_VARIABLE_TO_IGNORE = T.let(T.unsafe(nil), Symbol)
+
+# Raised when an RSpec API is called in the wrong scope, such as `before`
+# being called from within an example rather than from within an example
+# group block.
+#
+# source://rspec-core//lib/rspec/core/example_group.rb#740
+class RSpec::Core::ExampleGroup::WrongScopeError < ::NoMethodError; end
+
+# Dumps a list of hashes in a pretty, human readable format
+# for later parsing. The hashes are expected to have symbol
+# keys and string values, and each hash should have the same
+# set of keys.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/example_status_persister.rb#143
+class RSpec::Core::ExampleStatusDumper
+ # @return [ExampleStatusDumper] a new instance of ExampleStatusDumper
+ #
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#148
+ def initialize(examples); end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#152
+ def dump; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#188
+ def column_widths; end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#159
+ def formatted_header_rows; end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#176
+ def formatted_row_from(row_values); end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#166
+ def formatted_value_rows; end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#184
+ def headers; end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#172
+ def rows; end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#144
+ def dump(examples); end
+ end
+end
+
+# Merges together a list of example statuses from this run
+# and a list from previous runs (presumably loaded from disk).
+# Each example status object is expected to be a hash with
+# at least an `:example_id` and a `:status` key. Examples that
+# were loaded but not executed (due to filtering, `--fail-fast`
+# or whatever) should have a `:status` of `UNKNOWN_STATUS`.
+#
+# This will produce a new list that:
+# - Will be missing examples from previous runs that we know for sure
+# no longer exist.
+# - Will have the latest known status for any examples that either
+# definitively do exist or may still exist.
+# - Is sorted by file name and example definition order, so that
+# the saved file is easily scannable if users want to inspect it.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/example_status_persister.rb#74
+class RSpec::Core::ExampleStatusMerger
+ # @return [ExampleStatusMerger] a new instance of ExampleStatusMerger
+ #
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#79
+ def initialize(this_run, from_previous_runs); end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#85
+ def merge; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#102
+ def delete_previous_examples_that_no_longer_exist; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#108
+ def example_must_no_longer_exist?(ex_id); end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#95
+ def hash_from(example_list); end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#124
+ def loaded_spec_files; end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#132
+ def sort_value_from(example); end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#128
+ def spec_file_from(ex_id); end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#75
+ def merge(this_run, from_previous_runs); end
+ end
+end
+
+# Parses a string that has been previously dumped by ExampleStatusDumper.
+# Note that this parser is a bit naive in that it does a simple split on
+# "\n" and " | ", with no concern for handling escaping. For now, that's
+# OK because the values we plan to persist (example id, status, and perhaps
+# example duration) are highly unlikely to contain "\n" or " | " -- after
+# all, who puts those in file names?
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/example_status_persister.rb#207
+class RSpec::Core::ExampleStatusParser
+ # @return [ExampleStatusParser] a new instance of ExampleStatusParser
+ #
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#212
+ def initialize(string); end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#216
+ def parse; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#226
+ def headers; end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#222
+ def parse_row(line); end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#230
+ def split_line(line); end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#208
+ def parse(string); end
+ end
+end
+
+# Persists example ids and their statuses so that we can filter
+# to just the ones that failed the last time they ran.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/example_status_persister.rb#8
+class RSpec::Core::ExampleStatusPersister
+ # @return [ExampleStatusPersister] a new instance of ExampleStatusPersister
+ #
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#18
+ def initialize(examples, file_name); end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#23
+ def persist; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#40
+ def dump_statuses(unparsed_previous_runs); end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#46
+ def statuses_from_this_run; end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#9
+ def load_from(file_name); end
+
+ # source://rspec-core//lib/rspec/core/example_status_persister.rb#14
+ def persist(examples, file_name); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/filter_manager.rb#183
+RSpec::Core::ExclusionRules = RSpec::Core::FilterRules
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/filter_manager.rb#4
+class RSpec::Core::FilterManager
+ # @return [FilterManager] a new instance of FilterManager
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#7
+ def initialize; end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#22
+ def add_ids(rerun_path, scoped_ids); end
+
+ # @api private
+ # @param file_path [String]
+ # @param line_numbers [Array]
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#15
+ def add_location(file_path, line_numbers); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#30
+ def empty?; end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#57
+ def exclude(*args); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#61
+ def exclude_only(*args); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#65
+ def exclude_with_low_priority(*args); end
+
+ # Returns the value of attribute exclusions.
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#5
+ def exclusions; end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#69
+ def include(*args); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#73
+ def include_only(*args); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#77
+ def include_with_low_priority(*args); end
+
+ # Returns the value of attribute inclusions.
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#5
+ def inclusions; end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#34
+ def prune(examples); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#83
+ def add_path_to_arrays_filter(filter_key, path, values); end
+
+ # When a user specifies a particular spec location, that takes priority
+ # over any exclusion filters (such as if the spec is tagged with `:slow`
+ # and there is a `:slow => true` exclusion filter), but only for specs
+ # defined in the same file as the location filters. Excluded specs in
+ # other files should still be excluded.
+ #
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#101
+ def file_scoped_include?(ex_metadata, ids, locations); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#89
+ def prune_conditionally_filtered_examples(examples); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/filter_manager.rb#115
+class RSpec::Core::FilterRules
+ # @return [FilterRules] a new instance of FilterRules
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#130
+ def initialize(rules = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#161
+ def [](key); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#134
+ def add(updated); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#138
+ def add_with_low_priority(updated); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#149
+ def clear; end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#153
+ def delete(key); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#173
+ def description; end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#169
+ def each_pair(&block); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#165
+ def empty?; end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#157
+ def fetch(*args, &block); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#177
+ def include_example?(example); end
+
+ # Returns the value of attribute opposite.
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#119
+ def opposite; end
+
+ # Sets the attribute opposite
+ #
+ # @param value the value to set the attribute opposite to.
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#119
+ def opposite=(_arg0); end
+
+ # Returns the value of attribute rules.
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#120
+ def rules; end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#144
+ def use_only(updated); end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#122
+ def build; end
+ end
+end
+
+# source://rspec-core//lib/rspec/core/filter_manager.rb#116
+RSpec::Core::FilterRules::PROC_HEX_NUMBER = T.let(T.unsafe(nil), Regexp)
+
+# source://rspec-core//lib/rspec/core/filter_manager.rb#117
+RSpec::Core::FilterRules::PROJECT_DIR = T.let(T.unsafe(nil), String)
+
+# Tracks a collection of filterable items (e.g. modules, hooks, etc)
+# and provides an optimized API to get the applicable items for the
+# metadata of an example or example group.
+#
+# There are two implementations, optimized for different uses.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/metadata_filter.rb#87
+module RSpec::Core::FilterableItemRepository; end
+
+# This implementation is much more complex, and is optimized for
+# rare (or hopefully no) updates once the queries start. Updates
+# incur a cost as it has to clear the memoization and keep track
+# of applicable keys. Queries will be O(N) the first time an item
+# is provided with a given set of applicable metadata; subsequent
+# queries with items with the same set of applicable metadata will
+# be O(1) due to internal memoization.
+#
+# This is ideal for use by config, where filterable items (e.g. hooks)
+# are typically added at the start of the process (e.g. in `spec_helper`)
+# and then repeatedly queried as example groups and examples are defined.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/metadata_filter.rb#151
+class RSpec::Core::FilterableItemRepository::QueryOptimized < ::RSpec::Core::FilterableItemRepository::UpdateOptimized
+ # @return [QueryOptimized] a new instance of QueryOptimized
+ #
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#155
+ def initialize(applies_predicate); end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#164
+ def append(item, metadata); end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#174
+ def delete(item, metadata); end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#179
+ def items_for(metadata); end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#169
+ def prepend(item, metadata); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#217
+ def applicable_metadata_from(metadata); end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#118
+ def find_items_for(request_meta); end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#211
+ def handle_mutation(metadata); end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#235
+ def proc_keys_from(metadata); end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#203
+ def reconstruct_caches; end
+end
+
+# This implementation is simple, and is optimized for frequent
+# updates but rare queries. `append` and `prepend` do no extra
+# processing, and no internal memoization is done, since this
+# is not optimized for queries.
+#
+# This is ideal for use by a example or example group, which may
+# be updated multiple times with globally configured hooks, etc,
+# but will not be queried frequently by other examples or example
+# groups.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/metadata_filter.rb#98
+class RSpec::Core::FilterableItemRepository::UpdateOptimized
+ # @return [UpdateOptimized] a new instance of UpdateOptimized
+ #
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#101
+ def initialize(applies_predicate); end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#106
+ def append(item, metadata); end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#114
+ def delete(item, metadata); end
+
+ # Returns the value of attribute items_and_filters.
+ #
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#99
+ def items_and_filters; end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#118
+ def items_for(request_meta); end
+
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#110
+ def prepend(item, metadata); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/flat_map.rb#4
+module RSpec::Core::FlatMap
+ private
+
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/flat_map.rb#6
+ def flat_map(array, &block); end
+
+ class << self
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/flat_map.rb#6
+ def flat_map(array, &block); end
+ end
+end
+
+# ## Built-in Formatters
+#
+# * progress (default) - Prints dots for passing examples, `F` for failures, `*`
+# for pending.
+# * documentation - Prints the docstrings passed to `describe` and `it` methods
+# (and their aliases).
+# * html
+# * json - Useful for archiving data for subsequent analysis.
+#
+# The progress formatter is the default, but you can choose any one or more of
+# the other formatters by passing with the `--format` (or `-f` for short)
+# command-line option, e.g.
+#
+# rspec --format documentation
+#
+# You can also send the output of multiple formatters to different streams, e.g.
+#
+# rspec --format documentation --format html --out results.html
+#
+# This example sends the output of the documentation formatter to `$stdout`, and
+# the output of the html formatter to results.html.
+#
+# ## Custom Formatters
+#
+# You can tell RSpec to use a custom formatter by passing its path and name to
+# the `rspec` command. For example, if you define MyCustomFormatter in
+# path/to/my_custom_formatter.rb, you would type this command:
+#
+# rspec --require path/to/my_custom_formatter.rb --format MyCustomFormatter
+#
+# The reporter calls every formatter with this protocol:
+#
+# * To start
+# * `start(StartNotification)`
+# * Once per example group
+# * `example_group_started(GroupNotification)`
+# * Once per example
+# * `example_started(ExampleNotification)`
+# * One of these per example, depending on outcome
+# * `example_passed(ExampleNotification)`
+# * `example_failed(FailedExampleNotification)`
+# * `example_pending(ExampleNotification)`
+# * Optionally at any time
+# * `message(MessageNotification)`
+# * At the end of the suite
+# * `stop(ExamplesNotification)`
+# * `start_dump(NullNotification)`
+# * `dump_pending(ExamplesNotification)`
+# * `dump_failures(ExamplesNotification)`
+# * `dump_summary(SummaryNotification)`
+# * `seed(SeedNotification)`
+# * `close(NullNotification)`
+#
+# Only the notifications to which you subscribe your formatter will be called
+# on your formatter. To subscribe your formatter use:
+# `RSpec::Core::Formatters#register` e.g.
+#
+# `RSpec::Core::Formatters.register FormatterClassName, :example_passed, :example_failed`
+#
+# We recommend you implement the methods yourself; for simplicity we provide the
+# default formatter output via our notification objects but if you prefer you
+# can subclass `RSpec::Core::Formatters::BaseTextFormatter` and override the
+# methods you wish to enhance.
+#
+# @see RSpec::Core::Formatters::BaseTextFormatter
+# @see RSpec::Core::Reporter
+#
+# source://rspec-core//lib/rspec/core/formatters/console_codes.rb#3
+module RSpec::Core::Formatters
+ class << self
+ # Register the formatter class
+ #
+ # @param formatter_class [Class] formatter class to register
+ # @param notifications [Array] one or more notifications to be
+ # registered to the specified formatter
+ # @see RSpec::Core::Formatters::BaseFormatter
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#86
+ def register(formatter_class, *notifications); end
+ end
+end
+
+# Contains common logic for formatters used by `--bisect` to communicate results
+# back to the bisect runner.
+#
+# Subclasses must define a `notify_results(all_example_ids, failed_example_ids)`
+# method.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/base_bisect_formatter.rb#12
+class RSpec::Core::Formatters::BaseBisectFormatter
+ # @return [BaseBisectFormatter] a new instance of BaseBisectFormatter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_bisect_formatter.rb#17
+ def initialize(expected_failures); end
+
+ # source://rspec-core//lib/rspec/core/formatters/base_bisect_formatter.rb#23
+ def example_failed(notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/base_bisect_formatter.rb#27
+ def example_finished(notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/base_bisect_formatter.rb#37
+ def start_dump(_notification); end
+
+ class << self
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_bisect_formatter.rb#13
+ def inherited(formatter); end
+ end
+end
+
+# RSpec's built-in formatters are all subclasses of
+# RSpec::Core::Formatters::BaseFormatter.
+#
+# @see RSpec::Core::Formatters::BaseTextFormatter
+# @see RSpec::Core::Reporter
+# @see RSpec::Core::Formatters::Protocol
+#
+# source://rspec-core//lib/rspec/core/formatters/base_formatter.rb#13
+class RSpec::Core::Formatters::BaseFormatter
+ # @api public
+ # @param output [IO] the formatter output
+ # @return [BaseFormatter] a new instance of BaseFormatter
+ # @see RSpec::Core::Formatters::Protocol#initialize
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_formatter.rb#23
+ def initialize(output); end
+
+ # @api public
+ # @param _notification [NullNotification] (Ignored)
+ # @see RSpec::Core::Formatters::Protocol#close
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_formatter.rb#50
+ def close(_notification); end
+
+ # Returns the value of attribute example_group.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_formatter.rb#17
+ def example_group; end
+
+ # Sets the attribute example_group
+ #
+ # @param value the value to set the attribute example_group to.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_formatter.rb#17
+ def example_group=(_arg0); end
+
+ # @api public
+ # @param notification [GroupNotification] containing example_group
+ # subclass of `RSpec::Core::ExampleGroup`
+ # @see RSpec::Core::Formatters::Protocol#example_group_started
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_formatter.rb#42
+ def example_group_started(notification); end
+
+ # Returns the value of attribute output.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_formatter.rb#18
+ def output; end
+
+ # @api public
+ # @param notification [StartNotification]
+ # @see RSpec::Core::Formatters::Protocol#start
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_formatter.rb#32
+ def start(notification); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/formatters/base_formatter.rb#64
+ def output_supports_sync; end
+
+ # source://rspec-core//lib/rspec/core/formatters/base_formatter.rb#60
+ def restore_sync_output; end
+
+ # source://rspec-core//lib/rspec/core/formatters/base_formatter.rb#56
+ def start_sync_output; end
+end
+
+# Base for all of RSpec's built-in formatters. See
+# RSpec::Core::Formatters::BaseFormatter to learn more about all of the
+# methods called by the reporter.
+#
+# @see RSpec::Core::Formatters::BaseFormatter
+# @see RSpec::Core::Reporter
+#
+# source://rspec-core//lib/rspec/core/formatters/base_text_formatter.rb#12
+class RSpec::Core::Formatters::BaseTextFormatter < ::RSpec::Core::Formatters::BaseFormatter
+ # Invoked at the end of a suite run. Allows the formatter to do any
+ # tidying up, but be aware that formatter output streams may be used
+ # elsewhere so don't actually close them.
+ #
+ # @api public
+ # @param _notification [NullNotification] (Ignored)
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_text_formatter.rb#65
+ def close(_notification); end
+
+ # Dumps detailed information about each example failure.
+ #
+ # @api public
+ # @param notification [NullNotification]
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_text_formatter.rb#30
+ def dump_failures(notification); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_text_formatter.rb#47
+ def dump_pending(notification); end
+
+ # This method is invoked after the dumping of examples and failures.
+ # Each parameter is assigned to a corresponding attribute.
+ #
+ # @api public
+ # @param summary [SummaryNotification] containing duration,
+ # example_count, failure_count and pending_count
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_text_formatter.rb#42
+ def dump_summary(summary); end
+
+ # Used by the reporter to send messages to the output stream.
+ #
+ # @api public
+ # @param notification [MessageNotification] containing message
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_text_formatter.rb#21
+ def message(notification); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/base_text_formatter.rb#53
+ def seed(notification); end
+end
+
+# Used by `--bisect`. When it shells out and runs a portion of the suite, it uses
+# this formatter as a means to have the status reported back to it, via DRb.
+#
+# Note that since DRb calls carry considerable overhead compared to normal
+# method calls, we try to minimize the number of DRb calls for perf reasons,
+# opting to communicate only at the start and the end of the run, rather than
+# after each example.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/bisect_drb_formatter.rb#15
+class RSpec::Core::Formatters::BisectDRbFormatter < ::RSpec::Core::Formatters::BaseBisectFormatter
+ # @return [BisectDRbFormatter] a new instance of BisectDRbFormatter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/bisect_drb_formatter.rb#16
+ def initialize(_output); end
+
+ # source://rspec-core//lib/rspec/core/formatters/bisect_drb_formatter.rb#23
+ def notify_results(results); end
+end
+
+# ConsoleCodes provides helpers for formatting console output
+# with ANSI codes, e.g. color's and bold.
+#
+# source://rspec-core//lib/rspec/core/formatters/console_codes.rb#6
+module RSpec::Core::Formatters::ConsoleCodes
+ private
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/console_codes.rb#34
+ def config_colors_to_methods; end
+
+ # Fetches the correct code for the supplied symbol, or checks
+ # that a code is valid. Defaults to white (37).
+ #
+ # @param code_or_symbol [Symbol, Fixnum] Symbol or code to check
+ # @return [Fixnum] a console code
+ #
+ # source://rspec-core//lib/rspec/core/formatters/console_codes.rb#47
+ def console_code_for(code_or_symbol); end
+
+ # Wraps a piece of text in ANSI codes with the supplied code. Will
+ # only apply the control code if `RSpec.configuration.color_enabled?`
+ # returns true.
+ #
+ # @param text [String] the text to wrap
+ # @param code_or_symbol [Symbol, Fixnum] the desired control code
+ # @return [String] the wrapped text
+ #
+ # source://rspec-core//lib/rspec/core/formatters/console_codes.rb#66
+ def wrap(text, code_or_symbol); end
+
+ class << self
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/console_codes.rb#34
+ def config_colors_to_methods; end
+
+ # Fetches the correct code for the supplied symbol, or checks
+ # that a code is valid. Defaults to white (37).
+ #
+ # @param code_or_symbol [Symbol, Fixnum] Symbol or code to check
+ # @return [Fixnum] a console code
+ #
+ # source://rspec-core//lib/rspec/core/formatters/console_codes.rb#47
+ def console_code_for(code_or_symbol); end
+
+ # Wraps a piece of text in ANSI codes with the supplied code. Will
+ # only apply the control code if `RSpec.configuration.color_enabled?`
+ # returns true.
+ #
+ # @param text [String] the text to wrap
+ # @param code_or_symbol [Symbol, Fixnum] the desired control code
+ # @return [String] the wrapped text
+ #
+ # source://rspec-core//lib/rspec/core/formatters/console_codes.rb#66
+ def wrap(text, code_or_symbol); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/console_codes.rb#8
+RSpec::Core::Formatters::ConsoleCodes::VT100_CODES = T.let(T.unsafe(nil), Hash)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/console_codes.rb#29
+RSpec::Core::Formatters::ConsoleCodes::VT100_CODE_VALUES = T.let(T.unsafe(nil), Hash)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#7
+class RSpec::Core::Formatters::DeprecationFormatter
+ # @return [DeprecationFormatter] a new instance of DeprecationFormatter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#12
+ def initialize(deprecation_stream, summary_stream); end
+
+ # Returns the value of attribute count.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#10
+ def count; end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#32
+ def deprecation(notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#44
+ def deprecation_message_for(data); end
+
+ # Returns the value of attribute deprecation_stream.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#10
+ def deprecation_stream; end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#40
+ def deprecation_summary(_notification); end
+
+ # Returns the value of attribute deprecation_stream.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#10
+ def output; end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#20
+ def printer; end
+
+ # Returns the value of attribute summary_stream.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#10
+ def summary_stream; end
+end
+
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#60
+RSpec::Core::Formatters::DeprecationFormatter::DEPRECATION_STREAM_NOTICE = T.let(T.unsafe(nil), String)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#135
+class RSpec::Core::Formatters::DeprecationFormatter::DelayedPrinter
+ # @return [DelayedPrinter] a new instance of DelayedPrinter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#140
+ def initialize(deprecation_stream, summary_stream, deprecation_formatter); end
+
+ # Returns the value of attribute deprecation_formatter.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#138
+ def deprecation_formatter; end
+
+ # Returns the value of attribute deprecation_stream.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#138
+ def deprecation_stream; end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#163
+ def deprecation_summary; end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#172
+ def print_deferred_deprecation_warnings; end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#148
+ def print_deprecation_message(data); end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#155
+ def stash_deprecation_message(deprecation_message); end
+
+ # Returns the value of attribute summary_stream.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#138
+ def summary_stream; end
+end
+
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#136
+RSpec::Core::Formatters::DeprecationFormatter::DelayedPrinter::TOO_MANY_USES_LIMIT = T.let(T.unsafe(nil), Integer)
+
+# Wraps a File object and provides file-specific operations.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#196
+class RSpec::Core::Formatters::DeprecationFormatter::FileStream
+ # @return [FileStream] a new instance of FileStream
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#197
+ def initialize(file); end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#207
+ def puts(*args); end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#211
+ def summarize(summary_stream, deprecation_count); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#94
+class RSpec::Core::Formatters::DeprecationFormatter::GeneratedDeprecationMessage < ::Struct
+ # @return [GeneratedDeprecationMessage] a new instance of GeneratedDeprecationMessage
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#95
+ def initialize(data); end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#100
+ def to_s; end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#107
+ def too_many_warnings_message; end
+
+ # Returns the value of attribute type
+ #
+ # @return [Object] the current value of type
+ def type; end
+
+ # Sets the attribute type
+ #
+ # @param value [Object] the value to set the attribute type to.
+ # @return [Object] the newly set value
+ def type=(_); end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#113
+class RSpec::Core::Formatters::DeprecationFormatter::ImmediatePrinter
+ # @return [ImmediatePrinter] a new instance of ImmediatePrinter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#116
+ def initialize(deprecation_stream, summary_stream, deprecation_formatter); end
+
+ # Returns the value of attribute deprecation_formatter.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#114
+ def deprecation_formatter; end
+
+ # Returns the value of attribute deprecation_stream.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#114
+ def deprecation_stream; end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#128
+ def deprecation_summary; end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#123
+ def print_deprecation_message(data); end
+
+ # Returns the value of attribute summary_stream.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#114
+ def summary_stream; end
+end
+
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#52
+RSpec::Core::Formatters::DeprecationFormatter::RAISE_ERROR_CONFIG_NOTICE = T.let(T.unsafe(nil), String)
+
+# Not really a stream, but is usable in place of one.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#184
+class RSpec::Core::Formatters::DeprecationFormatter::RaiseErrorStream
+ # @raise [DeprecationError]
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#185
+ def puts(message); end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#189
+ def summarize(summary_stream, deprecation_count); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#66
+class RSpec::Core::Formatters::DeprecationFormatter::SpecifiedDeprecationMessage < ::Struct
+ # @return [SpecifiedDeprecationMessage] a new instance of SpecifiedDeprecationMessage
+ #
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#67
+ def initialize(data); end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#72
+ def to_s; end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#76
+ def too_many_warnings_message; end
+
+ # Returns the value of attribute type
+ #
+ # @return [Object] the current value of type
+ def type; end
+
+ # Sets the attribute type
+ #
+ # @param value [Object] the value to set the attribute type to.
+ # @return [Object] the newly set value
+ def type=(_); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#88
+ def deprecation_type_for(data); end
+
+ # source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#82
+ def output_formatted(str); end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# source://rspec-core//lib/rspec/core/formatters/deprecation_formatter.rb#62
+RSpec::Core::Formatters::DeprecationFormatter::TOO_MANY_WARNINGS_NOTICE = T.let(T.unsafe(nil), String)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#8
+class RSpec::Core::Formatters::DocumentationFormatter < ::RSpec::Core::Formatters::BaseTextFormatter
+ # @return [DocumentationFormatter] a new instance of DocumentationFormatter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#12
+ def initialize(output); end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#50
+ def example_failed(failure); end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#31
+ def example_group_finished(_notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#24
+ def example_group_started(notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#35
+ def example_passed(passed); end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#42
+ def example_pending(pending); end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#20
+ def example_started(_notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#57
+ def message(notification); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#96
+ def current_indentation(offset = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#85
+ def failure_output(example); end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#67
+ def flush_messages; end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#91
+ def next_failure_index; end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#75
+ def passed_output(example); end
+
+ # source://rspec-core//lib/rspec/core/formatters/documentation_formatter.rb#79
+ def pending_output(example, message); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#11
+class RSpec::Core::Formatters::ExceptionPresenter
+ # @return [ExceptionPresenter] a new instance of ExceptionPresenter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#16
+ def initialize(exception, example, options = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#78
+ def colorized_formatted_backtrace(colorizer = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#33
+ def colorized_message_lines(colorizer = T.unsafe(nil)); end
+
+ # Returns the value of attribute description.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#12
+ def description; end
+
+ # Returns the value of attribute example.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#12
+ def example; end
+
+ # Returns the value of attribute exception.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#12
+ def exception; end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#39
+ def formatted_backtrace(exception = T.unsafe(nil)); end
+
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#45
+ def formatted_cause(exception); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#84
+ def fully_formatted(failure_number, colorizer = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#89
+ def fully_formatted_lines(failure_number, colorizer); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#29
+ def message_lines; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#224
+ def add_shared_group_lines(lines, colorizer); end
+
+ # Returns the value of attribute backtrace_formatter.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#12
+ def backtrace_formatter; end
+
+ # Returns the value of attribute detail_formatter.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#12
+ def detail_formatter; end
+
+ # for 1.8.7
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#282
+ def encoded_description(description); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#120
+ def encoded_string(string); end
+
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#116
+ def encoding_of(string); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#292
+ def exception_backtrace; end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#150
+ def exception_class_name(exception = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#202
+ def exception_lines; end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#184
+ def exception_message_string(exception); end
+
+ # Returns the value of attribute extra_detail_formatter.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#12
+ def extra_detail_formatter; end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#213
+ def extra_failure_lines; end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#156
+ def failure_lines; end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#170
+ def failure_slash_error_lines; end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#104
+ def final_exception(exception, previous = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#258
+ def find_failed_line; end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#273
+ def formatted_message_and_backtrace(colorizer); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#134
+ def indent_lines(lines, failure_number); end
+
+ # Returns the value of attribute message_color.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#12
+ def message_color; end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#234
+ def read_failed_lines; end
+end
+
+# Configuring the `ExceptionPresenter` with the right set of options to handle
+# pending vs failed vs skipped and aggregated (or not) failures is not simple.
+# This class takes care of building an appropriate `ExceptionPresenter` for the
+# provided example.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#301
+class RSpec::Core::Formatters::ExceptionPresenter::Factory
+ # @return [Factory] a new instance of Factory
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#308
+ def initialize(example); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#302
+ def build; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#363
+ def multiple_exception_summarizer(exception, prior_detail_formatter, color); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#359
+ def multiple_exceptions_error?(exception); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#318
+ def options; end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#322
+ def pending_options; end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#384
+ def sub_failure_list_formatter(exception, message_color); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#343
+ def with_multiple_error_options_as_needed(exception, options); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#417
+class RSpec::Core::Formatters::ExceptionPresenter::Factory::CommonBacktraceTruncater
+ # @return [CommonBacktraceTruncater] a new instance of CommonBacktraceTruncater
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#418
+ def initialize(parent); end
+
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#422
+ def with_truncated_backtrace(child); end
+end
+
+# Used to prevent a confusing backtrace from showing up from the `aggregate_failures`
+# block declared for `:aggregate_failures` metadata.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#410
+module RSpec::Core::Formatters::ExceptionPresenter::Factory::EmptyBacktraceFormatter
+ class << self
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#411
+ def format_backtrace(*_arg0); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#442
+RSpec::Core::Formatters::ExceptionPresenter::PENDING_DETAIL_FORMATTER = T.let(T.unsafe(nil), Proc)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/failure_list_formatter.rb#7
+class RSpec::Core::Formatters::FailureListFormatter < ::RSpec::Core::Formatters::BaseFormatter
+ # Discard profile and messages
+ #
+ # These outputs are not really relevant in the context of this failure
+ # list formatter.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/failure_list_formatter.rb#18
+ def dump_profile(_profile); end
+
+ # source://rspec-core//lib/rspec/core/formatters/failure_list_formatter.rb#10
+ def example_failed(failure); end
+
+ # source://rspec-core//lib/rspec/core/formatters/failure_list_formatter.rb#19
+ def message(_message); end
+end
+
+# Formatter for providing message output as a fallback when no other
+# profiler implements #message
+#
+# @api private
+#
+# source://rspec-core//lib/rspec/core/formatters/fallback_message_formatter.rb#7
+class RSpec::Core::Formatters::FallbackMessageFormatter
+ # @api private
+ # @return [FallbackMessageFormatter] a new instance of FallbackMessageFormatter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/fallback_message_formatter.rb#10
+ def initialize(output); end
+
+ # Used by the reporter to send messages to the output stream.
+ #
+ # @api public
+ # @param notification [MessageNotification] containing message
+ #
+ # source://rspec-core//lib/rspec/core/formatters/fallback_message_formatter.rb#22
+ def message(notification); end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/fallback_message_formatter.rb#15
+ def output; end
+end
+
+# Formatters helpers.
+#
+# source://rspec-core//lib/rspec/core/formatters/helpers.rb#7
+module RSpec::Core::Formatters::Helpers
+ class << self
+ # Formats seconds into a human-readable string.
+ #
+ # @api private
+ # @example
+ # format_duration(1) #=> "1 minute 1 second"
+ # format_duration(135.14) #=> "2 minutes 15.14 seconds"
+ # @param duration [Float, Fixnum] in seconds
+ # @return [String] human-readable time
+ #
+ # source://rspec-core//lib/rspec/core/formatters/helpers.rb#24
+ def format_duration(duration); end
+
+ # Formats seconds to have 5 digits of precision with trailing zeros
+ # removed if the number is less than 1 or with 2 digits of precision if
+ # the number is greater than zero.
+ #
+ # The precision used is set in {Helpers::SUB_SECOND_PRECISION} and
+ # {Helpers::DEFAULT_PRECISION}.
+ #
+ # @api private
+ # @example
+ # format_seconds(0.000006) #=> "0.00001"
+ # format_seconds(0.020000) #=> "0.02"
+ # format_seconds(1.00000000001) #=> "1"
+ # @param float [Float]
+ # @return [String] formatted float
+ # @see #strip_trailing_zeroes
+ #
+ # source://rspec-core//lib/rspec/core/formatters/helpers.rb#60
+ def format_seconds(float, precision = T.unsafe(nil)); end
+
+ # Given a list of example ids, organizes them into a compact, ordered list.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/helpers.rb#102
+ def organize_ids(ids); end
+
+ # Pluralize a word based on a count.
+ #
+ # @api private
+ # @param count [Fixnum] number of objects
+ # @param string [String] word to be pluralized
+ # @return [String] pluralized word
+ #
+ # source://rspec-core//lib/rspec/core/formatters/helpers.rb#88
+ def pluralize(count, string); end
+
+ private
+
+ # Remove trailing zeros from a string.
+ #
+ # Only remove trailing zeros after a decimal place.
+ # see: http://rubular.com/r/ojtTydOgpn
+ #
+ # @api private
+ # @param string [String] string with trailing zeros
+ # @return [String] string with trailing zeros removed
+ #
+ # source://rspec-core//lib/rspec/core/formatters/helpers.rb#76
+ def strip_trailing_zeroes(string); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/helpers.rb#12
+RSpec::Core::Formatters::Helpers::DEFAULT_PRECISION = T.let(T.unsafe(nil), Integer)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/helpers.rb#9
+RSpec::Core::Formatters::Helpers::SUB_SECOND_PRECISION = T.let(T.unsafe(nil), Integer)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#8
+class RSpec::Core::Formatters::HtmlFormatter < ::RSpec::Core::Formatters::BaseFormatter
+ # @return [HtmlFormatter] a new instance of HtmlFormatter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#13
+ def initialize(output); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#103
+ def dump_summary(summary); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#55
+ def example_failed(failure); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#28
+ def example_group_started(notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#49
+ def example_passed(passed); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#93
+ def example_pending(pending); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#45
+ def example_started(_notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#22
+ def start(notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#40
+ def start_dump(_notification); end
+
+ private
+
+ # The number of the currently running example_group.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#120
+ def example_group_number; end
+
+ # The number of the currently running example (a global counter).
+ #
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#125
+ def example_number; end
+
+ # Override this method if you wish to output extra HTML for a failed
+ # spec. For example, you could output links to images or other files
+ # produced during the specs.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#141
+ def extra_failure_content(failure); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_formatter.rb#130
+ def percent_done; end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/html_printer.rb#7
+class RSpec::Core::Formatters::HtmlPrinter
+ include ::ERB::Escape
+ include ::ERB::Util
+
+ # @return [HtmlPrinter] a new instance of HtmlPrinter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#9
+ def initialize(output); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#79
+ def flush; end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#96
+ def make_example_group_header_red(group_id); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#103
+ def make_example_group_header_yellow(group_id); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#88
+ def make_header_red; end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#92
+ def make_header_yellow; end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#83
+ def move_progress(percent_done); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#36
+ def print_example_failed(pending_fixed, description, run_time, failure_id, exception, extra_content); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#18
+ def print_example_group_end; end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#23
+ def print_example_group_start(group_id, description, number_of_parents); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#29
+ def print_example_passed(description, run_time); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#53
+ def print_example_pending(description, pending_message); end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#13
+ def print_html_start; end
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#59
+ def print_summary(duration, example_count, failure_count, pending_count); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/formatters/html_printer.rb#112
+ def indentation_style(number_of_parents); end
+end
+
+# source://rspec-core//lib/rspec/core/formatters/html_printer.rb#140
+RSpec::Core::Formatters::HtmlPrinter::GLOBAL_SCRIPTS = T.let(T.unsafe(nil), String)
+
+# source://rspec-core//lib/rspec/core/formatters/html_printer.rb#218
+RSpec::Core::Formatters::HtmlPrinter::GLOBAL_STYLES = T.let(T.unsafe(nil), String)
+
+# source://rspec-core//lib/rspec/core/formatters/html_printer.rb#382
+RSpec::Core::Formatters::HtmlPrinter::HTML_HEADER = T.let(T.unsafe(nil), String)
+
+# source://rspec-core//lib/rspec/core/formatters/html_printer.rb#116
+RSpec::Core::Formatters::HtmlPrinter::REPORT_HEADER = T.let(T.unsafe(nil), String)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#8
+class RSpec::Core::Formatters::JsonFormatter < ::RSpec::Core::Formatters::BaseFormatter
+ # @return [JsonFormatter] a new instance of JsonFormatter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#13
+ def initialize(output); end
+
+ # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#56
+ def close(_notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#60
+ def dump_profile(profile); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#79
+ def dump_profile_slowest_example_groups(profile); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#67
+ def dump_profile_slowest_examples(profile); end
+
+ # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#24
+ def dump_summary(summary); end
+
+ # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#20
+ def message(notification); end
+
+ # Returns the value of attribute output_hash.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#11
+ def output_hash; end
+
+ # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#51
+ def seed(notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#35
+ def stop(group_notification); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/formatters/json_formatter.rb#88
+ def format_example(example); end
+end
+
+# `RSpec::Core::Formatters::Loader` is an internal class for
+# managing formatters used by a particular configuration. It is
+# not expected to be used directly, but only through the configuration
+# interface.
+#
+# @api private
+#
+# source://rspec-core//lib/rspec/core/formatters.rb#96
+class RSpec::Core::Formatters::Loader
+ # @api private
+ # @return [Loader] a new instance of Loader
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#105
+ def initialize(reporter); end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#144
+ def add(formatter_to_use, *paths); end
+
+ # @api private
+ # @return [String] the default formatter to setup, defaults to `progress`
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#118
+ def default_formatter; end
+
+ # @api private
+ # @return [String] the default formatter to setup, defaults to `progress`
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#118
+ def default_formatter=(_arg0); end
+
+ # @api private
+ # @return [Array] the loaded formatters
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#112
+ def formatters; end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#121
+ def prepare_default(output_stream, deprecation_stream); end
+
+ # @api private
+ # @return [Reporter] the reporter
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#115
+ def reporter; end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#126
+ def setup_default(output_stream, deprecation_stream); end
+
+ private
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#211
+ def built_in_formatter(key); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#234
+ def custom_formatter(formatter_ref); end
+
+ # @api private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#195
+ def duplicate_formatter_exists?(new_formatter); end
+
+ # @api private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#207
+ def existing_formatter_implements?(notification); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#181
+ def find_formatter(formatter_to_use); end
+
+ # @api private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#202
+ def has_matching_output?(formatter, new_formatter); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#228
+ def notifications_for(formatter_class); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#269
+ def open_stream(path_or_wrapper); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#250
+ def path_for(const_ref); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#188
+ def register(formatter, notifications); end
+
+ # @api private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#246
+ def string_const?(str); end
+
+ # activesupport/lib/active_support/inflector/methods.rb, line 48
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#259
+ def underscore(camel_cased_word); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#254
+ def underscore_with_fix_for_non_standard_rspec_naming(string); end
+
+ class << self
+ # Internal formatters are stored here when loaded.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters.rb#100
+ def formatters; end
+ end
+end
+
+# Formatter for providing profile output.
+#
+# @api private
+#
+# source://rspec-core//lib/rspec/core/formatters/profile_formatter.rb#8
+class RSpec::Core::Formatters::ProfileFormatter
+ # @api private
+ # @return [ProfileFormatter] a new instance of ProfileFormatter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/profile_formatter.rb#11
+ def initialize(output); end
+
+ # This method is invoked after the dumping the summary if profiling is
+ # enabled.
+ #
+ # @api public
+ # @param profile [ProfileNotification] containing duration,
+ # slowest_examples and slowest_example_groups
+ #
+ # source://rspec-core//lib/rspec/core/formatters/profile_formatter.rb#25
+ def dump_profile(profile); end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/profile_formatter.rb#16
+ def output; end
+
+ private
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/profile_formatter.rb#62
+ def bold(text); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/profile_formatter.rb#44
+ def dump_profile_slowest_example_groups(profile); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/profile_formatter.rb#32
+ def dump_profile_slowest_examples(profile); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/profile_formatter.rb#57
+ def format_caller(caller_info); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/progress_formatter.rb#8
+class RSpec::Core::Formatters::ProgressFormatter < ::RSpec::Core::Formatters::BaseTextFormatter
+ # source://rspec-core//lib/rspec/core/formatters/progress_formatter.rb#19
+ def example_failed(_notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/progress_formatter.rb#11
+ def example_passed(_notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/progress_formatter.rb#15
+ def example_pending(_notification); end
+
+ # source://rspec-core//lib/rspec/core/formatters/progress_formatter.rb#23
+ def start_dump(_notification); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#5
+class RSpec::Core::Formatters::SnippetExtractor
+ # @return [SnippetExtractor] a new instance of SnippetExtractor
+ #
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#35
+ def initialize(source, beginning_line_number, max_line_count = T.unsafe(nil)); end
+
+ # Returns the value of attribute beginning_line_number.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#24
+ def beginning_line_number; end
+
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#41
+ def expression_lines; end
+
+ # Returns the value of attribute max_line_count.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#24
+ def max_line_count; end
+
+ # Returns the value of attribute source.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#24
+ def source; end
+
+ private
+
+ # @raise [NoExpressionAtLineError]
+ #
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#95
+ def expression_node; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#107
+ def expression_outmost_node?(node); end
+
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#55
+ def line_range_of_expression; end
+
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#87
+ def line_range_of_location_nodes_in_expression; end
+
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#117
+ def location_nodes_at_beginning_line; end
+
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#70
+ def unclosed_tokens_in_line_range(line_range); end
+
+ class << self
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#26
+ def extract_expression_lines_at(file_path, beginning_line_number, max_line_count = T.unsafe(nil)); end
+
+ # @raise [NoSuchLineError]
+ #
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#9
+ def extract_line_at(file_path, line_number); end
+
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#128
+ def least_indentation_from(lines); end
+
+ # @raise [NoSuchFileError]
+ #
+ # source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#16
+ def source_from_file(path); end
+ end
+end
+
+# source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#22
+class RSpec::Core::Formatters::SnippetExtractor::NoExpressionAtLineError < ::StandardError; end
+
+# source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#6
+class RSpec::Core::Formatters::SnippetExtractor::NoSuchFileError < ::StandardError; end
+
+# source://rspec-core//lib/rspec/core/formatters/snippet_extractor.rb#7
+class RSpec::Core::Formatters::SnippetExtractor::NoSuchLineError < ::StandardError; end
+
+# Provides terminal syntax highlighting of code snippets
+# when coderay is available.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#7
+class RSpec::Core::Formatters::SyntaxHighlighter
+ # @return [SyntaxHighlighter] a new instance of SyntaxHighlighter
+ #
+ # source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#8
+ def initialize(configuration); end
+
+ # source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#12
+ def highlight(lines); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#50
+ def color_enabled_implementation; end
+
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#44
+ def implementation; end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#18
+ def attempt_to_add_rspec_terms_to_coderay_keywords; end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#61
+module RSpec::Core::Formatters::SyntaxHighlighter::CodeRayImplementation
+ class << self
+ # source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#64
+ def highlight_syntax(lines); end
+ end
+end
+
+# source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#62
+RSpec::Core::Formatters::SyntaxHighlighter::CodeRayImplementation::RESET_CODE = T.let(T.unsafe(nil), String)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#78
+module RSpec::Core::Formatters::SyntaxHighlighter::NoSyntaxHighlightingImplementation
+ class << self
+ # source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#79
+ def highlight_syntax(lines); end
+ end
+end
+
+# Not sure why, but our code above (and/or coderay itself) does not work
+# on Windows, so we disable the feature on Windows.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/syntax_highlighter.rb#87
+RSpec::Core::Formatters::SyntaxHighlighter::WindowsImplementation = RSpec::Core::Formatters::SyntaxHighlighter::NoSyntaxHighlightingImplementation
+
+# Mixin that makes the including class imitate a hash for backwards
+# compatibility. The including class should use `attr_accessor` to
+# declare attributes.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/metadata.rb#349
+module RSpec::Core::HashImitatable
+ mixes_in_class_methods ::RSpec::Core::HashImitatable::ClassMethods
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def <(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def <=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def >(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def >=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#388
+ def [](key); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#398
+ def []=(key, value); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def all?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def any?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def assoc(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def chain(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def chunk(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def chunk_while(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def clear(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def collect(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def collect_concat(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def compact(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def compact!(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def compare_by_identity(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def compare_by_identity?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def count(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def cycle(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def deconstruct_keys(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def default(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def default=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def default_proc(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def default_proc=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def delete(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def delete_if(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def detect(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def dig(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def drop(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def drop_while(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def each(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def each_cons(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def each_entry(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def each_key(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def each_pair(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def each_slice(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def each_value(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def each_with_index(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def each_with_object(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def empty?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def entries(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def except(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def fetch(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def fetch_values(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def filter(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def filter!(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def filter_map(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def find(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def find_all(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def find_index(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def first(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def flat_map(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def flatten(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def grep(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def grep_v(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def group_by(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def has_key?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def has_value?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def include?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def inject(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def invert(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def keep_if(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def key(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def key?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def keys(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def lazy(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def length(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def map(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def max(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def max_by(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def member?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def merge(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def merge!(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def min(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def min_by(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def minmax(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def minmax_by(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def none?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def one?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def partition(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def rassoc(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def reduce(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def rehash(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def reject(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def reject!(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def replace(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def reverse_each(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def select(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def select!(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def shift(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def size(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def slice(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def slice_after(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def slice_before(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def slice_when(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def sort(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def sort_by(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def store(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def sum(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def take(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def take_while(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def tally(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def to_a(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#354
+ def to_h; end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def to_hash(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def to_proc(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def to_set(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def transform_keys(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def transform_keys!(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def transform_values(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def transform_values!(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def uniq(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def update(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def value?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def values(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def values_at(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#367
+ def zip(*args, &block); end
+
+ private
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#414
+ def directly_supports_attribute?(name); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#410
+ def extra_hash_attributes; end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#418
+ def get_value(name); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#426
+ def hash_for_delegation; end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#430
+ def issue_deprecation(_method_name, *_args); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#422
+ def set_value(name, value); end
+
+ class << self
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#350
+ def included(klass); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/metadata.rb#435
+module RSpec::Core::HashImitatable::ClassMethods
+ # source://rspec-core//lib/rspec/core/metadata.rb#440
+ def attr_accessor(*names); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#436
+ def hash_attribute_names; end
+end
+
+# Provides `before`, `after` and `around` hooks as a means of
+# supporting common setup and teardown. This module is extended
+# onto {ExampleGroup}, making the methods available from any `describe`
+# or `context` block and included in {Configuration}, making them
+# available off of the configuration object to define global setup
+# or teardown logic.
+#
+# source://rspec-core//lib/rspec/core/hooks.rb#9
+module RSpec::Core::Hooks
+ # Declare a block of code to be run after each example (using `:example`)
+ # or once after all examples n the context (using `:context`). See
+ # {#before} for more information about ordering.
+ #
+ # ### Exceptions
+ #
+ # `after` hooks are guaranteed to run even when there are exceptions in
+ # `before` hooks or examples. When an exception is raised in an after
+ # block, the exception is captured for later reporting, and subsequent
+ # `after` blocks are run.
+ #
+ # ### Order
+ #
+ # `after` hooks are stored in three scopes, which are run in order:
+ # `:example`, `:context`, and `:suite`. They can also be declared in
+ # several different places: `RSpec.configure`, a parent group, the current
+ # group. They are run in the following order:
+ #
+ # after(:example) # Declared in the current group.
+ # after(:example) # Declared in a parent group.
+ # after(:example) # Declared in RSpec.configure.
+ # after(:context) # Declared in the current group.
+ # after(:context) # Declared in a parent group.
+ # after(:context) # Declared in RSpec.configure.
+ # after(:suite) # Declared in RSpec.configure.
+ #
+ # This is the reverse of the order in which `before` hooks are run.
+ # Similarly, if more than one `after` is declared within any example
+ # group, they are run in reverse order of that in which they are declared.
+ # Also `around` hooks will run after any `after` example hooks are
+ # invoked but before any `after` context hooks.
+ #
+ # @api public
+ # @note The `:example` and `:context` scopes are also available as
+ # `:each` and `:all`, respectively. Use whichever you prefer.
+ # @note The `:suite` scope is only supported for hooks registered on
+ # `RSpec.configuration` since they exist independently of any
+ # example or example group.
+ # @overload after
+ # @overload after
+ # @overload after
+ # @overload after
+ # @see #before
+ # @see #around
+ # @see ExampleGroup
+ # @see SharedContext
+ # @see SharedExampleGroup
+ # @see Configuration
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#277
+ def after(*args, &block); end
+
+ # Adds `block` to the back of the list of `after` blocks in the same
+ # scope (`:example`, `:context`, or `:suite`).
+ #
+ # See {#after} for scoping semantics.
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#287
+ def append_after(*args, &block); end
+
+ # Declare a block of code to be run before each example (using `:example`)
+ # or once before any example (using `:context`). These are usually
+ # declared directly in the {ExampleGroup} to which they apply, but they
+ # can also be shared across multiple groups.
+ #
+ # You can also use `before(:suite)` to run a block of code before any
+ # example groups are run. This should be declared in {RSpec.configure}.
+ #
+ # Instance variables declared in `before(:example)` or `before(:context)`
+ # are accessible within each example.
+ #
+ # ### Order
+ #
+ # `before` hooks are stored in three scopes, which are run in order:
+ # `:suite`, `:context`, and `:example`. They can also be declared in
+ # several different places: `RSpec.configure`, a parent group, the current
+ # group. They are run in the following order:
+ #
+ # before(:suite) # Declared in RSpec.configure.
+ # before(:context) # Declared in RSpec.configure.
+ # before(:context) # Declared in a parent group.
+ # before(:context) # Declared in the current group.
+ # before(:example) # Declared in RSpec.configure.
+ # before(:example) # Declared in a parent group.
+ # before(:example) # Declared in the current group.
+ #
+ # If more than one `before` is declared within any one example group, they
+ # are run in the order in which they are declared. Any `around` hooks will
+ # execute after `before` context hooks but before any `before` example
+ # hook regardless of where they are declared.
+ #
+ # ### Conditions
+ #
+ # When you add a conditions hash to `before(:example)` or
+ # `before(:context)`, RSpec will only apply that hook to groups or
+ # examples that match the conditions. e.g.
+ #
+ # RSpec.configure do |config|
+ # config.before(:example, :authorized => true) do
+ # log_in_as :authorized_user
+ # end
+ # end
+ #
+ # RSpec.describe Something, :authorized => true do
+ # # The before hook will run in before each example in this group.
+ # end
+ #
+ # RSpec.describe SomethingElse do
+ # it "does something", :authorized => true do
+ # # The before hook will run before this example.
+ # end
+ #
+ # it "does something else" do
+ # # The hook will not run before this example.
+ # end
+ # end
+ #
+ # Note that filtered config `:context` hooks can still be applied
+ # to individual examples that have matching metadata. Just like
+ # Ruby's object model is that every object has a singleton class
+ # which has only a single instance, RSpec's model is that every
+ # example has a singleton example group containing just the one
+ # example.
+ #
+ # ### Warning: `before(:suite, :with => :conditions)`
+ #
+ # The conditions hash is used to match against specific examples. Since
+ # `before(:suite)` is not run in relation to any specific example or
+ # group, conditions passed along with `:suite` are effectively ignored.
+ #
+ # ### Exceptions
+ #
+ # When an exception is raised in a `before` block, RSpec skips any
+ # subsequent `before` blocks and the example, but runs all of the
+ # `after(:example)` and `after(:context)` hooks.
+ #
+ # ### Warning: implicit before blocks
+ #
+ # `before` hooks can also be declared in shared contexts which get
+ # included implicitly either by you or by extension libraries. Since
+ # RSpec runs these in the order in which they are declared within each
+ # scope, load order matters, and can lead to confusing results when one
+ # before block depends on state that is prepared in another before block
+ # that gets run later.
+ #
+ # ### Warning: `before(:context)`
+ #
+ # It is very tempting to use `before(:context)` to speed things up, but we
+ # recommend that you avoid this as there are a number of gotchas, as well
+ # as things that simply don't work.
+ #
+ # #### Context
+ #
+ # `before(:context)` is run in an example that is generated to provide
+ # group context for the block.
+ #
+ # #### Instance variables
+ #
+ # Instance variables declared in `before(:context)` are shared across all
+ # the examples in the group. This means that each example can change the
+ # state of a shared object, resulting in an ordering dependency that can
+ # make it difficult to reason about failures.
+ #
+ # #### Unsupported RSpec constructs
+ #
+ # RSpec has several constructs that reset state between each example
+ # automatically. These are not intended for use from within
+ # `before(:context)`:
+ #
+ # * `let` declarations
+ # * `subject` declarations
+ # * Any mocking, stubbing or test double declaration
+ #
+ # ### other frameworks
+ #
+ # Mock object frameworks and database transaction managers (like
+ # ActiveRecord) are typically designed around the idea of setting up
+ # before an example, running that one example, and then tearing down. This
+ # means that mocks and stubs can (sometimes) be declared in
+ # `before(:context)`, but get torn down before the first real example is
+ # ever run.
+ #
+ # You _can_ create database-backed model objects in a `before(:context)`
+ # in rspec-rails, but it will not be wrapped in a transaction for you, so
+ # you are on your own to clean up in an `after(:context)` block.
+ #
+ # @api public
+ # @example before(:example) declared in an {ExampleGroup}
+ # RSpec.describe Thing do
+ # before(:example) do
+ # @thing = Thing.new
+ # end
+ #
+ # it "does something" do
+ # # Here you can access @thing.
+ # end
+ # end
+ # @example before(:context) declared in an {ExampleGroup}
+ # RSpec.describe Parser do
+ # before(:context) do
+ # File.open(file_to_parse, 'w') do |f|
+ # f.write <<-CONTENT
+ # stuff in the file
+ # CONTENT
+ # end
+ # end
+ #
+ # it "parses the file" do
+ # Parser.parse(file_to_parse)
+ # end
+ #
+ # after(:context) do
+ # File.delete(file_to_parse)
+ # end
+ # end
+ # @note The `:example` and `:context` scopes are also available as
+ # `:each` and `:all`, respectively. Use whichever you prefer.
+ # @note The `:suite` scope is only supported for hooks registered on
+ # `RSpec.configuration` since they exist independently of any
+ # example or example group.
+ # @overload before
+ # @overload before
+ # @overload before
+ # @overload before
+ # @see #after
+ # @see #around
+ # @see ExampleGroup
+ # @see SharedContext
+ # @see SharedExampleGroup
+ # @see Configuration
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#200
+ def append_before(*args, &block); end
+
+ # Declare a block of code, parts of which will be run before and parts
+ # after the example. It is your responsibility to run the example:
+ #
+ # around(:example) do |ex|
+ # # Do some stuff before.
+ # ex.run
+ # # Do some stuff after.
+ # end
+ #
+ # The yielded example aliases `run` with `call`, which lets you treat it
+ # like a `Proc`. This is especially handy when working with libraries
+ # that manage their own setup and teardown using a block or proc syntax,
+ # e.g.
+ #
+ # around(:example) {|ex| Database.transaction(&ex)}
+ # around(:example) {|ex| FakeFS(&ex)}
+ #
+ # ### Order
+ #
+ # The `around` hooks execute surrounding an example and its hooks.
+ #
+ # This means after any `before` context hooks, but before any `before`
+ # example hooks, and similarly after any `after` example hooks but before
+ # any `after` context hooks.
+ #
+ # They are not a synonym for `before`/`after`.
+ #
+ # @api public
+ # @note the syntax of `around` is similar to that of `before` and `after`
+ # but the semantics are quite different. `before` and `after` hooks are
+ # run in the context of the examples with which they are associated,
+ # whereas `around` hooks are actually responsible for running the
+ # examples. Consequently, `around` hooks do not have direct access to
+ # resources that are made available within the examples and their
+ # associated `before` and `after` hooks.
+ # @note `:example`/`:each` is the only supported scope.
+ # @overload around
+ # @overload around
+ # @overload around
+ # @overload around
+ # @yield [Example] the example to run
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#349
+ def around(*args, &block); end
+
+ # Declare a block of code to be run before each example (using `:example`)
+ # or once before any example (using `:context`). These are usually
+ # declared directly in the {ExampleGroup} to which they apply, but they
+ # can also be shared across multiple groups.
+ #
+ # You can also use `before(:suite)` to run a block of code before any
+ # example groups are run. This should be declared in {RSpec.configure}.
+ #
+ # Instance variables declared in `before(:example)` or `before(:context)`
+ # are accessible within each example.
+ #
+ # ### Order
+ #
+ # `before` hooks are stored in three scopes, which are run in order:
+ # `:suite`, `:context`, and `:example`. They can also be declared in
+ # several different places: `RSpec.configure`, a parent group, the current
+ # group. They are run in the following order:
+ #
+ # before(:suite) # Declared in RSpec.configure.
+ # before(:context) # Declared in RSpec.configure.
+ # before(:context) # Declared in a parent group.
+ # before(:context) # Declared in the current group.
+ # before(:example) # Declared in RSpec.configure.
+ # before(:example) # Declared in a parent group.
+ # before(:example) # Declared in the current group.
+ #
+ # If more than one `before` is declared within any one example group, they
+ # are run in the order in which they are declared. Any `around` hooks will
+ # execute after `before` context hooks but before any `before` example
+ # hook regardless of where they are declared.
+ #
+ # ### Conditions
+ #
+ # When you add a conditions hash to `before(:example)` or
+ # `before(:context)`, RSpec will only apply that hook to groups or
+ # examples that match the conditions. e.g.
+ #
+ # RSpec.configure do |config|
+ # config.before(:example, :authorized => true) do
+ # log_in_as :authorized_user
+ # end
+ # end
+ #
+ # RSpec.describe Something, :authorized => true do
+ # # The before hook will run in before each example in this group.
+ # end
+ #
+ # RSpec.describe SomethingElse do
+ # it "does something", :authorized => true do
+ # # The before hook will run before this example.
+ # end
+ #
+ # it "does something else" do
+ # # The hook will not run before this example.
+ # end
+ # end
+ #
+ # Note that filtered config `:context` hooks can still be applied
+ # to individual examples that have matching metadata. Just like
+ # Ruby's object model is that every object has a singleton class
+ # which has only a single instance, RSpec's model is that every
+ # example has a singleton example group containing just the one
+ # example.
+ #
+ # ### Warning: `before(:suite, :with => :conditions)`
+ #
+ # The conditions hash is used to match against specific examples. Since
+ # `before(:suite)` is not run in relation to any specific example or
+ # group, conditions passed along with `:suite` are effectively ignored.
+ #
+ # ### Exceptions
+ #
+ # When an exception is raised in a `before` block, RSpec skips any
+ # subsequent `before` blocks and the example, but runs all of the
+ # `after(:example)` and `after(:context)` hooks.
+ #
+ # ### Warning: implicit before blocks
+ #
+ # `before` hooks can also be declared in shared contexts which get
+ # included implicitly either by you or by extension libraries. Since
+ # RSpec runs these in the order in which they are declared within each
+ # scope, load order matters, and can lead to confusing results when one
+ # before block depends on state that is prepared in another before block
+ # that gets run later.
+ #
+ # ### Warning: `before(:context)`
+ #
+ # It is very tempting to use `before(:context)` to speed things up, but we
+ # recommend that you avoid this as there are a number of gotchas, as well
+ # as things that simply don't work.
+ #
+ # #### Context
+ #
+ # `before(:context)` is run in an example that is generated to provide
+ # group context for the block.
+ #
+ # #### Instance variables
+ #
+ # Instance variables declared in `before(:context)` are shared across all
+ # the examples in the group. This means that each example can change the
+ # state of a shared object, resulting in an ordering dependency that can
+ # make it difficult to reason about failures.
+ #
+ # #### Unsupported RSpec constructs
+ #
+ # RSpec has several constructs that reset state between each example
+ # automatically. These are not intended for use from within
+ # `before(:context)`:
+ #
+ # * `let` declarations
+ # * `subject` declarations
+ # * Any mocking, stubbing or test double declaration
+ #
+ # ### other frameworks
+ #
+ # Mock object frameworks and database transaction managers (like
+ # ActiveRecord) are typically designed around the idea of setting up
+ # before an example, running that one example, and then tearing down. This
+ # means that mocks and stubs can (sometimes) be declared in
+ # `before(:context)`, but get torn down before the first real example is
+ # ever run.
+ #
+ # You _can_ create database-backed model objects in a `before(:context)`
+ # in rspec-rails, but it will not be wrapped in a transaction for you, so
+ # you are on your own to clean up in an `after(:context)` block.
+ #
+ # @api public
+ # @example before(:example) declared in an {ExampleGroup}
+ #
+ # RSpec.describe Thing do
+ # before(:example) do
+ # @thing = Thing.new
+ # end
+ #
+ # it "does something" do
+ # # Here you can access @thing.
+ # end
+ # end
+ # @example before(:context) declared in an {ExampleGroup}
+ #
+ # RSpec.describe Parser do
+ # before(:context) do
+ # File.open(file_to_parse, 'w') do |f|
+ # f.write <<-CONTENT
+ # stuff in the file
+ # CONTENT
+ # end
+ # end
+ #
+ # it "parses the file" do
+ # Parser.parse(file_to_parse)
+ # end
+ #
+ # after(:context) do
+ # File.delete(file_to_parse)
+ # end
+ # end
+ # @note The `:example` and `:context` scopes are also available as
+ # `:each` and `:all`, respectively. Use whichever you prefer.
+ # @note The `:suite` scope is only supported for hooks registered on
+ # `RSpec.configuration` since they exist independently of any
+ # example or example group.
+ # @overload before
+ # @overload before
+ # @overload before
+ # @overload before
+ # @see #after
+ # @see #around
+ # @see ExampleGroup
+ # @see SharedContext
+ # @see SharedExampleGroup
+ # @see Configuration
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#200
+ def before(*args, &block); end
+
+ # Holds the various registered hooks.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#355
+ def hooks; end
+
+ # Declare a block of code to be run after each example (using `:example`)
+ # or once after all examples n the context (using `:context`). See
+ # {#before} for more information about ordering.
+ #
+ # ### Exceptions
+ #
+ # `after` hooks are guaranteed to run even when there are exceptions in
+ # `before` hooks or examples. When an exception is raised in an after
+ # block, the exception is captured for later reporting, and subsequent
+ # `after` blocks are run.
+ #
+ # ### Order
+ #
+ # `after` hooks are stored in three scopes, which are run in order:
+ # `:example`, `:context`, and `:suite`. They can also be declared in
+ # several different places: `RSpec.configure`, a parent group, the current
+ # group. They are run in the following order:
+ #
+ # after(:example) # Declared in the current group.
+ # after(:example) # Declared in a parent group.
+ # after(:example) # Declared in RSpec.configure.
+ # after(:context) # Declared in the current group.
+ # after(:context) # Declared in a parent group.
+ # after(:context) # Declared in RSpec.configure.
+ # after(:suite) # Declared in RSpec.configure.
+ #
+ # This is the reverse of the order in which `before` hooks are run.
+ # Similarly, if more than one `after` is declared within any example
+ # group, they are run in reverse order of that in which they are declared.
+ # Also `around` hooks will run after any `after` example hooks are
+ # invoked but before any `after` context hooks.
+ #
+ # @api public
+ # @note The `:example` and `:context` scopes are also available as
+ # `:each` and `:all`, respectively. Use whichever you prefer.
+ # @note The `:suite` scope is only supported for hooks registered on
+ # `RSpec.configuration` since they exist independently of any
+ # example or example group.
+ # @overload after
+ # @overload after
+ # @overload after
+ # @overload after
+ # @see #before
+ # @see #around
+ # @see ExampleGroup
+ # @see SharedContext
+ # @see SharedExampleGroup
+ # @see Configuration
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#277
+ def prepend_after(*args, &block); end
+
+ # Adds `block` to the front of the list of `before` blocks in the same
+ # scope (`:example`, `:context`, or `:suite`).
+ #
+ # See {#before} for scoping semantics.
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#210
+ def prepend_before(*args, &block); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/hooks.rb#379
+class RSpec::Core::Hooks::AfterContextHook < ::RSpec::Core::Hooks::Hook
+ # source://rspec-core//lib/rspec/core/hooks.rb#380
+ def run(example); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/hooks.rb#370
+class RSpec::Core::Hooks::AfterHook < ::RSpec::Core::Hooks::Hook
+ # source://rspec-core//lib/rspec/core/hooks.rb#371
+ def run(example); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/hooks.rb#388
+class RSpec::Core::Hooks::AroundHook < ::RSpec::Core::Hooks::Hook
+ # source://rspec-core//lib/rspec/core/hooks.rb#389
+ def execute_with(example, procsy); end
+
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#397
+ def hook_description; end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/hooks.rb#363
+class RSpec::Core::Hooks::BeforeHook < ::RSpec::Core::Hooks::Hook
+ # source://rspec-core//lib/rspec/core/hooks.rb#364
+ def run(example); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/hooks.rb#360
+class RSpec::Core::Hooks::Hook < ::Struct
+ # Returns the value of attribute block
+ #
+ # @return [Object] the current value of block
+ def block; end
+
+ # Sets the attribute block
+ #
+ # @param value [Object] the value to set the attribute block to.
+ # @return [Object] the newly set value
+ def block=(_); end
+
+ # Returns the value of attribute options
+ #
+ # @return [Object] the current value of options
+ def options; end
+
+ # Sets the attribute options
+ #
+ # @param value [Object] the value to set the attribute options to.
+ # @return [Object] the newly set value
+ def options=(_); end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# This provides the primary API used by other parts of rspec-core. By hiding all
+# implementation details behind this facade, it's allowed us to heavily optimize
+# this, so that, for example, hook collection objects are only instantiated when
+# a hook is added. This allows us to avoid many object allocations for the common
+# case of a group having no hooks.
+#
+# This is only possible because this interface provides a "tell, don't ask"-style
+# API, so that callers _tell_ this class what to do with the hooks, rather than
+# asking this class for a list of hooks, and then doing something with them.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/hooks.rb#420
+class RSpec::Core::Hooks::HookCollections
+ # @return [HookCollections] a new instance of HookCollections
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#421
+ def initialize(owner, filterable_item_repo_class); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#449
+ def register(prepend_or_append, position, *args, &block); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#442
+ def register_global_singleton_context_hooks(example, globals); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#431
+ def register_globals(host, globals); end
+
+ # Runs all of the blocks stored with the hook in the context of the
+ # example. If no example is provided, just calls the hook directly.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#475
+ def run(position, scope, example_or_group); end
+
+ protected
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#523
+ def all_hooks_for(position, scope); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#507
+ def matching_hooks_for(position, scope, example_or_group); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#533
+ def processable_hooks_for(position, scope, host); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#527
+ def run_owned_hooks_for(position, scope, example_or_group); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#553
+ def ensure_hooks_initialized_for(position, scope); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#591
+ def extract_scope_from(args); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#543
+ def hooks_for(position, scope); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#605
+ def known_scope?(scope); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#609
+ def normalized_scope_for(scope); end
+
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/hooks.rb#633
+ def owner_parent_groups; end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#571
+ def process(host, parent_groups, globals, position, scope); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#619
+ def run_around_example_hooks_for(example); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#613
+ def run_example_hooks_for(example, position, each_method); end
+
+ # source://rspec-core//lib/rspec/core/hooks.rb#584
+ def scope_and_options_from(*args); end
+end
+
+# source://rspec-core//lib/rspec/core/hooks.rb#505
+RSpec::Core::Hooks::HookCollections::EMPTY_HOOK_ARRAY = T.let(T.unsafe(nil), Array)
+
+# source://rspec-core//lib/rspec/core/hooks.rb#495
+RSpec::Core::Hooks::HookCollections::HOOK_TYPES = T.let(T.unsafe(nil), Hash)
+
+# source://rspec-core//lib/rspec/core/hooks.rb#491
+RSpec::Core::Hooks::HookCollections::SCOPES = T.let(T.unsafe(nil), Array)
+
+# source://rspec-core//lib/rspec/core/hooks.rb#493
+RSpec::Core::Hooks::HookCollections::SCOPE_ALIASES = T.let(T.unsafe(nil), Hash)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/filter_manager.rb#186
+class RSpec::Core::InclusionRules < ::RSpec::Core::FilterRules
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#187
+ def add(*args); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#191
+ def add_with_low_priority(*args); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#195
+ def include_example?(example); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#203
+ def split_file_scoped_rules; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#199
+ def standalone?; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#213
+ def apply_standalone_filter(updated); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#226
+ def is_standalone_filter?(rules); end
+
+ # source://rspec-core//lib/rspec/core/filter_manager.rb#221
+ def replace_filters(new_rules); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/invocations.rb#4
+module RSpec::Core::Invocations; end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/invocations.rb#28
+class RSpec::Core::Invocations::Bisect
+ # source://rspec-core//lib/rspec/core/invocations.rb#29
+ def call(options, err, out); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/invocations.rb#45
+ def bisect_formatter_klass_for(argument); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/invocations.rb#15
+class RSpec::Core::Invocations::DRbWithFallback
+ # source://rspec-core//lib/rspec/core/invocations.rb#16
+ def call(options, err, out); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/invocations.rb#6
+class RSpec::Core::Invocations::InitializeProject
+ # source://rspec-core//lib/rspec/core/invocations.rb#7
+ def call(*_args); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/invocations.rb#78
+class RSpec::Core::Invocations::PrintHelp < ::Struct
+ # source://rspec-core//lib/rspec/core/invocations.rb#79
+ def call(_options, _err, out); end
+
+ # Returns the value of attribute hidden_options
+ #
+ # @return [Object] the current value of hidden_options
+ def hidden_options; end
+
+ # Sets the attribute hidden_options
+ #
+ # @param value [Object] the value to set the attribute hidden_options to.
+ # @return [Object] the newly set value
+ def hidden_options=(_); end
+
+ # Returns the value of attribute parser
+ #
+ # @return [Object] the current value of parser
+ def parser; end
+
+ # Sets the attribute parser
+ #
+ # @param value [Object] the value to set the attribute parser to.
+ # @return [Object] the newly set value
+ def parser=(_); end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/invocations.rb#52
+class RSpec::Core::Invocations::PrintVersion
+ # source://rspec-core//lib/rspec/core/invocations.rb#53
+ def call(_options, _err, out); end
+end
+
+# Together with the example group metadata hash default block,
+# provides backwards compatibility for the old `:example_group`
+# key. In RSpec 2.x, the computed keys of a group's metadata
+# were exposed from a nested subhash keyed by `[:example_group]`, and
+# then the parent group's metadata was exposed by sub-subhash
+# keyed by `[:example_group][:example_group]`.
+#
+# In RSpec 3, we reorganized this to that the computed keys are
+# exposed directly of the group metadata hash (no nesting), and
+# `:parent_example_group` returns the parent group's metadata.
+#
+# Maintaining backwards compatibility was difficult: we wanted
+# `:example_group` to return an object that:
+#
+# * Exposes the top-level metadata keys that used to be nested
+# under `:example_group`.
+# * Supports mutation (rspec-rails, for example, assigns
+# `metadata[:example_group][:described_class]` when you use
+# anonymous controller specs) such that changes are written
+# back to the top-level metadata hash.
+# * Exposes the parent group metadata as
+# `[:example_group][:example_group]`.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/metadata.rb#470
+class RSpec::Core::LegacyExampleGroupHash
+ include ::RSpec::Core::HashImitatable
+ extend ::RSpec::Core::HashImitatable::ClassMethods
+
+ # @return [LegacyExampleGroupHash] a new instance of LegacyExampleGroupHash
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#473
+ def initialize(metadata); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#479
+ def to_h; end
+
+ private
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#485
+ def directly_supports_attribute?(name); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#489
+ def get_value(name); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#493
+ def set_value(name, value); end
+end
+
+# This module is included in {ExampleGroup}, making the methods
+# available to be called from within example blocks.
+#
+# @see ClassMethods
+#
+# source://rspec-core//lib/rspec/core/memoized_helpers.rb#9
+module RSpec::Core::MemoizedHelpers
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#135
+ def initialize(*_arg0); end
+
+ # Wraps the `subject` in `expect` to make it the target of an expectation.
+ # Designed to read nicely for one-liners.
+ #
+ # @example
+ #
+ # describe [1, 2, 3] do
+ # it { is_expected.to be_an Array }
+ # it { is_expected.not_to include 4 }
+ # end
+ # @note This only works if you are using rspec-expectations.
+ # @see #subject
+ # @see #should
+ # @see #should_not
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#120
+ def is_expected; end
+
+ # When `should` is called with no explicit receiver, the call is
+ # delegated to the object returned by `subject`. Combined with an
+ # implicit subject this supports very concise expressions.
+ #
+ # @example
+ #
+ # RSpec.describe Person do
+ # it { should be_eligible_to_vote }
+ # end
+ # @note This only works if you are using rspec-expectations.
+ # @note If you are using RSpec's newer expect-based syntax you may
+ # want to use `is_expected.to` instead of `should`.
+ # @see #subject
+ # @see #is_expected
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#80
+ def should(matcher = T.unsafe(nil), message = T.unsafe(nil)); end
+
+ # Just like `should`, `should_not` delegates to the subject (implicit or
+ # explicit) of the example group.
+ #
+ # @example
+ #
+ # RSpec.describe Person do
+ # it { should_not be_eligible_to_vote }
+ # end
+ # @note This only works if you are using rspec-expectations.
+ # @note If you are using RSpec's newer expect-based syntax you may
+ # want to use `is_expected.to_not` instead of `should_not`.
+ # @see #subject
+ # @see #is_expected
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#100
+ def should_not(matcher = T.unsafe(nil), message = T.unsafe(nil)); end
+
+ # @example
+ #
+ # # Explicit declaration of subject.
+ # RSpec.describe Person do
+ # subject { Person.new(:birthdate => 19.years.ago) }
+ # it "should be eligible to vote" do
+ # subject.should be_eligible_to_vote
+ # # ^ ^ explicit reference to subject not recommended
+ # end
+ # end
+ #
+ # # Implicit subject => { Person.new }.
+ # RSpec.describe Person do
+ # it "should be eligible to vote" do
+ # subject.should be_eligible_to_vote
+ # # ^ ^ explicit reference to subject not recommended
+ # end
+ # end
+ #
+ # # One-liner syntax - expectation is set on the subject.
+ # RSpec.describe Person do
+ # it { is_expected.to be_eligible_to_vote }
+ # # or
+ # it { should be_eligible_to_vote }
+ # end
+ # @note `subject` was contributed by Joe Ferris to support the one-liner
+ # syntax embraced by shoulda matchers:
+ #
+ # RSpec.describe Widget do
+ # it { is_expected.to validate_presence_of(:name) }
+ # # or
+ # it { should validate_presence_of(:name) }
+ # end
+ #
+ # While the examples below demonstrate how to use `subject`
+ # explicitly in examples, we recommend that you define a method with
+ # an intention revealing name instead.
+ # @note Because `subject` is designed to create state that is reset
+ # between each example, and `before(:context)` is designed to setup
+ # state that is shared across _all_ examples in an example group,
+ # `subject` is _not_ intended to be used in a `before(:context)` hook.
+ # @see #should
+ # @see #should_not
+ # @see #is_expected
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#57
+ def subject; end
+
+ private
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#141
+ def __init_memoized; end
+
+ # should just be placed in private section,
+ # but Ruby issues warnings on private attributes.
+ # and expanding it to the equivalent method upsets Rubocop,
+ # b/c it should obviously be a reader
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#129
+ def __memoized; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#150
+ def enforce_value_expectation(matcher, method_name); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#163
+ def matcher_supports_value_expectations?(matcher); end
+
+ class << self
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#542
+ def define_helpers_on(example_group); end
+
+ # Gets the named constant or yields.
+ # On 1.9, const_defined? / const_get take into account the
+ # the inheritance by default, and accept an argument to
+ # disable this behavior. It's important that we don't
+ # consider inheritance here; each example group level that
+ # uses a `let` should get its own `LetDefinitions` module.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#570
+ def get_constant_or_yield(example_group, name); end
+
+ # Gets the LetDefinitions module. The module is mixed into
+ # the example group and is used to hold all let definitions.
+ # This is done so that the block passed to `let` can be
+ # forwarded directly on to `define_method`, so that all method
+ # constructs (including `super` and `return`) can be used in
+ # a `let` block.
+ #
+ # The memoization is provided by a method definition on the
+ # example group that supers to the LetDefinitions definition
+ # in order to get the value to memoize.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#528
+ def module_for(example_group); end
+ end
+end
+
+# This module is extended onto {ExampleGroup}, making the methods
+# available to be called from within example group blocks.
+# You can think of them as being analagous to class macros.
+#
+# source://rspec-core//lib/rspec/core/memoized_helpers.rb#274
+module RSpec::Core::MemoizedHelpers::ClassMethods
+ # Generates a method whose return value is memoized after the first
+ # call. Useful for reducing duplication between examples that assign
+ # values to the same local variable.
+ #
+ # @example
+ #
+ # RSpec.describe Thing do
+ # let(:thing) { Thing.new }
+ #
+ # it "does something" do
+ # # First invocation, executes block, memoizes and returns result.
+ # thing.do_something
+ #
+ # # Second invocation, returns the memoized value.
+ # thing.should be_something
+ # end
+ # end
+ # @note `let` _can_ enhance readability when used sparingly (1,2, or
+ # maybe 3 declarations) in any given example group, but that can
+ # quickly degrade with overuse. YMMV.
+ # @note `let` can be configured to be threadsafe or not.
+ # If it is threadsafe, it will take longer to access the value.
+ # If it is not threadsafe, it may behave in surprising ways in examples
+ # that spawn separate threads. Specify this on `RSpec.configure`
+ # @note Because `let` is designed to create state that is reset between
+ # each example, and `before(:context)` is designed to setup state that
+ # is shared across _all_ examples in an example group, `let` is _not_
+ # intended to be used in a `before(:context)` hook.
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#306
+ def let(name, &block); end
+
+ # Just like `let`, except the block is invoked by an implicit `before`
+ # hook. This serves a dual purpose of setting up state and providing a
+ # memoized reference to that state.
+ #
+ # @example
+ #
+ # class Thing
+ # def self.count
+ # @count ||= 0
+ # end
+ #
+ # def self.count=(val)
+ # @count += val
+ # end
+ #
+ # def self.reset_count
+ # @count = 0
+ # end
+ #
+ # def initialize
+ # self.class.count += 1
+ # end
+ # end
+ #
+ # RSpec.describe Thing do
+ # after(:example) { Thing.reset_count }
+ #
+ # context "using let" do
+ # let(:thing) { Thing.new }
+ #
+ # it "is not invoked implicitly" do
+ # Thing.count.should eq(0)
+ # end
+ #
+ # it "can be invoked explicitly" do
+ # thing
+ # Thing.count.should eq(1)
+ # end
+ # end
+ #
+ # context "using let!" do
+ # let!(:thing) { Thing.new }
+ #
+ # it "is invoked implicitly" do
+ # Thing.count.should eq(1)
+ # end
+ #
+ # it "returns memoized version on first invocation" do
+ # thing
+ # Thing.count.should eq(1)
+ # end
+ # end
+ # end
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#400
+ def let!(name, &block); end
+
+ # Declares a `subject` for an example group which can then be wrapped
+ # with `expect` using `is_expected` to make it the target of an
+ # expectation in a concise, one-line example.
+ #
+ # Given a `name`, defines a method with that name which returns the
+ # `subject`. This lets you declare the subject once and access it
+ # implicitly in one-liners and explicitly using an intention revealing
+ # name.
+ #
+ # When given a `name`, calling `super` in the block is not supported.
+ #
+ # @example
+ #
+ # RSpec.describe CheckingAccount, "with $50" do
+ # subject { CheckingAccount.new(Money.new(50, :USD)) }
+ # it { is_expected.to have_a_balance_of(Money.new(50, :USD)) }
+ # it { is_expected.not_to be_overdrawn }
+ # end
+ #
+ # RSpec.describe CheckingAccount, "with a non-zero starting balance" do
+ # subject(:account) { CheckingAccount.new(Money.new(50, :USD)) }
+ # it { is_expected.not_to be_overdrawn }
+ # it "has a balance equal to the starting balance" do
+ # account.balance.should eq(Money.new(50, :USD))
+ # end
+ # end
+ # @note `subject` can be configured to be threadsafe or not.
+ # If it is threadsafe, it will take longer to access the value.
+ # If it is not threadsafe, it may behave in surprising ways in examples
+ # that spawn separate threads. Specify this on `RSpec.configure`
+ # @param name [String, Symbol] used to define an accessor with an
+ # intention revealing name
+ # @param block defines the value to be returned by `subject` in examples
+ # @see MemoizedHelpers#should
+ # @see MemoizedHelpers#should_not
+ # @see MemoizedHelpers#is_expected
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#444
+ def subject(name = T.unsafe(nil), &block); end
+
+ # Just like `subject`, except the block is invoked by an implicit
+ # `before` hook. This serves a dual purpose of setting up state and
+ # providing a memoized reference to that state.
+ #
+ # @example
+ #
+ # class Thing
+ # def self.count
+ # @count ||= 0
+ # end
+ #
+ # def self.count=(val)
+ # @count += val
+ # end
+ #
+ # def self.reset_count
+ # @count = 0
+ # end
+ #
+ # def initialize
+ # self.class.count += 1
+ # end
+ # end
+ #
+ # RSpec.describe Thing do
+ # after(:example) { Thing.reset_count }
+ #
+ # context "using subject" do
+ # subject { Thing.new }
+ #
+ # it "is not invoked implicitly" do
+ # Thing.count.should eq(0)
+ # end
+ #
+ # it "can be invoked explicitly" do
+ # subject
+ # Thing.count.should eq(1)
+ # end
+ # end
+ #
+ # context "using subject!" do
+ # subject!(:thing) { Thing.new }
+ #
+ # it "is invoked implicitly" do
+ # Thing.count.should eq(1)
+ # end
+ #
+ # it "returns memoized version on first invocation" do
+ # subject
+ # Thing.count.should eq(1)
+ # end
+ # end
+ # end
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#510
+ def subject!(name = T.unsafe(nil), &block); end
+end
+
+# Used internally to customize the behavior of the
+# memoized hash when used in a `before(:context)` hook.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/memoized_helpers.rb#200
+class RSpec::Core::MemoizedHelpers::ContextHookMemoized
+ class << self
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#222
+ def fetch_or_store(key, &_block); end
+
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#201
+ def isolate_for_context_hook(example_group_instance); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/memoized_helpers.rb#256
+class RSpec::Core::MemoizedHelpers::ContextHookMemoized::After < ::RSpec::Core::MemoizedHelpers::ContextHookMemoized
+ class << self
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#261
+ def article; end
+
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#257
+ def hook_expression; end
+
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#265
+ def hook_intention; end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/memoized_helpers.rb#241
+class RSpec::Core::MemoizedHelpers::ContextHookMemoized::Before < ::RSpec::Core::MemoizedHelpers::ContextHookMemoized
+ class << self
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#246
+ def article; end
+
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#242
+ def hook_expression; end
+
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#250
+ def hook_intention; end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/memoized_helpers.rb#186
+class RSpec::Core::MemoizedHelpers::NonThreadSafeMemoized
+ # @return [NonThreadSafeMemoized] a new instance of NonThreadSafeMemoized
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#187
+ def initialize; end
+
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#191
+ def fetch_or_store(key); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/memoized_helpers.rb#170
+class RSpec::Core::MemoizedHelpers::ThreadsafeMemoized
+ # @return [ThreadsafeMemoized] a new instance of ThreadsafeMemoized
+ #
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#171
+ def initialize; end
+
+ # source://rspec-core//lib/rspec/core/memoized_helpers.rb#176
+ def fetch_or_store(key); end
+end
+
+# Each ExampleGroup class and Example instance owns an instance of
+# Metadata, which is Hash extended to support lazy evaluation of values
+# associated with keys that may or may not be used by any example or group.
+#
+# In addition to metadata that is used internally, this also stores
+# user-supplied metadata, e.g.
+#
+# RSpec.describe Something, :type => :ui do
+# it "does something", :slow => true do
+# # ...
+# end
+# end
+#
+# `:type => :ui` is stored in the Metadata owned by the example group, and
+# `:slow => true` is stored in the Metadata owned by the example. These can
+# then be used to select which examples are run using the `--tag` option on
+# the command line, or several methods on `Configuration` used to filter a
+# run (e.g. `filter_run_including`, `filter_run_excluding`, etc).
+#
+# @see Example#metadata
+# @see ExampleGroup.metadata
+# @see FilterManager
+# @see Configuration#filter_run_including
+# @see Configuration#filter_run_excluding
+#
+# source://rspec-core//lib/rspec/core/metadata.rb#27
+module RSpec::Core::Metadata
+ class << self
+ # Returns an enumerator that iteratively walks up the given metadata through all
+ # example group ancestors, yielding each metadata hash along the way.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#71
+ def ascend(metadata); end
+
+ # Iteratively walks up from the given metadata through all
+ # example group ancestors, yielding each metadata hash along the way.
+ #
+ # @private
+ # @yield [metadata]
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#58
+ def ascending(metadata); end
+
+ # Used internally to build a hash from an args array.
+ # Symbols are converted into hash keys with a value of `true`.
+ # This is done to support simple tagging using a symbol, rather
+ # than needing to do `:symbol => true`.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#80
+ def build_hash_from(args, warn_about_example_group_filtering = T.unsafe(nil)); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#94
+ def deep_hash_dup(object); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#105
+ def id_from(metadata); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#110
+ def location_tuple_from(metadata); end
+
+ # @api private
+ # @param line [String] current code line
+ # @return [String] relative path to line
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#44
+ def relative_path(line); end
+
+ # Matches strings either at the beginning of the input or prefixed with a
+ # whitespace, containing the current path, either postfixed with the
+ # separator, or at the end of the string. Match groups are the character
+ # before and the character after the string if any.
+ #
+ # http://rubular.com/r/fT0gmX6VJX
+ # http://rubular.com/r/duOrD4i3wb
+ # http://rubular.com/r/sbAMHFrOx1
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#36
+ def relative_path_regex; end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/metadata.rb#247
+class RSpec::Core::Metadata::ExampleGroupHash < ::RSpec::Core::Metadata::HashPopulator
+ private
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#304
+ def described_class; end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#311
+ def full_description; end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/metadata.rb#265
+ def backwards_compatibility_default_proc(&example_group_selector); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#248
+ def create(parent_group_metadata, user_metadata, example_group_index, *args, &block); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#261
+ def hash_with_backwards_compatibility_default_proc; end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/metadata.rb#213
+class RSpec::Core::Metadata::ExampleHash < ::RSpec::Core::Metadata::HashPopulator
+ private
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#234
+ def described_class; end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#238
+ def full_description; end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/metadata.rb#214
+ def create(group_metadata, user_metadata, index_provider, description, block); end
+ end
+end
+
+# Used internally to populate metadata hashes with computed keys
+# managed by RSpec.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/metadata.rb#117
+class RSpec::Core::Metadata::HashPopulator
+ # @return [HashPopulator] a new instance of HashPopulator
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#120
+ def initialize(metadata, user_metadata, index_provider, description_args, block); end
+
+ # Returns the value of attribute block.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#118
+ def block; end
+
+ # Returns the value of attribute description_args.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#118
+ def description_args; end
+
+ # Returns the value of attribute metadata.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#118
+ def metadata; end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#128
+ def populate; end
+
+ # Returns the value of attribute user_metadata.
+ #
+ # source://rspec-core//lib/rspec/core/metadata.rb#118
+ def user_metadata; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#178
+ def build_description_from(parent_description = T.unsafe(nil), my_description = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#185
+ def build_scoped_id_for(file_path); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#170
+ def description_separator(parent_part, child_part); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#191
+ def ensure_valid_user_keys; end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#164
+ def file_path_and_line_number_from(backtrace); end
+
+ # source://rspec-core//lib/rspec/core/metadata.rb#143
+ def populate_location_attributes; end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/metadata.rb#325
+RSpec::Core::Metadata::RESERVED_KEYS = T.let(T.unsafe(nil), Array)
+
+# Contains metadata filtering logic. This has been extracted from
+# the metadata classes because it operates ON a metadata hash but
+# does not manage any of the state in the hash. We're moving towards
+# having metadata be a raw hash (not a custom subclass), so externalizing
+# this filtering logic helps us move in that direction.
+#
+# source://rspec-core//lib/rspec/core/metadata_filter.rb#8
+module RSpec::Core::MetadataFilter
+ class << self
+ # @private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#11
+ def apply?(predicate, filters, metadata); end
+
+ # @private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#16
+ def filter_applies?(key, filter_value, metadata); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#33
+ def silence_metadata_example_group_deprecations; end
+
+ private
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#42
+ def filter_applies_to_any_value?(key, value, metadata); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#73
+ def filters_apply?(key, value, metadata); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#46
+ def id_filter_applies?(rerun_paths_to_scoped_ids, metadata); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#54
+ def location_filter_applies?(locations, metadata); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/metadata_filter.rb#65
+ def proc_filter_applies?(key, proc, metadata); end
+ end
+end
+
+# Provides a single exception instance that provides access to
+# multiple sub-exceptions. This is used in situations where a single
+# individual spec has multiple exceptions, such as one in the `it` block
+# and one in an `after` block.
+#
+# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#452
+class RSpec::Core::MultipleExceptionError < ::StandardError
+ include ::RSpec::Core::MultipleExceptionError::InterfaceTag
+
+ # @param exceptions [Array] The initial list of exceptions.
+ # @return [MultipleExceptionError] a new instance of MultipleExceptionError
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#513
+ def initialize(*exceptions); end
+
+ # @return [nil] Provided only for interface compatibility with
+ # `RSpec::Expectations::MultipleExpectationsNotMetError`.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#510
+ def aggregation_block_label; end
+
+ # @return [Hash] Metadata used by RSpec for formatting purposes.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#506
+ def aggregation_metadata; end
+
+ # @return [Array] The list of failures and other exceptions, combined.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#503
+ def all_exceptions; end
+
+ # return [String] A description of the failure/error counts.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#538
+ def exception_count_description; end
+
+ # @return [Array] The list of failures.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#497
+ def failures; end
+
+ # @note RSpec does not actually use this -- instead it formats each exception
+ # individually.
+ # @return [String] Combines all the exception messages into a single string.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#528
+ def message; end
+
+ # @return [Array] The list of other errors.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#500
+ def other_errors; end
+
+ # @return [String] A summary of the failure, including the block label and a count of failures.
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#533
+ def summary; end
+end
+
+# Used so there is a common module in the ancestor chain of this class
+# and `RSpec::Expectations::MultipleExpectationsNotMetError`, which allows
+# code to detect exceptions that are instances of either, without first
+# checking to see if rspec-expectations is loaded.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#458
+module RSpec::Core::MultipleExceptionError::InterfaceTag
+ # Appends the provided exception to the list.
+ #
+ # @param exception [Exception] Exception to append to the list.
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#462
+ def add(exception); end
+
+ class << self
+ # Provides a way to force `ex` to be something that satisfies the multiple
+ # exception error interface. If it already satisfies it, it will be returned;
+ # otherwise it will wrap it in a `MultipleExceptionError`.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/formatters/exception_presenter.rb#488
+ def for(ex); end
+ end
+end
+
+# Notifications are value objects passed to formatters to provide them
+# with information about a particular event of interest.
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#9
+module RSpec::Core::Notifications; end
+
+# `CustomNotification` is used when sending custom events to formatters /
+# other registered listeners, it creates attributes based on supplied hash
+# of options.
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#512
+class RSpec::Core::Notifications::CustomNotification < ::Struct
+ class << self
+ # Build a custom notification based on the supplied option key / values.
+ #
+ # @param options [Hash] A hash of method / value pairs to create on this notification
+ # @return [CustomNotification]
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#517
+ def for(options = T.unsafe(nil)); end
+ end
+end
+
+# The `DeprecationNotification` is issued by the reporter when a deprecated
+# part of RSpec is encountered. It represents information about the
+# deprecated call site.
+#
+# @attr message [String] A custom message about the deprecation
+# @attr deprecated [String] A custom message about the deprecation (alias of
+# message)
+# @attr replacement [String] An optional replacement for the deprecation
+# @attr call_site [String] An optional call site from which the deprecation
+# was issued
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#493
+class RSpec::Core::Notifications::DeprecationNotification < ::Struct
+ # An optional call site from which the deprecation
+ # was issued
+ #
+ # @return [String] the current value of call_site
+ def call_site; end
+
+ # An optional call site from which the deprecation
+ # was issued
+ #
+ # @param value [String] the value to set the attribute call_site to.
+ # @return [String] the newly set value
+ def call_site=(_); end
+
+ # A custom message about the deprecation (alias of
+ # message)
+ #
+ # @return [String] the current value of deprecated
+ def deprecated; end
+
+ # A custom message about the deprecation (alias of
+ # message)
+ #
+ # @param value [String] the value to set the attribute deprecated to.
+ # @return [String] the newly set value
+ def deprecated=(_); end
+
+ # A custom message about the deprecation
+ #
+ # @return [String] the current value of message
+ def message; end
+
+ # A custom message about the deprecation
+ #
+ # @param value [String] the value to set the attribute message to.
+ # @return [String] the newly set value
+ def message=(_); end
+
+ # An optional replacement for the deprecation
+ #
+ # @return [String] the current value of replacement
+ def replacement; end
+
+ # An optional replacement for the deprecation
+ #
+ # @param value [String] the value to set the attribute replacement to.
+ # @return [String] the newly set value
+ def replacement=(_); end
+
+ class << self
+ def [](*_arg0); end
+
+ # Convenience way to initialize the notification
+ #
+ # @api
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#499
+ def from_hash(data); end
+
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+
+ private
+
+ def new(*_arg0); end
+ end
+end
+
+# The `ExampleNotification` represents notifications sent by the reporter
+# which contain information about the current (or soon to be) example.
+# It is used by formatters to access information about that example.
+#
+# @attr example [RSpec::Core::Example] the current example
+# @example
+# def example_started(notification)
+# puts "Hey I started #{notification.example.description}"
+# end
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#38
+class RSpec::Core::Notifications::ExampleNotification < ::Struct
+ # the current example
+ #
+ # @return [RSpec::Core::Example] the current value of example
+ def example; end
+
+ # the current example
+ #
+ # @param value [RSpec::Core::Example] the value to set the attribute example to.
+ # @return [RSpec::Core::Example] the newly set value
+ def example=(_); end
+
+ class << self
+ def [](*_arg0); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#41
+ def for(example); end
+
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+
+ private
+
+ def new(*_arg0); end
+ end
+end
+
+# The `ExamplesNotification` represents notifications sent by the reporter
+# which contain information about the suites examples.
+#
+# @example
+# def stop(notification)
+# puts "Hey I ran #{notification.examples.size}"
+# end
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#69
+class RSpec::Core::Notifications::ExamplesNotification
+ # @return [ExamplesNotification] a new instance of ExamplesNotification
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#70
+ def initialize(reporter); end
+
+ # @return [Array] list of examples
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#75
+ def examples; end
+
+ # @return [Array] list of failed examples
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#80
+ def failed_examples; end
+
+ # @return [Array] returns failed examples as notifications
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#97
+ def failure_notifications; end
+
+ # @return [String] The list of failed examples, fully formatted in the way
+ # that RSpec's built-in formatters emit.
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#110
+ def fully_formatted_failed_examples(colorizer = T.unsafe(nil)); end
+
+ # @return [String] The list of pending examples, fully formatted in the
+ # way that RSpec's built-in formatters emit.
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#122
+ def fully_formatted_pending_examples(colorizer = T.unsafe(nil)); end
+
+ # @return [Array] returns examples as notifications
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#91
+ def notifications; end
+
+ # @return [Array] list of pending examples
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#85
+ def pending_examples; end
+
+ # returns pending examples as notifications
+ #
+ # @return [Array]
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#104
+ def pending_notifications; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/notifications.rb#136
+ def format_examples(examples); end
+end
+
+# The `FailedExampleNotification` extends `ExampleNotification` with
+# things useful for examples that have failure info -- typically a
+# failed or pending spec.
+#
+# @attr example [RSpec::Core::Example] the current example
+# @example
+# def example_failed(notification)
+# puts "Hey I failed :("
+# puts "Here's my stack trace"
+# puts notification.exception.backtrace.join("\n")
+# end
+# @see ExampleNotification
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#156
+class RSpec::Core::Notifications::FailedExampleNotification < ::RSpec::Core::Notifications::ExampleNotification
+ # @return [FailedExampleNotification] a new instance of FailedExampleNotification
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#213
+ def initialize(example, exception_presenter = T.unsafe(nil)); end
+
+ # Returns the failures colorized formatted backtrace.
+ #
+ # @param colorizer [#wrap] An object to colorize the message_lines by
+ # @return [Array] the examples colorized backtrace lines
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#195
+ def colorized_formatted_backtrace(colorizer = T.unsafe(nil)); end
+
+ # Returns the message generated for this failure colorized line by line.
+ #
+ # @param colorizer [#wrap] An object to colorize the message_lines by
+ # @return [Array] The example failure message colorized
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#180
+ def colorized_message_lines(colorizer = T.unsafe(nil)); end
+
+ # @return [String] The example description
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#165
+ def description; end
+
+ # @return [Exception] The example failure
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#160
+ def exception; end
+
+ # Returns the failures formatted backtrace.
+ #
+ # @return [Array] the examples backtrace lines
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#187
+ def formatted_backtrace; end
+
+ # @return [String] The failure information fully formatted in the way that
+ # RSpec's built-in formatters emit.
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#201
+ def fully_formatted(failure_number, colorizer = T.unsafe(nil)); end
+
+ # @return [Array] The failure information fully formatted in the way that
+ # RSpec's built-in formatters emit, split by line.
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#207
+ def fully_formatted_lines(failure_number, colorizer = T.unsafe(nil)); end
+
+ # Returns the message generated for this failure line by line.
+ #
+ # @return [Array] The example failure message
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#172
+ def message_lines; end
+
+ class << self
+ def new(*_arg0); end
+ end
+end
+
+# The `GroupNotification` represents notifications sent by the reporter
+# which contain information about the currently running (or soon to be)
+# example group. It is used by formatters to access information about that
+# group.
+#
+# @attr group [RSpec::Core::ExampleGroup] the current group
+# @example
+# def example_group_started(notification)
+# puts "Hey I started #{notification.group.description}"
+# end
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#258
+class RSpec::Core::Notifications::GroupNotification < ::Struct
+ # the current group
+ #
+ # @return [RSpec::Core::ExampleGroup] the current value of group
+ def group; end
+
+ # the current group
+ #
+ # @param value [RSpec::Core::ExampleGroup] the value to set the attribute group to.
+ # @return [RSpec::Core::ExampleGroup] the newly set value
+ def group=(_); end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# The `MessageNotification` encapsulates generic messages that the reporter
+# sends to formatters.
+#
+# @attr message [String] the message
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#264
+class RSpec::Core::Notifications::MessageNotification < ::Struct
+ # the message
+ #
+ # @return [String] the current value of message
+ def message; end
+
+ # the message
+ #
+ # @param value [String] the value to set the attribute message to.
+ # @return [String] the newly set value
+ def message=(_); end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#11
+module RSpec::Core::Notifications::NullColorizer
+ private
+
+ # source://rspec-core//lib/rspec/core/notifications.rb#14
+ def wrap(line, _code_or_symbol); end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/notifications.rb#14
+ def wrap(line, _code_or_symbol); end
+ end
+end
+
+# `NullNotification` represents a placeholder value for notifications that
+# currently require no information, but we may wish to extend in future.
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#506
+class RSpec::Core::Notifications::NullNotification; end
+
+# @deprecated Use {FailedExampleNotification} instead.
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#223
+class RSpec::Core::Notifications::PendingExampleFailedAsExpectedNotification < ::RSpec::Core::Notifications::FailedExampleNotification; end
+
+# @deprecated Use {FailedExampleNotification} instead.
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#220
+class RSpec::Core::Notifications::PendingExampleFixedNotification < ::RSpec::Core::Notifications::FailedExampleNotification; end
+
+# The `ProfileNotification` holds information about the results of running a
+# test suite when profiling is enabled. It is used by formatters to provide
+# information at the end of the test run for profiling information.
+#
+# @attr duration [Float] the time taken (in seconds) to run the suite
+# @attr examples [Array] the examples run
+# @attr number_of_examples [Fixnum] the number of examples to profile
+# @attr example_groups [Array] example groups run
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#429
+class RSpec::Core::Notifications::ProfileNotification
+ # @return [ProfileNotification] a new instance of ProfileNotification
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#430
+ def initialize(duration, examples, number_of_examples, example_groups); end
+
+ # the time taken (in seconds) to run the suite
+ #
+ # @return [Float] the current value of duration
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#436
+ def duration; end
+
+ # the examples run
+ #
+ # @return [Array] the current value of examples
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#436
+ def examples; end
+
+ # the number of examples to profile
+ #
+ # @return [Fixnum] the current value of number_of_examples
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#436
+ def number_of_examples; end
+
+ # @return [String] the percentage of total time taken
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#455
+ def percentage; end
+
+ # @return [Float] the time taken (in seconds) to run the slowest examples
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#447
+ def slow_duration; end
+
+ # @return [Array] the slowest examples
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#439
+ def slowest_examples; end
+
+ # @return [Array] the slowest example groups
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#464
+ def slowest_groups; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/notifications.rb#470
+ def calculate_slowest_groups; end
+end
+
+# The `SeedNotification` holds the seed used to randomize examples and
+# whether that seed has been used or not.
+#
+# @attr seed [Fixnum] the seed used to randomize ordering
+# @attr used [Boolean] whether the seed has been used or not
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#271
+class RSpec::Core::Notifications::SeedNotification < ::Struct
+ # @return [String] The seed information fully formatted in the way that
+ # RSpec's built-in formatters emit.
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#282
+ def fully_formatted; end
+
+ # the seed used to randomize ordering
+ #
+ # @return [Fixnum] the current value of seed
+ def seed; end
+
+ # the seed used to randomize ordering
+ #
+ # @param value [Fixnum] the value to set the attribute seed to.
+ # @return [Fixnum] the newly set value
+ def seed=(_); end
+
+ # @api
+ # @return [Boolean] has the seed been used?
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#275
+ def seed_used?; end
+
+ # whether the seed has been used or not
+ #
+ # @param value [Boolean] the value to set the attribute used to.
+ # @return [Boolean] the newly set value
+ def used=(_); end
+
+ private
+
+ # whether the seed has been used or not
+ #
+ # @return [Boolean] the current value of used
+ def used; end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# The `SkippedExampleNotification` extends `ExampleNotification` with
+# things useful for specs that are skipped.
+#
+# @attr example [RSpec::Core::Example] the current example
+# @see ExampleNotification
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#230
+class RSpec::Core::Notifications::SkippedExampleNotification < ::RSpec::Core::Notifications::ExampleNotification
+ # @return [String] The pending detail fully formatted in the way that
+ # RSpec's built-in formatters emit.
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#235
+ def fully_formatted(pending_number, colorizer = T.unsafe(nil)); end
+
+ class << self
+ def new(*_arg0); end
+ end
+end
+
+# The `StartNotification` represents a notification sent by the reporter
+# when the suite is started. It contains the expected amount of examples
+# to be executed, and the load time of RSpec.
+#
+# @attr count [Fixnum] the number counted
+# @attr load_time [Float] the number of seconds taken to boot RSpec
+# and load the spec files
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#26
+class RSpec::Core::Notifications::StartNotification < ::Struct
+ # the number counted
+ #
+ # @return [Fixnum] the current value of count
+ def count; end
+
+ # the number counted
+ #
+ # @param value [Fixnum] the value to set the attribute count to.
+ # @return [Fixnum] the newly set value
+ def count=(_); end
+
+ # the number of seconds taken to boot RSpec
+ # and load the spec files
+ #
+ # @return [Float] the current value of load_time
+ def load_time; end
+
+ # the number of seconds taken to boot RSpec
+ # and load the spec files
+ #
+ # @param value [Float] the value to set the attribute load_time to.
+ # @return [Float] the newly set value
+ def load_time=(_); end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# The `SummaryNotification` holds information about the results of running
+# a test suite. It is used by formatters to provide information at the end
+# of the test run.
+#
+# @attr duration [Float] the time taken (in seconds) to run the suite
+# @attr examples [Array] the examples run
+# @attr failed_examples [Array] the failed examples
+# @attr pending_examples [Array] the pending examples
+# @attr load_time [Float] the number of seconds taken to boot RSpec
+# and load the spec files
+# @attr errors_outside_of_examples_count [Integer] the number of errors that
+# have occurred processing
+# the spec suite
+#
+# source://rspec-core//lib/rspec/core/notifications.rb#300
+class RSpec::Core::Notifications::SummaryNotification < ::Struct
+ include ::RSpec::Core::ShellEscape
+
+ # Formats failures into a rerunable command format.
+ #
+ # @api public
+ # @param colorizer [#wrap] An object which supports wrapping text with
+ # specific colors.
+ # @return [String] A colorized summary line.
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#364
+ def colorized_rerun_commands(colorizer = T.unsafe(nil)); end
+
+ # Wraps the results line with colors based on the configured
+ # colors for failure, pending, and success. Defaults to red,
+ # yellow, green accordingly.
+ #
+ # @api public
+ # @param colorizer [#wrap] An object which supports wrapping text with
+ # specific colors.
+ # @return [String] A colorized results line.
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#347
+ def colorized_totals_line(colorizer = T.unsafe(nil)); end
+
+ # the time taken (in seconds) to run the suite
+ #
+ # @return [Float] the current value of duration
+ def duration; end
+
+ # the time taken (in seconds) to run the suite
+ #
+ # @param value [Float] the value to set the attribute duration to.
+ # @return [Float] the newly set value
+ def duration=(_); end
+
+ # the number of errors that
+ # have occurred processing
+ # the spec suite
+ #
+ # @return [Integer] the current value of errors_outside_of_examples_count
+ def errors_outside_of_examples_count; end
+
+ # the number of errors that
+ # have occurred processing
+ # the spec suite
+ #
+ # @param value [Integer] the value to set the attribute errors_outside_of_examples_count to.
+ # @return [Integer] the newly set value
+ def errors_outside_of_examples_count=(_); end
+
+ # @api
+ # @return [Fixnum] the number of examples run
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#306
+ def example_count; end
+
+ # the examples run
+ #
+ # @return [Array] the current value of examples
+ def examples; end
+
+ # the examples run
+ #
+ # @param value [Array] the value to set the attribute examples to.
+ # @return [Array] the newly set value
+ def examples=(_); end
+
+ # the failed examples
+ #
+ # @return [Array] the current value of failed_examples
+ def failed_examples; end
+
+ # the failed examples
+ #
+ # @param value [Array] the value to set the attribute failed_examples to.
+ # @return [Array] the newly set value
+ def failed_examples=(_); end
+
+ # @api
+ # @return [Fixnum] the number of failed examples
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#312
+ def failure_count; end
+
+ # @return [String] a formatted version of the time it took to run the
+ # suite
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#374
+ def formatted_duration; end
+
+ # @return [String] a formatted version of the time it took to boot RSpec
+ # and load the spec files
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#380
+ def formatted_load_time; end
+
+ # @return [String] The summary information fully formatted in the way that
+ # RSpec's built-in formatters emit.
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#386
+ def fully_formatted(colorizer = T.unsafe(nil)); end
+
+ # the number of seconds taken to boot RSpec
+ # and load the spec files
+ #
+ # @return [Float] the current value of load_time
+ def load_time; end
+
+ # the number of seconds taken to boot RSpec
+ # and load the spec files
+ #
+ # @param value [Float] the value to set the attribute load_time to.
+ # @return [Float] the newly set value
+ def load_time=(_); end
+
+ # @api
+ # @return [Fixnum] the number of pending examples
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#318
+ def pending_count; end
+
+ # the pending examples
+ #
+ # @return [Array] the current value of pending_examples
+ def pending_examples; end
+
+ # the pending examples
+ #
+ # @param value [Array] the value to set the attribute pending_examples to.
+ # @return [Array] the newly set value
+ def pending_examples=(_); end
+
+ # @api
+ # @return [String] A line summarising the result totals of the spec run.
+ #
+ # source://rspec-core//lib/rspec/core/notifications.rb#324
+ def totals_line; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/notifications.rb#408
+ def duplicate_rerun_locations; end
+
+ # source://rspec-core//lib/rspec/core/notifications.rb#402
+ def rerun_argument_for(example); end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# # Used in place of a {Reporter} for situations where we don't want reporting output.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/reporter.rb#259
+class RSpec::Core::NullReporter
+ class << self
+ private
+
+ # source://rspec-core//lib/rspec/core/reporter.rb#260
+ def method_missing(*_arg0); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/ordering.rb#4
+module RSpec::Core::Ordering; end
+
+# Manages ordering configuration.
+#
+# @note This is not intended to be used externally. Use
+# the APIs provided by `RSpec::Core::Configuration` instead.
+# @private
+#
+# source://rspec-core//lib/rspec/core/ordering.rb#144
+class RSpec::Core::Ordering::ConfigurationManager
+ # @return [ConfigurationManager] a new instance of ConfigurationManager
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#147
+ def initialize; end
+
+ # source://rspec-core//lib/rspec/core/ordering.rb#190
+ def force(hash); end
+
+ # source://rspec-core//lib/rspec/core/ordering.rb#164
+ def order=(type); end
+
+ # Returns the value of attribute ordering_registry.
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#145
+ def ordering_registry; end
+
+ # source://rspec-core//lib/rspec/core/ordering.rb#201
+ def register_ordering(name, strategy = T.unsafe(nil)); end
+
+ # Returns the value of attribute seed.
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#145
+ def seed; end
+
+ # source://rspec-core//lib/rspec/core/ordering.rb#158
+ def seed=(seed); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#154
+ def seed_used?; end
+end
+
+# Orders items based on a custom block.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/ordering.rb#71
+class RSpec::Core::Ordering::Custom
+ # @return [Custom] a new instance of Custom
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#72
+ def initialize(callable); end
+
+ # source://rspec-core//lib/rspec/core/ordering.rb#76
+ def order(list); end
+end
+
+# A strategy which delays looking up the ordering until needed
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/ordering.rb#83
+class RSpec::Core::Ordering::Delayed
+ # @return [Delayed] a new instance of Delayed
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#84
+ def initialize(registry, name); end
+
+ # source://rspec-core//lib/rspec/core/ordering.rb#89
+ def order(list); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/ordering.rb#99
+ def lookup_strategy; end
+
+ # source://rspec-core//lib/rspec/core/ordering.rb#95
+ def strategy; end
+end
+
+# The default global ordering (defined order).
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/ordering.rb#7
+class RSpec::Core::Ordering::Identity
+ # source://rspec-core//lib/rspec/core/ordering.rb#8
+ def order(items); end
+end
+
+# Orders items randomly.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/ordering.rb#15
+class RSpec::Core::Ordering::Random
+ # @return [Random] a new instance of Random
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#16
+ def initialize(configuration); end
+
+ # source://rspec-core//lib/rspec/core/ordering.rb#25
+ def order(items); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#21
+ def used?; end
+
+ private
+
+ # http://en.wikipedia.org/wiki/Jenkins_hash_function
+ # Jenkins provides a good distribution and is simpler than MD5.
+ # It's a bit slower than MD5 (primarily because `Digest::MD5` is
+ # implemented in C) but has the advantage of not requiring us
+ # to load another part of stdlib, which we try to minimize.
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#39
+ def jenkins_hash_digest(string); end
+end
+
+# source://rspec-core//lib/rspec/core/ordering.rb#58
+RSpec::Core::Ordering::Random::MAX_32_BIT = T.let(T.unsafe(nil), Integer)
+
+# Orders items by modification time (most recent modified first).
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/ordering.rb#63
+class RSpec::Core::Ordering::RecentlyModified
+ # source://rspec-core//lib/rspec/core/ordering.rb#64
+ def order(list); end
+end
+
+# Stores the different ordering strategies.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/ordering.rb#107
+class RSpec::Core::Ordering::Registry
+ # @return [Registry] a new instance of Registry
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#108
+ def initialize(configuration); end
+
+ # source://rspec-core//lib/rspec/core/ordering.rb#122
+ def fetch(name, &fallback); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#126
+ def has_strategy?(name); end
+
+ # source://rspec-core//lib/rspec/core/ordering.rb#130
+ def register(sym, strategy); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/ordering.rb#134
+ def used_random_seed?; end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/output_wrapper.rb#4
+class RSpec::Core::OutputWrapper
+ # @private
+ # @return [OutputWrapper] a new instance of OutputWrapper
+ #
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#9
+ def initialize(output); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def <<(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def advise(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def autoclose=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def autoclose?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def binmode(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def binmode?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def close(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def close_on_exec=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def close_on_exec?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def close_read(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def close_write(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def closed?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def each(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def each_byte(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def each_char(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def each_codepoint(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def each_line(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def eof(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def eof?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def external_encoding(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def fcntl(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def fdatasync(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def fileno(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def flush(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def fsync(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def getbyte(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def getc(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def gets(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def inspect(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def internal_encoding(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def ioctl(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def isatty(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def lineno(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def lineno=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#17
+ def method_missing(name, *args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def nonblock(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def nonblock=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def nonblock?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def nread(*args, &block); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#6
+ def output; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#6
+ def output=(_arg0); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def path(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def pathconf(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def pid(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def pos(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def pos=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def pread(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def print(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def printf(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def putc(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def puts(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def pwrite(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def read(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def read_nonblock(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def readbyte(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def readchar(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def readline(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def readlines(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def readpartial(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def ready?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def reopen(*args, &block); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#13
+ def respond_to?(name, priv = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def rewind(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def seek(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def set_encoding(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def set_encoding_by_bom(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def stat(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def sync(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def sync=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def sysread(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def sysseek(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def syswrite(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def tell(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def timeout(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def timeout=(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def to_i(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def to_io(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def to_path(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def tty?(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def ungetbyte(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def ungetc(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def wait(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def wait_priority(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def wait_readable(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def wait_writable(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def write(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/output_wrapper.rb#23
+ def write_nonblock(*args, &block); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/option_parser.rb#6
+class RSpec::Core::Parser
+ # @return [Parser] a new instance of Parser
+ #
+ # source://rspec-core//lib/rspec/core/option_parser.rb#13
+ def initialize(original_args); end
+
+ # Returns the value of attribute original_args.
+ #
+ # source://rspec-core//lib/rspec/core/option_parser.rb#11
+ def original_args; end
+
+ # source://rspec-core//lib/rspec/core/option_parser.rb#17
+ def parse(source = T.unsafe(nil)); end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/option_parser.rb#310
+ def add_tag_filter(options, filter_type, tag_name, value = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/option_parser.rb#318
+ def configure_only_failures(options); end
+
+ # source://rspec-core//lib/rspec/core/option_parser.rb#39
+ def parser(options); end
+
+ # source://rspec-core//lib/rspec/core/option_parser.rb#314
+ def set_fail_fast(options, value); end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/option_parser.rb#7
+ def parse(args, source = T.unsafe(nil)); end
+ end
+end
+
+# Provides methods to mark examples as pending. These methods are available
+# to be called from within any example or hook.
+#
+# source://rspec-core//lib/rspec/core/pending.rb#5
+module RSpec::Core::Pending
+ # Marks an example as pending. The rest of the example will still be
+ # executed, and if it passes the example will fail to indicate that the
+ # pending can be removed.
+ #
+ # @example
+ # describe "some behaviour" do
+ # # reported as "Pending: no reason given"
+ # it "is pending with no message" do
+ # pending
+ # raise "broken"
+ # end
+ #
+ # # reported as "Pending: something else getting finished"
+ # it "is pending with a custom message" do
+ # pending("something else getting finished")
+ # raise "broken"
+ # end
+ # end
+ # @note When using `pending` inside an example body using this method
+ # hooks, such as `before(:example)`, have already be run. This means that
+ # a failure from the code in the `before` hook will prevent the example
+ # from being considered pending, as the example body would not be
+ # executed. If you need to consider hooks as pending as well you can use
+ # the pending metadata as an alternative, e.g.
+ # `it "does something", pending: "message"`.
+ # @overload pending
+ # @overload pending
+ # @param message [String] optional message to add to the summary report.
+ #
+ # source://rspec-core//lib/rspec/core/pending.rb#62
+ def pending(message = T.unsafe(nil)); end
+
+ # Marks an example as pending and skips execution.
+ #
+ # @example
+ # describe "an example" do
+ # # reported as "Pending: no reason given"
+ # it "is skipped with no message" do
+ # skip
+ # end
+ #
+ # # reported as "Pending: something else getting finished"
+ # it "is skipped with a custom message" do
+ # skip "something else getting finished"
+ # end
+ # end
+ # @overload skip
+ # @overload skip
+ # @param message [String] optional message to add to the summary report.
+ # @raise [SkipDeclaredInExample]
+ #
+ # source://rspec-core//lib/rspec/core/pending.rb#110
+ def skip(message = T.unsafe(nil)); end
+
+ class << self
+ # Mark example as fixed.
+ #
+ # @param example [RSpec::Core::Example] the example to mark as fixed
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/pending.rb#152
+ def mark_fixed!(example); end
+
+ # Mark example as pending.
+ #
+ # @param example [RSpec::Core::Example] the example to mark as pending
+ # @param message_or_bool [Boolean, String] the message to use, or true
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/pending.rb#135
+ def mark_pending!(example, message_or_bool); end
+
+ # Mark example as skipped.
+ #
+ # @param example [RSpec::Core::Example] the example to mark as skipped
+ # @param message_or_bool [Boolean, String] the message to use, or true
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/pending.rb#124
+ def mark_skipped!(example, message_or_bool); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/pending.rb#29
+RSpec::Core::Pending::NOT_YET_IMPLEMENTED = T.let(T.unsafe(nil), String)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/pending.rb#26
+RSpec::Core::Pending::NO_REASON_GIVEN = T.let(T.unsafe(nil), String)
+
+# source://rspec-core//lib/rspec/core/pending.rb#22
+class RSpec::Core::Pending::PendingExampleFixedError < ::StandardError; end
+
+# Raised in the middle of an example to indicate that it should be marked
+# as skipped.
+#
+# source://rspec-core//lib/rspec/core/pending.rb#8
+class RSpec::Core::Pending::SkipDeclaredInExample < ::StandardError
+ # @return [SkipDeclaredInExample] a new instance of SkipDeclaredInExample
+ #
+ # source://rspec-core//lib/rspec/core/pending.rb#11
+ def initialize(argument); end
+
+ # Returns the value of attribute argument.
+ #
+ # source://rspec-core//lib/rspec/core/pending.rb#9
+ def argument; end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/profiler.rb#4
+class RSpec::Core::Profiler
+ # @return [Profiler] a new instance of Profiler
+ #
+ # source://rspec-core//lib/rspec/core/profiler.rb#7
+ def initialize; end
+
+ # source://rspec-core//lib/rspec/core/profiler.rb#20
+ def example_group_finished(notification); end
+
+ # source://rspec-core//lib/rspec/core/profiler.rb#13
+ def example_group_started(notification); end
+
+ # Returns the value of attribute example_groups.
+ #
+ # source://rspec-core//lib/rspec/core/profiler.rb#11
+ def example_groups; end
+
+ # source://rspec-core//lib/rspec/core/profiler.rb#28
+ def example_started(notification); end
+end
+
+# source://rspec-core//lib/rspec/core/profiler.rb#5
+RSpec::Core::Profiler::NOTIFICATIONS = T.let(T.unsafe(nil), Array)
+
+# A reporter will send notifications to listeners, usually formatters for the
+# spec suite run.
+#
+# source://rspec-core//lib/rspec/core/reporter.rb#4
+class RSpec::Core::Reporter
+ # @return [Reporter] a new instance of Reporter
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#14
+ def initialize(configuration); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#214
+ def abort_with(msg, exit_status); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#193
+ def close_after; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#155
+ def deprecation(hash); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#143
+ def example_failed(example); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#133
+ def example_finished(example); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#122
+ def example_group_finished(group); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#117
+ def example_group_started(group); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#138
+ def example_passed(example); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#149
+ def example_pending(example); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#127
+ def example_started(example); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#28
+ def examples; end
+
+ # Reports a run that exited early without having run any examples.
+ #
+ # @param exit_code [Integer] the exit_code to be return by the reporter
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#84
+ def exit_early(exit_code); end
+
+ # @private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#221
+ def fail_fast_limit_met?; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#28
+ def failed_examples; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#173
+ def finish; end
+
+ # Send a custom message to supporting formatters.
+ #
+ # @param message [#to_s] A message object to send to formatters
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#99
+ def message(message); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#206
+ def notify(event, notification); end
+
+ # Provides a way to notify of an exception that is not tied to any
+ # particular example (such as an exception encountered in a :suite hook).
+ # Exceptions will be formatted the same way they normally are.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#163
+ def notify_non_example_exception(exception, context_description); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#28
+ def pending_examples; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#45
+ def prepare_default(loader, output_stream, deprecation_stream); end
+
+ # Publish a custom event to supporting registered formatters.
+ #
+ # @param event [Symbol] Name of the custom event to trigger on formatters
+ # @param options [Hash] Hash of arguments to provide via `CustomNotification`
+ # @see RSpec::Core::Notifications::CustomNotification
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#108
+ def publish(event, options = T.unsafe(nil)); end
+
+ # Registers a listener to a list of notifications. The reporter will send
+ # notification of events to all registered listeners.
+ #
+ # @param listener [Object] An object that wishes to be notified of reporter
+ # events
+ # @param notifications [Array] Array of symbols represents the events a
+ # listener wishes to subscribe too
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#37
+ def register_listener(listener, *notifications); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#52
+ def registered_listeners(notification); end
+
+ # Initializes the report run and yields itself for further reporting. The
+ # block is required, so that the reporter can manage cleaning up after the
+ # run.
+ #
+ # @example
+ #
+ # reporter.report(group.examples.size) do |r|
+ # example_groups.map {|g| g.run(r) }
+ # end
+ # @overload report
+ # @overload report
+ # @param expected_example_count [Integer] the number of examples being run
+ # @yield [Block] block yields itself for further reporting.
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#71
+ def report(expected_example_count); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#89
+ def start(expected_example_count, time = T.unsafe(nil)); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#200
+ def stop; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/reporter.rb#242
+ def close; end
+
+ # source://rspec-core//lib/rspec/core/reporter.rb#233
+ def ensure_listeners_ready; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#246
+ def mute_profile_output?; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/reporter.rb#252
+ def seed_used?; end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/reporter.rb#6
+RSpec::Core::Reporter::RSPEC_NOTIFICATIONS = T.let(T.unsafe(nil), RSpec::Core::Set)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/ruby_project.rb#7
+module RSpec::Core::RubyProject
+ private
+
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#12
+ def add_dir_to_load_path(dir); end
+
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#8
+ def add_to_load_path(*dirs); end
+
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#28
+ def ascend_until; end
+
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#20
+ def determine_root; end
+
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#24
+ def find_first_parent_containing(dir); end
+
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#16
+ def root; end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#12
+ def add_dir_to_load_path(dir); end
+
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#8
+ def add_to_load_path(*dirs); end
+
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#28
+ def ascend_until; end
+
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#20
+ def determine_root; end
+
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#24
+ def find_first_parent_containing(dir); end
+
+ # source://rspec-core//lib/rspec/core/ruby_project.rb#16
+ def root; end
+ end
+end
+
+# Provides the main entry point to run a suite of RSpec examples.
+#
+# source://rspec-core//lib/rspec/core/runner.rb#4
+class RSpec::Core::Runner
+ # @return [Runner] a new instance of Runner
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#75
+ def initialize(options, configuration = T.unsafe(nil), world = T.unsafe(nil)); end
+
+ # @attr_reader
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#7
+ def configuration; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#129
+ def configure(err, out); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#194
+ def exit_code(examples_passed = T.unsafe(nil)); end
+
+ # @attr_reader
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#7
+ def options; end
+
+ # Configures and runs a spec suite.
+ #
+ # @param err [IO] error stream
+ # @param out [IO] output stream
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#85
+ def run(err, out); end
+
+ # Runs the provided example groups.
+ #
+ # @param example_groups [Array] groups to run
+ # @return [Fixnum] exit status code. 0 if all specs passed,
+ # or the configured failure exit code (1 by default) if specs
+ # failed.
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#113
+ def run_specs(example_groups); end
+
+ # Wires together the various configuration objects and state holders.
+ #
+ # @param err [IO] error stream
+ # @param out [IO] output stream
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#98
+ def setup(err, out); end
+
+ # @attr_reader
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#7
+ def world; end
+
+ private
+
+ # source://rspec-core//lib/rspec/core/runner.rb#203
+ def persist_example_statuses; end
+
+ class << self
+ # Register an `at_exit` hook that runs the suite when the process exits.
+ #
+ # @note This is not generally needed. The `rspec` command takes care
+ # of running examples for you without involving an `at_exit`
+ # hook. This is only needed if you are running specs using
+ # the `ruby` command, and even then, the normal way to invoke
+ # this is by requiring `rspec/autorun`.
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#16
+ def autorun; end
+
+ # @private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#141
+ def autorun_disabled?; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#136
+ def disable_autorun!; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#180
+ def handle_interrupt; end
+
+ # @private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#146
+ def installed_at_exit?; end
+
+ # Runs the suite of specs and exits the process with an appropriate exit
+ # code.
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#43
+ def invoke; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#29
+ def perform_at_exit; end
+
+ # Run a suite of RSpec examples. Does not exit.
+ #
+ # This is used internally by RSpec to run a suite, but is available
+ # for use by any other automation tool.
+ #
+ # If you want to run this multiple times in the same process, and you
+ # want files like `spec_helper.rb` to be reloaded, be sure to load `load`
+ # instead of `require`.
+ #
+ # @param args [Array] command-line-supported arguments
+ # @param err [IO] error stream
+ # @param out [IO] output stream
+ # @return [Fixnum] exit status code. 0 if all specs passed,
+ # or the configured failure exit code (1 by default) if specs
+ # failed.
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#64
+ def run(args, err = T.unsafe(nil), out = T.unsafe(nil)); end
+
+ # @private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#151
+ def running_in_drb?; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/runner.rb#175
+ def trap_interrupt; end
+ end
+end
+
+# We use this to replace `::Set` so we can have the advantage of
+# constant time key lookups for unique arrays but without the
+# potential to pollute a developers environment with an extra
+# piece of the stdlib. This helps to prevent false positive
+# builds.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/set.rb#11
+class RSpec::Core::Set
+ include ::Enumerable
+
+ # @return [Set] a new instance of Set
+ #
+ # source://rspec-core//lib/rspec/core/set.rb#14
+ def initialize(array = T.unsafe(nil)); end
+
+ # source://rspec-core//lib/rspec/core/set.rb#23
+ def <<(key); end
+
+ # source://rspec-core//lib/rspec/core/set.rb#48
+ def clear; end
+
+ # source://rspec-core//lib/rspec/core/set.rb#28
+ def delete(key); end
+
+ # source://rspec-core//lib/rspec/core/set.rb#32
+ def each(&block); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/set.rb#19
+ def empty?; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/set.rb#37
+ def include?(key); end
+
+ # source://rspec-core//lib/rspec/core/set.rb#41
+ def merge(values); end
+end
+
+# Exposes {ExampleGroup}-level methods to a module, so you can include that
+# module in an {ExampleGroup}.
+#
+# @example
+#
+# module LoggedInAsAdmin
+# extend RSpec::Core::SharedContext
+# before(:example) do
+# log_in_as :admin
+# end
+# end
+#
+# describe "admin section" do
+# include LoggedInAsAdmin
+# # ...
+# end
+#
+# source://rspec-core//lib/rspec/core/shared_context.rb#19
+module RSpec::Core::SharedContext
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/shared_context.rb#28
+ def __shared_context_recordings; end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def after(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def append_after(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def append_before(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def around(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def before(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def context(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def describe(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def hooks(*args, &block); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/shared_context.rb#21
+ def included(group); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def let(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def let!(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def prepend_after(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def prepend_before(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def subject(*args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#42
+ def subject!(*args, &block); end
+
+ class << self
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/shared_context.rb#40
+ def record(methods); end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/shared_context.rb#33
+class RSpec::Core::SharedContext::Recording < ::Struct
+ # Returns the value of attribute args
+ #
+ # @return [Object] the current value of args
+ def args; end
+
+ # Sets the attribute args
+ #
+ # @param value [Object] the value to set the attribute args to.
+ # @return [Object] the newly set value
+ def args=(_); end
+
+ # Returns the value of attribute block
+ #
+ # @return [Object] the current value of block
+ def block; end
+
+ # Sets the attribute block
+ #
+ # @param value [Object] the value to set the attribute block to.
+ # @return [Object] the newly set value
+ def block=(_); end
+
+ # Returns the value of attribute method_name
+ #
+ # @return [Object] the current value of method_name
+ def method_name; end
+
+ # Sets the attribute method_name
+ #
+ # @param value [Object] the value to set the attribute method_name to.
+ # @return [Object] the newly set value
+ def method_name=(_); end
+
+ # source://rspec-core//lib/rspec/core/shared_context.rb#34
+ def playback_onto(group); end
+
+ class << self
+ def [](*_arg0); end
+ def inspect; end
+ def keyword_init?; end
+ def members; end
+ def new(*_arg0); end
+ end
+end
+
+# Shared example groups let you define common context and/or common
+# examples that you wish to use in multiple example groups.
+#
+# When defined, the shared group block is stored for later evaluation.
+# It can later be included in an example group either explicitly
+# (using `include_examples`, `include_context` or `it_behaves_like`)
+# or implicitly (via matching metadata).
+#
+# Named shared example groups are scoped based on where they are
+# defined. Shared groups defined in an example group are available
+# for inclusion in that example group or any child example groups,
+# but not in any parent or sibling example groups. Shared example
+# groups defined at the top level can be included from any example group.
+#
+# source://rspec-core//lib/rspec/core/shared_example_group.rb#57
+module RSpec::Core::SharedExampleGroup
+ # Stores the block for later use. The block will be evaluated
+ # in the context of an example group via `include_examples`,
+ # `include_context`, or `it_behaves_like`.
+ #
+ # @example
+ # shared_examples "auditable" do
+ # it "stores an audit record on save!" do
+ # expect { auditable.save! }.to change(Audit, :count).by(1)
+ # end
+ # end
+ #
+ # RSpec.describe Account do
+ # it_behaves_like "auditable" do
+ # let(:auditable) { Account.new }
+ # end
+ # end
+ # @overload shared_examples
+ # @overload shared_examples
+ # @see ExampleGroup.it_behaves_like
+ # @see ExampleGroup.include_examples
+ # @see ExampleGroup.include_context
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#90
+ def shared_context(name, *args, &block); end
+
+ # Stores the block for later use. The block will be evaluated
+ # in the context of an example group via `include_examples`,
+ # `include_context`, or `it_behaves_like`.
+ #
+ # @example
+ # shared_examples "auditable" do
+ # it "stores an audit record on save!" do
+ # expect { auditable.save! }.to change(Audit, :count).by(1)
+ # end
+ # end
+ #
+ # RSpec.describe Account do
+ # it_behaves_like "auditable" do
+ # let(:auditable) { Account.new }
+ # end
+ # end
+ # @overload shared_examples
+ # @overload shared_examples
+ # @see ExampleGroup.it_behaves_like
+ # @see ExampleGroup.include_examples
+ # @see ExampleGroup.include_context
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#90
+ def shared_examples(name, *args, &block); end
+
+ # Stores the block for later use. The block will be evaluated
+ # in the context of an example group via `include_examples`,
+ # `include_context`, or `it_behaves_like`.
+ #
+ # @example
+ # shared_examples "auditable" do
+ # it "stores an audit record on save!" do
+ # expect { auditable.save! }.to change(Audit, :count).by(1)
+ # end
+ # end
+ #
+ # RSpec.describe Account do
+ # it_behaves_like "auditable" do
+ # let(:auditable) { Account.new }
+ # end
+ # end
+ # @overload shared_examples
+ # @overload shared_examples
+ # @see ExampleGroup.it_behaves_like
+ # @see ExampleGroup.include_examples
+ # @see ExampleGroup.include_context
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#90
+ def shared_examples_for(name, *args, &block); end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/shared_example_group.rb#149
+class RSpec::Core::SharedExampleGroup::Registry
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#150
+ def add(context, name, *metadata_args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#174
+ def find(lookup_contexts, name); end
+
+ private
+
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#257
+ def ensure_block_has_source_location(_block); end
+
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#245
+ def formatted_location(block); end
+
+ # TODO: remove this in RSpec 4. This exists only to support
+ # `config.shared_context_metadata_behavior == :trigger_inclusion`,
+ # the legacy behavior of shared context metadata, which we do
+ # not want to support in RSpec 4.
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#189
+ def legacy_add(context, name, *metadata_args, &block); end
+
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#204
+ def shared_example_groups; end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#208
+ def valid_name?(candidate); end
+
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#215
+ def warn_if_key_taken(context, key, new_block); end
+end
+
+# Shared examples top level DSL.
+#
+# @api private
+#
+# source://rspec-core//lib/rspec/core/shared_example_group.rb#106
+module RSpec::Core::SharedExampleGroup::TopLevelDSL
+ class << self
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#108
+ def definitions; end
+
+ # Adds the top level DSL methods to Module and the top level binding.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#126
+ def expose_globally!; end
+
+ # @api private
+ # @private
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#119
+ def exposed_globally?; end
+
+ # Removes the top level DSL methods to Module and the top level binding.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#135
+ def remove_globally!; end
+ end
+end
+
+# Contains information about the inclusion site of a shared example group.
+#
+# source://rspec-core//lib/rspec/core/example_group.rb#782
+class RSpec::Core::SharedExampleGroupInclusionStackFrame
+ # @private
+ # @return [SharedExampleGroupInclusionStackFrame] a new instance of SharedExampleGroupInclusionStackFrame
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#789
+ def initialize(shared_group_name, inclusion_location); end
+
+ # @return [String] Description of this stack frame, in the form used by
+ # RSpec's built-in formatters.
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#805
+ def description; end
+
+ # @return [String] The {#inclusion_location}, formatted for display by a formatter.
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#795
+ def formatted_inclusion_location; end
+
+ # @return [String] the location where the shared example was included
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#786
+ def inclusion_location; end
+
+ # @return [String] the name of the shared example group
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#784
+ def shared_group_name; end
+
+ class << self
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#811
+ def current_backtrace; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#829
+ def shared_example_group_inclusions; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/example_group.rb#816
+ def with_frame(name, location); end
+ end
+end
+
+# Represents some functionality that is shared with multiple example groups.
+# The functionality is defined by the provided block, which is lazily
+# eval'd when the `SharedExampleGroupModule` instance is included in an example
+# group.
+#
+# source://rspec-core//lib/rspec/core/shared_example_group.rb#9
+class RSpec::Core::SharedExampleGroupModule < ::Module
+ # @return [SharedExampleGroupModule] a new instance of SharedExampleGroupModule
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#13
+ def initialize(description, definition, metadata); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#11
+ def definition; end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#34
+ def include_in(klass, inclusion_line, args, customization_block); end
+
+ # Ruby callback for when a module is included in another module is class.
+ # Our definition evaluates the shared group block in the context of the
+ # including example group.
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#28
+ def included(klass); end
+
+ # Provides a human-readable representation of this module.
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#20
+ def inspect; end
+
+ # Provides a human-readable representation of this module.
+ #
+ # source://rspec-core//lib/rspec/core/shared_example_group.rb#20
+ def to_s; end
+end
+
+# Deals with the fact that `shellwords` only works on POSIX systems.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/shell_escape.rb#5
+module RSpec::Core::ShellEscape
+ private
+
+ # source://rspec-core//lib/rspec/core/shell_escape.rb#32
+ def conditionally_quote(id); end
+
+ # :nocov:
+ #
+ # source://rspec-core//lib/rspec/core/shell_escape.rb#19
+ def escape(shell_command); end
+
+ # source://rspec-core//lib/rspec/core/shell_escape.rb#8
+ def quote(argument); end
+
+ # source://rspec-core//lib/rspec/core/shell_escape.rb#37
+ def shell_allows_unquoted_ids?; end
+
+ class << self
+ # source://rspec-core//lib/rspec/core/shell_escape.rb#32
+ def conditionally_quote(id); end
+
+ # source://rspec-core//lib/rspec/core/shell_escape.rb#19
+ def escape(shell_command); end
+
+ # source://rspec-core//lib/rspec/core/shell_escape.rb#8
+ def quote(argument); end
+
+ # @return [Boolean]
+ #
+ # source://rspec-core//lib/rspec/core/shell_escape.rb#37
+ def shell_allows_unquoted_ids?; end
+ end
+end
+
+# Known shells that require quoting: zsh, csh, tcsh.
+#
+# Feel free to add other shells to this list that are known to
+# allow `rspec ./some_spec.rb[1:1]` syntax without quoting the id.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/shell_escape.rb#30
+RSpec::Core::ShellEscape::SHELLS_ALLOWING_UNQUOTED_IDS = T.let(T.unsafe(nil), Array)
+
+# Provides an execution context for before/after :suite hooks.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/example.rb#651
+class RSpec::Core::SuiteHookContext < ::RSpec::Core::Example
+ # @return [SuiteHookContext] a new instance of SuiteHookContext
+ #
+ # source://rspec-core//lib/rspec/core/example.rb#652
+ def initialize(hook_description, reporter); end
+
+ # source://rspec-core//lib/rspec/core/example.rb#659
+ def set_exception(exception); end
+end
+
+# This avoids issues with reporting time caused by examples that
+# change the value/meaning of Time.now without properly restoring
+# it.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core.rb#174
+class RSpec::Core::Time
+ class << self
+ def now(in: T.unsafe(nil)); end
+ end
+end
+
+# Version information for RSpec Core.
+#
+# source://rspec-core//lib/rspec/core/version.rb#4
+module RSpec::Core::Version; end
+
+# Current version of RSpec Core, in semantic versioning format.
+#
+# source://rspec-core//lib/rspec/core/version.rb#6
+RSpec::Core::Version::STRING = T.let(T.unsafe(nil), String)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/warnings.rb#6
+module RSpec::Core::Warnings
+ # Used internally to print deprecation warnings.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/warnings.rb#10
+ def deprecate(deprecated, data = T.unsafe(nil)); end
+
+ # Used internally to print deprecation warnings.
+ #
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/warnings.rb#22
+ def warn_deprecation(message, opts = T.unsafe(nil)); end
+
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/warnings.rb#27
+ def warn_with(message, options = T.unsafe(nil)); end
+end
+
+# Internal container for global non-configuration data.
+#
+# @api private
+#
+# source://rspec-core//lib/rspec/core/world.rb#6
+class RSpec::Core::World
+ # @api private
+ # @return [World] a new instance of World
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#26
+ def initialize(configuration = T.unsafe(nil)); end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#115
+ def all_example_groups; end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#120
+ def all_examples; end
+
+ # Add exclusion filters to announcement message.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#226
+ def announce_exclusion_filter(announcements); end
+
+ # Notify reporter of filters.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#171
+ def announce_filters; end
+
+ # Add inclusion filters to announcement message.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#217
+ def announce_inclusion_filter(announcements); end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#210
+ def everything_filtered_message; end
+
+ # Get count of examples to be run.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#109
+ def example_count(groups = T.unsafe(nil)); end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#8
+ def example_group_counts_by_spec_file; end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#8
+ def example_groups; end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#102
+ def exclusion_filter; end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#69
+ def filter_manager; end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#8
+ def filtered_examples; end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#97
+ def inclusion_filter; end
+
+ # Used internally to signal that a failure outside of an example
+ # has occurred, and that therefore the exit status should indicate
+ # the run failed.
+ #
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#24
+ def non_example_failure; end
+
+ # Used internally to signal that a failure outside of an example
+ # has occurred, and that therefore the exit status should indicate
+ # the run failed.
+ #
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#24
+ def non_example_failure=(_arg0); end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#87
+ def num_example_groups_defined_in(file); end
+
+ # Apply ordering strategy from configuration to example groups.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#52
+ def ordered_example_groups; end
+
+ # Find line number of previous declaration.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#140
+ def preceding_declaration_line(absolute_file_name, filter_line); end
+
+ # Prepares filters so that they apply to example groups when they run.
+ #
+ # This is a separate method so that filters can be modified/replaced and
+ # examples refiltered during a process's lifetime, which can be useful for
+ # a custom runner.
+ #
+ # @api public
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#43
+ def prepare_example_filtering; end
+
+ # Records an example group.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#81
+ def record(example_group); end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#74
+ def registered_example_group_files; end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#205
+ def report_filter_message(message); end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#149
+ def reporter; end
+
+ # Reset world to 'scratch' before running suite.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#60
+ def reset; end
+
+ # Used internally to signify that a SystemExit occurred in
+ # `Configuration#load_file_handling_errors`, and thus examples cannot
+ # be counted accurately. Specifically, we cannot accurately report
+ # "No examples found".
+ #
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#18
+ def rspec_is_quitting; end
+
+ # Used internally to signify that a SystemExit occurred in
+ # `Configuration#load_file_handling_errors`, and thus examples cannot
+ # be counted accurately. Specifically, we cannot accurately report
+ # "No examples found".
+ #
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#18
+ def rspec_is_quitting=(_arg0); end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#92
+ def shared_example_group_registry; end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#154
+ def source_from_file(path); end
+
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#164
+ def syntax_highlighter; end
+
+ # Traverses the tree of each top level group.
+ # For each it yields the group, then the children, recursively.
+ # Halts the traversal of a branch of the tree as soon as the passed block returns true.
+ # Note that siblings groups and their sub-trees will continue to be explored.
+ # This is intended to make it easy to find the top-most group that satisfies some
+ # condition.
+ #
+ # @api private
+ # @private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#131
+ def traverse_example_group_trees_until(&block); end
+
+ # Used internally to determine what to do when a SIGINT is received.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#11
+ def wants_to_quit; end
+
+ # Used internally to determine what to do when a SIGINT is received.
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#11
+ def wants_to_quit=(_arg0); end
+
+ private
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#234
+ def descending_declaration_line_numbers_by_file; end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#252
+ def fail_if_config_and_cli_options_invalid; end
+end
+
+# Provides a null implementation for initial use by configuration.
+#
+# @api private
+# @private
+#
+# source://rspec-core//lib/rspec/core/world.rb#264
+module RSpec::Core::World::Null
+ class << self
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#280
+ def all_example_groups; end
+
+ # :nocov:
+ #
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#276
+ def example_groups; end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#265
+ def non_example_failure; end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#266
+ def non_example_failure=(_); end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#268
+ def registered_example_group_files; end
+
+ # @api private
+ #
+ # source://rspec-core//lib/rspec/core/world.rb#272
+ def traverse_example_group_trees_until; end
+ end
+end
+
+# Namespace for the example group subclasses generated by top-level
+# `describe`.
+#
+# @private
+#
+# source://rspec-core//lib/rspec/core/example_group.rb#839
+module RSpec::ExampleGroups
+ extend ::RSpec::Support::RecursiveConstMethods
+
+ class << self
+ # source://rspec-core//lib/rspec/core/example_group.rb#842
+ def assign_const(group); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#862
+ def base_name_for(group); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#850
+ def constant_scope_for(group); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#895
+ def disambiguate(name, const_scope); end
+
+ # source://rspec-core//lib/rspec/core/example_group.rb#856
+ def remove_all_constants; end
+ end
+end
+
+# @private
+#
+# source://rspec-core//lib/rspec/core.rb#187
+RSpec::MODULES_TO_AUTOLOAD = T.let(T.unsafe(nil), Hash)
+
+# @private
+#
+# source://rspec-core//lib/rspec/core/shared_context.rb#54
+RSpec::SharedContext = RSpec::Core::SharedContext
diff --git a/sorbet/rbi/gems/rspec-expectations@3.13.1.rbi b/sorbet/rbi/gems/rspec-expectations@3.13.1.rbi
new file mode 100644
index 0000000..e245ff5
--- /dev/null
+++ b/sorbet/rbi/gems/rspec-expectations@3.13.1.rbi
@@ -0,0 +1,8158 @@
+# typed: true
+
+# DO NOT EDIT MANUALLY
+# This is an autogenerated file for types exported from the `rspec-expectations` gem.
+# Please instead update this file by running `bin/tapioca gem rspec-expectations`.
+
+
+# RSpec's top level namespace. All of rspec-expectations is contained
+# in the `RSpec::Expectations` and `RSpec::Matchers` namespaces.
+#
+# source://rspec-expectations//lib/rspec/matchers/english_phrasing.rb#1
+module RSpec
+ class << self
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#70
+ def clear_examples; end
+
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#85
+ def configuration; end
+
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#49
+ def configuration=(_arg0); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#97
+ def configure; end
+
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#194
+ def const_missing(name); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42
+ def context(*args, &example_group_block); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#122
+ def current_example; end
+
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#128
+ def current_example=(example); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#154
+ def current_scope; end
+
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#134
+ def current_scope=(scope); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42
+ def describe(*args, &example_group_block); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42
+ def example_group(*args, &example_group_block); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42
+ def fcontext(*args, &example_group_block); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42
+ def fdescribe(*args, &example_group_block); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#58
+ def reset; end
+
+ # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110
+ def shared_context(name, *args, &block); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110
+ def shared_examples(name, *args, &block); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core/shared_example_group.rb#110
+ def shared_examples_for(name, *args, &block); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#160
+ def world; end
+
+ # source://rspec-core/3.13.0/lib/rspec/core.rb#49
+ def world=(_arg0); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42
+ def xcontext(*args, &example_group_block); end
+
+ # source://rspec-core/3.13.0/lib/rspec/core/dsl.rb#42
+ def xdescribe(*args, &example_group_block); end
+ end
+end
+
+# RSpec::Expectations provides a simple, readable API to express
+# the expected outcomes in a code example. To express an expected
+# outcome, wrap an object or block in `expect`, call `to` or `to_not`
+# (aliased as `not_to`) and pass it a matcher object:
+#
+# expect(order.total).to eq(Money.new(5.55, :USD))
+# expect(list).to include(user)
+# expect(message).not_to match(/foo/)
+# expect { do_something }.to raise_error
+#
+# The last form (the block form) is needed to match against ruby constructs
+# that are not objects, but can only be observed when executing a block
+# of code. This includes raising errors, throwing symbols, yielding,
+# and changing values.
+#
+# When `expect(...).to` is invoked with a matcher, it turns around
+# and calls `matcher.matches?(