Sha256: b069bc9c9db4759c79d391e69e4290bab304d67140c2ebbc20c6887356396428
Contents?: true
Size: 278 Bytes
Versions: 11
Compression:
Stored size: 278 Bytes
Contents
STRING_OR_SYM = Transform(/^:?[A-Za-z]\w*$/) do |str| case str when /^:/ str.slice(1, str.length - 1).to_sym else str end end NUMBER = Transform(/^(?:\d+|a|an|no)$/) do |num| case num when 'no' 0 when 'a', 'an' 1 else Integer(num) end end
Version data entries
11 entries across 11 versions & 1 rubygems