summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ast.rb2
-rw-r--r--compile.c2
-rw-r--r--debug.c2
-rw-r--r--gc.c2
-rw-r--r--io_buffer.c2
-rw-r--r--iseq.c2
-rw-r--r--object.c2
-rw-r--r--ractor.rb2
-rw-r--r--string.c2
9 files changed, 9 insertions, 9 deletions
diff --git a/ast.rb b/ast.rb
index f3f72c747f..ec870d8c7a 100644
--- a/ast.rb
+++ b/ast.rb
@@ -53,7 +53,7 @@ module RubyVM::AbstractSyntaxTree
# # (ERROR@1:7-1:11),
# # (LASGN@1:12-1:15 :y (LIT@1:14-1:15 2))]
#
- # Note that parsing continues even after the errored expresion.
+ # Note that parsing continues even after the errored expression.
#
def self.parse string, keep_script_lines: false, error_tolerant: false, keep_tokens: false
Primitive.ast_s_parse string, keep_script_lines, error_tolerant, keep_tokens
diff --git a/compile.c b/compile.c
index cdea789afd..742ddf9d98 100644
--- a/compile.c
+++ b/compile.c
@@ -4847,7 +4847,7 @@ when_vals(rb_iseq_t *iseq, LINK_ANCHOR *const cond_seq, const NODE *vals,
if (!COMPILE(cond_seq, "when cond", val)) return -1;
}
- // Emit patern === target
+ // Emit pattern === target
ADD_INSN1(cond_seq, vals, topn, INT2FIX(1));
ADD_CALL(cond_seq, vals, idEqq, INT2FIX(1));
ADD_INSNL(cond_seq, val, branchif, l1);
diff --git a/debug.c b/debug.c
index d4576b64e5..f1b83714d8 100644
--- a/debug.c
+++ b/debug.c
@@ -450,7 +450,7 @@ check_filter(const char *str, const struct debug_log_filter *filter, bool *state
// (func_name or file_name) contains baz or boo
//
// RUBY_DEBUG_LOG_FILTER=foo,bar,-baz,-boo
-// retunrs true if
+// returns true if
// (func_name or file_name) contains foo or bar
// or
// (func_name or file_name) doesn't contain baz and
diff --git a/gc.c b/gc.c
index d830fd9fae..a68e5251d3 100644
--- a/gc.c
+++ b/gc.c
@@ -9792,7 +9792,7 @@ gc_exit(rb_objspace_t *objspace, enum gc_enter_event event, unsigned int *lock_l
{
GC_ASSERT(during_gc != 0);
- gc_event_hook(objspace, RUBY_INTERNAL_EVENT_GC_EXIT, 0); /* TODO: which parameter should be passsed? */
+ gc_event_hook(objspace, RUBY_INTERNAL_EVENT_GC_EXIT, 0); /* TODO: which parameter should be passed? */
gc_record(objspace, 1, gc_enter_event_cstr(event));
RUBY_DEBUG_LOG("%s (%s)", gc_enter_event_cstr(event), gc_current_status(objspace));
gc_report(1, objspace, "gc_exit: %s [%s]\n", gc_enter_event_cstr(event), gc_current_status(objspace));
diff --git a/io_buffer.c b/io_buffer.c
index 1599c54886..91083cd7e4 100644
--- a/io_buffer.c
+++ b/io_buffer.c
@@ -783,7 +783,7 @@ rb_io_buffer_inspect(VALUE self)
VALUE result = rb_io_buffer_to_s(self);
if (io_buffer_validate(data)) {
- // Limit the maximum size genearted by inspect.
+ // Limit the maximum size generated by inspect.
if (data->size <= 256) {
io_buffer_hexdump(result, 16, data->base, data->size, 0);
}
diff --git a/iseq.c b/iseq.c
index 51ecd7faf7..3305edde96 100644
--- a/iseq.c
+++ b/iseq.c
@@ -3805,7 +3805,7 @@ succ_index_lookup(const struct succ_index_table *sd, int x)
* call-seq:
* iseq.script_lines -> array or nil
*
- * It returns recorded script lines if it is availalble.
+ * It returns recorded script lines if it is available.
* The script lines are not limited to the iseq range, but
* are entire lines of the source file.
*
diff --git a/object.c b/object.c
index 3e38c04e1a..8041c192ce 100644
--- a/object.c
+++ b/object.c
@@ -3237,7 +3237,7 @@ rb_opts_exception_p(VALUE opts, int default_value)
* Integer(-1) # => -1
*
* With floating-point argument +object+ given,
- * returns +object+ truncated to an intger:
+ * returns +object+ truncated to an integer:
*
* Integer(1.9) # => 1 # Rounds toward zero.
* Integer(-1.9) # => -1 # Rounds toward zero.
diff --git a/ractor.rb b/ractor.rb
index e7485dc4bf..fc9462c149 100644
--- a/ractor.rb
+++ b/ractor.rb
@@ -19,7 +19,7 @@
# # fails immediately with
# # ArgumentError (can not isolate a Proc because it accesses outer variables (a).)
#
-# The object must be explicity shared:
+# The object must be explicitly shared:
# a = 1
# r = Ractor.new(a) { |a1| puts "I am in Ractor! a=#{a1}"}
#
diff --git a/string.c b/string.c
index eefa6f397c..6fd5866336 100644
--- a/string.c
+++ b/string.c
@@ -333,7 +333,7 @@ rb_str_update_shared_ary(VALUE str, VALUE old_root, VALUE new_root)
return;
}
- // if the root string isn't embedded, we don't need to touch the ponter.
+ // if the root string isn't embedded, we don't need to touch the pointer.
// it already points to the shame shared buffer
if (!STR_EMBED_P(new_root)) {
return;