From ac2d6f1898a5aa1aad7cc254290ec9341d2cdf60 Mon Sep 17 00:00:00 2001 From: Conrad Irwin Date: Fri, 23 Dec 2011 08:33:21 -0800 Subject: Remove assumption about a stable $: In some environments (e.g. [1]) $: can change between loading the library and using it. To avoid this problem, we always pass an absolute path to autoload internal modules. [1] https://github.com/pry/pry/issues/280 --- lib/coderay/scanner.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/coderay/scanner.rb') diff --git a/lib/coderay/scanner.rb b/lib/coderay/scanner.rb index 7ecbe4f..f102163 100644 --- a/lib/coderay/scanner.rb +++ b/lib/coderay/scanner.rb @@ -320,4 +320,4 @@ surrounding code: end end -end \ No newline at end of file +end -- cgit v1.2.1 From f32eb2da2272e298006021e235ea64455f7d35b5 Mon Sep 17 00:00:00 2001 From: Kornelius Kalnbach Date: Tue, 27 Dec 2011 03:41:17 +0100 Subject: use coderay_path on all autoload calls --- lib/coderay/scanner.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/coderay/scanner.rb') diff --git a/lib/coderay/scanner.rb b/lib/coderay/scanner.rb index f102163..907cf00 100644 --- a/lib/coderay/scanner.rb +++ b/lib/coderay/scanner.rb @@ -2,8 +2,8 @@ require 'strscan' module CodeRay - - autoload :WordList, 'coderay/helpers/word_list' + + autoload :WordList, coderay_path('helpers', 'word_list') # = Scanners # -- cgit v1.2.1