regexp_parser 1.8.0 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +70 -0
- data/Gemfile +1 -0
- data/README.md +12 -11
- data/Rakefile +2 -2
- data/lib/regexp_parser/expression.rb +10 -19
- data/lib/regexp_parser/expression/classes/free_space.rb +1 -1
- data/lib/regexp_parser/expression/classes/group.rb +22 -2
- data/lib/regexp_parser/expression/classes/root.rb +4 -16
- data/lib/regexp_parser/expression/methods/match_length.rb +2 -2
- data/lib/regexp_parser/expression/methods/traverse.rb +2 -2
- data/lib/regexp_parser/expression/quantifier.rb +9 -0
- data/lib/regexp_parser/expression/sequence.rb +0 -10
- data/lib/regexp_parser/lexer.rb +2 -2
- data/lib/regexp_parser/parser.rb +27 -0
- data/lib/regexp_parser/scanner.rb +1248 -1258
- data/lib/regexp_parser/scanner/char_type.rl +11 -11
- data/lib/regexp_parser/scanner/property.rl +2 -2
- data/lib/regexp_parser/scanner/scanner.rl +175 -181
- data/lib/regexp_parser/syntax/any.rb +2 -2
- data/lib/regexp_parser/syntax/version_lookup.rb +2 -2
- data/lib/regexp_parser/version.rb +1 -1
- data/regexp_parser.gemspec +1 -1
- data/spec/expression/base_spec.rb +10 -0
- data/spec/expression/subexpression_spec.rb +1 -1
- data/spec/expression/to_s_spec.rb +39 -31
- data/spec/lexer/literals_spec.rb +24 -49
- data/spec/parser/errors_spec.rb +1 -1
- data/spec/parser/escapes_spec.rb +1 -1
- data/spec/parser/free_space_spec.rb +4 -25
- data/spec/parser/quantifiers_spec.rb +16 -0
- data/spec/parser/set/ranges_spec.rb +3 -3
- data/spec/scanner/escapes_spec.rb +7 -0
- data/spec/scanner/free_space_spec.rb +32 -0
- data/spec/scanner/groups_spec.rb +10 -1
- data/spec/scanner/literals_spec.rb +28 -38
- data/spec/scanner/quantifiers_spec.rb +18 -13
- data/spec/scanner/sets_spec.rb +8 -2
- data/spec/spec_helper.rb +1 -0
- metadata +57 -61
- data/spec/expression/root_spec.rb +0 -9
- data/spec/expression/sequence_spec.rb +0 -9
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a3d9161fb969c7c5aac0798a31054ed4f0d5da8992b8167afa7025492d1042c9
|
4
|
+
data.tar.gz: 8321d42545c5dbfc810ad3f32fb03677e95d1dba3f3145f20af2e655f1ca45c3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: def5d282e5720c260bcb581e666704d04579534f8e04986867382836e58f4949d1eea0d3f7b3b2efdb71c5796b3bc6e5c4f92594aab9c9cd61985de18627c026
|
7
|
+
data.tar.gz: 3e2671325e18a6b4d61b5cd9da410f21a3cdc24382f415b9517498437d2c5e8e473ebe481aeb610667f33aa9d538d05d43b3fae5565b1fb856690e81377e82e5
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,75 @@
|
|
1
1
|
## [Unreleased]
|
2
2
|
|
3
|
+
## [2.0.2] - 2020-12-25 - [Janosch Müller](mailto:janosch84@gmail.com)
|
4
|
+
|
5
|
+
### Fixed
|
6
|
+
|
7
|
+
- fixed `FrozenError` when calling `#to_s` on a frozen `Group::Passive`
|
8
|
+
* thanks to [Daniel Gollahon](https://github.com/dgollahon)
|
9
|
+
|
10
|
+
## [2.0.1] - 2020-12-20 - [Janosch Müller](mailto:janosch84@gmail.com)
|
11
|
+
|
12
|
+
### Fixed
|
13
|
+
|
14
|
+
- fixed error when scanning some group names
|
15
|
+
* this affected names containing hyphens, digits or multibyte chars, e.g. `/(?<a1>a)/`
|
16
|
+
* thanks to [Daniel Gollahon](https://github.com/dgollahon) for the report
|
17
|
+
- fixed error when scanning hex escapes with just one hex digit
|
18
|
+
* e.g. `/\x0A/` was scanned correctly, but the equivalent `/\xA/` was not
|
19
|
+
* thanks to [Daniel Gollahon](https://github.com/dgollahon) for the report
|
20
|
+
|
21
|
+
## [2.0.0] - 2020-11-25 - [Janosch Müller](mailto:janosch84@gmail.com)
|
22
|
+
|
23
|
+
### Changed
|
24
|
+
|
25
|
+
- some methods that used to return byte-based indices now return char-based indices
|
26
|
+
* the returned values have only changed for Regexps that contain multibyte chars
|
27
|
+
* this is only a breaking change if you used such methods directly AND relied on them pointing to bytes
|
28
|
+
* affected methods:
|
29
|
+
* `Regexp::Token` `#length`, `#offset`, `#te`, `#ts`
|
30
|
+
* `Regexp::Expression::Base` `#full_length`, `#offset`, `#starts_at`, `#te`, `#ts`
|
31
|
+
* thanks to [Akinori MUSHA](https://github.com/knu) for the report
|
32
|
+
- removed some deprecated methods/signatures
|
33
|
+
* these are rarely used and have been showing deprecation warnings for a long time
|
34
|
+
* `Regexp::Expression::Subexpression.new` with 3 arguments
|
35
|
+
* `Regexp::Expression::Root.new` without a token argument
|
36
|
+
* `Regexp::Expression.parsed`
|
37
|
+
|
38
|
+
### Added
|
39
|
+
|
40
|
+
- `Regexp::Expression::Base#base_length`
|
41
|
+
* returns the character count of an expression body, ignoring any quantifier
|
42
|
+
- pragmatic, experimental support for chained quantifiers
|
43
|
+
* e.g.: `/^a{10}{4,6}$/` matches exactly 40, 50 or 60 `a`s
|
44
|
+
* successive quantifiers used to be silently dropped by the parser
|
45
|
+
* they are now wrapped with passive groups as if they were written `(?:a{10}){4,6}`
|
46
|
+
* thanks to [calfeld](https://github.com/calfeld) for reporting this a while back
|
47
|
+
|
48
|
+
### Fixed
|
49
|
+
|
50
|
+
- incorrect encoding output for non-ascii comments
|
51
|
+
* this led to a crash when calling `#to_s` on parse results containing such comments
|
52
|
+
* thanks to [Michael Glass](https://github.com/michaelglass) for the report
|
53
|
+
- some crashes when scanning contrived patterns such as `'\😋'`
|
54
|
+
|
55
|
+
### [1.8.2] - 2020-10-11 - [Janosch Müller](mailto:janosch84@gmail.com)
|
56
|
+
|
57
|
+
### Fixed
|
58
|
+
|
59
|
+
- fix `FrozenError` in `Expression::Base#repetitions` on Ruby 3.0
|
60
|
+
* thanks to [Thomas Walpole](https://github.com/twalpole)
|
61
|
+
- removed "unknown future version" warning on Ruby 3.0
|
62
|
+
|
63
|
+
### [1.8.1] - 2020-09-28 - [Janosch Müller](mailto:janosch84@gmail.com)
|
64
|
+
|
65
|
+
### Fixed
|
66
|
+
|
67
|
+
- fixed scanning of comment-like text in normal mode
|
68
|
+
* this was an old bug, but had become more prevalent in v1.8.0
|
69
|
+
* thanks to [Tietew](https://github.com/Tietew) for the report
|
70
|
+
- specified correct minimum Ruby version in gemspec
|
71
|
+
* it said 1.9 but really required 2.0 as of v1.8.0
|
72
|
+
|
3
73
|
### [1.8.0] - 2020-09-20 - [Janosch Müller](mailto:janosch84@gmail.com)
|
4
74
|
|
5
75
|
### Changed
|
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# Regexp::Parser
|
2
2
|
|
3
|
-
[![Gem Version](https://badge.fury.io/rb/regexp_parser.svg)](http://badge.fury.io/rb/regexp_parser) [![Build Status](https://
|
3
|
+
[![Gem Version](https://badge.fury.io/rb/regexp_parser.svg)](http://badge.fury.io/rb/regexp_parser) [![Build Status](https://github.com/ammar/regexp_parser/workflows/tests/badge.svg)](https://github.com/ammar/regexp_parser/actions) [![Code Climate](https://codeclimate.com/github/ammar/regexp_parser.svg)](https://codeclimate.com/github/ammar/regexp_parser/badges)
|
4
4
|
|
5
5
|
A Ruby gem for tokenizing, parsing, and transforming regular expressions.
|
6
6
|
|
@@ -8,8 +8,8 @@ A Ruby gem for tokenizing, parsing, and transforming regular expressions.
|
|
8
8
|
* A scanner/tokenizer based on [Ragel](http://www.colm.net/open-source/ragel/)
|
9
9
|
* A lexer that produces a "stream" of token objects.
|
10
10
|
* A parser that produces a "tree" of Expression objects (OO API)
|
11
|
-
* Runs on Ruby 2.x and JRuby runtimes
|
12
|
-
* Recognizes Ruby 1.8, 1.9, and
|
11
|
+
* Runs on Ruby 2.x, 3.x and JRuby runtimes
|
12
|
+
* Recognizes Ruby 1.8, 1.9, 2.x and 3.x regular expressions [See Supported Syntax](#supported-syntax)
|
13
13
|
|
14
14
|
|
15
15
|
_For examples of regexp_parser in use, see [Example Projects](#example-projects)._
|
@@ -18,13 +18,10 @@ _For examples of regexp_parser in use, see [Example Projects](#example-projects)
|
|
18
18
|
---
|
19
19
|
## Requirements
|
20
20
|
|
21
|
-
* Ruby >=
|
21
|
+
* Ruby >= 2.0
|
22
22
|
* Ragel >= 6.0, but only if you want to build the gem or work on the scanner.
|
23
23
|
|
24
24
|
|
25
|
-
_Note: See the .travis.yml file for covered versions._
|
26
|
-
|
27
|
-
|
28
25
|
---
|
29
26
|
## Install
|
30
27
|
|
@@ -317,7 +314,7 @@ Expression class. See the next section for details._
|
|
317
314
|
|
318
315
|
## Supported Syntax
|
319
316
|
The three modules support all the regular expression syntax features of Ruby 1.8,
|
320
|
-
1.9, and
|
317
|
+
1.9, 2.x and 3.x:
|
321
318
|
|
322
319
|
_Note that not all of these are available in all versions of Ruby_
|
323
320
|
|
@@ -440,13 +437,17 @@ rake install
|
|
440
437
|
## Example Projects
|
441
438
|
Projects using regexp_parser.
|
442
439
|
|
440
|
+
- [capybara](https://github.com/teamcapybara/capybara) is an integration testing tool that uses regexp_parser to convert Regexps to css/xpath selectors.
|
441
|
+
|
442
|
+
- [js_regex](https://github.com/janosch-x/js_regex) converts Ruby regular expressions to JavaScript-compatible regular expressions.
|
443
|
+
|
443
444
|
- [meta_re](https://github.com/ammar/meta_re) is a regular expression preprocessor with alias support.
|
444
445
|
|
445
446
|
- [mutant](https://github.com/mbj/mutant) (before v0.9.0) manipulates your regular expressions (amongst others) to see if your tests cover their behavior.
|
446
447
|
|
447
|
-
- [
|
448
|
+
- [rubocop](https://github.com/rubocop-hq/rubocop) is a linter for Ruby that uses regexp_parser to lint Regexps.
|
448
449
|
|
449
|
-
- [
|
450
|
+
- [twitter-cldr-rb](https://github.com/twitter/twitter-cldr-rb) is a localization helper that uses regexp_parser to generate examples of postal codes.
|
450
451
|
|
451
452
|
|
452
453
|
## References
|
@@ -475,4 +476,4 @@ Documentation and books used while working on this project.
|
|
475
476
|
|
476
477
|
---
|
477
478
|
##### Copyright
|
478
|
-
_Copyright (c) 2010-
|
479
|
+
_Copyright (c) 2010-2020 Ammar Ali. See LICENSE file for details._
|
data/Rakefile
CHANGED
@@ -25,7 +25,7 @@ end
|
|
25
25
|
|
26
26
|
namespace :ragel do
|
27
27
|
desc "Process the ragel source files and output ruby code"
|
28
|
-
task :rb do
|
28
|
+
task :rb do
|
29
29
|
RAGEL_SOURCE_FILES.each do |file|
|
30
30
|
output_file = "#{RAGEL_OUTPUT_DIR}/#{file}.rb"
|
31
31
|
# using faster flat table driven FSM, about 25% larger code, but about 30% faster
|
@@ -42,7 +42,7 @@ namespace :ragel do
|
|
42
42
|
end
|
43
43
|
|
44
44
|
desc "Delete the ragel generated source file(s)"
|
45
|
-
task :clean do
|
45
|
+
task :clean do
|
46
46
|
RAGEL_SOURCE_FILES.each do |file|
|
47
47
|
sh "rm -f #{RAGEL_OUTPUT_DIR}/#{file}.rb"
|
48
48
|
end
|
@@ -34,6 +34,10 @@ module Regexp::Expression
|
|
34
34
|
|
35
35
|
alias :starts_at :ts
|
36
36
|
|
37
|
+
def base_length
|
38
|
+
to_s(:base).length
|
39
|
+
end
|
40
|
+
|
37
41
|
def full_length
|
38
42
|
to_s.length
|
39
43
|
end
|
@@ -80,8 +84,12 @@ module Regexp::Expression
|
|
80
84
|
return 1..1 unless quantified?
|
81
85
|
min = quantifier.min
|
82
86
|
max = quantifier.max < 0 ? Float::INFINITY : quantifier.max
|
83
|
-
|
84
|
-
|
87
|
+
range = min..max
|
88
|
+
# fix Range#minmax on old Rubies - https://bugs.ruby-lang.org/issues/15807
|
89
|
+
if RUBY_VERSION.to_f < 2.7
|
90
|
+
range.define_singleton_method(:minmax) { [min, max] }
|
91
|
+
end
|
92
|
+
range
|
85
93
|
end
|
86
94
|
|
87
95
|
def greedy?
|
@@ -114,23 +122,6 @@ module Regexp::Expression
|
|
114
122
|
alias :to_h :attributes
|
115
123
|
end
|
116
124
|
|
117
|
-
def self.parsed(exp)
|
118
|
-
warn('WARNING: Regexp::Expression::Base.parsed is buggy and '\
|
119
|
-
'will be removed in 2.0.0. Use Regexp::Parser.parse instead.')
|
120
|
-
case exp
|
121
|
-
when String
|
122
|
-
Regexp::Parser.parse(exp)
|
123
|
-
when Regexp
|
124
|
-
Regexp::Parser.parse(exp.source) # <- causes loss of root options
|
125
|
-
when Regexp::Expression # <- never triggers
|
126
|
-
exp
|
127
|
-
else
|
128
|
-
raise ArgumentError, 'Expression.parsed accepts a String, Regexp, or '\
|
129
|
-
'a Regexp::Expression as a value for exp, but it '\
|
130
|
-
"was given #{exp.class.name}."
|
131
|
-
end
|
132
|
-
end
|
133
|
-
|
134
125
|
end # module Regexp::Expression
|
135
126
|
|
136
127
|
require 'regexp_parser/expression/quantifier'
|
@@ -1,7 +1,7 @@
|
|
1
1
|
module Regexp::Expression
|
2
2
|
|
3
3
|
class FreeSpace < Regexp::Expression::Base
|
4
|
-
def quantify(
|
4
|
+
def quantify(_token, _text, _min = nil, _max = nil, _mode = :greedy)
|
5
5
|
raise "Can not quantify a free space object"
|
6
6
|
end
|
7
7
|
end
|
@@ -10,9 +10,29 @@ module Regexp::Expression
|
|
10
10
|
def comment?; false end
|
11
11
|
end
|
12
12
|
|
13
|
-
class
|
14
|
-
|
13
|
+
class Passive < Group::Base
|
14
|
+
attr_writer :implicit
|
15
|
+
|
16
|
+
def initialize(*)
|
17
|
+
@implicit = false
|
18
|
+
super
|
19
|
+
end
|
20
|
+
|
21
|
+
def to_s(format = :full)
|
22
|
+
if implicit?
|
23
|
+
"#{expressions.join}#{quantifier_affix(format)}"
|
24
|
+
else
|
25
|
+
super
|
26
|
+
end
|
27
|
+
end
|
28
|
+
|
29
|
+
def implicit?
|
30
|
+
@implicit
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
15
34
|
class Absence < Group::Base; end
|
35
|
+
class Atomic < Group::Base; end
|
16
36
|
class Options < Group::Base
|
17
37
|
attr_accessor :option_changes
|
18
38
|
end
|
@@ -1,24 +1,12 @@
|
|
1
1
|
module Regexp::Expression
|
2
2
|
|
3
3
|
class Root < Regexp::Expression::Subexpression
|
4
|
-
|
5
|
-
|
6
|
-
unless args.first.is_a?(Regexp::Token)
|
7
|
-
warn('WARNING: Root.new without a Token argument is deprecated and '\
|
8
|
-
'will be removed in 2.0.0. Use Root.build for the old behavior.')
|
9
|
-
return super(self.class.build_token, *args)
|
10
|
-
end
|
11
|
-
super
|
4
|
+
def self.build(options = {})
|
5
|
+
new(build_token, options)
|
12
6
|
end
|
13
7
|
|
14
|
-
|
15
|
-
|
16
|
-
new(build_token, options)
|
17
|
-
end
|
18
|
-
|
19
|
-
def build_token
|
20
|
-
Regexp::Token.new(:expression, :root, '', 0)
|
21
|
-
end
|
8
|
+
def self.build_token
|
9
|
+
Regexp::Token.new(:expression, :root, '', 0)
|
22
10
|
end
|
23
11
|
end
|
24
12
|
end
|
@@ -10,7 +10,7 @@ class Regexp::MatchLength
|
|
10
10
|
self.exp_class = exp.class
|
11
11
|
self.min_rep = exp.repetitions.min
|
12
12
|
self.max_rep = exp.repetitions.max
|
13
|
-
if base = opts[:base]
|
13
|
+
if (base = opts[:base])
|
14
14
|
self.base_min = base
|
15
15
|
self.base_max = base
|
16
16
|
self.reify = ->{ '.' * base }
|
@@ -32,7 +32,7 @@ class Regexp::MatchLength
|
|
32
32
|
end
|
33
33
|
end
|
34
34
|
|
35
|
-
def endless_each
|
35
|
+
def endless_each
|
36
36
|
return enum_for(__method__) unless block_given?
|
37
37
|
(min..max).each { |num| yield(num) if include?(num) }
|
38
38
|
end
|
@@ -36,7 +36,7 @@ module Regexp::Expression
|
|
36
36
|
|
37
37
|
# Iterates over the expressions of this expression as an array, passing
|
38
38
|
# the expression and its index within its parent to the given block.
|
39
|
-
def each_expression(include_self = false
|
39
|
+
def each_expression(include_self = false)
|
40
40
|
return enum_for(__method__, include_self) unless block_given?
|
41
41
|
|
42
42
|
traverse(include_self) do |event, exp, index|
|
@@ -47,7 +47,7 @@ module Regexp::Expression
|
|
47
47
|
# Returns a new array with the results of calling the given block once
|
48
48
|
# for every expression. If a block is not given, returns an array with
|
49
49
|
# each expression and its level index as an array.
|
50
|
-
def flat_map(include_self = false
|
50
|
+
def flat_map(include_self = false)
|
51
51
|
result = []
|
52
52
|
|
53
53
|
each_expression(include_self) do |exp, index|
|
@@ -40,5 +40,14 @@ module Regexp::Expression
|
|
40
40
|
RUBY
|
41
41
|
end
|
42
42
|
alias :lazy? :reluctant?
|
43
|
+
|
44
|
+
def ==(other)
|
45
|
+
other.class == self.class &&
|
46
|
+
other.token == token &&
|
47
|
+
other.mode == mode &&
|
48
|
+
other.min == min &&
|
49
|
+
other.max == max
|
50
|
+
end
|
51
|
+
alias :eq :==
|
43
52
|
end
|
44
53
|
end
|
@@ -7,16 +7,6 @@ module Regexp::Expression
|
|
7
7
|
# Used as the base class for the Alternation alternatives, Conditional
|
8
8
|
# branches, and CharacterSet::Intersection intersected sequences.
|
9
9
|
class Sequence < Regexp::Expression::Subexpression
|
10
|
-
# TODO: this override is here for backwards compatibility, remove in 2.0.0
|
11
|
-
def initialize(*args)
|
12
|
-
if args.count == 3
|
13
|
-
warn('WARNING: Sequence.new without a Regexp::Token argument is '\
|
14
|
-
'deprecated and will be removed in 2.0.0.')
|
15
|
-
return self.class.at_levels(*args)
|
16
|
-
end
|
17
|
-
super
|
18
|
-
end
|
19
|
-
|
20
10
|
class << self
|
21
11
|
def add_to(subexpression, params = {}, active_opts = {})
|
22
12
|
sequence = at_levels(
|
data/lib/regexp_parser/lexer.rb
CHANGED
@@ -96,10 +96,10 @@ class Regexp::Lexer
|
|
96
96
|
|
97
97
|
tokens.pop
|
98
98
|
tokens << Regexp::Token.new(:literal, :literal, lead,
|
99
|
-
token.ts, (token.te - last.
|
99
|
+
token.ts, (token.te - last.length),
|
100
100
|
nesting, set_nesting, conditional_nesting)
|
101
101
|
tokens << Regexp::Token.new(:literal, :literal, last,
|
102
|
-
(token.ts + lead.
|
102
|
+
(token.ts + lead.length), token.te,
|
103
103
|
nesting, set_nesting, conditional_nesting)
|
104
104
|
end
|
105
105
|
|
data/lib/regexp_parser/parser.rb
CHANGED
@@ -438,6 +438,28 @@ class Regexp::Parser
|
|
438
438
|
target_node || raise(ArgumentError, 'No valid target found for '\
|
439
439
|
"'#{token.text}' ")
|
440
440
|
|
441
|
+
# in case of chained quantifiers, wrap target in an implicit passive group
|
442
|
+
# description of the problem: https://github.com/ammar/regexp_parser/issues/3
|
443
|
+
# rationale for this solution: https://github.com/ammar/regexp_parser/pull/69
|
444
|
+
if target_node.quantified?
|
445
|
+
new_token = Regexp::Token.new(
|
446
|
+
:group,
|
447
|
+
:passive,
|
448
|
+
'', # text
|
449
|
+
target_node.ts,
|
450
|
+
nil, # te (unused)
|
451
|
+
target_node.level,
|
452
|
+
target_node.set_level,
|
453
|
+
target_node.conditional_level
|
454
|
+
)
|
455
|
+
new_group = Group::Passive.new(new_token, active_opts)
|
456
|
+
new_group.implicit = true
|
457
|
+
new_group << target_node
|
458
|
+
increase_level(target_node)
|
459
|
+
node.expressions[offset] = new_group
|
460
|
+
target_node = new_group
|
461
|
+
end
|
462
|
+
|
441
463
|
case token.token
|
442
464
|
when :zero_or_one
|
443
465
|
target_node.quantify(:zero_or_one, token.text, 0, 1, :greedy)
|
@@ -468,6 +490,11 @@ class Regexp::Parser
|
|
468
490
|
end
|
469
491
|
end
|
470
492
|
|
493
|
+
def increase_level(exp)
|
494
|
+
exp.level += 1
|
495
|
+
exp.respond_to?(:each) && exp.each { |subexp| increase_level(subexp) }
|
496
|
+
end
|
497
|
+
|
471
498
|
def interval(target_node, token)
|
472
499
|
text = token.text
|
473
500
|
mchr = text[text.length-1].chr =~ /[?+]/ ? text[text.length-1].chr : nil
|
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
# line 1 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
4
4
|
|
5
|
-
# line
|
5
|
+
# line 673 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
6
6
|
|
7
7
|
|
8
8
|
# THIS IS A GENERATED FILE, DO NOT EDIT DIRECTLY
|
@@ -88,72 +88,74 @@ class Regexp::Scanner
|
|
88
88
|
self.set_depth = 0
|
89
89
|
self.group_depth = 0
|
90
90
|
self.conditional_stack = []
|
91
|
+
self.char_pos = 0
|
91
92
|
|
92
93
|
|
93
|
-
# line
|
94
|
+
# line 94 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner.rb"
|
94
95
|
class << self
|
95
96
|
attr_accessor :_re_scanner_trans_keys
|
96
97
|
private :_re_scanner_trans_keys, :_re_scanner_trans_keys=
|
97
98
|
end
|
98
99
|
self._re_scanner_trans_keys = [
|
99
100
|
0, 0, -128, -65, -128, -65,
|
100
|
-
-128, -65,
|
101
|
-
|
102
|
-
|
103
|
-
39,
|
101
|
+
-128, -65, 41, 41, 39,
|
102
|
+
57, 39, 39, 33, 62,
|
103
|
+
62, 62, 39, 60, 39, 57,
|
104
|
+
39, 39, 48, 57, 39,
|
104
105
|
57, 39, 57, 48, 57,
|
105
|
-
|
106
|
-
48,
|
107
|
-
57,
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
106
|
+
45, 62, 62, 62, 48, 57,
|
107
|
+
48, 62, 43, 62, 48,
|
108
|
+
57, 48, 57, 48, 125,
|
109
|
+
44, 125, 123, 123, 9, 122,
|
110
|
+
9, 125, 9, 122, -128,
|
111
|
+
-65, -128, -65, 38, 38,
|
112
|
+
45, 122, 45, 122, 93, 93,
|
113
|
+
94, 120, 97, 120, 108,
|
114
|
+
115, 110, 112, 117, 117,
|
115
|
+
109, 109, 58, 58, 93, 93,
|
116
|
+
104, 104, 97, 97, 99,
|
117
|
+
99, 105, 105, 105, 105,
|
118
|
+
108, 108, 97, 97, 110, 110,
|
119
|
+
107, 107, 110, 110, 116,
|
120
|
+
116, 114, 114, 108, 108,
|
121
|
+
105, 105, 103, 103, 105, 105,
|
122
|
+
116, 116, 114, 114, 97,
|
123
|
+
97, 112, 112, 104, 104,
|
124
|
+
111, 111, 119, 119, 101, 101,
|
125
|
+
114, 114, 114, 117, 105,
|
126
|
+
105, 110, 110, 110, 110,
|
127
|
+
99, 99, 112, 112, 97, 97,
|
128
|
+
99, 99, 101, 101, 112,
|
129
|
+
112, 112, 112, 111, 111,
|
130
|
+
114, 114, 100, 100, 100, 100,
|
131
|
+
65, 122, 61, 61, 93,
|
132
|
+
93, -128, -65, -128, -65,
|
132
133
|
45, 45, 92, 92, 92, 92,
|
133
134
|
45, 45, 92, 92, 92,
|
134
135
|
92, 48, 123, 48, 102,
|
135
136
|
48, 102, 48, 102, 48, 102,
|
136
137
|
9, 125, 9, 125, 9,
|
137
138
|
125, 9, 125, 9, 125,
|
138
|
-
9, 125, 48, 123,
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
43, 63,
|
146
|
-
|
147
|
-
|
148
|
-
-128, -65, -128, -65,
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
139
|
+
9, 125, 48, 123, 39, 39,
|
140
|
+
41, 41, 41, 57, 62,
|
141
|
+
62, -128, 127, -62, -12,
|
142
|
+
1, 127, 1, 127, 9, 32,
|
143
|
+
33, 126, 10, 10, 63,
|
144
|
+
63, 33, 126, 33, 126,
|
145
|
+
62, 62, 43, 63, 43, 63,
|
146
|
+
43, 63, 65, 122, 44,
|
147
|
+
57, 43, 63, 68, 119,
|
148
|
+
80, 112, -62, 125, -128, -65,
|
149
|
+
-128, -65, -128, -65, 38,
|
150
|
+
38, 38, 93, 46, 61,
|
151
|
+
48, 122, -62, 125, -128, -65,
|
152
|
+
-128, -65, -128, -65, 48,
|
153
|
+
55, 48, 55, 77, 77,
|
154
|
+
45, 45, 0, 0, 67, 99,
|
155
|
+
45, 45, 0, 0, 92,
|
156
|
+
92, 48, 102, 39, 60,
|
157
|
+
39, 57, 49, 57, 41, 57,
|
158
|
+
45, 62, 0
|
157
159
|
]
|
158
160
|
|
159
161
|
class << self
|
@@ -161,26 +163,26 @@ class << self
|
|
161
163
|
private :_re_scanner_key_spans, :_re_scanner_key_spans=
|
162
164
|
end
|
163
165
|
self._re_scanner_key_spans = [
|
164
|
-
0, 64, 64, 64,
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
3, 1, 1, 1, 1, 1, 1, 1,
|
166
|
+
0, 64, 64, 64, 1, 19, 1, 30,
|
167
|
+
1, 22, 19, 1, 10, 19, 19, 10,
|
168
|
+
18, 1, 10, 15, 20, 10, 10, 78,
|
169
|
+
82, 1, 114, 117, 114, 64, 64, 1,
|
170
|
+
78, 78, 1, 27, 24, 8, 3, 1,
|
170
171
|
1, 1, 1, 1, 1, 1, 1, 1,
|
171
172
|
1, 1, 1, 1, 1, 1, 1, 1,
|
172
|
-
1, 1, 1, 1, 1, 1, 4, 1,
|
173
173
|
1, 1, 1, 1, 1, 1, 1, 1,
|
174
|
-
1, 1, 1, 1,
|
174
|
+
1, 1, 1, 1, 4, 1, 1, 1,
|
175
|
+
1, 1, 1, 1, 1, 1, 1, 1,
|
176
|
+
1, 1, 1, 58, 1, 1, 64, 64,
|
175
177
|
1, 1, 1, 1, 1, 1, 76, 55,
|
176
178
|
55, 55, 55, 117, 117, 117, 117, 117,
|
177
|
-
117, 76, 1,
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
33, 1, 0, 1, 55, 22,
|
183
|
-
17,
|
179
|
+
117, 76, 1, 1, 17, 1, 256, 51,
|
180
|
+
127, 127, 24, 94, 1, 1, 94, 94,
|
181
|
+
1, 21, 21, 21, 58, 14, 21, 52,
|
182
|
+
33, 188, 64, 64, 64, 1, 56, 16,
|
183
|
+
75, 188, 64, 64, 64, 8, 8, 1,
|
184
|
+
1, 0, 33, 1, 0, 1, 55, 22,
|
185
|
+
19, 9, 17, 18
|
184
186
|
]
|
185
187
|
|
186
188
|
class << self
|
@@ -188,26 +190,26 @@ class << self
|
|
188
190
|
private :_re_scanner_index_offsets, :_re_scanner_index_offsets=
|
189
191
|
end
|
190
192
|
self._re_scanner_index_offsets = [
|
191
|
-
0, 0, 65, 130, 195,
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
193
|
+
0, 0, 65, 130, 195, 197, 217, 219,
|
194
|
+
250, 252, 275, 295, 297, 308, 328, 348,
|
195
|
+
359, 378, 380, 391, 407, 428, 439, 450,
|
196
|
+
529, 612, 614, 729, 847, 962, 1027, 1092,
|
197
|
+
1094, 1173, 1252, 1254, 1282, 1307, 1316, 1320,
|
198
|
+
1322, 1324, 1326, 1328, 1330, 1332, 1334, 1336,
|
199
|
+
1338, 1340, 1342, 1344, 1346, 1348, 1350, 1352,
|
200
|
+
1354, 1356, 1358, 1360, 1362, 1364, 1366, 1368,
|
201
|
+
1370, 1372, 1374, 1376, 1378, 1383, 1385, 1387,
|
202
|
+
1389, 1391, 1393, 1395, 1397, 1399, 1401, 1403,
|
203
|
+
1405, 1407, 1409, 1411, 1470, 1472, 1474, 1539,
|
204
|
+
1604, 1606, 1608, 1610, 1612, 1614, 1616, 1693,
|
205
|
+
1749, 1805, 1861, 1917, 2035, 2153, 2271, 2389,
|
206
|
+
2507, 2625, 2702, 2704, 2706, 2724, 2726, 2983,
|
207
|
+
3035, 3163, 3291, 3316, 3411, 3413, 3415, 3510,
|
208
|
+
3605, 3607, 3629, 3651, 3673, 3732, 3747, 3769,
|
209
|
+
3822, 3856, 4045, 4110, 4175, 4240, 4242, 4299,
|
210
|
+
4316, 4392, 4581, 4646, 4711, 4776, 4785, 4794,
|
211
|
+
4796, 4798, 4799, 4833, 4835, 4836, 4838, 4894,
|
212
|
+
4917, 4937, 4947, 4965
|
211
213
|
]
|
212
214
|
|
213
215
|
class << self
|
@@ -239,673 +241,606 @@ self._re_scanner_indicies = [
|
|
239
241
|
3, 3, 3, 3, 3, 3, 3, 3,
|
240
242
|
3, 3, 3, 3, 3, 3, 3, 3,
|
241
243
|
3, 3, 3, 3, 3, 3, 3, 3,
|
242
|
-
3, 3, 0,
|
243
|
-
|
244
|
-
4, 4, 4, 4, 4, 4, 4, 4,
|
245
|
-
4, 4, 4, 4, 4, 4, 4, 4,
|
246
|
-
4, 4, 4, 4, 4, 4, 4, 4,
|
244
|
+
3, 3, 0, 6, 5, 8, 7, 7,
|
245
|
+
7, 7, 7, 4, 7, 7, 4, 4,
|
247
246
|
4, 4, 4, 4, 4, 4, 4, 4,
|
248
|
-
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
5, 5, 5, 5, 5, 5, 5, 5,
|
254
|
-
5, 5, 5, 5, 5, 5, 5, 5,
|
255
|
-
5, 5, 5, 5, 5, 5, 5, 5,
|
256
|
-
5, 5, 5, 5, 5, 5, 5, 5,
|
257
|
-
5, 5, 5, 5, 5, 5, 5, 5,
|
258
|
-
5, 5, 5, 5, 0, 6, 6, 6,
|
259
|
-
6, 6, 6, 6, 6, 6, 6, 6,
|
260
|
-
6, 6, 6, 6, 6, 6, 6, 6,
|
261
|
-
6, 6, 6, 6, 6, 6, 6, 6,
|
262
|
-
6, 6, 6, 6, 6, 6, 6, 6,
|
263
|
-
6, 6, 6, 6, 6, 6, 6, 6,
|
264
|
-
6, 6, 6, 6, 6, 6, 6, 6,
|
265
|
-
6, 6, 6, 6, 6, 6, 6, 6,
|
266
|
-
6, 6, 6, 6, 6, 0, 9, 8,
|
267
|
-
10, 7, 7, 7, 7, 7, 7, 7,
|
268
|
-
7, 11, 11, 11, 11, 11, 11, 11,
|
269
|
-
11, 11, 11, 7, 7, 7, 7, 7,
|
270
|
-
7, 7, 11, 11, 11, 11, 11, 11,
|
271
|
-
11, 11, 11, 11, 11, 11, 11, 11,
|
247
|
+
7, 8, 7, 10, 9, 9, 9, 9,
|
248
|
+
9, 9, 9, 9, 9, 9, 9, 4,
|
249
|
+
9, 9, 4, 4, 4, 4, 4, 4,
|
250
|
+
4, 4, 4, 4, 9, 9, 9, 10,
|
251
|
+
8, 9, 8, 9, 12, 11, 11, 11,
|
272
252
|
11, 11, 11, 11, 11, 11, 11, 11,
|
273
|
-
11, 11, 11, 11, 7, 7, 7, 7,
|
274
|
-
11, 7, 11, 11, 11, 11, 11, 11,
|
275
253
|
11, 11, 11, 11, 11, 11, 11, 11,
|
276
|
-
11,
|
277
|
-
|
278
|
-
|
279
|
-
|
280
|
-
|
281
|
-
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
290
|
-
|
291
|
-
|
292
|
-
|
293
|
-
|
294
|
-
|
295
|
-
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
14, 14, 14, 14, 14, 14, 14, 14,
|
301
|
-
14, 16, 14, 17, 14, 14, 14, 18,
|
302
|
-
14, 19, 14, 14, 20, 20, 20, 20,
|
303
|
-
20, 20, 20, 20, 20, 20, 14, 14,
|
304
|
-
14, 14, 14, 14, 14, 20, 20, 20,
|
305
|
-
20, 20, 20, 20, 20, 20, 20, 20,
|
306
|
-
20, 20, 20, 20, 20, 20, 20, 20,
|
307
|
-
20, 20, 20, 20, 20, 20, 20, 14,
|
308
|
-
14, 14, 14, 20, 14, 20, 20, 20,
|
309
|
-
20, 20, 20, 20, 20, 20, 20, 20,
|
310
|
-
20, 20, 20, 20, 20, 20, 20, 20,
|
311
|
-
20, 20, 20, 20, 20, 20, 20, 14,
|
312
|
-
21, 21, 21, 21, 21, 21, 21, 21,
|
313
|
-
21, 21, 14, 17, 14, 14, 14, 14,
|
314
|
-
14, 14, 14, 14, 21, 21, 21, 21,
|
315
|
-
21, 21, 21, 21, 21, 21, 14, 21,
|
316
|
-
22, 22, 22, 22, 22, 22, 22, 22,
|
317
|
-
22, 14, 17, 14, 14, 14, 18, 14,
|
318
|
-
18, 14, 14, 22, 22, 22, 22, 22,
|
319
|
-
22, 22, 22, 22, 22, 14, 17, 14,
|
320
|
-
14, 14, 18, 14, 18, 14, 14, 20,
|
321
|
-
20, 20, 20, 20, 20, 20, 20, 20,
|
322
|
-
20, 14, 14, 14, 14, 14, 14, 14,
|
323
|
-
20, 20, 20, 20, 20, 20, 20, 20,
|
324
|
-
20, 20, 20, 20, 20, 20, 20, 20,
|
325
|
-
20, 20, 20, 20, 20, 20, 20, 20,
|
326
|
-
20, 20, 14, 14, 14, 14, 20, 14,
|
327
|
-
20, 20, 20, 20, 20, 20, 20, 20,
|
328
|
-
20, 20, 20, 20, 20, 20, 20, 20,
|
329
|
-
20, 20, 20, 20, 20, 20, 20, 20,
|
330
|
-
20, 20, 14, 23, 14, 24, 14, 14,
|
254
|
+
11, 13, 11, 15, 14, 14, 14, 14,
|
255
|
+
14, 16, 14, 14, 11, 17, 17, 17,
|
256
|
+
17, 17, 17, 17, 17, 17, 14, 15,
|
257
|
+
14, 18, 17, 17, 17, 17, 17, 17,
|
258
|
+
17, 17, 17, 11, 15, 11, 11, 11,
|
259
|
+
11, 11, 11, 11, 11, 18, 18, 18,
|
260
|
+
18, 18, 18, 18, 18, 18, 18, 11,
|
261
|
+
15, 11, 11, 11, 19, 11, 19, 11,
|
262
|
+
11, 17, 17, 17, 17, 17, 17, 17,
|
263
|
+
17, 17, 17, 11, 18, 18, 18, 18,
|
264
|
+
18, 18, 18, 18, 18, 18, 11, 21,
|
265
|
+
20, 20, 11, 22, 22, 22, 22, 22,
|
266
|
+
22, 22, 22, 22, 20, 20, 20, 20,
|
267
|
+
15, 20, 15, 20, 23, 22, 22, 22,
|
268
|
+
22, 22, 22, 22, 22, 22, 11, 23,
|
269
|
+
23, 23, 23, 23, 23, 23, 23, 23,
|
270
|
+
23, 11, 11, 11, 11, 15, 11, 24,
|
271
|
+
11, 24, 11, 11, 22, 22, 22, 22,
|
272
|
+
22, 22, 22, 22, 22, 22, 11, 11,
|
273
|
+
11, 11, 15, 11, 23, 23, 23, 23,
|
274
|
+
23, 23, 23, 23, 23, 23, 11, 26,
|
275
|
+
26, 26, 26, 26, 26, 26, 26, 26,
|
276
|
+
26, 25, 26, 26, 26, 26, 26, 26,
|
277
|
+
26, 26, 26, 26, 25, 25, 25, 25,
|
331
278
|
25, 25, 25, 25, 25, 25, 25, 25,
|
332
|
-
25, 25, 14, 14, 14, 14, 17, 14,
|
333
|
-
14, 25, 25, 25, 25, 25, 25, 25,
|
334
279
|
25, 25, 25, 25, 25, 25, 25, 25,
|
335
280
|
25, 25, 25, 25, 25, 25, 25, 25,
|
336
|
-
25, 25, 25, 14, 14, 14, 14, 25,
|
337
|
-
14, 25, 25, 25, 25, 25, 25, 25,
|
338
281
|
25, 25, 25, 25, 25, 25, 25, 25,
|
339
282
|
25, 25, 25, 25, 25, 25, 25, 25,
|
340
|
-
25, 25, 25, 14, 26, 26, 26, 26,
|
341
|
-
26, 26, 26, 26, 26, 26, 14, 26,
|
342
|
-
26, 26, 26, 26, 26, 26, 26, 26,
|
343
|
-
26, 14, 14, 14, 14, 17, 14, 26,
|
344
|
-
27, 27, 27, 27, 27, 27, 27, 27,
|
345
|
-
27, 14, 23, 14, 23, 14, 14, 27,
|
346
|
-
27, 27, 27, 27, 27, 27, 27, 27,
|
347
|
-
27, 14, 14, 14, 14, 17, 14, 23,
|
348
|
-
14, 23, 14, 14, 25, 25, 25, 25,
|
349
|
-
25, 25, 25, 25, 25, 25, 14, 14,
|
350
|
-
14, 14, 17, 14, 14, 25, 25, 25,
|
351
283
|
25, 25, 25, 25, 25, 25, 25, 25,
|
352
284
|
25, 25, 25, 25, 25, 25, 25, 25,
|
353
|
-
25, 25, 25, 25, 25, 25, 25,
|
354
|
-
|
285
|
+
25, 25, 25, 25, 25, 25, 25, 27,
|
286
|
+
25, 26, 25, 25, 25, 28, 28, 28,
|
287
|
+
28, 28, 28, 28, 28, 28, 28, 25,
|
355
288
|
25, 25, 25, 25, 25, 25, 25, 25,
|
356
289
|
25, 25, 25, 25, 25, 25, 25, 25,
|
357
|
-
25, 25, 25, 25, 25, 25, 25,
|
358
|
-
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
363
|
-
|
364
|
-
|
365
|
-
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
290
|
+
25, 25, 25, 25, 25, 25, 25, 25,
|
291
|
+
25, 25, 25, 25, 25, 25, 25, 25,
|
292
|
+
25, 25, 25, 25, 25, 25, 25, 25,
|
293
|
+
25, 25, 25, 25, 25, 25, 25, 25,
|
294
|
+
25, 25, 25, 25, 25, 25, 25, 25,
|
295
|
+
25, 25, 25, 25, 25, 25, 25, 25,
|
296
|
+
25, 25, 27, 25, 29, 30, 31, 31,
|
297
|
+
31, 31, 31, 30, 30, 30, 30, 30,
|
298
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
299
|
+
30, 30, 30, 30, 30, 31, 30, 30,
|
300
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
301
|
+
30, 30, 31, 31, 30, 31, 31, 31,
|
302
|
+
31, 31, 31, 31, 31, 31, 31, 30,
|
303
|
+
30, 30, 31, 30, 30, 30, 31, 31,
|
370
304
|
31, 31, 31, 31, 31, 31, 31, 31,
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
375
|
-
|
376
|
-
|
377
|
-
|
378
|
-
|
379
|
-
|
380
|
-
|
381
|
-
|
382
|
-
|
383
|
-
|
384
|
-
|
385
|
-
|
386
|
-
|
387
|
-
|
388
|
-
|
389
|
-
|
390
|
-
|
391
|
-
|
392
|
-
|
393
|
-
|
394
|
-
|
395
|
-
|
396
|
-
|
397
|
-
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
|
402
|
-
|
403
|
-
|
404
|
-
|
405
|
-
|
406
|
-
|
407
|
-
|
408
|
-
|
409
|
-
|
410
|
-
|
411
|
-
|
412
|
-
|
413
|
-
|
414
|
-
|
415
|
-
|
416
|
-
|
417
|
-
|
418
|
-
|
419
|
-
|
420
|
-
|
421
|
-
|
422
|
-
|
423
|
-
|
424
|
-
|
425
|
-
|
426
|
-
|
427
|
-
|
428
|
-
|
429
|
-
|
430
|
-
|
431
|
-
|
432
|
-
|
433
|
-
|
434
|
-
|
435
|
-
|
436
|
-
|
437
|
-
|
438
|
-
|
439
|
-
|
440
|
-
|
441
|
-
|
442
|
-
|
443
|
-
|
444
|
-
|
445
|
-
|
446
|
-
|
447
|
-
|
448
|
-
|
449
|
-
|
450
|
-
|
451
|
-
|
452
|
-
|
453
|
-
|
454
|
-
|
455
|
-
|
456
|
-
|
457
|
-
|
458
|
-
|
459
|
-
|
460
|
-
|
461
|
-
|
462
|
-
|
463
|
-
|
464
|
-
|
465
|
-
|
466
|
-
|
467
|
-
|
468
|
-
|
469
|
-
|
470
|
-
|
471
|
-
|
472
|
-
|
473
|
-
|
474
|
-
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
|
481
|
-
|
482
|
-
|
483
|
-
|
484
|
-
|
485
|
-
|
486
|
-
|
487
|
-
|
488
|
-
99, 103, 33, 105, 104, 107, 104, 108,
|
305
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
306
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
307
|
+
30, 30, 30, 32, 31, 30, 31, 31,
|
308
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
309
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
310
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
311
|
+
30, 31, 31, 31, 31, 31, 30, 30,
|
312
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
313
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
314
|
+
31, 30, 30, 30, 30, 30, 30, 30,
|
315
|
+
30, 30, 30, 30, 30, 31, 31, 30,
|
316
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
317
|
+
31, 31, 30, 30, 30, 31, 30, 30,
|
318
|
+
30, 31, 31, 31, 31, 31, 31, 31,
|
319
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
320
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
321
|
+
31, 31, 31, 30, 30, 30, 30, 31,
|
322
|
+
30, 31, 31, 31, 31, 31, 31, 31,
|
323
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
324
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
325
|
+
31, 31, 31, 30, 30, 33, 30, 31,
|
326
|
+
31, 31, 31, 31, 30, 30, 30, 30,
|
327
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
328
|
+
30, 30, 30, 30, 30, 30, 31, 30,
|
329
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
330
|
+
30, 30, 30, 31, 31, 30, 31, 31,
|
331
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
332
|
+
30, 30, 30, 31, 30, 30, 30, 31,
|
333
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
334
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
335
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
336
|
+
31, 30, 30, 30, 30, 31, 30, 31,
|
337
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
338
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
339
|
+
31, 31, 31, 31, 31, 31, 31, 31,
|
340
|
+
31, 30, 35, 35, 35, 35, 35, 35,
|
341
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
342
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
343
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
344
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
345
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
346
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
347
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
348
|
+
35, 35, 34, 36, 36, 36, 36, 36,
|
349
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
350
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
351
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
352
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
353
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
354
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
355
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
356
|
+
36, 36, 36, 34, 38, 37, 41, 40,
|
357
|
+
40, 40, 40, 40, 40, 40, 40, 40,
|
358
|
+
40, 40, 40, 40, 40, 40, 40, 40,
|
359
|
+
40, 40, 41, 41, 41, 41, 41, 41,
|
360
|
+
41, 41, 41, 41, 41, 41, 41, 41,
|
361
|
+
41, 41, 41, 41, 41, 41, 41, 41,
|
362
|
+
41, 41, 41, 41, 40, 40, 40, 40,
|
363
|
+
40, 40, 41, 41, 41, 41, 41, 41,
|
364
|
+
41, 41, 41, 41, 41, 41, 41, 41,
|
365
|
+
41, 41, 41, 41, 41, 41, 41, 41,
|
366
|
+
41, 41, 41, 41, 40, 41, 42, 40,
|
367
|
+
40, 40, 40, 40, 40, 40, 40, 40,
|
368
|
+
40, 40, 40, 40, 40, 40, 40, 40,
|
369
|
+
40, 41, 41, 41, 41, 41, 41, 41,
|
370
|
+
41, 41, 41, 41, 41, 41, 41, 41,
|
371
|
+
41, 41, 41, 41, 41, 41, 41, 41,
|
372
|
+
41, 41, 41, 40, 40, 40, 40, 40,
|
373
|
+
40, 41, 41, 41, 41, 41, 41, 41,
|
374
|
+
41, 41, 41, 41, 41, 41, 41, 41,
|
375
|
+
41, 41, 41, 41, 41, 41, 41, 41,
|
376
|
+
41, 41, 41, 40, 43, 40, 44, 40,
|
377
|
+
40, 45, 46, 47, 48, 40, 40, 49,
|
378
|
+
40, 40, 40, 40, 50, 40, 40, 40,
|
379
|
+
51, 40, 40, 52, 40, 53, 40, 54,
|
380
|
+
55, 40, 45, 46, 47, 48, 40, 40,
|
381
|
+
49, 40, 40, 40, 40, 50, 40, 40,
|
382
|
+
40, 51, 40, 40, 52, 40, 53, 40,
|
383
|
+
54, 55, 40, 56, 40, 40, 40, 40,
|
384
|
+
40, 40, 57, 40, 58, 40, 59, 40,
|
385
|
+
60, 40, 61, 40, 62, 40, 63, 40,
|
386
|
+
64, 40, 61, 40, 65, 40, 66, 40,
|
387
|
+
61, 40, 67, 40, 68, 40, 69, 40,
|
388
|
+
61, 40, 70, 40, 71, 40, 72, 40,
|
389
|
+
61, 40, 73, 40, 74, 40, 75, 40,
|
390
|
+
61, 40, 76, 40, 77, 40, 78, 40,
|
391
|
+
61, 40, 79, 40, 80, 40, 81, 40,
|
392
|
+
61, 40, 82, 40, 40, 83, 40, 84,
|
393
|
+
40, 75, 40, 85, 40, 75, 40, 86,
|
394
|
+
40, 87, 40, 88, 40, 61, 40, 89,
|
395
|
+
40, 80, 40, 90, 40, 91, 40, 61,
|
396
|
+
40, 48, 40, 92, 92, 92, 92, 92,
|
397
|
+
92, 92, 92, 92, 92, 92, 92, 92,
|
398
|
+
92, 92, 92, 92, 92, 92, 92, 92,
|
399
|
+
92, 92, 92, 92, 92, 40, 40, 40,
|
400
|
+
40, 40, 40, 92, 92, 92, 92, 92,
|
401
|
+
92, 92, 92, 92, 92, 92, 92, 92,
|
402
|
+
92, 92, 92, 92, 92, 92, 92, 92,
|
403
|
+
92, 92, 92, 92, 92, 40, 93, 40,
|
404
|
+
94, 40, 96, 96, 96, 96, 96, 96,
|
405
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
406
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
407
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
408
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
409
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
410
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
411
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
412
|
+
96, 96, 95, 97, 97, 97, 97, 97,
|
413
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
414
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
415
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
416
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
417
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
418
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
419
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
420
|
+
97, 97, 97, 95, 98, 30, 100, 99,
|
421
|
+
102, 99, 103, 30, 105, 104, 107, 104,
|
489
422
|
108, 108, 108, 108, 108, 108, 108, 108,
|
490
|
-
108,
|
491
|
-
|
492
|
-
|
493
|
-
|
494
|
-
|
495
|
-
|
496
|
-
|
497
|
-
|
498
|
-
|
499
|
-
110, 110, 110, 110, 110, 110,
|
500
|
-
|
501
|
-
110, 110, 110,
|
502
|
-
|
503
|
-
|
504
|
-
|
505
|
-
110, 110, 110,
|
506
|
-
111, 111, 111, 111, 111, 111,
|
507
|
-
|
508
|
-
111, 111, 111,
|
509
|
-
|
510
|
-
|
511
|
-
|
512
|
-
111, 111, 111,
|
513
|
-
112, 112, 112, 112, 112, 112,
|
514
|
-
|
515
|
-
112, 112, 112,
|
516
|
-
|
517
|
-
|
518
|
-
|
519
|
-
112, 112, 112,
|
520
|
-
113, 113, 113, 113, 113, 113,
|
521
|
-
|
522
|
-
113, 113, 113,
|
523
|
-
|
524
|
-
|
525
|
-
|
526
|
-
113, 113, 113,
|
527
|
-
109,
|
528
|
-
|
529
|
-
|
530
|
-
|
531
|
-
|
532
|
-
114, 114, 114, 114, 114,
|
533
|
-
|
534
|
-
114, 114,
|
535
|
-
|
536
|
-
|
537
|
-
|
538
|
-
114, 114,
|
539
|
-
|
540
|
-
|
541
|
-
112,
|
542
|
-
|
543
|
-
|
544
|
-
|
545
|
-
|
546
|
-
|
547
|
-
115, 115, 115,
|
548
|
-
|
549
|
-
|
550
|
-
|
551
|
-
|
552
|
-
|
553
|
-
|
554
|
-
|
555
|
-
|
556
|
-
|
557
|
-
|
558
|
-
|
559
|
-
|
560
|
-
|
423
|
+
108, 108, 30, 30, 30, 30, 30, 30,
|
424
|
+
30, 108, 108, 108, 108, 108, 108, 30,
|
425
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
426
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
427
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
428
|
+
30, 108, 108, 108, 108, 108, 108, 30,
|
429
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
430
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
431
|
+
30, 30, 30, 109, 30, 110, 110, 110,
|
432
|
+
110, 110, 110, 110, 110, 110, 110, 30,
|
433
|
+
30, 30, 30, 30, 30, 30, 110, 110,
|
434
|
+
110, 110, 110, 110, 30, 30, 30, 30,
|
435
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
436
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
437
|
+
30, 30, 30, 30, 30, 30, 110, 110,
|
438
|
+
110, 110, 110, 110, 30, 111, 111, 111,
|
439
|
+
111, 111, 111, 111, 111, 111, 111, 30,
|
440
|
+
30, 30, 30, 30, 30, 30, 111, 111,
|
441
|
+
111, 111, 111, 111, 30, 30, 30, 30,
|
442
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
443
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
444
|
+
30, 30, 30, 30, 30, 30, 111, 111,
|
445
|
+
111, 111, 111, 111, 30, 112, 112, 112,
|
446
|
+
112, 112, 112, 112, 112, 112, 112, 30,
|
447
|
+
30, 30, 30, 30, 30, 30, 112, 112,
|
448
|
+
112, 112, 112, 112, 30, 30, 30, 30,
|
449
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
450
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
451
|
+
30, 30, 30, 30, 30, 30, 112, 112,
|
452
|
+
112, 112, 112, 112, 30, 113, 113, 113,
|
453
|
+
113, 113, 113, 113, 113, 113, 113, 30,
|
454
|
+
30, 30, 30, 30, 30, 30, 113, 113,
|
455
|
+
113, 113, 113, 113, 30, 30, 30, 30,
|
456
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
457
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
458
|
+
30, 30, 30, 30, 30, 30, 113, 113,
|
459
|
+
113, 113, 113, 113, 30, 109, 109, 109,
|
460
|
+
109, 109, 30, 30, 30, 30, 30, 30,
|
461
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
462
|
+
30, 30, 30, 30, 109, 30, 30, 30,
|
463
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
464
|
+
30, 30, 30, 30, 114, 114, 114, 114,
|
465
|
+
114, 114, 114, 114, 114, 114, 30, 30,
|
466
|
+
30, 30, 30, 30, 30, 114, 114, 114,
|
467
|
+
114, 114, 114, 30, 30, 30, 30, 30,
|
468
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
469
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
470
|
+
30, 30, 30, 30, 30, 114, 114, 114,
|
471
|
+
114, 114, 114, 30, 30, 30, 30, 30,
|
472
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
473
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
474
|
+
30, 112, 30, 109, 109, 109, 109, 109,
|
475
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
476
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
477
|
+
30, 30, 109, 30, 30, 30, 30, 30,
|
478
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
479
|
+
30, 30, 115, 115, 115, 115, 115, 115,
|
480
|
+
115, 115, 115, 115, 30, 30, 30, 30,
|
481
|
+
30, 30, 30, 115, 115, 115, 115, 115,
|
482
|
+
115, 30, 30, 30, 30, 30, 30, 30,
|
483
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
484
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
485
|
+
30, 30, 30, 115, 115, 115, 115, 115,
|
486
|
+
115, 30, 30, 30, 30, 30, 30, 30,
|
487
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
488
|
+
30, 30, 30, 30, 30, 30, 30, 112,
|
489
|
+
30, 109, 109, 109, 109, 109, 30, 30,
|
490
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
491
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
492
|
+
109, 30, 30, 30, 30, 30, 30, 30,
|
493
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
561
494
|
116, 116, 116, 116, 116, 116, 116, 116,
|
562
|
-
116,
|
563
|
-
|
564
|
-
|
565
|
-
|
566
|
-
|
567
|
-
|
568
|
-
|
569
|
-
|
570
|
-
|
571
|
-
109, 109, 109,
|
572
|
-
|
573
|
-
|
574
|
-
|
575
|
-
|
576
|
-
117, 117, 117, 117, 117, 117, 117,
|
577
|
-
|
578
|
-
117, 117, 117, 117,
|
579
|
-
|
580
|
-
|
581
|
-
|
582
|
-
117, 117, 117, 117,
|
583
|
-
|
584
|
-
|
585
|
-
|
586
|
-
109,
|
587
|
-
|
588
|
-
|
589
|
-
|
590
|
-
|
591
|
-
118, 118, 118, 118, 118,
|
592
|
-
|
593
|
-
118, 118,
|
594
|
-
|
595
|
-
|
596
|
-
|
597
|
-
118, 118,
|
598
|
-
|
599
|
-
|
600
|
-
112,
|
601
|
-
|
602
|
-
|
603
|
-
|
604
|
-
|
605
|
-
|
606
|
-
|
607
|
-
|
608
|
-
|
609
|
-
|
610
|
-
|
611
|
-
|
612
|
-
|
613
|
-
|
614
|
-
|
615
|
-
|
616
|
-
120, 120,
|
617
|
-
119,
|
495
|
+
116, 116, 30, 30, 30, 30, 30, 30,
|
496
|
+
30, 116, 116, 116, 116, 116, 116, 30,
|
497
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
498
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
499
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
500
|
+
30, 116, 116, 116, 116, 116, 116, 30,
|
501
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
502
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
503
|
+
30, 30, 30, 30, 30, 112, 30, 109,
|
504
|
+
109, 109, 109, 109, 30, 30, 30, 30,
|
505
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
506
|
+
30, 30, 30, 30, 30, 30, 109, 30,
|
507
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
508
|
+
30, 30, 30, 30, 30, 30, 117, 117,
|
509
|
+
117, 117, 117, 117, 117, 117, 117, 117,
|
510
|
+
30, 30, 30, 30, 30, 30, 30, 117,
|
511
|
+
117, 117, 117, 117, 117, 30, 30, 30,
|
512
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
513
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
514
|
+
30, 30, 30, 30, 30, 30, 30, 117,
|
515
|
+
117, 117, 117, 117, 117, 30, 30, 30,
|
516
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
517
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
518
|
+
30, 30, 30, 112, 30, 109, 109, 109,
|
519
|
+
109, 109, 30, 30, 30, 30, 30, 30,
|
520
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
521
|
+
30, 30, 30, 30, 109, 30, 30, 30,
|
522
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
523
|
+
30, 30, 30, 30, 118, 118, 118, 118,
|
524
|
+
118, 118, 118, 118, 118, 118, 30, 30,
|
525
|
+
30, 30, 30, 30, 30, 118, 118, 118,
|
526
|
+
118, 118, 118, 30, 30, 30, 30, 30,
|
527
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
528
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
529
|
+
30, 30, 30, 30, 30, 118, 118, 118,
|
530
|
+
118, 118, 118, 30, 30, 30, 30, 30,
|
531
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
532
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
533
|
+
30, 112, 30, 109, 109, 109, 109, 109,
|
534
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
535
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
536
|
+
30, 30, 109, 30, 30, 30, 30, 30,
|
537
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
538
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
539
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
540
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
541
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
542
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
543
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
544
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
545
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
546
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
547
|
+
30, 30, 30, 30, 30, 30, 30, 112,
|
548
|
+
30, 120, 120, 120, 120, 120, 120, 120,
|
549
|
+
120, 120, 120, 119, 119, 119, 119, 119,
|
550
|
+
119, 119, 120, 120, 120, 120, 120, 120,
|
618
551
|
119, 119, 119, 119, 119, 119, 119, 119,
|
619
552
|
119, 119, 119, 119, 119, 119, 119, 119,
|
620
553
|
119, 119, 119, 119, 119, 119, 119, 119,
|
621
|
-
119,
|
554
|
+
119, 119, 120, 120, 120, 120, 120, 120,
|
622
555
|
119, 119, 119, 119, 119, 119, 119, 119,
|
623
556
|
119, 119, 119, 119, 119, 119, 119, 119,
|
624
|
-
119, 119, 119,
|
625
|
-
|
626
|
-
|
627
|
-
|
628
|
-
|
629
|
-
|
630
|
-
|
631
|
-
|
632
|
-
|
633
|
-
|
634
|
-
|
635
|
-
|
636
|
-
|
637
|
-
|
638
|
-
|
639
|
-
|
640
|
-
|
641
|
-
|
642
|
-
|
643
|
-
|
644
|
-
|
645
|
-
|
646
|
-
|
647
|
-
|
648
|
-
|
649
|
-
|
650
|
-
|
651
|
-
|
652
|
-
|
653
|
-
|
654
|
-
|
655
|
-
|
656
|
-
|
657
|
-
|
658
|
-
|
659
|
-
|
557
|
+
119, 119, 119, 119, 30, 119, 123, 122,
|
558
|
+
124, 121, 124, 121, 121, 121, 121, 121,
|
559
|
+
121, 125, 125, 125, 125, 125, 125, 125,
|
560
|
+
125, 125, 125, 121, 123, 126, 30, 30,
|
561
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
562
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
563
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
564
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
565
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
566
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
567
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
568
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
569
|
+
2, 2, 2, 2, 2, 2, 2, 2,
|
570
|
+
2, 2, 2, 2, 2, 2, 2, 2,
|
571
|
+
2, 2, 2, 2, 2, 2, 2, 2,
|
572
|
+
2, 2, 2, 2, 2, 2, 3, 3,
|
573
|
+
3, 3, 3, 3, 3, 3, 3, 3,
|
574
|
+
3, 3, 3, 3, 3, 3, 127, 127,
|
575
|
+
127, 127, 127, 30, 30, 30, 30, 30,
|
576
|
+
30, 30, 30, 30, 30, 30, 30, 128,
|
577
|
+
128, 128, 128, 128, 128, 128, 128, 129,
|
578
|
+
129, 129, 129, 129, 128, 128, 128, 128,
|
579
|
+
128, 128, 128, 128, 128, 128, 128, 128,
|
580
|
+
128, 128, 128, 128, 128, 128, 130, 131,
|
581
|
+
131, 132, 133, 131, 131, 131, 134, 135,
|
582
|
+
136, 137, 131, 131, 138, 131, 131, 131,
|
583
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
584
|
+
131, 131, 131, 131, 131, 139, 131, 131,
|
585
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
586
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
587
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
588
|
+
131, 140, 141, 142, 143, 131, 131, 131,
|
589
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
590
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
591
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
592
|
+
131, 144, 145, 142, 131, 128, 131, 2,
|
593
|
+
2, 2, 2, 2, 2, 2, 2, 2,
|
594
|
+
2, 2, 2, 2, 2, 2, 2, 2,
|
595
|
+
2, 2, 2, 2, 2, 2, 2, 2,
|
596
|
+
2, 2, 2, 2, 2, 3, 3, 3,
|
597
|
+
3, 3, 3, 3, 3, 3, 3, 3,
|
598
|
+
3, 3, 3, 3, 3, 127, 127, 127,
|
599
|
+
127, 127, 146, 128, 128, 128, 128, 128,
|
600
|
+
128, 128, 128, 128, 128, 128, 128, 128,
|
660
601
|
128, 128, 128, 128, 128, 128, 128, 128,
|
661
|
-
128, 128, 129, 129, 129, 129, 129, 33,
|
662
|
-
33, 33, 33, 33, 33, 33, 33, 33,
|
663
|
-
33, 33, 33, 130, 130, 130, 130, 130,
|
664
|
-
130, 130, 130, 131, 131, 131, 131, 131,
|
665
|
-
130, 130, 130, 130, 130, 130, 130, 130,
|
666
|
-
130, 130, 130, 130, 130, 130, 130, 130,
|
667
|
-
130, 130, 132, 133, 133, 134, 135, 133,
|
668
|
-
133, 133, 136, 137, 138, 139, 133, 133,
|
669
|
-
140, 133, 133, 133, 133, 133, 133, 133,
|
670
|
-
133, 133, 133, 133, 133, 133, 133, 133,
|
671
|
-
133, 141, 133, 133, 133, 133, 133, 133,
|
672
|
-
133, 133, 133, 133, 133, 133, 133, 133,
|
673
|
-
133, 133, 133, 133, 133, 133, 133, 133,
|
674
|
-
133, 133, 133, 133, 133, 142, 143, 144,
|
675
|
-
145, 133, 133, 133, 133, 133, 133, 133,
|
676
|
-
133, 133, 133, 133, 133, 133, 133, 133,
|
677
|
-
133, 133, 133, 133, 133, 133, 133, 133,
|
678
|
-
133, 133, 133, 133, 133, 146, 147, 144,
|
679
|
-
133, 130, 133, 127, 127, 127, 127, 127,
|
680
|
-
127, 127, 127, 127, 127, 127, 127, 127,
|
681
|
-
127, 127, 127, 127, 127, 127, 127, 127,
|
682
|
-
127, 127, 127, 127, 127, 127, 127, 127,
|
683
|
-
127, 148, 128, 128, 128, 128, 128, 128,
|
684
602
|
128, 128, 128, 128, 128, 128, 128, 128,
|
685
|
-
128, 128,
|
686
|
-
|
687
|
-
|
688
|
-
|
689
|
-
|
690
|
-
|
691
|
-
|
692
|
-
|
693
|
-
|
694
|
-
|
695
|
-
|
696
|
-
|
697
|
-
|
698
|
-
|
699
|
-
|
700
|
-
|
701
|
-
|
702
|
-
|
703
|
-
|
704
|
-
|
705
|
-
|
706
|
-
|
707
|
-
|
708
|
-
|
709
|
-
|
710
|
-
|
711
|
-
|
712
|
-
|
713
|
-
|
714
|
-
|
715
|
-
|
716
|
-
|
717
|
-
|
718
|
-
|
719
|
-
|
720
|
-
|
721
|
-
|
722
|
-
|
723
|
-
|
724
|
-
|
725
|
-
|
726
|
-
|
727
|
-
|
728
|
-
|
729
|
-
|
730
|
-
|
731
|
-
|
732
|
-
|
733
|
-
|
734
|
-
|
735
|
-
|
736
|
-
|
737
|
-
|
738
|
-
|
739
|
-
|
740
|
-
|
741
|
-
|
742
|
-
|
743
|
-
|
744
|
-
|
745
|
-
|
746
|
-
|
747
|
-
|
748
|
-
|
749
|
-
|
750
|
-
|
751
|
-
|
752
|
-
|
753
|
-
|
754
|
-
|
755
|
-
|
756
|
-
|
757
|
-
|
758
|
-
|
759
|
-
|
760
|
-
|
761
|
-
|
762
|
-
|
763
|
-
|
764
|
-
|
765
|
-
|
766
|
-
|
767
|
-
|
768
|
-
|
769
|
-
|
770
|
-
|
771
|
-
|
772
|
-
|
773
|
-
|
774
|
-
|
775
|
-
|
776
|
-
|
777
|
-
|
778
|
-
|
779
|
-
|
780
|
-
|
781
|
-
|
782
|
-
|
783
|
-
|
784
|
-
|
785
|
-
|
786
|
-
33, 33, 33, 33, 33, 33, 33, 33,
|
787
|
-
33, 33, 33, 33, 33, 33, 33, 33,
|
788
|
-
33, 33, 174, 33, 175, 175, 175, 175,
|
789
|
-
175, 175, 175, 175, 175, 175, 175, 175,
|
790
|
-
175, 175, 175, 175, 175, 175, 175, 175,
|
791
|
-
175, 175, 175, 175, 175, 175, 175, 175,
|
792
|
-
175, 175, 176, 176, 176, 176, 176, 176,
|
603
|
+
128, 128, 146, 146, 146, 146, 146, 146,
|
604
|
+
146, 146, 146, 146, 146, 146, 146, 146,
|
605
|
+
146, 146, 146, 146, 146, 146, 146, 146,
|
606
|
+
146, 146, 146, 146, 146, 146, 146, 146,
|
607
|
+
146, 146, 146, 146, 146, 146, 146, 146,
|
608
|
+
146, 146, 146, 146, 146, 146, 146, 146,
|
609
|
+
146, 146, 146, 146, 146, 146, 146, 146,
|
610
|
+
146, 146, 146, 146, 146, 146, 146, 146,
|
611
|
+
146, 146, 146, 146, 146, 146, 146, 146,
|
612
|
+
146, 146, 146, 146, 146, 146, 146, 146,
|
613
|
+
146, 146, 146, 146, 146, 146, 146, 146,
|
614
|
+
146, 146, 146, 146, 146, 146, 146, 146,
|
615
|
+
146, 128, 146, 128, 128, 128, 128, 128,
|
616
|
+
128, 128, 128, 129, 129, 129, 129, 129,
|
617
|
+
128, 128, 128, 128, 128, 128, 128, 128,
|
618
|
+
128, 128, 128, 128, 128, 128, 128, 128,
|
619
|
+
128, 128, 130, 147, 147, 147, 147, 147,
|
620
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
621
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
622
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
623
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
624
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
625
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
626
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
627
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
628
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
629
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
630
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
631
|
+
147, 128, 147, 130, 130, 130, 130, 130,
|
632
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
633
|
+
147, 147, 147, 147, 147, 147, 147, 147,
|
634
|
+
147, 147, 130, 147, 131, 131, 146, 146,
|
635
|
+
131, 131, 131, 146, 146, 146, 146, 131,
|
636
|
+
131, 146, 131, 131, 131, 131, 131, 131,
|
637
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
638
|
+
131, 131, 146, 131, 131, 131, 131, 131,
|
639
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
640
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
641
|
+
131, 131, 131, 131, 131, 131, 146, 146,
|
642
|
+
146, 146, 131, 131, 131, 131, 131, 131,
|
643
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
644
|
+
131, 131, 131, 131, 131, 131, 131, 131,
|
645
|
+
131, 131, 131, 131, 131, 131, 146, 146,
|
646
|
+
146, 131, 146, 149, 132, 151, 150, 154,
|
647
|
+
153, 5, 153, 153, 153, 155, 156, 152,
|
648
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
649
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
650
|
+
8, 153, 157, 154, 8, 153, 153, 153,
|
651
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
652
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
653
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
654
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
655
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
656
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
657
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
658
|
+
153, 153, 153, 153, 8, 153, 152, 153,
|
659
|
+
152, 153, 153, 153, 152, 152, 152, 153,
|
660
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
661
|
+
153, 153, 153, 153, 153, 153, 153, 158,
|
662
|
+
153, 152, 152, 152, 153, 153, 153, 153,
|
663
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
664
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
665
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
666
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
667
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
668
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
669
|
+
153, 153, 153, 153, 153, 153, 153, 153,
|
670
|
+
153, 153, 153, 152, 153, 8, 9, 161,
|
671
|
+
160, 160, 160, 160, 160, 160, 160, 160,
|
672
|
+
160, 160, 160, 160, 160, 160, 160, 160,
|
673
|
+
160, 160, 160, 161, 160, 163, 162, 162,
|
674
|
+
162, 162, 162, 162, 162, 162, 162, 162,
|
675
|
+
162, 162, 162, 162, 162, 162, 162, 162,
|
676
|
+
162, 163, 162, 165, 164, 164, 164, 164,
|
677
|
+
164, 164, 164, 164, 164, 164, 164, 164,
|
678
|
+
164, 164, 164, 164, 164, 164, 164, 165,
|
679
|
+
164, 167, 167, 166, 166, 166, 166, 167,
|
680
|
+
166, 166, 166, 168, 166, 166, 166, 166,
|
681
|
+
166, 166, 166, 166, 166, 166, 166, 166,
|
682
|
+
166, 166, 167, 166, 166, 166, 166, 166,
|
683
|
+
166, 166, 167, 166, 166, 166, 166, 169,
|
684
|
+
166, 166, 166, 169, 166, 166, 166, 166,
|
685
|
+
166, 166, 166, 166, 166, 166, 166, 166,
|
686
|
+
166, 166, 167, 166, 171, 170, 170, 170,
|
687
|
+
28, 28, 28, 28, 28, 28, 28, 28,
|
688
|
+
28, 28, 170, 173, 172, 172, 172, 172,
|
689
|
+
172, 172, 172, 172, 172, 172, 172, 172,
|
690
|
+
172, 172, 172, 172, 172, 172, 172, 173,
|
691
|
+
172, 174, 30, 30, 30, 174, 30, 30,
|
692
|
+
30, 30, 30, 30, 30, 30, 30, 174,
|
693
|
+
174, 30, 30, 30, 174, 174, 30, 30,
|
694
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
695
|
+
30, 174, 30, 30, 30, 174, 30, 30,
|
696
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
697
|
+
174, 30, 30, 30, 174, 30, 175, 30,
|
698
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
699
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
700
|
+
30, 30, 30, 30, 30, 30, 30, 30,
|
701
|
+
30, 30, 30, 30, 30, 30, 175, 30,
|
702
|
+
176, 176, 176, 176, 176, 176, 176, 176,
|
703
|
+
176, 176, 176, 176, 176, 176, 176, 176,
|
793
704
|
176, 176, 176, 176, 176, 176, 176, 176,
|
794
|
-
176, 176,
|
795
|
-
|
796
|
-
|
797
|
-
|
798
|
-
|
799
|
-
|
800
|
-
|
801
|
-
|
802
|
-
|
803
|
-
|
804
|
-
|
805
|
-
|
806
|
-
|
807
|
-
|
808
|
-
|
809
|
-
|
810
|
-
|
811
|
-
|
812
|
-
|
813
|
-
|
814
|
-
|
815
|
-
|
816
|
-
|
817
|
-
|
818
|
-
|
819
|
-
|
820
|
-
|
821
|
-
|
822
|
-
|
823
|
-
|
824
|
-
|
825
|
-
|
826
|
-
|
827
|
-
|
828
|
-
|
829
|
-
|
830
|
-
|
831
|
-
|
832
|
-
|
833
|
-
|
834
|
-
|
835
|
-
|
836
|
-
|
837
|
-
|
838
|
-
|
839
|
-
188,
|
840
|
-
|
841
|
-
|
842
|
-
|
843
|
-
|
844
|
-
|
845
|
-
|
705
|
+
176, 176, 176, 176, 176, 176, 177, 177,
|
706
|
+
177, 177, 177, 177, 177, 177, 177, 177,
|
707
|
+
177, 177, 177, 177, 177, 177, 178, 178,
|
708
|
+
178, 178, 178, 35, 35, 35, 35, 35,
|
709
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
710
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
711
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
712
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
713
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
714
|
+
35, 35, 179, 35, 180, 35, 179, 179,
|
715
|
+
179, 179, 35, 181, 179, 35, 35, 35,
|
716
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
717
|
+
35, 35, 35, 35, 35, 179, 35, 35,
|
718
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
719
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
720
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
721
|
+
35, 182, 183, 184, 185, 35, 35, 35,
|
722
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
723
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
724
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
725
|
+
35, 179, 179, 179, 35, 35, 35, 35,
|
726
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
727
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
728
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
729
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
730
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
731
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
732
|
+
35, 35, 35, 35, 35, 35, 35, 35,
|
733
|
+
35, 35, 35, 35, 35, 186, 36, 36,
|
734
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
735
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
736
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
737
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
738
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
739
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
740
|
+
36, 36, 36, 36, 36, 36, 36, 36,
|
741
|
+
36, 36, 36, 36, 36, 36, 186, 187,
|
742
|
+
187, 187, 187, 187, 187, 187, 187, 187,
|
743
|
+
187, 187, 187, 187, 187, 187, 187, 187,
|
744
|
+
187, 187, 187, 187, 187, 187, 187, 187,
|
745
|
+
187, 187, 187, 187, 187, 187, 187, 187,
|
746
|
+
187, 187, 187, 187, 187, 187, 187, 187,
|
747
|
+
187, 187, 187, 187, 187, 187, 187, 187,
|
748
|
+
187, 187, 187, 187, 187, 187, 187, 187,
|
749
|
+
187, 187, 187, 187, 187, 187, 187, 186,
|
750
|
+
188, 186, 190, 189, 189, 189, 189, 189,
|
751
|
+
189, 189, 189, 189, 189, 189, 189, 189,
|
752
|
+
189, 189, 189, 189, 189, 189, 189, 189,
|
753
|
+
189, 189, 189, 189, 189, 189, 189, 189,
|
754
|
+
189, 189, 189, 189, 189, 189, 189, 189,
|
755
|
+
189, 189, 189, 189, 189, 189, 189, 189,
|
756
|
+
189, 189, 189, 189, 189, 189, 189, 189,
|
757
|
+
189, 191, 189, 194, 193, 193, 193, 193,
|
758
|
+
193, 193, 193, 193, 193, 193, 193, 195,
|
759
|
+
193, 193, 196, 193, 198, 198, 198, 198,
|
760
|
+
198, 198, 198, 198, 198, 198, 197, 197,
|
761
|
+
197, 197, 197, 197, 197, 198, 198, 198,
|
762
|
+
197, 197, 197, 198, 197, 197, 197, 198,
|
763
|
+
197, 198, 197, 197, 197, 197, 198, 197,
|
764
|
+
197, 197, 197, 197, 198, 197, 198, 197,
|
765
|
+
197, 197, 197, 197, 197, 197, 197, 198,
|
766
|
+
197, 197, 197, 198, 197, 197, 197, 198,
|
846
767
|
197, 197, 197, 197, 197, 197, 197, 197,
|
847
|
-
197, 197,
|
848
|
-
|
849
|
-
|
850
|
-
|
851
|
-
|
852
|
-
|
853
|
-
|
854
|
-
|
855
|
-
|
856
|
-
|
857
|
-
|
858
|
-
|
859
|
-
|
860
|
-
|
861
|
-
|
862
|
-
204,
|
863
|
-
|
864
|
-
|
865
|
-
|
866
|
-
|
867
|
-
|
868
|
-
|
869
|
-
|
768
|
+
197, 197, 197, 197, 197, 197, 198, 197,
|
769
|
+
199, 199, 199, 199, 199, 199, 199, 199,
|
770
|
+
199, 199, 199, 199, 199, 199, 199, 199,
|
771
|
+
199, 199, 199, 199, 199, 199, 199, 199,
|
772
|
+
199, 199, 199, 199, 199, 199, 200, 200,
|
773
|
+
200, 200, 200, 200, 200, 200, 200, 200,
|
774
|
+
200, 200, 200, 200, 200, 200, 201, 201,
|
775
|
+
201, 201, 201, 96, 96, 96, 96, 96,
|
776
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
777
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
778
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
779
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
780
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
781
|
+
96, 96, 202, 96, 96, 96, 202, 202,
|
782
|
+
202, 202, 96, 96, 202, 96, 203, 204,
|
783
|
+
204, 204, 204, 204, 204, 204, 205, 205,
|
784
|
+
96, 96, 96, 96, 96, 202, 96, 30,
|
785
|
+
30, 206, 207, 96, 96, 30, 207, 96,
|
786
|
+
96, 30, 96, 208, 96, 96, 209, 96,
|
787
|
+
207, 207, 96, 96, 96, 207, 207, 96,
|
788
|
+
30, 202, 202, 202, 202, 96, 96, 210,
|
789
|
+
210, 98, 207, 210, 210, 96, 207, 96,
|
790
|
+
96, 96, 96, 96, 210, 96, 209, 96,
|
791
|
+
210, 207, 210, 211, 210, 207, 212, 96,
|
792
|
+
30, 202, 202, 202, 96, 96, 96, 96,
|
793
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
794
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
795
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
796
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
797
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
798
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
799
|
+
96, 96, 96, 96, 96, 96, 96, 96,
|
800
|
+
96, 96, 96, 96, 96, 213, 97, 97,
|
801
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
802
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
803
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
804
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
805
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
806
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
807
|
+
97, 97, 97, 97, 97, 97, 97, 97,
|
808
|
+
97, 97, 97, 97, 97, 97, 213, 214,
|
809
|
+
214, 214, 214, 214, 214, 214, 214, 214,
|
810
|
+
214, 214, 214, 214, 214, 214, 214, 214,
|
811
|
+
214, 214, 214, 214, 214, 214, 214, 214,
|
812
|
+
214, 214, 214, 214, 214, 214, 214, 214,
|
813
|
+
214, 214, 214, 214, 214, 214, 214, 214,
|
814
|
+
214, 214, 214, 214, 214, 214, 214, 214,
|
815
|
+
214, 214, 214, 214, 214, 214, 214, 214,
|
816
|
+
214, 214, 214, 214, 214, 214, 214, 213,
|
817
|
+
216, 216, 216, 216, 216, 216, 216, 216,
|
818
|
+
215, 218, 218, 218, 218, 218, 218, 218,
|
819
|
+
218, 217, 220, 99, 222, 221, 99, 224,
|
870
820
|
104, 104, 104, 104, 104, 104, 104, 104,
|
871
821
|
104, 104, 104, 104, 104, 104, 104, 104,
|
872
822
|
104, 104, 104, 104, 104, 104, 104, 104,
|
873
|
-
104, 104, 104, 104, 104, 104,
|
874
|
-
|
875
|
-
225, 225, 225, 225, 225, 225, 225, 224,
|
876
|
-
224, 224, 224, 224, 224, 224, 225, 225,
|
877
|
-
225, 225, 225, 225, 224, 224, 224, 224,
|
878
|
-
224, 224, 224, 224, 224, 224, 224, 224,
|
879
|
-
224, 224, 224, 224, 224, 224, 224, 224,
|
880
|
-
224, 224, 224, 224, 224, 224, 225, 225,
|
881
|
-
225, 225, 225, 225, 224, 227, 226, 226,
|
882
|
-
226, 226, 226, 228, 226, 226, 226, 229,
|
823
|
+
104, 104, 104, 104, 104, 104, 104, 225,
|
824
|
+
104, 227, 226, 104, 107, 104, 229, 229,
|
883
825
|
229, 229, 229, 229, 229, 229, 229, 229,
|
884
|
-
|
885
|
-
|
886
|
-
|
887
|
-
|
888
|
-
|
889
|
-
|
890
|
-
|
891
|
-
|
892
|
-
|
893
|
-
|
894
|
-
|
895
|
-
|
896
|
-
125, 125,
|
897
|
-
|
898
|
-
125, 125, 125, 125,
|
899
|
-
|
900
|
-
|
901
|
-
|
902
|
-
126, 126, 126, 126, 126, 126, 126, 126,
|
903
|
-
126, 126, 126, 126, 126, 126, 126, 126,
|
904
|
-
231, 231, 231, 231, 126, 231, 126, 126,
|
905
|
-
126, 126, 126, 126, 126, 126, 126, 126,
|
906
|
-
126, 126, 126, 126, 126, 126, 126, 126,
|
907
|
-
126, 126, 126, 126, 126, 126, 126, 126,
|
908
|
-
231, 0
|
826
|
+
228, 228, 228, 228, 228, 228, 228, 229,
|
827
|
+
229, 229, 229, 229, 229, 228, 228, 228,
|
828
|
+
228, 228, 228, 228, 228, 228, 228, 228,
|
829
|
+
228, 228, 228, 228, 228, 228, 228, 228,
|
830
|
+
228, 228, 228, 228, 228, 228, 228, 229,
|
831
|
+
229, 229, 229, 229, 229, 228, 231, 230,
|
832
|
+
230, 230, 230, 230, 232, 230, 230, 230,
|
833
|
+
233, 233, 233, 233, 233, 233, 233, 233,
|
834
|
+
233, 230, 230, 234, 230, 123, 122, 122,
|
835
|
+
122, 122, 122, 235, 122, 122, 235, 235,
|
836
|
+
235, 235, 235, 235, 235, 235, 235, 235,
|
837
|
+
122, 125, 125, 125, 125, 125, 125, 125,
|
838
|
+
125, 125, 235, 124, 235, 235, 235, 235,
|
839
|
+
235, 235, 125, 125, 125, 125, 125, 125,
|
840
|
+
125, 125, 125, 125, 235, 235, 126, 126,
|
841
|
+
235, 235, 235, 235, 235, 235, 235, 235,
|
842
|
+
235, 235, 126, 126, 126, 126, 123, 126,
|
843
|
+
0
|
909
844
|
]
|
910
845
|
|
911
846
|
class << self
|
@@ -913,35 +848,36 @@ class << self
|
|
913
848
|
private :_re_scanner_trans_targs, :_re_scanner_trans_targs=
|
914
849
|
end
|
915
850
|
self._re_scanner_trans_targs = [
|
916
|
-
110, 111,
|
917
|
-
|
918
|
-
|
919
|
-
21,
|
920
|
-
28,
|
921
|
-
|
922
|
-
|
923
|
-
|
924
|
-
|
925
|
-
|
926
|
-
|
927
|
-
|
928
|
-
|
929
|
-
|
930
|
-
|
931
|
-
|
932
|
-
|
933
|
-
|
934
|
-
|
935
|
-
110,
|
851
|
+
110, 111, 1, 2, 110, 4, 110, 6,
|
852
|
+
110, 8, 120, 110, 10, 16, 11, 110,
|
853
|
+
12, 14, 13, 15, 17, 18, 20, 19,
|
854
|
+
21, 110, 23, 126, 24, 26, 0, 27,
|
855
|
+
28, 128, 129, 129, 29, 129, 129, 129,
|
856
|
+
129, 33, 34, 129, 36, 37, 48, 52,
|
857
|
+
56, 60, 64, 68, 73, 77, 79, 82,
|
858
|
+
38, 45, 39, 43, 40, 41, 42, 129,
|
859
|
+
44, 46, 47, 49, 50, 51, 53, 54,
|
860
|
+
55, 57, 58, 59, 61, 62, 63, 65,
|
861
|
+
66, 67, 69, 71, 70, 72, 74, 75,
|
862
|
+
76, 78, 80, 81, 84, 85, 129, 137,
|
863
|
+
137, 86, 89, 137, 143, 137, 145, 92,
|
864
|
+
137, 146, 137, 148, 95, 98, 96, 97,
|
865
|
+
137, 99, 100, 101, 102, 103, 104, 137,
|
866
|
+
150, 151, 106, 107, 151, 108, 109, 3,
|
867
|
+
112, 113, 114, 115, 116, 110, 117, 110,
|
868
|
+
121, 122, 110, 123, 110, 124, 110, 110,
|
869
|
+
125, 110, 110, 110, 110, 110, 110, 118,
|
870
|
+
110, 119, 110, 5, 110, 7, 110, 110,
|
936
871
|
110, 110, 110, 110, 110, 110, 110, 110,
|
937
|
-
|
938
|
-
|
939
|
-
|
940
|
-
|
941
|
-
139,
|
942
|
-
|
943
|
-
|
944
|
-
|
872
|
+
110, 9, 110, 22, 110, 110, 127, 25,
|
873
|
+
130, 131, 132, 129, 133, 134, 135, 129,
|
874
|
+
129, 129, 129, 30, 129, 129, 31, 129,
|
875
|
+
129, 129, 32, 35, 83, 136, 136, 138,
|
876
|
+
139, 140, 137, 141, 141, 137, 88, 137,
|
877
|
+
91, 137, 137, 94, 105, 137, 87, 137,
|
878
|
+
142, 137, 137, 137, 144, 137, 90, 137,
|
879
|
+
147, 149, 137, 93, 137, 137, 151, 152,
|
880
|
+
153, 154, 155, 151
|
945
881
|
]
|
946
882
|
|
947
883
|
class << self
|
@@ -949,35 +885,36 @@ class << self
|
|
949
885
|
private :_re_scanner_trans_actions, :_re_scanner_trans_actions=
|
950
886
|
end
|
951
887
|
self._re_scanner_trans_actions = [
|
952
|
-
1, 2, 0,
|
953
|
-
|
954
|
-
0, 9, 0, 0, 0, 0, 0, 0,
|
955
|
-
0, 0, 0, 0, 10, 0, 0, 0,
|
956
|
-
0, 0, 0, 0, 12, 13, 14, 0,
|
957
|
-
15, 16, 17, 18, 0, 0, 19, 0,
|
888
|
+
1, 2, 0, 0, 3, 4, 5, 0,
|
889
|
+
6, 0, 7, 8, 0, 0, 0, 9,
|
958
890
|
0, 0, 0, 0, 0, 0, 0, 0,
|
891
|
+
0, 10, 0, 0, 0, 0, 0, 0,
|
892
|
+
0, 12, 13, 14, 0, 15, 16, 17,
|
893
|
+
18, 0, 0, 19, 0, 0, 0, 0,
|
959
894
|
0, 0, 0, 0, 0, 0, 0, 0,
|
960
|
-
0, 0,
|
895
|
+
0, 0, 0, 0, 0, 0, 0, 20,
|
961
896
|
0, 0, 0, 0, 0, 0, 0, 0,
|
962
897
|
0, 0, 0, 0, 0, 0, 0, 0,
|
963
898
|
0, 0, 0, 0, 0, 0, 0, 0,
|
964
|
-
0,
|
965
|
-
|
966
|
-
27, 0,
|
967
|
-
|
968
|
-
0,
|
969
|
-
|
970
|
-
|
971
|
-
|
972
|
-
|
973
|
-
|
974
|
-
|
975
|
-
|
976
|
-
|
977
|
-
|
978
|
-
|
979
|
-
|
980
|
-
|
899
|
+
0, 0, 0, 0, 0, 0, 21, 22,
|
900
|
+
23, 0, 0, 25, 0, 26, 0, 0,
|
901
|
+
27, 0, 28, 0, 0, 0, 0, 0,
|
902
|
+
29, 0, 0, 0, 0, 0, 0, 30,
|
903
|
+
0, 31, 0, 0, 32, 0, 0, 0,
|
904
|
+
0, 0, 0, 0, 0, 35, 36, 37,
|
905
|
+
0, 0, 38, 0, 39, 40, 41, 42,
|
906
|
+
40, 43, 44, 45, 46, 47, 48, 49,
|
907
|
+
50, 0, 51, 0, 52, 0, 53, 54,
|
908
|
+
55, 56, 57, 58, 59, 60, 61, 62,
|
909
|
+
63, 0, 64, 0, 65, 66, 68, 0,
|
910
|
+
0, 40, 40, 69, 0, 40, 70, 71,
|
911
|
+
72, 73, 74, 0, 75, 76, 0, 77,
|
912
|
+
78, 79, 0, 0, 0, 80, 81, 0,
|
913
|
+
40, 40, 82, 83, 84, 85, 0, 86,
|
914
|
+
0, 87, 88, 0, 0, 89, 0, 90,
|
915
|
+
0, 91, 92, 93, 40, 94, 0, 95,
|
916
|
+
40, 0, 96, 0, 97, 98, 99, 40,
|
917
|
+
40, 40, 40, 100
|
981
918
|
]
|
982
919
|
|
983
920
|
class << self
|
@@ -998,13 +935,13 @@ self._re_scanner_to_state_actions = [
|
|
998
935
|
0, 0, 0, 0, 0, 0, 0, 0,
|
999
936
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1000
937
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1001
|
-
0, 0, 0, 0, 0, 0,
|
938
|
+
0, 0, 0, 0, 0, 0, 33, 0,
|
1002
939
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1003
|
-
0, 0, 0, 0, 0, 0, 0,
|
1004
|
-
|
1005
|
-
|
1006
|
-
0, 0, 0, 0, 0,
|
1007
|
-
0, 0
|
940
|
+
0, 0, 0, 0, 0, 0, 0, 67,
|
941
|
+
67, 67, 0, 0, 0, 0, 0, 0,
|
942
|
+
67, 67, 0, 0, 0, 0, 0, 0,
|
943
|
+
0, 0, 0, 0, 0, 0, 0, 67,
|
944
|
+
0, 0, 0, 0
|
1008
945
|
]
|
1009
946
|
|
1010
947
|
class << self
|
@@ -1025,13 +962,13 @@ self._re_scanner_from_state_actions = [
|
|
1025
962
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1026
963
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1027
964
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1028
|
-
0, 0, 0, 0, 0, 0,
|
1029
|
-
0, 0, 0, 0, 0, 0, 0, 0,
|
965
|
+
0, 0, 0, 0, 0, 0, 34, 0,
|
1030
966
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1031
|
-
|
1032
|
-
|
1033
|
-
|
1034
|
-
0, 0
|
967
|
+
0, 0, 0, 0, 0, 0, 0, 34,
|
968
|
+
34, 34, 0, 0, 0, 0, 0, 0,
|
969
|
+
34, 34, 0, 0, 0, 0, 0, 0,
|
970
|
+
0, 0, 0, 0, 0, 0, 0, 34,
|
971
|
+
0, 0, 0, 0
|
1035
972
|
]
|
1036
973
|
|
1037
974
|
class << self
|
@@ -1042,7 +979,7 @@ self._re_scanner_eof_actions = [
|
|
1042
979
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1043
980
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1044
981
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1045
|
-
0,
|
982
|
+
0, 11, 11, 11, 11, 0, 0, 0,
|
1046
983
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1047
984
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1048
985
|
0, 0, 0, 0, 0, 0, 0, 0,
|
@@ -1050,15 +987,15 @@ self._re_scanner_eof_actions = [
|
|
1050
987
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1051
988
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1052
989
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1053
|
-
|
1054
|
-
|
1055
|
-
|
990
|
+
24, 24, 0, 24, 24, 0, 24, 24,
|
991
|
+
24, 24, 24, 24, 24, 24, 24, 24,
|
992
|
+
24, 24, 0, 0, 0, 0, 0, 0,
|
1056
993
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1057
994
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1058
|
-
0,
|
1059
|
-
0,
|
995
|
+
0, 24, 0, 0, 0, 0, 0, 0,
|
996
|
+
0, 24, 0, 0, 0, 0, 0, 0,
|
1060
997
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1061
|
-
0, 0
|
998
|
+
0, 0, 0, 0
|
1062
999
|
]
|
1063
1000
|
|
1064
1001
|
class << self
|
@@ -1066,26 +1003,26 @@ class << self
|
|
1066
1003
|
private :_re_scanner_eof_trans, :_re_scanner_eof_trans=
|
1067
1004
|
end
|
1068
1005
|
self._re_scanner_eof_trans = [
|
1069
|
-
0, 1, 1, 1,
|
1070
|
-
|
1071
|
-
|
1072
|
-
|
1073
|
-
|
1074
|
-
|
1075
|
-
|
1076
|
-
|
1077
|
-
|
1078
|
-
|
1079
|
-
|
1006
|
+
0, 1, 1, 1, 5, 5, 5, 5,
|
1007
|
+
1, 12, 12, 12, 12, 12, 12, 12,
|
1008
|
+
12, 12, 12, 12, 12, 12, 26, 26,
|
1009
|
+
26, 0, 0, 0, 0, 35, 35, 38,
|
1010
|
+
40, 40, 40, 40, 40, 40, 40, 40,
|
1011
|
+
40, 40, 40, 40, 40, 40, 40, 40,
|
1012
|
+
40, 40, 40, 40, 40, 40, 40, 40,
|
1013
|
+
40, 40, 40, 40, 40, 40, 40, 40,
|
1014
|
+
40, 40, 40, 40, 40, 40, 40, 40,
|
1015
|
+
40, 40, 40, 40, 40, 40, 40, 40,
|
1016
|
+
40, 40, 40, 40, 40, 40, 96, 96,
|
1080
1017
|
0, 0, 102, 0, 0, 107, 0, 0,
|
1081
1018
|
0, 0, 0, 0, 0, 0, 0, 0,
|
1082
|
-
0, 0, 122, 122, 122, 122, 0,
|
1083
|
-
|
1084
|
-
|
1085
|
-
0, 0,
|
1086
|
-
|
1087
|
-
|
1088
|
-
|
1019
|
+
0, 0, 122, 122, 122, 122, 0, 147,
|
1020
|
+
147, 148, 148, 147, 149, 151, 153, 153,
|
1021
|
+
160, 161, 163, 165, 167, 171, 173, 0,
|
1022
|
+
0, 0, 187, 187, 187, 187, 190, 193,
|
1023
|
+
0, 0, 214, 214, 214, 216, 218, 220,
|
1024
|
+
220, 220, 224, 224, 224, 224, 229, 0,
|
1025
|
+
236, 236, 236, 236
|
1089
1026
|
]
|
1090
1027
|
|
1091
1028
|
class << self
|
@@ -1104,36 +1041,36 @@ self.re_scanner_error = 0;
|
|
1104
1041
|
class << self
|
1105
1042
|
attr_accessor :re_scanner_en_char_type
|
1106
1043
|
end
|
1107
|
-
self.re_scanner_en_char_type =
|
1044
|
+
self.re_scanner_en_char_type = 127;
|
1108
1045
|
class << self
|
1109
1046
|
attr_accessor :re_scanner_en_unicode_property
|
1110
1047
|
end
|
1111
|
-
self.re_scanner_en_unicode_property =
|
1048
|
+
self.re_scanner_en_unicode_property = 128;
|
1112
1049
|
class << self
|
1113
1050
|
attr_accessor :re_scanner_en_character_set
|
1114
1051
|
end
|
1115
|
-
self.re_scanner_en_character_set =
|
1052
|
+
self.re_scanner_en_character_set = 129;
|
1116
1053
|
class << self
|
1117
1054
|
attr_accessor :re_scanner_en_set_escape_sequence
|
1118
1055
|
end
|
1119
|
-
self.re_scanner_en_set_escape_sequence =
|
1056
|
+
self.re_scanner_en_set_escape_sequence = 136;
|
1120
1057
|
class << self
|
1121
1058
|
attr_accessor :re_scanner_en_escape_sequence
|
1122
1059
|
end
|
1123
|
-
self.re_scanner_en_escape_sequence =
|
1060
|
+
self.re_scanner_en_escape_sequence = 137;
|
1124
1061
|
class << self
|
1125
1062
|
attr_accessor :re_scanner_en_conditional_expression
|
1126
1063
|
end
|
1127
|
-
self.re_scanner_en_conditional_expression =
|
1064
|
+
self.re_scanner_en_conditional_expression = 151;
|
1128
1065
|
class << self
|
1129
1066
|
attr_accessor :re_scanner_en_main
|
1130
1067
|
end
|
1131
1068
|
self.re_scanner_en_main = 110;
|
1132
1069
|
|
1133
1070
|
|
1134
|
-
# line
|
1071
|
+
# line 761 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1135
1072
|
|
1136
|
-
# line
|
1073
|
+
# line 1073 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner.rb"
|
1137
1074
|
begin
|
1138
1075
|
p ||= 0
|
1139
1076
|
pe ||= data.length
|
@@ -1144,9 +1081,9 @@ begin
|
|
1144
1081
|
act = 0
|
1145
1082
|
end
|
1146
1083
|
|
1147
|
-
# line
|
1084
|
+
# line 762 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1148
1085
|
|
1149
|
-
# line
|
1086
|
+
# line 1086 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner.rb"
|
1150
1087
|
begin
|
1151
1088
|
testEof = false
|
1152
1089
|
_slen, _trans, _keys, _inds, _acts, _nacts = nil
|
@@ -1169,12 +1106,12 @@ begin
|
|
1169
1106
|
end
|
1170
1107
|
if _goto_level <= _resume
|
1171
1108
|
case _re_scanner_from_state_actions[cs]
|
1172
|
-
when
|
1109
|
+
when 34 then
|
1173
1110
|
# line 1 "NONE"
|
1174
1111
|
begin
|
1175
1112
|
ts = p
|
1176
1113
|
end
|
1177
|
-
# line
|
1114
|
+
# line 1114 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner.rb"
|
1178
1115
|
end
|
1179
1116
|
_keys = cs << 1
|
1180
1117
|
_inds = _re_scanner_index_offsets[cs]
|
@@ -1193,35 +1130,35 @@ ts = p
|
|
1193
1130
|
cs = _re_scanner_trans_targs[_trans]
|
1194
1131
|
if _re_scanner_trans_actions[_trans] != 0
|
1195
1132
|
case _re_scanner_trans_actions[_trans]
|
1196
|
-
when
|
1197
|
-
# line
|
1133
|
+
when 36 then
|
1134
|
+
# line 151 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1198
1135
|
begin
|
1199
1136
|
self.group_depth = group_depth + 1 end
|
1200
1137
|
when 4 then
|
1201
|
-
# line
|
1138
|
+
# line 152 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1202
1139
|
begin
|
1203
1140
|
self.group_depth = group_depth - 1 end
|
1204
|
-
when
|
1141
|
+
when 40 then
|
1205
1142
|
# line 1 "NONE"
|
1206
1143
|
begin
|
1207
1144
|
te = p+1
|
1208
1145
|
end
|
1209
|
-
when
|
1146
|
+
when 68 then
|
1210
1147
|
# line 12 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/char_type.rl"
|
1211
1148
|
begin
|
1212
1149
|
te = p+1
|
1213
1150
|
begin
|
1214
|
-
case text =
|
1215
|
-
when '\d'; emit(:type, :digit, text
|
1216
|
-
when '\D'; emit(:type, :nondigit, text
|
1217
|
-
when '\h'; emit(:type, :hex, text
|
1218
|
-
when '\H'; emit(:type, :nonhex, text
|
1219
|
-
when '\s'; emit(:type, :space, text
|
1220
|
-
when '\S'; emit(:type, :nonspace, text
|
1221
|
-
when '\w'; emit(:type, :word, text
|
1222
|
-
when '\W'; emit(:type, :nonword, text
|
1223
|
-
when '\R'; emit(:type, :linebreak, text
|
1224
|
-
when '\X'; emit(:type, :xgrapheme, text
|
1151
|
+
case text = copy(data, ts-1, te)
|
1152
|
+
when '\d'; emit(:type, :digit, text)
|
1153
|
+
when '\D'; emit(:type, :nondigit, text)
|
1154
|
+
when '\h'; emit(:type, :hex, text)
|
1155
|
+
when '\H'; emit(:type, :nonhex, text)
|
1156
|
+
when '\s'; emit(:type, :space, text)
|
1157
|
+
when '\S'; emit(:type, :nonspace, text)
|
1158
|
+
when '\w'; emit(:type, :word, text)
|
1159
|
+
when '\W'; emit(:type, :nonword, text)
|
1160
|
+
when '\R'; emit(:type, :linebreak, text)
|
1161
|
+
when '\X'; emit(:type, :xgrapheme, text)
|
1225
1162
|
end
|
1226
1163
|
begin
|
1227
1164
|
top -= 1
|
@@ -1237,7 +1174,7 @@ te = p+1
|
|
1237
1174
|
begin
|
1238
1175
|
te = p+1
|
1239
1176
|
begin
|
1240
|
-
text =
|
1177
|
+
text = copy(data, ts-1, te)
|
1241
1178
|
type = (text[1] == 'P') ^ (text[3] == '^') ? :nonproperty : :property
|
1242
1179
|
|
1243
1180
|
name = data[ts+2..te-2].pack('c*').gsub(/[\^\s_\-]/, '').downcase
|
@@ -1245,7 +1182,7 @@ te = p+1
|
|
1245
1182
|
token = self.class.short_prop_map[name] || self.class.long_prop_map[name]
|
1246
1183
|
raise UnknownUnicodePropertyError.new(name) unless token
|
1247
1184
|
|
1248
|
-
self.emit(type, token.to_sym, text
|
1185
|
+
self.emit(type, token.to_sym, text)
|
1249
1186
|
|
1250
1187
|
begin
|
1251
1188
|
top -= 1
|
@@ -1257,132 +1194,130 @@ te = p+1
|
|
1257
1194
|
end
|
1258
1195
|
end
|
1259
1196
|
when 16 then
|
1260
|
-
# line
|
1197
|
+
# line 179 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1261
1198
|
begin
|
1262
1199
|
te = p+1
|
1263
1200
|
begin # special case, emits two tokens
|
1264
|
-
emit(:literal, :literal, '-'
|
1265
|
-
emit(:set, :intersection, '&&'
|
1201
|
+
emit(:literal, :literal, '-')
|
1202
|
+
emit(:set, :intersection, '&&')
|
1266
1203
|
end
|
1267
1204
|
end
|
1268
|
-
when
|
1269
|
-
# line
|
1205
|
+
when 73 then
|
1206
|
+
# line 184 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1270
1207
|
begin
|
1271
1208
|
te = p+1
|
1272
1209
|
begin
|
1273
|
-
text =
|
1210
|
+
text = copy(data, ts, te)
|
1274
1211
|
if tokens.last[1] == :open
|
1275
|
-
emit(:set, :negate, text
|
1212
|
+
emit(:set, :negate, text)
|
1276
1213
|
else
|
1277
|
-
emit(:literal, :literal, text
|
1214
|
+
emit(:literal, :literal, text)
|
1278
1215
|
end
|
1279
1216
|
end
|
1280
1217
|
end
|
1281
|
-
when
|
1282
|
-
# line
|
1218
|
+
when 75 then
|
1219
|
+
# line 205 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1283
1220
|
begin
|
1284
1221
|
te = p+1
|
1285
1222
|
begin
|
1286
|
-
emit(:set, :intersection,
|
1223
|
+
emit(:set, :intersection, copy(data, ts, te))
|
1287
1224
|
end
|
1288
1225
|
end
|
1289
|
-
when
|
1290
|
-
# line
|
1226
|
+
when 71 then
|
1227
|
+
# line 209 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1291
1228
|
begin
|
1292
1229
|
te = p+1
|
1293
1230
|
begin
|
1294
1231
|
begin
|
1295
1232
|
stack[top] = cs
|
1296
1233
|
top+= 1
|
1297
|
-
cs =
|
1234
|
+
cs = 136
|
1298
1235
|
_goto_level = _again
|
1299
1236
|
next
|
1300
1237
|
end
|
1301
1238
|
|
1302
1239
|
end
|
1303
1240
|
end
|
1304
|
-
when
|
1305
|
-
# line
|
1241
|
+
when 69 then
|
1242
|
+
# line 239 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1306
1243
|
begin
|
1307
1244
|
te = p+1
|
1308
1245
|
begin
|
1309
|
-
emit(:literal, :literal,
|
1246
|
+
emit(:literal, :literal, copy(data, ts, te))
|
1310
1247
|
end
|
1311
1248
|
end
|
1312
1249
|
when 14 then
|
1313
|
-
# line
|
1250
|
+
# line 243 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1314
1251
|
begin
|
1315
1252
|
te = p+1
|
1316
1253
|
begin
|
1317
|
-
|
1318
|
-
|
1319
|
-
emit(:literal, :literal, char, *rest)
|
1254
|
+
text = copy(data, ts, te)
|
1255
|
+
emit(:literal, :literal, text)
|
1320
1256
|
end
|
1321
1257
|
end
|
1322
|
-
when
|
1323
|
-
# line
|
1258
|
+
when 76 then
|
1259
|
+
# line 193 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1324
1260
|
begin
|
1325
1261
|
te = p
|
1326
1262
|
p = p - 1; begin
|
1327
|
-
text =
|
1263
|
+
text = copy(data, ts, te)
|
1328
1264
|
# ranges cant start with a subset or intersection/negation/range operator
|
1329
1265
|
if tokens.last[0] == :set
|
1330
|
-
emit(:literal, :literal, text
|
1266
|
+
emit(:literal, :literal, text)
|
1331
1267
|
else
|
1332
|
-
emit(:set, :range, text
|
1268
|
+
emit(:set, :range, text)
|
1333
1269
|
end
|
1334
1270
|
end
|
1335
1271
|
end
|
1336
|
-
when
|
1337
|
-
# line
|
1272
|
+
when 79 then
|
1273
|
+
# line 213 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1338
1274
|
begin
|
1339
1275
|
te = p
|
1340
1276
|
p = p - 1; begin
|
1341
|
-
emit(:set, :open,
|
1277
|
+
emit(:set, :open, copy(data, ts, te))
|
1342
1278
|
begin
|
1343
1279
|
stack[top] = cs
|
1344
1280
|
top+= 1
|
1345
|
-
cs =
|
1281
|
+
cs = 129
|
1346
1282
|
_goto_level = _again
|
1347
1283
|
next
|
1348
1284
|
end
|
1349
1285
|
|
1350
1286
|
end
|
1351
1287
|
end
|
1352
|
-
when
|
1353
|
-
# line
|
1288
|
+
when 74 then
|
1289
|
+
# line 243 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1354
1290
|
begin
|
1355
1291
|
te = p
|
1356
1292
|
p = p - 1; begin
|
1357
|
-
|
1358
|
-
|
1359
|
-
emit(:literal, :literal, char, *rest)
|
1293
|
+
text = copy(data, ts, te)
|
1294
|
+
emit(:literal, :literal, text)
|
1360
1295
|
end
|
1361
1296
|
end
|
1362
1297
|
when 15 then
|
1363
|
-
# line
|
1298
|
+
# line 193 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1364
1299
|
begin
|
1365
1300
|
begin p = ((te))-1; end
|
1366
1301
|
begin
|
1367
|
-
text =
|
1302
|
+
text = copy(data, ts, te)
|
1368
1303
|
# ranges cant start with a subset or intersection/negation/range operator
|
1369
1304
|
if tokens.last[0] == :set
|
1370
|
-
emit(:literal, :literal, text
|
1305
|
+
emit(:literal, :literal, text)
|
1371
1306
|
else
|
1372
|
-
emit(:set, :range, text
|
1307
|
+
emit(:set, :range, text)
|
1373
1308
|
end
|
1374
1309
|
end
|
1375
1310
|
end
|
1376
1311
|
when 18 then
|
1377
|
-
# line
|
1312
|
+
# line 213 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1378
1313
|
begin
|
1379
1314
|
begin p = ((te))-1; end
|
1380
1315
|
begin
|
1381
|
-
emit(:set, :open,
|
1316
|
+
emit(:set, :open, copy(data, ts, te))
|
1382
1317
|
begin
|
1383
1318
|
stack[top] = cs
|
1384
1319
|
top+= 1
|
1385
|
-
cs =
|
1320
|
+
cs = 129
|
1386
1321
|
_goto_level = _again
|
1387
1322
|
next
|
1388
1323
|
end
|
@@ -1390,21 +1325,20 @@ p = p - 1; begin
|
|
1390
1325
|
end
|
1391
1326
|
end
|
1392
1327
|
when 13 then
|
1393
|
-
# line
|
1328
|
+
# line 243 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1394
1329
|
begin
|
1395
1330
|
begin p = ((te))-1; end
|
1396
1331
|
begin
|
1397
|
-
|
1398
|
-
|
1399
|
-
emit(:literal, :literal, char, *rest)
|
1332
|
+
text = copy(data, ts, te)
|
1333
|
+
emit(:literal, :literal, text)
|
1400
1334
|
end
|
1401
1335
|
end
|
1402
|
-
when
|
1403
|
-
# line
|
1336
|
+
when 81 then
|
1337
|
+
# line 252 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1404
1338
|
begin
|
1405
1339
|
te = p+1
|
1406
1340
|
begin
|
1407
|
-
emit(:escape, :literal,
|
1341
|
+
emit(:escape, :literal, copy(data, ts-1, te))
|
1408
1342
|
begin
|
1409
1343
|
top -= 1
|
1410
1344
|
cs = stack[top]
|
@@ -1414,30 +1348,30 @@ te = p+1
|
|
1414
1348
|
|
1415
1349
|
end
|
1416
1350
|
end
|
1417
|
-
when
|
1418
|
-
# line
|
1351
|
+
when 80 then
|
1352
|
+
# line 257 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1419
1353
|
begin
|
1420
1354
|
te = p+1
|
1421
1355
|
begin
|
1422
1356
|
p = p - 1;
|
1423
|
-
cs =
|
1357
|
+
cs = 129;
|
1424
1358
|
begin
|
1425
1359
|
stack[top] = cs
|
1426
1360
|
top+= 1
|
1427
|
-
cs =
|
1361
|
+
cs = 137
|
1428
1362
|
_goto_level = _again
|
1429
1363
|
next
|
1430
1364
|
end
|
1431
1365
|
|
1432
1366
|
end
|
1433
1367
|
end
|
1434
|
-
when
|
1435
|
-
# line
|
1368
|
+
when 85 then
|
1369
|
+
# line 268 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1436
1370
|
begin
|
1437
1371
|
te = p+1
|
1438
1372
|
begin
|
1439
|
-
text =
|
1440
|
-
emit(:backref, :number, text
|
1373
|
+
text = copy(data, ts-1, te)
|
1374
|
+
emit(:backref, :number, text)
|
1441
1375
|
begin
|
1442
1376
|
top -= 1
|
1443
1377
|
cs = stack[top]
|
@@ -1447,12 +1381,12 @@ te = p+1
|
|
1447
1381
|
|
1448
1382
|
end
|
1449
1383
|
end
|
1450
|
-
when
|
1451
|
-
# line
|
1384
|
+
when 92 then
|
1385
|
+
# line 274 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1452
1386
|
begin
|
1453
1387
|
te = p+1
|
1454
1388
|
begin
|
1455
|
-
emit(:escape, :octal,
|
1389
|
+
emit(:escape, :octal, copy(data, ts-1, te))
|
1456
1390
|
begin
|
1457
1391
|
top -= 1
|
1458
1392
|
cs = stack[top]
|
@@ -1462,27 +1396,27 @@ te = p+1
|
|
1462
1396
|
|
1463
1397
|
end
|
1464
1398
|
end
|
1465
|
-
when
|
1466
|
-
# line
|
1399
|
+
when 82 then
|
1400
|
+
# line 279 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1467
1401
|
begin
|
1468
1402
|
te = p+1
|
1469
1403
|
begin
|
1470
|
-
case text =
|
1471
|
-
when '\.'; emit(:escape, :dot, text
|
1472
|
-
when '\|'; emit(:escape, :alternation, text
|
1473
|
-
when '\^'; emit(:escape, :bol, text
|
1474
|
-
when '\$'; emit(:escape, :eol, text
|
1475
|
-
when '\?'; emit(:escape, :zero_or_one, text
|
1476
|
-
when '\*'; emit(:escape, :zero_or_more, text
|
1477
|
-
when '\+'; emit(:escape, :one_or_more, text
|
1478
|
-
when '\('; emit(:escape, :group_open, text
|
1479
|
-
when '\)'; emit(:escape, :group_close, text
|
1480
|
-
when '\{'; emit(:escape, :interval_open, text
|
1481
|
-
when '\}'; emit(:escape, :interval_close, text
|
1482
|
-
when '\['; emit(:escape, :set_open, text
|
1483
|
-
when '\]'; emit(:escape, :set_close, text
|
1404
|
+
case text = copy(data, ts-1, te)
|
1405
|
+
when '\.'; emit(:escape, :dot, text)
|
1406
|
+
when '\|'; emit(:escape, :alternation, text)
|
1407
|
+
when '\^'; emit(:escape, :bol, text)
|
1408
|
+
when '\$'; emit(:escape, :eol, text)
|
1409
|
+
when '\?'; emit(:escape, :zero_or_one, text)
|
1410
|
+
when '\*'; emit(:escape, :zero_or_more, text)
|
1411
|
+
when '\+'; emit(:escape, :one_or_more, text)
|
1412
|
+
when '\('; emit(:escape, :group_open, text)
|
1413
|
+
when '\)'; emit(:escape, :group_close, text)
|
1414
|
+
when '\{'; emit(:escape, :interval_open, text)
|
1415
|
+
when '\}'; emit(:escape, :interval_close, text)
|
1416
|
+
when '\['; emit(:escape, :set_open, text)
|
1417
|
+
when '\]'; emit(:escape, :set_close, text)
|
1484
1418
|
when "\\\\";
|
1485
|
-
emit(:escape, :backslash, text
|
1419
|
+
emit(:escape, :backslash, text)
|
1486
1420
|
end
|
1487
1421
|
begin
|
1488
1422
|
top -= 1
|
@@ -1493,22 +1427,22 @@ te = p+1
|
|
1493
1427
|
|
1494
1428
|
end
|
1495
1429
|
end
|
1496
|
-
when
|
1497
|
-
# line
|
1430
|
+
when 88 then
|
1431
|
+
# line 300 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1498
1432
|
begin
|
1499
1433
|
te = p+1
|
1500
1434
|
begin
|
1501
1435
|
# \b is emitted as backspace only when inside a character set, otherwise
|
1502
1436
|
# it is a word boundary anchor. A syntax might "normalize" it if needed.
|
1503
|
-
case text =
|
1504
|
-
when '\a'; emit(:escape, :bell, text
|
1505
|
-
when '\b'; emit(:escape, :backspace, text
|
1506
|
-
when '\e'; emit(:escape, :escape, text
|
1507
|
-
when '\f'; emit(:escape, :form_feed, text
|
1508
|
-
when '\n'; emit(:escape, :newline, text
|
1509
|
-
when '\r'; emit(:escape, :carriage, text
|
1510
|
-
when '\t'; emit(:escape, :tab, text
|
1511
|
-
when '\v'; emit(:escape, :vertical_tab, text
|
1437
|
+
case text = copy(data, ts-1, te)
|
1438
|
+
when '\a'; emit(:escape, :bell, text)
|
1439
|
+
when '\b'; emit(:escape, :backspace, text)
|
1440
|
+
when '\e'; emit(:escape, :escape, text)
|
1441
|
+
when '\f'; emit(:escape, :form_feed, text)
|
1442
|
+
when '\n'; emit(:escape, :newline, text)
|
1443
|
+
when '\r'; emit(:escape, :carriage, text)
|
1444
|
+
when '\t'; emit(:escape, :tab, text)
|
1445
|
+
when '\v'; emit(:escape, :vertical_tab, text)
|
1512
1446
|
end
|
1513
1447
|
begin
|
1514
1448
|
top -= 1
|
@@ -1519,16 +1453,16 @@ te = p+1
|
|
1519
1453
|
|
1520
1454
|
end
|
1521
1455
|
end
|
1522
|
-
when
|
1523
|
-
# line
|
1456
|
+
when 29 then
|
1457
|
+
# line 316 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1524
1458
|
begin
|
1525
1459
|
te = p+1
|
1526
1460
|
begin
|
1527
|
-
text =
|
1461
|
+
text = copy(data, ts-1, te)
|
1528
1462
|
if text[2].chr == '{'
|
1529
|
-
emit(:escape, :codepoint_list, text
|
1463
|
+
emit(:escape, :codepoint_list, text)
|
1530
1464
|
else
|
1531
|
-
emit(:escape, :codepoint, text
|
1465
|
+
emit(:escape, :codepoint, text)
|
1532
1466
|
end
|
1533
1467
|
begin
|
1534
1468
|
top -= 1
|
@@ -1539,12 +1473,12 @@ te = p+1
|
|
1539
1473
|
|
1540
1474
|
end
|
1541
1475
|
end
|
1542
|
-
when
|
1543
|
-
# line
|
1476
|
+
when 98 then
|
1477
|
+
# line 326 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1544
1478
|
begin
|
1545
1479
|
te = p+1
|
1546
1480
|
begin
|
1547
|
-
emit(:escape, :hex,
|
1481
|
+
emit(:escape, :hex, copy(data, ts-1, te))
|
1548
1482
|
begin
|
1549
1483
|
top -= 1
|
1550
1484
|
cs = stack[top]
|
@@ -1554,8 +1488,8 @@ te = p+1
|
|
1554
1488
|
|
1555
1489
|
end
|
1556
1490
|
end
|
1557
|
-
when
|
1558
|
-
# line
|
1491
|
+
when 25 then
|
1492
|
+
# line 335 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1559
1493
|
begin
|
1560
1494
|
te = p+1
|
1561
1495
|
begin
|
@@ -1569,8 +1503,8 @@ te = p+1
|
|
1569
1503
|
|
1570
1504
|
end
|
1571
1505
|
end
|
1572
|
-
when
|
1573
|
-
# line
|
1506
|
+
when 27 then
|
1507
|
+
# line 340 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1574
1508
|
begin
|
1575
1509
|
te = p+1
|
1576
1510
|
begin
|
@@ -1584,46 +1518,46 @@ te = p+1
|
|
1584
1518
|
|
1585
1519
|
end
|
1586
1520
|
end
|
1587
|
-
when
|
1588
|
-
# line
|
1521
|
+
when 86 then
|
1522
|
+
# line 345 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1589
1523
|
begin
|
1590
1524
|
te = p+1
|
1591
1525
|
begin
|
1592
1526
|
p = p - 1;
|
1593
|
-
cs = ((in_set? ?
|
1527
|
+
cs = ((in_set? ? 129 : 110));
|
1594
1528
|
begin
|
1595
1529
|
stack[top] = cs
|
1596
1530
|
top+= 1
|
1597
|
-
cs =
|
1531
|
+
cs = 127
|
1598
1532
|
_goto_level = _again
|
1599
1533
|
next
|
1600
1534
|
end
|
1601
1535
|
|
1602
1536
|
end
|
1603
1537
|
end
|
1604
|
-
when
|
1605
|
-
# line
|
1538
|
+
when 87 then
|
1539
|
+
# line 351 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1606
1540
|
begin
|
1607
1541
|
te = p+1
|
1608
1542
|
begin
|
1609
1543
|
p = p - 1;
|
1610
|
-
cs = ((in_set? ?
|
1544
|
+
cs = ((in_set? ? 129 : 110));
|
1611
1545
|
begin
|
1612
1546
|
stack[top] = cs
|
1613
1547
|
top+= 1
|
1614
|
-
cs =
|
1548
|
+
cs = 128
|
1615
1549
|
_goto_level = _again
|
1616
1550
|
next
|
1617
1551
|
end
|
1618
1552
|
|
1619
1553
|
end
|
1620
1554
|
end
|
1621
|
-
when
|
1622
|
-
# line
|
1555
|
+
when 23 then
|
1556
|
+
# line 357 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1623
1557
|
begin
|
1624
1558
|
te = p+1
|
1625
1559
|
begin
|
1626
|
-
emit(:escape, :literal,
|
1560
|
+
emit(:escape, :literal, copy(data, ts-1, te))
|
1627
1561
|
begin
|
1628
1562
|
top -= 1
|
1629
1563
|
cs = stack[top]
|
@@ -1633,12 +1567,12 @@ te = p+1
|
|
1633
1567
|
|
1634
1568
|
end
|
1635
1569
|
end
|
1636
|
-
when
|
1637
|
-
# line
|
1570
|
+
when 91 then
|
1571
|
+
# line 274 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1638
1572
|
begin
|
1639
1573
|
te = p
|
1640
1574
|
p = p - 1; begin
|
1641
|
-
emit(:escape, :octal,
|
1575
|
+
emit(:escape, :octal, copy(data, ts-1, te))
|
1642
1576
|
begin
|
1643
1577
|
top -= 1
|
1644
1578
|
cs = stack[top]
|
@@ -1648,12 +1582,12 @@ p = p - 1; begin
|
|
1648
1582
|
|
1649
1583
|
end
|
1650
1584
|
end
|
1651
|
-
when
|
1652
|
-
# line
|
1585
|
+
when 97 then
|
1586
|
+
# line 326 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1653
1587
|
begin
|
1654
1588
|
te = p
|
1655
1589
|
p = p - 1; begin
|
1656
|
-
emit(:escape, :hex,
|
1590
|
+
emit(:escape, :hex, copy(data, ts-1, te))
|
1657
1591
|
begin
|
1658
1592
|
top -= 1
|
1659
1593
|
cs = stack[top]
|
@@ -1663,8 +1597,8 @@ p = p - 1; begin
|
|
1663
1597
|
|
1664
1598
|
end
|
1665
1599
|
end
|
1666
|
-
when
|
1667
|
-
# line
|
1600
|
+
when 94 then
|
1601
|
+
# line 335 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1668
1602
|
begin
|
1669
1603
|
te = p
|
1670
1604
|
p = p - 1; begin
|
@@ -1678,8 +1612,8 @@ p = p - 1; begin
|
|
1678
1612
|
|
1679
1613
|
end
|
1680
1614
|
end
|
1681
|
-
when
|
1682
|
-
# line
|
1615
|
+
when 96 then
|
1616
|
+
# line 340 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1683
1617
|
begin
|
1684
1618
|
te = p
|
1685
1619
|
p = p - 1; begin
|
@@ -1693,15 +1627,45 @@ p = p - 1; begin
|
|
1693
1627
|
|
1694
1628
|
end
|
1695
1629
|
end
|
1696
|
-
when
|
1630
|
+
when 89 then
|
1631
|
+
# line 357 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1632
|
+
begin
|
1633
|
+
te = p
|
1634
|
+
p = p - 1; begin
|
1635
|
+
emit(:escape, :literal, copy(data, ts-1, te))
|
1636
|
+
begin
|
1637
|
+
top -= 1
|
1638
|
+
cs = stack[top]
|
1639
|
+
_goto_level = _again
|
1640
|
+
next
|
1641
|
+
end
|
1642
|
+
|
1643
|
+
end
|
1644
|
+
end
|
1645
|
+
when 22 then
|
1646
|
+
# line 357 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1647
|
+
begin
|
1648
|
+
begin p = ((te))-1; end
|
1649
|
+
begin
|
1650
|
+
emit(:escape, :literal, copy(data, ts-1, te))
|
1651
|
+
begin
|
1652
|
+
top -= 1
|
1653
|
+
cs = stack[top]
|
1654
|
+
_goto_level = _again
|
1655
|
+
next
|
1656
|
+
end
|
1657
|
+
|
1658
|
+
end
|
1659
|
+
end
|
1660
|
+
when 90 then
|
1697
1661
|
# line 1 "NONE"
|
1698
1662
|
begin
|
1699
1663
|
case act
|
1700
1664
|
when 18 then
|
1701
1665
|
begin begin p = ((te))-1; end
|
1702
1666
|
|
1703
|
-
text =
|
1704
|
-
emit(:backref, :number, text
|
1667
|
+
text = copy(data, ts-1, te)
|
1668
|
+
emit(:backref, :number, text)
|
1705
1669
|
begin
|
1706
1670
|
top -= 1
|
1707
1671
|
cs = stack[top]
|
@@ -1713,7 +1677,7 @@ p = p - 1; begin
|
|
1713
1677
|
when 19 then
|
1714
1678
|
begin begin p = ((te))-1; end
|
1715
1679
|
|
1716
|
-
emit(:escape, :octal,
|
1680
|
+
emit(:escape, :octal, copy(data, ts-1, te))
|
1717
1681
|
begin
|
1718
1682
|
top -= 1
|
1719
1683
|
cs = stack[top]
|
@@ -1724,18 +1688,18 @@ p = p - 1; begin
|
|
1724
1688
|
end
|
1725
1689
|
end
|
1726
1690
|
end
|
1727
|
-
when
|
1728
|
-
# line
|
1691
|
+
when 32 then
|
1692
|
+
# line 367 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1729
1693
|
begin
|
1730
1694
|
te = p+1
|
1731
1695
|
begin
|
1732
|
-
text =
|
1733
|
-
emit(:conditional, :condition, text
|
1734
|
-
emit(:conditional, :condition_close, ')'
|
1696
|
+
text = copy(data, ts, te-1)
|
1697
|
+
emit(:conditional, :condition, text)
|
1698
|
+
emit(:conditional, :condition_close, ')')
|
1735
1699
|
end
|
1736
1700
|
end
|
1737
|
-
when
|
1738
|
-
# line
|
1701
|
+
when 99 then
|
1702
|
+
# line 373 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1739
1703
|
begin
|
1740
1704
|
te = p+1
|
1741
1705
|
begin
|
@@ -1750,8 +1714,8 @@ te = p+1
|
|
1750
1714
|
|
1751
1715
|
end
|
1752
1716
|
end
|
1753
|
-
when
|
1754
|
-
# line
|
1717
|
+
when 100 then
|
1718
|
+
# line 373 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1755
1719
|
begin
|
1756
1720
|
te = p
|
1757
1721
|
p = p - 1; begin
|
@@ -1766,8 +1730,8 @@ p = p - 1; begin
|
|
1766
1730
|
|
1767
1731
|
end
|
1768
1732
|
end
|
1769
|
-
when
|
1770
|
-
# line
|
1733
|
+
when 31 then
|
1734
|
+
# line 373 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1771
1735
|
begin
|
1772
1736
|
begin p = ((te))-1; end
|
1773
1737
|
begin
|
@@ -1782,377 +1746,398 @@ p = p - 1; begin
|
|
1782
1746
|
|
1783
1747
|
end
|
1784
1748
|
end
|
1785
|
-
when
|
1786
|
-
# line
|
1749
|
+
when 38 then
|
1750
|
+
# line 386 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1787
1751
|
begin
|
1788
1752
|
te = p+1
|
1789
1753
|
begin
|
1790
|
-
emit(:meta, :dot,
|
1754
|
+
emit(:meta, :dot, copy(data, ts, te))
|
1791
1755
|
end
|
1792
1756
|
end
|
1793
|
-
when
|
1794
|
-
# line
|
1757
|
+
when 43 then
|
1758
|
+
# line 390 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1795
1759
|
begin
|
1796
1760
|
te = p+1
|
1797
1761
|
begin
|
1798
1762
|
if conditional_stack.last == group_depth
|
1799
|
-
emit(:conditional, :separator,
|
1763
|
+
emit(:conditional, :separator, copy(data, ts, te))
|
1800
1764
|
else
|
1801
|
-
emit(:meta, :alternation,
|
1765
|
+
emit(:meta, :alternation, copy(data, ts, te))
|
1802
1766
|
end
|
1803
1767
|
end
|
1804
1768
|
end
|
1805
|
-
when
|
1806
|
-
# line
|
1769
|
+
when 42 then
|
1770
|
+
# line 400 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1807
1771
|
begin
|
1808
1772
|
te = p+1
|
1809
1773
|
begin
|
1810
|
-
emit(:anchor, :bol,
|
1774
|
+
emit(:anchor, :bol, copy(data, ts, te))
|
1811
1775
|
end
|
1812
1776
|
end
|
1813
|
-
when
|
1814
|
-
# line
|
1777
|
+
when 35 then
|
1778
|
+
# line 404 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1815
1779
|
begin
|
1816
1780
|
te = p+1
|
1817
1781
|
begin
|
1818
|
-
emit(:anchor, :eol,
|
1782
|
+
emit(:anchor, :eol, copy(data, ts, te))
|
1819
1783
|
end
|
1820
1784
|
end
|
1821
|
-
when
|
1822
|
-
# line
|
1785
|
+
when 63 then
|
1786
|
+
# line 408 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1823
1787
|
begin
|
1824
1788
|
te = p+1
|
1825
1789
|
begin
|
1826
|
-
emit(:keep, :mark,
|
1790
|
+
emit(:keep, :mark, copy(data, ts, te))
|
1827
1791
|
end
|
1828
1792
|
end
|
1829
|
-
when
|
1830
|
-
# line
|
1793
|
+
when 62 then
|
1794
|
+
# line 412 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1831
1795
|
begin
|
1832
1796
|
te = p+1
|
1833
1797
|
begin
|
1834
|
-
case text =
|
1835
|
-
when '\\A'; emit(:anchor, :bos, text
|
1836
|
-
when '\\z'; emit(:anchor, :eos, text
|
1837
|
-
when '\\Z'; emit(:anchor, :eos_ob_eol, text
|
1838
|
-
when '\\b'; emit(:anchor, :word_boundary, text
|
1839
|
-
when '\\B'; emit(:anchor, :nonword_boundary, text
|
1840
|
-
when '\\G'; emit(:anchor, :match_start, text
|
1798
|
+
case text = copy(data, ts, te)
|
1799
|
+
when '\\A'; emit(:anchor, :bos, text)
|
1800
|
+
when '\\z'; emit(:anchor, :eos, text)
|
1801
|
+
when '\\Z'; emit(:anchor, :eos_ob_eol, text)
|
1802
|
+
when '\\b'; emit(:anchor, :word_boundary, text)
|
1803
|
+
when '\\B'; emit(:anchor, :nonword_boundary, text)
|
1804
|
+
when '\\G'; emit(:anchor, :match_start, text)
|
1841
1805
|
end
|
1842
1806
|
end
|
1843
1807
|
end
|
1844
|
-
when
|
1845
|
-
# line
|
1808
|
+
when 41 then
|
1809
|
+
# line 423 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1846
1810
|
begin
|
1847
1811
|
te = p+1
|
1848
1812
|
begin
|
1849
1813
|
append_literal(data, ts, te)
|
1850
1814
|
end
|
1851
1815
|
end
|
1852
|
-
when
|
1853
|
-
# line
|
1816
|
+
when 52 then
|
1817
|
+
# line 438 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1854
1818
|
begin
|
1855
1819
|
te = p+1
|
1856
1820
|
begin
|
1857
|
-
text =
|
1821
|
+
text = copy(data, ts, te)
|
1858
1822
|
|
1859
1823
|
conditional_stack << group_depth
|
1860
1824
|
|
1861
|
-
emit(:conditional, :open, text[0..-2]
|
1862
|
-
emit(:conditional, :condition_open, '('
|
1825
|
+
emit(:conditional, :open, text[0..-2])
|
1826
|
+
emit(:conditional, :condition_open, '(')
|
1863
1827
|
begin
|
1864
1828
|
stack[top] = cs
|
1865
1829
|
top+= 1
|
1866
|
-
cs =
|
1830
|
+
cs = 151
|
1867
1831
|
_goto_level = _again
|
1868
1832
|
next
|
1869
1833
|
end
|
1870
1834
|
|
1871
1835
|
end
|
1872
1836
|
end
|
1873
|
-
when
|
1874
|
-
# line
|
1837
|
+
when 53 then
|
1838
|
+
# line 469 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1875
1839
|
begin
|
1876
1840
|
te = p+1
|
1877
1841
|
begin
|
1878
|
-
text =
|
1842
|
+
text = copy(data, ts, te)
|
1879
1843
|
if text[2..-1] =~ /([^\-mixdau:]|^$)|-.*([dau])/
|
1880
1844
|
raise InvalidGroupOption.new($1 || "-#{$2}", text)
|
1881
1845
|
end
|
1882
|
-
emit_options(text
|
1846
|
+
emit_options(text)
|
1883
1847
|
end
|
1884
1848
|
end
|
1885
|
-
when
|
1886
|
-
# line
|
1849
|
+
when 51 then
|
1850
|
+
# line 483 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1887
1851
|
begin
|
1888
1852
|
te = p+1
|
1889
1853
|
begin
|
1890
|
-
case text =
|
1891
|
-
when '(?='; emit(:assertion, :lookahead, text
|
1892
|
-
when '(?!'; emit(:assertion, :nlookahead, text
|
1893
|
-
when '(?<='; emit(:assertion, :lookbehind, text
|
1894
|
-
when '(?<!'; emit(:assertion, :nlookbehind, text
|
1854
|
+
case text = copy(data, ts, te)
|
1855
|
+
when '(?='; emit(:assertion, :lookahead, text)
|
1856
|
+
when '(?!'; emit(:assertion, :nlookahead, text)
|
1857
|
+
when '(?<='; emit(:assertion, :lookbehind, text)
|
1858
|
+
when '(?<!'; emit(:assertion, :nlookbehind, text)
|
1895
1859
|
end
|
1896
1860
|
end
|
1897
1861
|
end
|
1898
1862
|
when 6 then
|
1899
|
-
# line
|
1863
|
+
# line 500 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1900
1864
|
begin
|
1901
1865
|
te = p+1
|
1902
1866
|
begin
|
1903
|
-
case text =
|
1904
|
-
when '(?:'; emit(:group, :passive, text
|
1905
|
-
when '(?>'; emit(:group, :atomic, text
|
1906
|
-
when '(?~'; emit(:group, :absence, text
|
1867
|
+
case text = copy(data, ts, te)
|
1868
|
+
when '(?:'; emit(:group, :passive, text)
|
1869
|
+
when '(?>'; emit(:group, :atomic, text)
|
1870
|
+
when '(?~'; emit(:group, :absence, text)
|
1907
1871
|
|
1908
1872
|
when /^\(\?(?:<>|'')/
|
1909
1873
|
validation_error(:group, 'named group', 'name is empty')
|
1910
1874
|
|
1911
|
-
when /^\(
|
1912
|
-
emit(:group, :named_ab, text
|
1875
|
+
when /^\(\?<[^>]+>/
|
1876
|
+
emit(:group, :named_ab, text)
|
1913
1877
|
|
1914
|
-
when /^\(\?'
|
1915
|
-
emit(:group, :named_sq, text
|
1878
|
+
when /^\(\?'[^']+'/
|
1879
|
+
emit(:group, :named_sq, text)
|
1916
1880
|
|
1917
1881
|
end
|
1918
1882
|
end
|
1919
1883
|
end
|
1920
1884
|
when 9 then
|
1921
|
-
# line
|
1885
|
+
# line 541 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1922
1886
|
begin
|
1923
1887
|
te = p+1
|
1924
1888
|
begin
|
1925
|
-
case text =
|
1889
|
+
case text = copy(data, ts, te)
|
1926
1890
|
when /^\\([gk])(<>|'')/ # angle brackets
|
1927
1891
|
validation_error(:backref, 'ref/call', 'ref ID is empty')
|
1928
1892
|
|
1929
|
-
|
1893
|
+
# TODO: finer quirks of choosing recursive or non-recursive refs/calls.
|
1894
|
+
# e.g.: `a-1` is a valid group id: 'aa'[/(?<a-1>a)\g<a-1>/] # => 'aa'
|
1895
|
+
when /^\\([gk])<[^\p{digit}+\->][^>+\-]*>/ # angle-brackets
|
1930
1896
|
if $1 == 'k'
|
1931
|
-
emit(:backref, :name_ref_ab, text
|
1897
|
+
emit(:backref, :name_ref_ab, text)
|
1932
1898
|
else
|
1933
|
-
emit(:backref, :name_call_ab, text
|
1899
|
+
emit(:backref, :name_call_ab, text)
|
1934
1900
|
end
|
1935
1901
|
|
1936
|
-
when /^\\([gk])'[^\
|
1902
|
+
when /^\\([gk])'[^\p{digit}+\-'][^'+\-]*'/ # single quotes
|
1937
1903
|
if $1 == 'k'
|
1938
|
-
emit(:backref, :name_ref_sq, text
|
1904
|
+
emit(:backref, :name_ref_sq, text)
|
1939
1905
|
else
|
1940
|
-
emit(:backref, :name_call_sq, text
|
1906
|
+
emit(:backref, :name_call_sq, text)
|
1941
1907
|
end
|
1942
1908
|
|
1943
1909
|
when /^\\([gk])<\d+>/ # angle-brackets
|
1944
1910
|
if $1 == 'k'
|
1945
|
-
emit(:backref, :number_ref_ab, text
|
1911
|
+
emit(:backref, :number_ref_ab, text)
|
1946
1912
|
else
|
1947
|
-
emit(:backref, :number_call_ab, text
|
1913
|
+
emit(:backref, :number_call_ab, text)
|
1948
1914
|
end
|
1949
1915
|
|
1950
1916
|
when /^\\([gk])'\d+'/ # single quotes
|
1951
1917
|
if $1 == 'k'
|
1952
|
-
emit(:backref, :number_ref_sq, text
|
1918
|
+
emit(:backref, :number_ref_sq, text)
|
1953
1919
|
else
|
1954
|
-
emit(:backref, :number_call_sq, text
|
1920
|
+
emit(:backref, :number_call_sq, text)
|
1955
1921
|
end
|
1956
1922
|
|
1957
1923
|
when /^\\(?:g<\+|g<-|(k)<-)\d+>/ # angle-brackets
|
1958
1924
|
if $1 == 'k'
|
1959
|
-
emit(:backref, :number_rel_ref_ab, text
|
1925
|
+
emit(:backref, :number_rel_ref_ab, text)
|
1960
1926
|
else
|
1961
|
-
emit(:backref, :number_rel_call_ab, text
|
1927
|
+
emit(:backref, :number_rel_call_ab, text)
|
1962
1928
|
end
|
1963
1929
|
|
1964
1930
|
when /^\\(?:g'\+|g'-|(k)'-)\d+'/ # single quotes
|
1965
1931
|
if $1 == 'k'
|
1966
|
-
emit(:backref, :number_rel_ref_sq, text
|
1932
|
+
emit(:backref, :number_rel_ref_sq, text)
|
1967
1933
|
else
|
1968
|
-
emit(:backref, :number_rel_call_sq, text
|
1934
|
+
emit(:backref, :number_rel_call_sq, text)
|
1969
1935
|
end
|
1970
1936
|
|
1971
|
-
when /^\\k<[^\
|
1972
|
-
emit(:backref, :name_recursion_ref_ab, text
|
1937
|
+
when /^\\k<[^\p{digit}+\->][^>]*[+\-]\d+>/ # angle-brackets
|
1938
|
+
emit(:backref, :name_recursion_ref_ab, text)
|
1973
1939
|
|
1974
|
-
when /^\\k'[^\
|
1975
|
-
emit(:backref, :name_recursion_ref_sq, text
|
1940
|
+
when /^\\k'[^\p{digit}+\-'][^']*[+\-]\d+'/ # single-quotes
|
1941
|
+
emit(:backref, :name_recursion_ref_sq, text)
|
1976
1942
|
|
1977
1943
|
when /^\\([gk])<[+\-]?\d+[+\-]\d+>/ # angle-brackets
|
1978
|
-
emit(:backref, :number_recursion_ref_ab, text
|
1944
|
+
emit(:backref, :number_recursion_ref_ab, text)
|
1979
1945
|
|
1980
1946
|
when /^\\([gk])'[+\-]?\d+[+\-]\d+'/ # single-quotes
|
1981
|
-
emit(:backref, :number_recursion_ref_sq, text
|
1947
|
+
emit(:backref, :number_recursion_ref_sq, text)
|
1982
1948
|
|
1983
1949
|
end
|
1984
1950
|
end
|
1985
1951
|
end
|
1986
|
-
when
|
1987
|
-
# line
|
1952
|
+
when 60 then
|
1953
|
+
# line 608 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
1988
1954
|
begin
|
1989
1955
|
te = p+1
|
1990
1956
|
begin
|
1991
|
-
case text =
|
1992
|
-
when '?' ; emit(:quantifier, :zero_or_one, text
|
1993
|
-
when '??'; emit(:quantifier, :zero_or_one_reluctant, text
|
1994
|
-
when '?+'; emit(:quantifier, :zero_or_one_possessive, text
|
1957
|
+
case text = copy(data, ts, te)
|
1958
|
+
when '?' ; emit(:quantifier, :zero_or_one, text)
|
1959
|
+
when '??'; emit(:quantifier, :zero_or_one_reluctant, text)
|
1960
|
+
when '?+'; emit(:quantifier, :zero_or_one_possessive, text)
|
1995
1961
|
end
|
1996
1962
|
end
|
1997
1963
|
end
|
1998
|
-
when
|
1999
|
-
# line
|
1964
|
+
when 56 then
|
1965
|
+
# line 616 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2000
1966
|
begin
|
2001
1967
|
te = p+1
|
2002
1968
|
begin
|
2003
|
-
case text =
|
2004
|
-
when '*' ; emit(:quantifier, :zero_or_more, text
|
2005
|
-
when '*?'; emit(:quantifier, :zero_or_more_reluctant, text
|
2006
|
-
when '*+'; emit(:quantifier, :zero_or_more_possessive, text
|
1969
|
+
case text = copy(data, ts, te)
|
1970
|
+
when '*' ; emit(:quantifier, :zero_or_more, text)
|
1971
|
+
when '*?'; emit(:quantifier, :zero_or_more_reluctant, text)
|
1972
|
+
when '*+'; emit(:quantifier, :zero_or_more_possessive, text)
|
2007
1973
|
end
|
2008
1974
|
end
|
2009
1975
|
end
|
2010
|
-
when
|
2011
|
-
# line
|
1976
|
+
when 58 then
|
1977
|
+
# line 624 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2012
1978
|
begin
|
2013
1979
|
te = p+1
|
2014
1980
|
begin
|
2015
|
-
case text =
|
2016
|
-
when '+' ; emit(:quantifier, :one_or_more, text
|
2017
|
-
when '+?'; emit(:quantifier, :one_or_more_reluctant, text
|
2018
|
-
when '++'; emit(:quantifier, :one_or_more_possessive, text
|
1981
|
+
case text = copy(data, ts, te)
|
1982
|
+
when '+' ; emit(:quantifier, :one_or_more, text)
|
1983
|
+
when '+?'; emit(:quantifier, :one_or_more_reluctant, text)
|
1984
|
+
when '++'; emit(:quantifier, :one_or_more_possessive, text)
|
2019
1985
|
end
|
2020
1986
|
end
|
2021
1987
|
end
|
2022
|
-
when
|
2023
|
-
# line
|
1988
|
+
when 66 then
|
1989
|
+
# line 632 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2024
1990
|
begin
|
2025
1991
|
te = p+1
|
2026
1992
|
begin
|
2027
|
-
emit(:quantifier, :interval,
|
1993
|
+
emit(:quantifier, :interval, copy(data, ts, te))
|
2028
1994
|
end
|
2029
1995
|
end
|
2030
|
-
when
|
2031
|
-
# line
|
1996
|
+
when 47 then
|
1997
|
+
# line 647 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2032
1998
|
begin
|
2033
1999
|
te = p+1
|
2034
2000
|
begin
|
2035
2001
|
if free_spacing
|
2036
|
-
emit(:free_space, :comment,
|
2002
|
+
emit(:free_space, :comment, copy(data, ts, te))
|
2037
2003
|
else
|
2038
|
-
|
2004
|
+
# consume only the pound sign (#) and backtrack to do regular scanning
|
2005
|
+
append_literal(data, ts, ts + 1)
|
2006
|
+
begin p = (( ts + 1))-1; end
|
2007
|
+
|
2039
2008
|
end
|
2040
2009
|
end
|
2041
2010
|
end
|
2042
|
-
when
|
2043
|
-
# line
|
2011
|
+
when 50 then
|
2012
|
+
# line 469 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2044
2013
|
begin
|
2045
2014
|
te = p
|
2046
2015
|
p = p - 1; begin
|
2047
|
-
text =
|
2016
|
+
text = copy(data, ts, te)
|
2048
2017
|
if text[2..-1] =~ /([^\-mixdau:]|^$)|-.*([dau])/
|
2049
2018
|
raise InvalidGroupOption.new($1 || "-#{$2}", text)
|
2050
2019
|
end
|
2051
|
-
emit_options(text
|
2020
|
+
emit_options(text)
|
2052
2021
|
end
|
2053
2022
|
end
|
2054
|
-
when
|
2055
|
-
# line
|
2023
|
+
when 54 then
|
2024
|
+
# line 483 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2056
2025
|
begin
|
2057
2026
|
te = p
|
2058
2027
|
p = p - 1; begin
|
2059
|
-
text =
|
2060
|
-
emit(:
|
2028
|
+
case text = copy(data, ts, te)
|
2029
|
+
when '(?='; emit(:assertion, :lookahead, text)
|
2030
|
+
when '(?!'; emit(:assertion, :nlookahead, text)
|
2031
|
+
when '(?<='; emit(:assertion, :lookbehind, text)
|
2032
|
+
when '(?<!'; emit(:assertion, :nlookbehind, text)
|
2033
|
+
end
|
2061
2034
|
end
|
2062
2035
|
end
|
2063
|
-
when
|
2064
|
-
# line
|
2036
|
+
when 48 then
|
2037
|
+
# line 518 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2038
|
+
begin
|
2039
|
+
te = p
|
2040
|
+
p = p - 1; begin
|
2041
|
+
text = copy(data, ts, te)
|
2042
|
+
emit(:group, :capture, text)
|
2043
|
+
end
|
2044
|
+
end
|
2045
|
+
when 59 then
|
2046
|
+
# line 608 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2065
2047
|
begin
|
2066
2048
|
te = p
|
2067
2049
|
p = p - 1; begin
|
2068
|
-
case text =
|
2069
|
-
when '?' ; emit(:quantifier, :zero_or_one, text
|
2070
|
-
when '??'; emit(:quantifier, :zero_or_one_reluctant, text
|
2071
|
-
when '?+'; emit(:quantifier, :zero_or_one_possessive, text
|
2050
|
+
case text = copy(data, ts, te)
|
2051
|
+
when '?' ; emit(:quantifier, :zero_or_one, text)
|
2052
|
+
when '??'; emit(:quantifier, :zero_or_one_reluctant, text)
|
2053
|
+
when '?+'; emit(:quantifier, :zero_or_one_possessive, text)
|
2072
2054
|
end
|
2073
2055
|
end
|
2074
2056
|
end
|
2075
|
-
when
|
2076
|
-
# line
|
2057
|
+
when 55 then
|
2058
|
+
# line 616 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2077
2059
|
begin
|
2078
2060
|
te = p
|
2079
2061
|
p = p - 1; begin
|
2080
|
-
case text =
|
2081
|
-
when '*' ; emit(:quantifier, :zero_or_more, text
|
2082
|
-
when '*?'; emit(:quantifier, :zero_or_more_reluctant, text
|
2083
|
-
when '*+'; emit(:quantifier, :zero_or_more_possessive, text
|
2062
|
+
case text = copy(data, ts, te)
|
2063
|
+
when '*' ; emit(:quantifier, :zero_or_more, text)
|
2064
|
+
when '*?'; emit(:quantifier, :zero_or_more_reluctant, text)
|
2065
|
+
when '*+'; emit(:quantifier, :zero_or_more_possessive, text)
|
2084
2066
|
end
|
2085
2067
|
end
|
2086
2068
|
end
|
2087
|
-
when
|
2088
|
-
# line
|
2069
|
+
when 57 then
|
2070
|
+
# line 624 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2089
2071
|
begin
|
2090
2072
|
te = p
|
2091
2073
|
p = p - 1; begin
|
2092
|
-
case text =
|
2093
|
-
when '+' ; emit(:quantifier, :one_or_more, text
|
2094
|
-
when '+?'; emit(:quantifier, :one_or_more_reluctant, text
|
2095
|
-
when '++'; emit(:quantifier, :one_or_more_possessive, text
|
2074
|
+
case text = copy(data, ts, te)
|
2075
|
+
when '+' ; emit(:quantifier, :one_or_more, text)
|
2076
|
+
when '+?'; emit(:quantifier, :one_or_more_reluctant, text)
|
2077
|
+
when '++'; emit(:quantifier, :one_or_more_possessive, text)
|
2096
2078
|
end
|
2097
2079
|
end
|
2098
2080
|
end
|
2099
|
-
when
|
2100
|
-
# line
|
2081
|
+
when 65 then
|
2082
|
+
# line 632 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2101
2083
|
begin
|
2102
2084
|
te = p
|
2103
2085
|
p = p - 1; begin
|
2104
|
-
emit(:quantifier, :interval,
|
2086
|
+
emit(:quantifier, :interval, copy(data, ts, te))
|
2105
2087
|
end
|
2106
2088
|
end
|
2107
|
-
when
|
2108
|
-
# line
|
2089
|
+
when 64 then
|
2090
|
+
# line 637 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2109
2091
|
begin
|
2110
2092
|
te = p
|
2111
2093
|
p = p - 1; begin
|
2112
2094
|
append_literal(data, ts, te)
|
2113
2095
|
end
|
2114
2096
|
end
|
2115
|
-
when
|
2116
|
-
# line
|
2097
|
+
when 61 then
|
2098
|
+
# line 643 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2117
2099
|
begin
|
2118
2100
|
te = p
|
2119
2101
|
p = p - 1; begin
|
2120
2102
|
begin
|
2121
2103
|
stack[top] = cs
|
2122
2104
|
top+= 1
|
2123
|
-
cs =
|
2105
|
+
cs = 137
|
2124
2106
|
_goto_level = _again
|
2125
2107
|
next
|
2126
2108
|
end
|
2127
2109
|
|
2128
2110
|
end
|
2129
2111
|
end
|
2130
|
-
when
|
2131
|
-
# line
|
2112
|
+
when 46 then
|
2113
|
+
# line 647 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2132
2114
|
begin
|
2133
2115
|
te = p
|
2134
2116
|
p = p - 1; begin
|
2135
2117
|
if free_spacing
|
2136
|
-
emit(:free_space, :comment,
|
2118
|
+
emit(:free_space, :comment, copy(data, ts, te))
|
2137
2119
|
else
|
2138
|
-
|
2120
|
+
# consume only the pound sign (#) and backtrack to do regular scanning
|
2121
|
+
append_literal(data, ts, ts + 1)
|
2122
|
+
begin p = (( ts + 1))-1; end
|
2123
|
+
|
2139
2124
|
end
|
2140
2125
|
end
|
2141
2126
|
end
|
2142
|
-
when
|
2143
|
-
# line
|
2127
|
+
when 45 then
|
2128
|
+
# line 657 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2144
2129
|
begin
|
2145
2130
|
te = p
|
2146
2131
|
p = p - 1; begin
|
2147
2132
|
if free_spacing
|
2148
|
-
emit(:free_space, :whitespace,
|
2133
|
+
emit(:free_space, :whitespace, copy(data, ts, te))
|
2149
2134
|
else
|
2150
2135
|
append_literal(data, ts, te)
|
2151
2136
|
end
|
2152
2137
|
end
|
2153
2138
|
end
|
2154
|
-
when
|
2155
|
-
# line
|
2139
|
+
when 44 then
|
2140
|
+
# line 668 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2156
2141
|
begin
|
2157
2142
|
te = p
|
2158
2143
|
p = p - 1; begin
|
@@ -2160,19 +2145,19 @@ p = p - 1; begin
|
|
2160
2145
|
end
|
2161
2146
|
end
|
2162
2147
|
when 3 then
|
2163
|
-
# line
|
2148
|
+
# line 469 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2164
2149
|
begin
|
2165
2150
|
begin p = ((te))-1; end
|
2166
2151
|
begin
|
2167
|
-
text =
|
2152
|
+
text = copy(data, ts, te)
|
2168
2153
|
if text[2..-1] =~ /([^\-mixdau:]|^$)|-.*([dau])/
|
2169
2154
|
raise InvalidGroupOption.new($1 || "-#{$2}", text)
|
2170
2155
|
end
|
2171
|
-
emit_options(text
|
2156
|
+
emit_options(text)
|
2172
2157
|
end
|
2173
2158
|
end
|
2174
2159
|
when 10 then
|
2175
|
-
# line
|
2160
|
+
# line 637 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2176
2161
|
begin
|
2177
2162
|
begin p = ((te))-1; end
|
2178
2163
|
begin
|
@@ -2180,14 +2165,14 @@ p = p - 1; begin
|
|
2180
2165
|
end
|
2181
2166
|
end
|
2182
2167
|
when 8 then
|
2183
|
-
# line
|
2168
|
+
# line 643 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2184
2169
|
begin
|
2185
2170
|
begin p = ((te))-1; end
|
2186
2171
|
begin
|
2187
2172
|
begin
|
2188
2173
|
stack[top] = cs
|
2189
2174
|
top+= 1
|
2190
|
-
cs =
|
2175
|
+
cs = 137
|
2191
2176
|
_goto_level = _again
|
2192
2177
|
next
|
2193
2178
|
end
|
@@ -2205,6 +2190,25 @@ p = p - 1; begin
|
|
2205
2190
|
next
|
2206
2191
|
end
|
2207
2192
|
end
|
2193
|
+
when 42 then
|
2194
|
+
begin begin p = ((te))-1; end
|
2195
|
+
|
2196
|
+
text = copy(data, ts, te)
|
2197
|
+
if text[2..-1] =~ /([^\-mixdau:]|^$)|-.*([dau])/
|
2198
|
+
raise InvalidGroupOption.new($1 || "-#{$2}", text)
|
2199
|
+
end
|
2200
|
+
emit_options(text)
|
2201
|
+
end
|
2202
|
+
when 43 then
|
2203
|
+
begin begin p = ((te))-1; end
|
2204
|
+
|
2205
|
+
case text = copy(data, ts, te)
|
2206
|
+
when '(?='; emit(:assertion, :lookahead, text)
|
2207
|
+
when '(?!'; emit(:assertion, :nlookahead, text)
|
2208
|
+
when '(?<='; emit(:assertion, :lookbehind, text)
|
2209
|
+
when '(?<!'; emit(:assertion, :nlookbehind, text)
|
2210
|
+
end
|
2211
|
+
end
|
2208
2212
|
when 56 then
|
2209
2213
|
begin begin p = ((te))-1; end
|
2210
2214
|
|
@@ -2212,22 +2216,22 @@ end
|
|
2212
2216
|
end
|
2213
2217
|
end
|
2214
2218
|
end
|
2215
|
-
when
|
2216
|
-
# line
|
2219
|
+
when 78 then
|
2220
|
+
# line 139 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2217
2221
|
begin
|
2218
2222
|
|
2219
|
-
text =
|
2223
|
+
text = copy(data, ts ? ts-1 : 0, -1)
|
2220
2224
|
raise PrematureEndError.new( text )
|
2221
2225
|
end
|
2222
|
-
# line
|
2226
|
+
# line 213 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2223
2227
|
begin
|
2224
2228
|
te = p
|
2225
2229
|
p = p - 1; begin
|
2226
|
-
emit(:set, :open,
|
2230
|
+
emit(:set, :open, copy(data, ts, te))
|
2227
2231
|
begin
|
2228
2232
|
stack[top] = cs
|
2229
2233
|
top+= 1
|
2230
|
-
cs =
|
2234
|
+
cs = 129
|
2231
2235
|
_goto_level = _again
|
2232
2236
|
next
|
2233
2237
|
end
|
@@ -2235,21 +2239,21 @@ p = p - 1; begin
|
|
2235
2239
|
end
|
2236
2240
|
end
|
2237
2241
|
when 17 then
|
2238
|
-
# line
|
2242
|
+
# line 139 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2239
2243
|
begin
|
2240
2244
|
|
2241
|
-
text =
|
2245
|
+
text = copy(data, ts ? ts-1 : 0, -1)
|
2242
2246
|
raise PrematureEndError.new( text )
|
2243
2247
|
end
|
2244
|
-
# line
|
2248
|
+
# line 213 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2245
2249
|
begin
|
2246
2250
|
begin p = ((te))-1; end
|
2247
2251
|
begin
|
2248
|
-
emit(:set, :open,
|
2252
|
+
emit(:set, :open, copy(data, ts, te))
|
2249
2253
|
begin
|
2250
2254
|
stack[top] = cs
|
2251
2255
|
top+= 1
|
2252
|
-
cs =
|
2256
|
+
cs = 129
|
2253
2257
|
_goto_level = _again
|
2254
2258
|
next
|
2255
2259
|
end
|
@@ -2257,34 +2261,13 @@ p = p - 1; begin
|
|
2257
2261
|
end
|
2258
2262
|
end
|
2259
2263
|
when 93 then
|
2260
|
-
# line
|
2261
|
-
begin
|
2262
|
-
|
2263
|
-
text = ts ? copy(data, ts-1..-1) : data.pack('c*')
|
2264
|
-
raise PrematureEndError.new( text )
|
2265
|
-
end
|
2266
|
-
# line 329 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2267
|
-
begin
|
2268
|
-
te = p
|
2269
|
-
p = p - 1; begin
|
2270
|
-
emit(:escape, :hex, *text(data, ts, te, 1))
|
2271
|
-
begin
|
2272
|
-
top -= 1
|
2273
|
-
cs = stack[top]
|
2274
|
-
_goto_level = _again
|
2275
|
-
next
|
2276
|
-
end
|
2277
|
-
|
2278
|
-
end
|
2279
|
-
end
|
2280
|
-
when 89 then
|
2281
|
-
# line 137 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2264
|
+
# line 139 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2282
2265
|
begin
|
2283
2266
|
|
2284
|
-
text =
|
2267
|
+
text = copy(data, ts ? ts-1 : 0, -1)
|
2285
2268
|
raise PrematureEndError.new( text )
|
2286
2269
|
end
|
2287
|
-
# line
|
2270
|
+
# line 335 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2288
2271
|
begin
|
2289
2272
|
te = p
|
2290
2273
|
p = p - 1; begin
|
@@ -2298,14 +2281,14 @@ p = p - 1; begin
|
|
2298
2281
|
|
2299
2282
|
end
|
2300
2283
|
end
|
2301
|
-
when
|
2302
|
-
# line
|
2284
|
+
when 95 then
|
2285
|
+
# line 139 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2303
2286
|
begin
|
2304
2287
|
|
2305
|
-
text =
|
2288
|
+
text = copy(data, ts ? ts-1 : 0, -1)
|
2306
2289
|
raise PrematureEndError.new( text )
|
2307
2290
|
end
|
2308
|
-
# line
|
2291
|
+
# line 340 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2309
2292
|
begin
|
2310
2293
|
te = p
|
2311
2294
|
p = p - 1; begin
|
@@ -2319,14 +2302,14 @@ p = p - 1; begin
|
|
2319
2302
|
|
2320
2303
|
end
|
2321
2304
|
end
|
2322
|
-
when
|
2323
|
-
# line
|
2305
|
+
when 26 then
|
2306
|
+
# line 139 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2324
2307
|
begin
|
2325
2308
|
|
2326
|
-
text =
|
2309
|
+
text = copy(data, ts ? ts-1 : 0, -1)
|
2327
2310
|
raise PrematureEndError.new( text )
|
2328
2311
|
end
|
2329
|
-
# line
|
2312
|
+
# line 335 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2330
2313
|
begin
|
2331
2314
|
begin p = ((te))-1; end
|
2332
2315
|
begin
|
@@ -2340,14 +2323,14 @@ p = p - 1; begin
|
|
2340
2323
|
|
2341
2324
|
end
|
2342
2325
|
end
|
2343
|
-
when
|
2344
|
-
# line
|
2326
|
+
when 28 then
|
2327
|
+
# line 139 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2345
2328
|
begin
|
2346
2329
|
|
2347
|
-
text =
|
2330
|
+
text = copy(data, ts ? ts-1 : 0, -1)
|
2348
2331
|
raise PrematureEndError.new( text )
|
2349
2332
|
end
|
2350
|
-
# line
|
2333
|
+
# line 340 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2351
2334
|
begin
|
2352
2335
|
begin p = ((te))-1; end
|
2353
2336
|
begin
|
@@ -2361,14 +2344,14 @@ p = p - 1; begin
|
|
2361
2344
|
|
2362
2345
|
end
|
2363
2346
|
end
|
2364
|
-
when
|
2365
|
-
# line
|
2347
|
+
when 30 then
|
2348
|
+
# line 145 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2366
2349
|
begin
|
2367
2350
|
|
2368
|
-
text =
|
2351
|
+
text = copy(data, ts ? ts-1 : 0, -1)
|
2369
2352
|
validation_error(:sequence, 'sequence', text)
|
2370
2353
|
end
|
2371
|
-
# line
|
2354
|
+
# line 331 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2372
2355
|
begin
|
2373
2356
|
te = p+1
|
2374
2357
|
begin
|
@@ -2382,27 +2365,27 @@ te = p+1
|
|
2382
2365
|
end
|
2383
2366
|
end
|
2384
2367
|
when 5 then
|
2385
|
-
# line
|
2368
|
+
# line 152 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2386
2369
|
begin
|
2387
2370
|
self.group_depth = group_depth - 1 end
|
2388
|
-
# line
|
2371
|
+
# line 454 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2389
2372
|
begin
|
2390
2373
|
te = p+1
|
2391
2374
|
begin
|
2392
|
-
emit(:group, :comment,
|
2375
|
+
emit(:group, :comment, copy(data, ts, te))
|
2393
2376
|
end
|
2394
2377
|
end
|
2395
|
-
when
|
2396
|
-
# line
|
2378
|
+
when 37 then
|
2379
|
+
# line 152 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2397
2380
|
begin
|
2398
2381
|
self.group_depth = group_depth - 1 end
|
2399
|
-
# line
|
2382
|
+
# line 523 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2400
2383
|
begin
|
2401
2384
|
te = p+1
|
2402
2385
|
begin
|
2403
2386
|
if conditional_stack.last == group_depth + 1
|
2404
2387
|
conditional_stack.pop
|
2405
|
-
emit(:conditional, :close,
|
2388
|
+
emit(:conditional, :close, copy(data, ts, te))
|
2406
2389
|
else
|
2407
2390
|
if spacing_stack.length > 1 &&
|
2408
2391
|
spacing_stack.last[:depth] == group_depth + 1
|
@@ -2410,38 +2393,38 @@ te = p+1
|
|
2410
2393
|
self.free_spacing = spacing_stack.last[:free_spacing]
|
2411
2394
|
end
|
2412
2395
|
|
2413
|
-
emit(:group, :close,
|
2396
|
+
emit(:group, :close, copy(data, ts, te))
|
2414
2397
|
end
|
2415
2398
|
end
|
2416
2399
|
end
|
2417
|
-
when
|
2418
|
-
# line
|
2400
|
+
when 39 then
|
2401
|
+
# line 153 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2419
2402
|
begin
|
2420
2403
|
self.set_depth = set_depth + 1 end
|
2421
|
-
# line
|
2404
|
+
# line 429 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2422
2405
|
begin
|
2423
2406
|
te = p+1
|
2424
2407
|
begin
|
2425
|
-
emit(:set, :open,
|
2408
|
+
emit(:set, :open, copy(data, ts, te))
|
2426
2409
|
begin
|
2427
2410
|
stack[top] = cs
|
2428
2411
|
top+= 1
|
2429
|
-
cs =
|
2412
|
+
cs = 129
|
2430
2413
|
_goto_level = _again
|
2431
2414
|
next
|
2432
2415
|
end
|
2433
2416
|
|
2434
2417
|
end
|
2435
2418
|
end
|
2436
|
-
when
|
2437
|
-
# line
|
2419
|
+
when 72 then
|
2420
|
+
# line 154 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2438
2421
|
begin
|
2439
2422
|
self.set_depth = set_depth - 1 end
|
2440
|
-
# line
|
2423
|
+
# line 160 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2441
2424
|
begin
|
2442
2425
|
te = p+1
|
2443
2426
|
begin
|
2444
|
-
emit(:set, :close,
|
2427
|
+
emit(:set, :close, copy(data, ts, te))
|
2445
2428
|
if in_set?
|
2446
2429
|
begin
|
2447
2430
|
top -= 1
|
@@ -2460,16 +2443,16 @@ te = p+1
|
|
2460
2443
|
end
|
2461
2444
|
end
|
2462
2445
|
end
|
2463
|
-
when
|
2464
|
-
# line
|
2446
|
+
when 77 then
|
2447
|
+
# line 154 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2465
2448
|
begin
|
2466
2449
|
self.set_depth = set_depth - 1 end
|
2467
|
-
# line
|
2450
|
+
# line 169 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2468
2451
|
begin
|
2469
2452
|
te = p+1
|
2470
2453
|
begin # special case, emits two tokens
|
2471
|
-
emit(:literal, :literal, copy(data, ts
|
2472
|
-
emit(:set, :close, copy(data, ts+1
|
2454
|
+
emit(:literal, :literal, copy(data, ts, te-1))
|
2455
|
+
emit(:set, :close, copy(data, ts+1, te))
|
2473
2456
|
if in_set?
|
2474
2457
|
begin
|
2475
2458
|
top -= 1
|
@@ -2489,14 +2472,14 @@ te = p+1
|
|
2489
2472
|
end
|
2490
2473
|
end
|
2491
2474
|
when 20 then
|
2492
|
-
# line
|
2475
|
+
# line 154 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2493
2476
|
begin
|
2494
2477
|
self.set_depth = set_depth - 1 end
|
2495
|
-
# line
|
2478
|
+
# line 218 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2496
2479
|
begin
|
2497
2480
|
te = p+1
|
2498
2481
|
begin
|
2499
|
-
text =
|
2482
|
+
text = copy(data, ts, te)
|
2500
2483
|
|
2501
2484
|
type = :posixclass
|
2502
2485
|
class_name = text[2..-3]
|
@@ -2505,85 +2488,96 @@ te = p+1
|
|
2505
2488
|
type = :nonposixclass
|
2506
2489
|
end
|
2507
2490
|
|
2508
|
-
emit(type, class_name.to_sym, text
|
2491
|
+
emit(type, class_name.to_sym, text)
|
2509
2492
|
end
|
2510
2493
|
end
|
2511
2494
|
when 19 then
|
2512
|
-
# line
|
2495
|
+
# line 154 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2513
2496
|
begin
|
2514
2497
|
self.set_depth = set_depth - 1 end
|
2515
|
-
# line
|
2498
|
+
# line 231 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2516
2499
|
begin
|
2517
2500
|
te = p+1
|
2518
2501
|
begin
|
2519
|
-
emit(:set, :collation,
|
2502
|
+
emit(:set, :collation, copy(data, ts, te))
|
2520
2503
|
end
|
2521
2504
|
end
|
2522
2505
|
when 21 then
|
2523
|
-
# line
|
2506
|
+
# line 154 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2524
2507
|
begin
|
2525
2508
|
self.set_depth = set_depth - 1 end
|
2526
|
-
# line
|
2509
|
+
# line 235 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2527
2510
|
begin
|
2528
2511
|
te = p+1
|
2529
2512
|
begin
|
2530
|
-
emit(:set, :equivalent,
|
2513
|
+
emit(:set, :equivalent, copy(data, ts, te))
|
2531
2514
|
end
|
2532
2515
|
end
|
2533
|
-
when
|
2516
|
+
when 70 then
|
2534
2517
|
# line 1 "NONE"
|
2535
2518
|
begin
|
2536
2519
|
te = p+1
|
2537
2520
|
end
|
2538
|
-
# line
|
2521
|
+
# line 153 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2539
2522
|
begin
|
2540
2523
|
self.set_depth = set_depth + 1 end
|
2541
|
-
when
|
2524
|
+
when 84 then
|
2542
2525
|
# line 1 "NONE"
|
2543
2526
|
begin
|
2544
2527
|
te = p+1
|
2545
2528
|
end
|
2546
|
-
# line
|
2529
|
+
# line 268 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2547
2530
|
begin
|
2548
2531
|
act = 18; end
|
2549
|
-
when
|
2532
|
+
when 83 then
|
2550
2533
|
# line 1 "NONE"
|
2551
2534
|
begin
|
2552
2535
|
te = p+1
|
2553
2536
|
end
|
2554
|
-
# line
|
2537
|
+
# line 274 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2555
2538
|
begin
|
2556
2539
|
act = 19; end
|
2540
|
+
when 7 then
|
2541
|
+
# line 1 "NONE"
|
2542
|
+
begin
|
2543
|
+
te = p+1
|
2544
|
+
end
|
2545
|
+
# line 483 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2546
|
+
begin
|
2547
|
+
act = 43; end
|
2557
2548
|
when 2 then
|
2558
2549
|
# line 1 "NONE"
|
2559
2550
|
begin
|
2560
2551
|
te = p+1
|
2561
2552
|
end
|
2562
|
-
# line
|
2553
|
+
# line 668 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2563
2554
|
begin
|
2564
2555
|
act = 56; end
|
2565
|
-
when
|
2556
|
+
when 49 then
|
2566
2557
|
# line 1 "NONE"
|
2567
2558
|
begin
|
2568
2559
|
te = p+1
|
2569
2560
|
end
|
2570
|
-
# line
|
2561
|
+
# line 152 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2571
2562
|
begin
|
2572
2563
|
self.group_depth = group_depth - 1 end
|
2573
|
-
# line
|
2564
|
+
# line 151 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2574
2565
|
begin
|
2575
2566
|
self.group_depth = group_depth + 1 end
|
2576
|
-
# line
|
2567
|
+
# line 469 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2568
|
+
begin
|
2569
|
+
act = 42; end
|
2570
|
+
# line 2570 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner.rb"
|
2577
2571
|
end
|
2578
2572
|
end
|
2579
2573
|
end
|
2580
2574
|
if _goto_level <= _again
|
2581
2575
|
case _re_scanner_to_state_actions[cs]
|
2582
|
-
when
|
2576
|
+
when 67 then
|
2583
2577
|
# line 1 "NONE"
|
2584
2578
|
begin
|
2585
2579
|
ts = nil; end
|
2586
|
-
when
|
2580
|
+
when 33 then
|
2587
2581
|
# line 1 "NONE"
|
2588
2582
|
begin
|
2589
2583
|
ts = nil; end
|
@@ -2591,7 +2585,7 @@ ts = nil; end
|
|
2591
2585
|
begin
|
2592
2586
|
act = 0
|
2593
2587
|
end
|
2594
|
-
# line
|
2588
|
+
# line 2588 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner.rb"
|
2595
2589
|
end
|
2596
2590
|
|
2597
2591
|
if cs == 0
|
@@ -2618,14 +2612,14 @@ act = 0
|
|
2618
2612
|
|
2619
2613
|
raise PrematureEndError.new('unicode property')
|
2620
2614
|
end
|
2621
|
-
when
|
2622
|
-
# line
|
2615
|
+
when 24 then
|
2616
|
+
# line 139 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2623
2617
|
begin
|
2624
2618
|
|
2625
|
-
text =
|
2619
|
+
text = copy(data, ts ? ts-1 : 0, -1)
|
2626
2620
|
raise PrematureEndError.new( text )
|
2627
2621
|
end
|
2628
|
-
# line
|
2622
|
+
# line 2622 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner.rb"
|
2629
2623
|
end
|
2630
2624
|
end
|
2631
2625
|
|
@@ -2636,13 +2630,13 @@ act = 0
|
|
2636
2630
|
end
|
2637
2631
|
end
|
2638
2632
|
|
2639
|
-
# line
|
2633
|
+
# line 763 "/Users/jannoschmuller/code/regexp_parser/lib/regexp_parser/scanner/scanner.rl"
|
2640
2634
|
|
2641
2635
|
# to avoid "warning: assigned but unused variable - testEof"
|
2642
2636
|
testEof = testEof
|
2643
2637
|
|
2644
2638
|
if cs == re_scanner_error
|
2645
|
-
text =
|
2639
|
+
text = copy(data, ts ? ts-1 : 0, -1)
|
2646
2640
|
raise ScannerError.new("Scan error at '#{text}'")
|
2647
2641
|
end
|
2648
2642
|
|
@@ -2670,22 +2664,29 @@ end
|
|
2670
2664
|
end
|
2671
2665
|
|
2672
2666
|
# Emits an array with the details of the scanned pattern
|
2673
|
-
def emit(type, token, text
|
2667
|
+
def emit(type, token, text)
|
2674
2668
|
#puts "EMIT: type: #{type}, token: #{token}, text: #{text}, ts: #{ts}, te: #{te}"
|
2675
2669
|
|
2676
2670
|
emit_literal if literal
|
2677
2671
|
|
2672
|
+
# Ragel runs with byte-based indices (ts, te). These are of little value to
|
2673
|
+
# end-users, so we keep track of char-based indices and emit those instead.
|
2674
|
+
ts_char_pos = char_pos
|
2675
|
+
te_char_pos = char_pos + text.length
|
2676
|
+
|
2678
2677
|
if block
|
2679
|
-
block.call type, token, text,
|
2678
|
+
block.call type, token, text, ts_char_pos, te_char_pos
|
2680
2679
|
end
|
2681
2680
|
|
2682
|
-
tokens << [type, token, text,
|
2681
|
+
tokens << [type, token, text, ts_char_pos, te_char_pos]
|
2682
|
+
|
2683
|
+
self.char_pos = te_char_pos
|
2683
2684
|
end
|
2684
2685
|
|
2685
2686
|
private
|
2686
2687
|
|
2687
2688
|
attr_accessor :tokens, :literal, :block, :free_spacing, :spacing_stack,
|
2688
|
-
:group_depth, :set_depth, :conditional_stack
|
2689
|
+
:group_depth, :set_depth, :conditional_stack, :char_pos
|
2689
2690
|
|
2690
2691
|
def free_spacing?(input_object, options)
|
2691
2692
|
if options && !input_object.is_a?(String)
|
@@ -2708,36 +2709,25 @@ end
|
|
2708
2709
|
end
|
2709
2710
|
|
2710
2711
|
# Copy from ts to te from data as text
|
2711
|
-
def copy(data,
|
2712
|
-
data[
|
2713
|
-
end
|
2714
|
-
|
2715
|
-
# Copy from ts to te from data as text, returning an array with the text
|
2716
|
-
# and the offsets used to copy it.
|
2717
|
-
def text(data, ts, te, soff = 0)
|
2718
|
-
[copy(data, ts-soff..te-1), ts-soff, te]
|
2712
|
+
def copy(data, ts, te)
|
2713
|
+
data[ts...te].pack('c*').force_encoding('utf-8')
|
2719
2714
|
end
|
2720
2715
|
|
2721
2716
|
# Appends one or more characters to the literal buffer, to be emitted later
|
2722
|
-
# by a call to emit_literal.
|
2717
|
+
# by a call to emit_literal.
|
2723
2718
|
def append_literal(data, ts, te)
|
2724
2719
|
self.literal = literal || []
|
2725
|
-
literal <<
|
2720
|
+
literal << copy(data, ts, te)
|
2726
2721
|
end
|
2727
2722
|
|
2728
|
-
# Emits the literal run collected by calls to the append_literal method
|
2729
|
-
# using the total start (ts) and end (te) offsets of the run.
|
2723
|
+
# Emits the literal run collected by calls to the append_literal method.
|
2730
2724
|
def emit_literal
|
2731
|
-
|
2732
|
-
text = literal.map {|t| t[0]}.join
|
2733
|
-
|
2734
|
-
text.force_encoding('utf-8') if text.respond_to?(:force_encoding)
|
2735
|
-
|
2725
|
+
text = literal.join
|
2736
2726
|
self.literal = nil
|
2737
|
-
emit(:literal, :literal, text
|
2727
|
+
emit(:literal, :literal, text)
|
2738
2728
|
end
|
2739
2729
|
|
2740
|
-
def emit_options(text
|
2730
|
+
def emit_options(text)
|
2741
2731
|
token = nil
|
2742
2732
|
|
2743
2733
|
# Ruby allows things like '(?-xxxx)' or '(?xx-xx--xx-:abc)'.
|
@@ -2763,14 +2753,14 @@ end
|
|
2763
2753
|
token = :options_switch
|
2764
2754
|
end
|
2765
2755
|
|
2766
|
-
emit(:group, token, text
|
2756
|
+
emit(:group, token, text)
|
2767
2757
|
end
|
2768
2758
|
|
2769
2759
|
def emit_meta_control_sequence(data, ts, te, token)
|
2770
2760
|
if data.last < 0x00 || data.last > 0x7F
|
2771
2761
|
validation_error(:sequence, 'escape', token.to_s)
|
2772
2762
|
end
|
2773
|
-
emit(:escape, token,
|
2763
|
+
emit(:escape, token, copy(data, ts-1, te))
|
2774
2764
|
end
|
2775
2765
|
|
2776
2766
|
# Centralizes and unifies the handling of validation related
|