Skip to content

Commit

Permalink
various: fix minor typos (#281)
Browse files Browse the repository at this point in the history
Signed-off-by: Patrick Linnane <patrick@linnane.io>
Co-authored-by: Douglas Eichelberger <697964+dduugg@users.noreply.github.com>
  • Loading branch information
p-linnane and dduugg authored Feb 16, 2024
1 parent 894757a commit dd113ca
Show file tree
Hide file tree
Showing 8 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@

### New features

* [#49](https://github.com/dduugg/yard-sorbet/issues/49) Apply `@abstract` tags to `abstact!`/`interface!` modules
* [#49](https://github.com/dduugg/yard-sorbet/issues/49) Apply `@abstract` tags to `abstract!`/`interface!` modules
* [#43](https://github.com/dduugg/yard-sorbet/issues/43) Add `T::Enum` support

### Bug fixes
Expand Down
2 changes: 1 addition & 1 deletion lib/yard-sorbet/handlers/abstract_dsl_handler.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

module YARDSorbet
module Handlers
# Apllies an `@abstract` tag to `abstract!`/`interface!` modules (if not alerady present).
# Applies an `@abstract` tag to `abstract!`/`interface!` modules (if not alerady present).
class AbstractDSLHandler < YARD::Handlers::Ruby::Base
extend T::Sig

Expand Down
4 changes: 2 additions & 2 deletions lib/yard-sorbet/node_utils.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def self.bfs_traverse(node, &_blk)
until queue.empty?
n = queue.deq(true)
yield n
enque_children(queue, n)
enqueue_children(queue, n)
end
end

Expand All @@ -34,7 +34,7 @@ def self.delete_node(node)

# Enqueue the eligible children of a node in the BFS queue
sig { params(queue: Queue, node: YARD::Parser::Ruby::AstNode).void }
def self.enque_children(queue, node)
def self.enqueue_children(queue, node)
last_child = node.children.last
node.children.each do |child|
next if child == last_child &&
Expand Down
2 changes: 1 addition & 1 deletion sorbet/tapioca/require.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# typed: strong
# frozen_string_literal: true

# Add your extra requires here (`bin/tapioca require` can be used to boostrap this list)
# Add your extra requires here (`bin/tapioca require` can be used to bootstrap this list)
require 'rspec/core/rake_task'
require 'rubocop/rake_task'
2 changes: 1 addition & 1 deletion spec/data/struct_handler.txt
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ end
class SpecializedPersonStruct < T::Struct
const :special, String

# This is a special intializer
# This is a special initializer
# @param special a very special param
# @return an initialized struct
def initialize(special:)
Expand Down
2 changes: 1 addition & 1 deletion spec/yard_sorbet/handlers/include_handler_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
expect(node.class_mixins.map(&:to_s)).to include('M::ClassMethods')
end

it 'attches class method namespace to explicit receiver' do
it 'attaches class method namespace to explicit receiver' do
node = YARD::Registry.at('Receiver')
expect(node.class_mixins.map(&:to_s)).to include('M::ClassMethods')
end
Expand Down
2 changes: 1 addition & 1 deletion spec/yard_sorbet/handlers/sig_handler_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@
end

describe 'nested classes' do
it 'keep docstrings for outer class methods preceding inner classe' do
it 'keep docstrings for outer class methods preceding inner classes' do
expect(YARD::Registry.at('Outer#outer').docstring).to eq('outer method')
end

Expand Down
2 changes: 1 addition & 1 deletion spec/yard_sorbet/handlers/struct_class_handler_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

it 'uses the docstring from an explicit initializer' do
node = YARD::Registry.at('SpecializedPersonStruct#initialize')
expect(node.docstring).to eq('This is a special intializer')
expect(node.docstring).to eq('This is a special initializer')
end

it 'preserves param tag text' do
Expand Down

0 comments on commit dd113ca

Please sign in to comment.