summaryrefslogtreecommitdiffstats
path: root/tool
diff options
context:
space:
mode:
authoryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-08-08 17:11:39 +0000
committeryugui <yugui@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-08-08 17:11:39 +0000
commit9afa5221e9786ae11a679b493acc1462e0034481 (patch)
tree3ebe66592dea0cb8b8c61913a15dfc65cc5ad04a /tool
parenta584997cadcb29f4f16d40f2224cf131800eb5c0 (diff)
downloadruby-9afa5221e9786ae11a679b493acc1462e0034481.tar.gz
ruby-9afa5221e9786ae11a679b493acc1462e0034481.tar.xz
ruby-9afa5221e9786ae11a679b493acc1462e0034481.zip
* tool/compile_prelude.rb: fixes a regexp pattern for require.
It had matched 'require("foo"('. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@24477 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'tool')
-rwxr-xr-xtool/compile_prelude.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/tool/compile_prelude.rb b/tool/compile_prelude.rb
index 88b7d69f1..17b00f955 100755
--- a/tool/compile_prelude.rb
+++ b/tool/compile_prelude.rb
@@ -51,8 +51,8 @@ lines_list = preludes.map {|filename|
"nil"
end
}
- if /require\s*(\(?)\s*(["'])(.*?)\2\s*\1/ =~ line
- orig, path = $&, $3
+ if /require\s*\(?\s*(["'])(.*?)\1\s*\)?/ =~ line
+ orig, path = $&, $2
srcdir = File.expand_path("../..", __FILE__)
path = File.expand_path(path, srcdir)
if File.exist?(path)