paco 0.2.2 → 0.2.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8d72f440d9727dc302366b842d7a7bf3d3d2ac84f4e13b41ce8954dad4b971f0
4
- data.tar.gz: 81b0e2b377c35060db0416472115754cd62d45efda5f302265003b1340e639b4
3
+ metadata.gz: 33b91a49bb7dd72f8ca4217ab79949a911544b3a741088b05bc62cc38e09cb05
4
+ data.tar.gz: 7567277a97be383523040abcd78882a27a2bb149c31208f92d2e840c934feefe
5
5
  SHA512:
6
- metadata.gz: 3aaa2ce601f6da71e1d24a0a13bee121abc3c6d52b9120e6795b57e5880cefbb2fae9c24b69f7e6284a54913b293e25c6d3fcbe7e503105e782fd84817e13413
7
- data.tar.gz: fed4af90111069f4c39f4ce6ed85b72480aaf6bf10bcf4f06e8701a60f037095638647b423282a7dfe00ae0f1e8c17e94b907368879394b0f664ae06a812a47e
6
+ metadata.gz: d5cdcf9f6aedcb5b4b52332ede84f3f4f4adb443836c8c79c69e50a75ad2594355374faaf0f986ca4cf8ec19de9bff9cc890c86160425bb4fd33e16333853f37
7
+ data.tar.gz: b0875c0886ca461193b3c68f5b06a7e50161b58a2300c7fcbe11422c07118370c8a07eef614a9aaf09b13ed9d46c325ebbd3fb74e3ccf85de23201ebeff580af
data/CHANGELOG.md CHANGED
@@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning].
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [0.2.3] - 2023-08-28
11
+
12
+ - Remove `ruby-next-core` as a dependency. ([@palkan][])
13
+
10
14
  ## [0.2.2] - 2023-08-23
11
15
 
12
16
  ### Fixed
data/lib/paco/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Paco
4
- VERSION = "0.2.2"
4
+ VERSION = "0.2.3"
5
5
  end
data/lib/paco.rb CHANGED
@@ -1,7 +1,8 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require "ruby-next/language/setup"
4
- RubyNext::Language.setup_gem_load_path(transpile: true)
3
+ if RUBY_VERSION < "2.6.0"
4
+ $LOAD_PATH.unshift File.expand_path("./.rbnext", __dir__)
5
+ end
5
6
 
6
7
  require "paco/version"
7
8
  require "paco/parse_error"
metadata CHANGED
@@ -1,29 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: paco
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Svyatoslav Kryukov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-08-23 00:00:00.000000000 Z
12
- dependencies:
13
- - !ruby/object:Gem::Dependency
14
- name: ruby-next-core
15
- requirement: !ruby/object:Gem::Requirement
16
- requirements:
17
- - - ">="
18
- - !ruby/object:Gem::Version
19
- version: 0.15.0
20
- type: :runtime
21
- prerelease: false
22
- version_requirements: !ruby/object:Gem::Requirement
23
- requirements:
24
- - - ">="
25
- - !ruby/object:Gem::Version
26
- version: 0.15.0
11
+ date: 2023-08-29 00:00:00.000000000 Z
12
+ dependencies: []
27
13
  description: Paco is a parser combinator library.
28
14
  email:
29
15
  - s.g.kryukov@yandex.ru
@@ -34,13 +20,12 @@ files:
34
20
  - CHANGELOG.md
35
21
  - LICENSE.txt
36
22
  - README.md
37
- - lib/.rbnext/2.3/paco/context.rb
38
- - lib/.rbnext/2.3/paco/index.rb
39
- - lib/.rbnext/2.3/paco/parse_error.rb
40
- - lib/.rbnext/2.5/paco/combinators.rb
41
- - lib/.rbnext/2.5/paco/parser.rb
42
- - lib/.rbnext/2.5/paco/rspec/parse_matcher.rb
43
- - lib/.rbnext/2.6/paco/context.rb
23
+ - lib/.rbnext/paco/combinators.rb
24
+ - lib/.rbnext/paco/context.rb
25
+ - lib/.rbnext/paco/index.rb
26
+ - lib/.rbnext/paco/parse_error.rb
27
+ - lib/.rbnext/paco/parser.rb
28
+ - lib/.rbnext/paco/rspec/parse_matcher.rb
44
29
  - lib/paco.rb
45
30
  - lib/paco/callstack.rb
46
31
  - lib/paco/combinators.rb
@@ -1,51 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "paco/callstack"
4
- require "paco/index"
5
-
6
- module Paco
7
- class Context
8
- attr_reader :input, :last_pos, :callstack
9
- attr_accessor :pos
10
-
11
- def initialize(input, pos: 0, with_callstack: false)
12
- @input = input
13
- @pos = pos
14
- @callstack = Callstack.new if with_callstack
15
- end
16
-
17
- def read(n)
18
- input[pos, n]
19
- end
20
-
21
- def read_all
22
- input[pos..-1]
23
- end
24
-
25
- def eof?
26
- pos >= input.length
27
- end
28
-
29
- # @param [Integer] from
30
- # @return [Paco::Index]
31
- def index(from = nil)
32
- Index.calculate(input: input, pos: from || pos)
33
- end
34
-
35
- # @param [Paco::Parser] parser
36
- def failure_parse(parser)
37
- @callstack&.failure(pos: pos, parser: parser.desc)
38
- end
39
-
40
- # @param [Paco::Parser] parser
41
- def start_parse(parser)
42
- @callstack&.start(pos: pos, parser: parser.desc)
43
- end
44
-
45
- # @param [Object] result
46
- # @param [Paco::Parser] parser
47
- def success_parse(result, parser)
48
- @callstack&.success(pos: pos, result: result, parser: parser.desc)
49
- end
50
- end
51
- end
File without changes
File without changes
File without changes
File without changes
File without changes