summaryrefslogtreecommitdiff
path: root/dir.c
diff options
context:
space:
mode:
authorzzak <zzak@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-11-03 04:47:49 +0000
committerzzak <zzak@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-11-03 04:47:49 +0000
commitc420f8449ea45dd4c45db9dea601039c47f3ecf3 (patch)
treed267e5a6db31e829c3d91f41397da2c98d065a81 /dir.c
parentbdbc8c5b74b0b17da710c9f174a920e4c8b3cb02 (diff)
* dir.c (Dir#glob):
Documentation for pattern section, backslash subsection Patch by Eric Bouchut [ruby-core#48528] [Bug #7230] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37447 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'dir.c')
-rw-r--r--dir.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/dir.c b/dir.c
index 1a375ea85d..11e3028813 100644
--- a/dir.c
+++ b/dir.c
@@ -1782,7 +1782,7 @@ dir_s_aref(int argc, VALUE *argv, VALUE obj)
* <code>/ .* /x</code> in regexp. Note, this
* will not match Unix-like hidden files (dotfiles).
* In order to include those in the match results,
- * you must use something like "{*,.*}".
+ * you must use something like <code>"{*,.*}"</code>.
* <code>**</code>:: Matches directories recursively.
* <code>?</code>:: Matches any one character. Equivalent to
* <code>/.{1}/</code> in regexp.
@@ -1796,10 +1796,11 @@ dir_s_aref(int argc, VALUE *argv, VALUE obj)
* More than two literals may be specified.
* Equivalent to pattern alternation in
* regexp.
- * <code> \ </code>:: Escapes the next metacharacter.
- * Note that this means you cannot use backslash in windows
- * as part of a glob, i.e. Dir["c:\\foo*"] will not work
- * use Dir["c:/foo*"] instead
+ * <code> \\ </code>:: Escapes the next metacharacter.
+ * Note that this means you cannot use backslash
+ * in windows as part of a glob,
+ * i.e. <code>Dir["c:\\foo*"]</code> will not work,
+ * use <code>Dir["c:/foo*"]</code> instead.
*
* Dir["config.?"] #=> ["config.h"]
* Dir.glob("config.?") #=> ["config.h"]