Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update rubocop-on-rbs v1.0.0 #2023

Merged
merged 3 commits into from
Sep 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,9 @@ GEM
unicode-display_width (>= 2.4.0, < 3.0)
rubocop-ast (1.32.3)
parser (>= 3.3.1.0)
rubocop-on-rbs (0.6.0)
rubocop-on-rbs (1.0.0)
rbs (~> 3.5)
rubocop (~> 1.41)
rubocop (~> 1.61)
zlib
rubocop-rubycw (0.1.6)
rubocop (~> 1.0)
Expand Down Expand Up @@ -145,7 +145,7 @@ GEM
timeout (0.4.1)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
unicode-display_width (2.5.0)
unicode-display_width (2.6.0)
zlib (3.1.1)

PLATFORMS
Expand Down
2 changes: 0 additions & 2 deletions core/array.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -600,8 +600,6 @@ class Array[unchecked out Elem] < Object
#
def self.try_convert: [U] (untyped) -> ::Array[U]?

public

# <!--
# rdoc-file=array.c
# - array & other_array -> new_array
Expand Down
2 changes: 0 additions & 2 deletions core/complex.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,6 @@ class Complex < Numeric
#
alias self.rectangular self.rect

public

# <!--
# rdoc-file=complex.c
# - complex * numeric -> new_complex
Expand Down
2 changes: 0 additions & 2 deletions core/data.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,6 @@ class Data

def self.allocate: () -> bot

public

# <!--
# rdoc-file=struct.c
# - self == other -> true or false
Expand Down
2 changes: 0 additions & 2 deletions core/dir.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -759,8 +759,6 @@ class Dir
#
alias self.unlink self.delete

public

# <!--
# rdoc-file=dir.c
# - chdir -> 0
Expand Down
2 changes: 0 additions & 2 deletions core/encoding.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -780,8 +780,6 @@ class Encoding::Converter < Object
?xml: :text | :attr
) -> conversion_path

public

# <!--
# rdoc-file=transcode.c
# - ec == other -> true or false
Expand Down
2 changes: 0 additions & 2 deletions core/enumerator/product.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,6 @@ class Enumerator[unchecked out Elem, out Return = void]
#
def initialize: (*_EachEntry[Elem]) -> void

public

# <!--
# rdoc-file=enumerator.c
# - obj.each { |...| ... } -> obj
Expand Down
12 changes: 0 additions & 12 deletions core/errors.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -270,8 +270,6 @@ class NameError[T] < StandardError
#
def initialize: (?string msg, ?String? name, ?receiver: T?) -> void

public

# <!--
# rdoc-file=error.c
# - name_error.local_variables -> array
Expand Down Expand Up @@ -362,8 +360,6 @@ class NoMethodError[T] < NameError[T]
#
def initialize: (?string? msg, ?String? name, ?Array[untyped] args, ?boolish `private`, ?receiver: T?) -> void

public

# <!--
# rdoc-file=error.c
# - no_method_error.args -> obj
Expand Down Expand Up @@ -471,8 +467,6 @@ class SignalException < Exception
def initialize: (?string sig_name) -> void
| (int sig_number, ?string sig_name) -> void

public

def signm: () -> String

# <!--
Expand Down Expand Up @@ -608,8 +602,6 @@ class SystemCallError < StandardError
#
def self.===: (untyped other) -> bool

public

# <!--
# rdoc-file=error.c
# - system_call_error.errno -> integer
Expand Down Expand Up @@ -637,8 +629,6 @@ class SystemExit < Exception
| (string msg) -> void
| (true | false | int status, ?string msg) -> void

public

# <!--
# rdoc-file=error.c
# - system_exit.status -> integer
Expand Down Expand Up @@ -726,8 +716,6 @@ class UncaughtThrowError < ArgumentError
#
def initialize: (untyped tag, untyped value) -> void

public

# <!--
# rdoc-file=vm_eval.c
# - uncaught_throw.tag -> obj
Expand Down
2 changes: 0 additions & 2 deletions core/file.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -1769,8 +1769,6 @@ class File < IO
#
def self.zero?: (string | _ToPath | IO file_name) -> bool

public

# <!--
# rdoc-file=file.c
# - file.atime -> time
Expand Down
2 changes: 0 additions & 2 deletions core/float.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,6 @@
# * #truncate: Returns `self` truncated to a given precision.
#
class Float < Numeric
public

# <!--
# rdoc-file=numeric.c
# - self % other -> float
Expand Down
2 changes: 0 additions & 2 deletions core/hash.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -559,8 +559,6 @@ class Hash[unchecked out K, unchecked out V] < Object
def self.try_convert: [U, V] (_ToHash[U, V]) -> ::Hash[U, V]
| (untyped) -> (::Hash[untyped, untyped] | nil)

public

# <!--
# rdoc-file=hash.c
# - hash < other_hash -> true or false
Expand Down
2 changes: 0 additions & 2 deletions core/integer.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,6 @@ class Integer < Numeric
def self.try_convert: (int) -> Integer
| (untyped) -> Integer?

public

# <!--
# rdoc-file=numeric.c
# - self % other -> real_number
Expand Down
2 changes: 0 additions & 2 deletions core/io/buffer.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -184,8 +184,6 @@ class IO
#
def self.string: (int) { (Buffer) -> void } -> String

public

# <!--
# rdoc-file=io_buffer.c
# - <=>(other) -> true or false
Expand Down
2 changes: 0 additions & 2 deletions core/numeric.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,6 @@
class Numeric
include Comparable

public

# <!--
# rdoc-file=numeric.c
# - self % other -> real_numeric
Expand Down
2 changes: 0 additions & 2 deletions core/object_space/weak_key_map.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,6 @@ module ObjectSpace
# sitting in the cache forever.
#
class WeakKeyMap[Key, Value]
public

# <!--
# rdoc-file=weakmap.c
# - map[key] -> value
Expand Down
6 changes: 0 additions & 6 deletions core/ractor.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -597,8 +597,6 @@ class Ractor
#
def self.yield: (untyped obj, ?move: boolish) -> untyped

public

# <!--
# rdoc-file=ractor.rb
# - <<(obj, move: false)
Expand Down Expand Up @@ -925,8 +923,6 @@ class Ractor
# # Ractor::MovedError (can not send any methods to a moved object)
#
class MovedObject < BasicObject
public

# <!--
# rdoc-file=ractor.c
# - !(*args)
Expand Down Expand Up @@ -1007,8 +1003,6 @@ class Ractor
# end
#
class RemoteError < Ractor::Error
public

def ractor: () -> Ractor
end

Expand Down
2 changes: 0 additions & 2 deletions core/rational.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,6 @@
# #=> (1.0000000000000002+1.7320508075688772i)
#
class Rational < Numeric
public

def %: (Integer) -> Rational
| (Float) -> Float
| (Rational) -> Rational
Expand Down
2 changes: 0 additions & 2 deletions core/rbs/unnamed/argf.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,6 @@ module RBS
class ARGFClass
include Enumerable[String]

public

# <!--
# rdoc-file=io.c
# - ARGF.argv -> ARGV
Expand Down
2 changes: 0 additions & 2 deletions stdlib/bigdecimal/0/big_decimal.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -408,8 +408,6 @@ class BigDecimal < Numeric
#
def self.save_rounding_mode: () { (?nil) -> void } -> void

public

# <!--
# rdoc-file=ext/bigdecimal/bigdecimal.c
# - a % b
Expand Down
10 changes: 0 additions & 10 deletions stdlib/cgi/0/core.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -382,8 +382,6 @@ class CGI
#
def self.parse: (String query) -> Hash[String, Array[String]]

public

# <!-- rdoc-file=lib/cgi/core.rb -->
# Return the accept character set for this CGI instance.
#
Expand Down Expand Up @@ -706,8 +704,6 @@ class CGI
#
def self.parse: (String raw_cookie) -> Hash[String, instance]

public

# <!-- rdoc-file=lib/cgi/cookie.rb -->
# Domain for which this cookie applies, as a `String`
#
Expand Down Expand Up @@ -864,8 +860,6 @@ class CGI
end

module Escape
public

# <!--
# rdoc-file=ext/cgi/escape/escape.c
# - CGI.escape(string) -> string
Expand Down Expand Up @@ -940,8 +934,6 @@ class CGI
# mode.
#
module QueryExtension
public

# <!--
# rdoc-file=lib/cgi/core.rb
# - [](key)
Expand Down Expand Up @@ -1135,8 +1127,6 @@ class CGI
module Util
include CGI::Escape

public

# <!--
# rdoc-file=lib/cgi/util.rb
# - escapeElement(string, *elements)
Expand Down
2 changes: 0 additions & 2 deletions stdlib/date/0/date.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -733,8 +733,6 @@ class Date
#
def self.xmlschema: (String str, ?Integer start) -> Date

public

# <!--
# rdoc-file=ext/date/date_core.c
# - d + other -> date
Expand Down
2 changes: 0 additions & 2 deletions stdlib/date/0/date_time.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -388,8 +388,6 @@ class DateTime < Date
#
def self.xmlschema: (String str, ?Integer start) -> DateTime

public

# <!--
# rdoc-file=ext/date/date_core.c
# - deconstruct_keys(array_of_names_or_nil) -> hash
Expand Down
2 changes: 0 additions & 2 deletions stdlib/dbm/0/dbm.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,6 @@ class DBM
def self.open: (String filename, ?Integer mode, ?Integer flags) -> DBM
| [T] (String filename, ?Integer mode, ?Integer flags) { (DBM) -> T } -> T

public

# <!--
# rdoc-file=ext/dbm/dbm.c
# - dbm[key] -> string value or nil
Expand Down
2 changes: 0 additions & 2 deletions stdlib/delegate/0/delegator.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ class Delegator < BasicObject

def self.public_api: () -> untyped

public

# <!--
# rdoc-file=lib/delegate.rb
# - !()
Expand Down
2 changes: 0 additions & 2 deletions stdlib/delegate/0/simple_delegator.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,6 @@
# Unique: 6
#
class SimpleDelegator < Delegator
public

# <!--
# rdoc-file=lib/delegate.rb
# - __getobj__() { || ... }
Expand Down
4 changes: 0 additions & 4 deletions stdlib/digest/0/digest.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,6 @@ Digest::REQUIRE_MUTEX: Thread::Mutex
# calculate message digest values.
#
module Digest::Instance
public

# <!-- rdoc-file=ext/digest/digest.c -->
# Updates the digest using a given *string* and returns self.
#
Expand Down Expand Up @@ -403,8 +401,6 @@ end
# Data_Wrap_Struct(0, 0, 0, (void *)&sha1));
#
class Digest::Base < Digest::Class
public

# <!-- rdoc-file=ext/digest/digest.c -->
# Update the digest using given *string* and return `self`.
#
Expand Down
4 changes: 0 additions & 4 deletions stdlib/etc/0/etc.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -709,8 +709,6 @@ module Etc

def self.new: (*untyped) -> untyped

public

def gid: () -> Integer

def gid=: (Integer new_gid) -> void
Expand Down Expand Up @@ -807,8 +805,6 @@ module Etc

def self.new: (*untyped) -> untyped

public

def change: () -> Integer

def change=: (Integer new_change) -> void
Expand Down
2 changes: 0 additions & 2 deletions stdlib/logger/0/formatter.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ class Logger
# Default formatter for log messages.
#
class Formatter
public

attr_accessor datetime_format: String?

# <!--
Expand Down
2 changes: 0 additions & 2 deletions stdlib/logger/0/log_device.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ class Logger
attr_reader dev: _WriteCloser
attr_reader filename: String?

public

# <!--
# rdoc-file=lib/logger/log_device.rb
# - close()
Expand Down
2 changes: 0 additions & 2 deletions stdlib/logger/0/logger.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -357,8 +357,6 @@ class Logger

include Logger::Severity

public

# <!--
# rdoc-file=lib/logger.rb
# - <<(msg)
Expand Down
Loading