Permalink
Browse files

modify constant name

  • Loading branch information...
kachick committed May 18, 2012
1 parent 52c9914 commit c7e6fd1ac7a3c7ed2b2c7cf0582692f5bf6a3360
Showing with 2 additions and 2 deletions.
  1. +1 −1 lib/integer/base.rb
  2. +1 −1 lib/integer/base/singleton_class.rb
View
@@ -6,7 +6,7 @@ module Base
class InvalidCharacter < TypeError; end
- SPECIAL_CHAR = /[\x00-\x20\-\+]/
+ SPECIAL_CHAR_PATTERN = /[\x00-\x20\-\+]/
end
@@ -64,7 +64,7 @@ def base_chars_for(chars)
raise InvalidCharacter, 'dupulicated characters'
when chars.any?{|s|s.length != 1}
raise InvalidCharacter, 'chars must be Array<Char> (Char: length 1)'
- when chars.any?{|c|SPECIAL_CHAR =~ c}
+ when chars.any?{|c|SPECIAL_CHAR_PATTERN =~ c}
raise InvalidCharacter, 'included Special Characters (-, +, space, control-char)'
else
chars

0 comments on commit c7e6fd1

Please sign in to comment.