From 29e6d97517bbd4dcc540464c8473172232f3e228 Mon Sep 17 00:00:00 2001
From: Yudai Takada <13041216+ydah@users.noreply.github.com>
Date: Mon, 21 Nov 2022 14:07:18 +0900
Subject: [PATCH] Fix typos (#6775)
* s/Innteger/Integer/
* s/diretory/directory/
* s/Bufer/Buffer/
* s/defalt/default/
* s/covearge/coverage/
---
array.c | 2 +-
ext/coverage/coverage.c | 4 ++--
file.c | 2 +-
io_buffer.c | 2 +-
vm_backtrace.c | 2 +-
5 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/array.c b/array.c
index f242031b4f..adc4b3147a 100644
--- a/array.c
+++ b/array.c
@@ -2086,7 +2086,7 @@ rb_ary_first(int argc, VALUE *argv, VALUE ary)
*
* If +self+ is empty, returns +nil+.
*
- * When non-negative \Innteger argument +n+ is given,
+ * When non-negative \Integer argument +n+ is given,
* returns the last +n+ elements in a new \Array:
*
* a = [:foo, 'bar', 2]
diff --git a/ext/coverage/coverage.c b/ext/coverage/coverage.c
index c8229ae8fe..4578de54e4 100644
--- a/ext/coverage/coverage.c
+++ b/ext/coverage/coverage.c
@@ -131,7 +131,7 @@ rb_coverage_setup(int argc, VALUE *argv, VALUE klass)
* Start/resume the coverage measurement.
*
* Caveat: Currently, only process-global coverage measurement is supported.
- * You cannot measure per-thread covearge. If your process has multiple thread,
+ * You cannot measure per-thread coverage. If your process has multiple thread,
* using Coverage.resume/suspend to capture code coverage executed from only
* a limited code block, may yield misleading results.
*/
@@ -470,7 +470,7 @@ rb_coverage_running(VALUE klass)
* This feature is experimental, so these APIs may be changed in future.
*
* Caveat: Currently, only process-global coverage measurement is supported.
- * You cannot measure per-thread covearge.
+ * You cannot measure per-thread coverage.
*
* = Usage
*
diff --git a/file.c b/file.c
index 10eb1081e3..5b17093ca3 100644
--- a/file.c
+++ b/file.c
@@ -7284,7 +7284,7 @@ const char ruby_null_device[] =
*
* - ::blockdev?: Returns whether the file at the given path is a block device.
* - ::chardev?: Returns whether the file at the given path is a character device.
- * - ::directory?: Returns whether the file at the given path is a diretory.
+ * - ::directory?: Returns whether the file at the given path is a directory.
* - ::executable?: Returns whether the file at the given path is executable
* by the effective user and group of the current process.
* - ::executable_real?: Returns whether the file at the given path is executable
diff --git a/io_buffer.c b/io_buffer.c
index dc9d613524..e5d6c19612 100644
--- a/io_buffer.c
+++ b/io_buffer.c
@@ -535,7 +535,7 @@ io_flags_for_size(size_t size)
* Create a new zero-filled IO::Buffer of +size+ bytes.
* By default, the buffer will be _internal_: directly allocated chunk
* of the memory. But if the requested +size+ is more than OS-specific
- * IO::Bufer::PAGE_SIZE, the buffer would be allocated using the
+ * IO::Buffer::PAGE_SIZE, the buffer would be allocated using the
* virtual memory mechanism (anonymous +mmap+ on Unix, +VirtualAlloc+
* on Windows). The behavior can be forced by passing IO::Buffer::MAPPED
* as a second parameter.
diff --git a/vm_backtrace.c b/vm_backtrace.c
index 12157ef707..75546cd229 100644
--- a/vm_backtrace.c
+++ b/vm_backtrace.c
@@ -805,7 +805,7 @@ backtrace_load_data(VALUE self, VALUE str)
* call-seq: Thread::Backtrace::limit -> integer
*
* Returns maximum backtrace length set by --backtrace-limit
- * command-line option. The defalt is -1 which means unlimited
+ * command-line option. The default is -1 which means unlimited
* backtraces. If the value is zero or positive, the error backtraces,
* produced by Exception#full_message, are abbreviated and the extra lines
* are replaced by ... 3 levels...