diff options
Diffstat (limited to 'io.c')
-rw-r--r-- | io.c | 9 |
1 files changed, 7 insertions, 2 deletions
@@ -14625,11 +14625,16 @@ set_LAST_READ_LINE(VALUE val, ID _x, VALUE *_y) * ARGV.replace ["file2", "file3"] * ARGF.read # Returns the contents of file2 and file3 * - * If +ARGV+ is empty, ARGF acts as if it contained STDIN, i.e. the data - * piped to your script. For example: + * If +ARGV+ is empty, ARGF acts as if it contained <tt>"-"</tt> that + * makes ARGF read from STDIN, i.e. the data piped or typed to your + * script. For example: * * $ echo "glark" | ruby -e 'p ARGF.read' * "glark\n" + * + * $ echo Glark > file1 + * $ echo "glark" | ruby -e 'p ARGF.read' -- - file1 + * "glark\nGlark\n" */ /* |