summaryrefslogtreecommitdiff
path: root/io.c
diff options
context:
space:
mode:
authorhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-21 15:16:54 +0000
committerhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-21 15:16:54 +0000
commit2476bf2bb15f1b84363d9400c4994702ba3b59cf (patch)
treec4b2e2d177d6909f917326843624fc0f9f7c568e /io.c
parent774b42d64385c2447ac38802ae0d045f3d7b9e95 (diff)
Clarify the behavior of IO.write without offset in write mode.
https://github.com/ruby/ruby/pull/1571 Patch by @takanabe [fix GH-1571] [Bug #11638][ruby-core:71277] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60294 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r--io.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/io.c b/io.c
index 8dbdfad8ec..f01dea6873 100644
--- a/io.c
+++ b/io.c
@@ -10287,8 +10287,8 @@ io_s_write(int argc, VALUE *argv, int binary)
* Opens the file, optionally seeks to the given <i>offset</i>, writes
* <i>string</i>, then returns the length written.
* <code>write</code> ensures the file is closed before returning.
- * If <i>offset</i> is not given, the file is truncated. Otherwise,
- * it is not truncated.
+ * If <i>offset</i> is not given in write mode, the file is truncated.
+ * Otherwise, it is not truncated.
*
* IO.write("testfile", "0123456789", 20) #=> 10
* # File could contain: "This is line one\nThi0123456789two\nThis is line three\nAnd so on...\n"