rley 0.6.08 → 0.6.09

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 552a2a05bcb871b84b8d86b7c0bab8de2d776754
4
- data.tar.gz: 0f80fc6e91cbe752393e04d878afeb6646ea0d27
3
+ metadata.gz: 8a924baa9568e3076c5c8ebb0d3f1e9ff162ab09
4
+ data.tar.gz: f01496851e2679a598a34f6635caf27e90aeda19
5
5
  SHA512:
6
- metadata.gz: 9cc73045f3e36363b201b61262ba9e8bac5154585033d8a1a48b0a45cdb259050bebdb42df747f0254276930e58488d740ab7a98d0659da485deb0ee22898798
7
- data.tar.gz: 129611092776086798e54391535b50c9bdb673a8a4342fca81a3a8c66628113cf83aae1a872a1b1969845502347707e6994ed99e0a7ebeb25942acf8b0425eb4
6
+ metadata.gz: 80b5ac648702c5ab11e2e84e6748b0be336f8ff39c61d6f05b49fda2a50ed7213cd82f4711590d8173434feaa83e4236a0b7ed56c74242eac53f2608d6ab1d4c
7
+ data.tar.gz: b8cf7f4a64c2526a784b0f6396e031040e57244a15ae760d5b050900fb26ad38c98e5fb66316fa29381384482fa2b40722502e11b7ede794fb1f65e31508a2f8
@@ -1,3 +1,15 @@
1
+ ### 0.6.09 / 2018-10-20
2
+ * [FIXED] Method `GrmFlowGraph#traverse_df` now returns a meaningful message when the grammar uses a terminal symbol without declaring it first.
3
+
4
+ ### 0.6.08 / 2018-06-24
5
+ * [NEW] Methods `Engine#to_pforest`, `Engine#pforest_visitor` added.
6
+ * [NEW] Class `SPPF::AlternativeNode` Added method `accept` to support Visitor pattern.
7
+ * [NEW] Class `SPPF::EpsilonNode` Added method `accept` to support Visitor pattern.
8
+ * [CHANGE] Class `ParseForestVisitor` vastly reworked, now supports visits of cyclic structure.
9
+ * [CHANGE] Class `Formatter::Debug`: Supports now visit events for both parse trees and forests.
10
+ * [CHANGE] File `examples/NLP/nano_eng/nano_en_demo.rb` Added demo steps to show how to produce a parse forest.
11
+
12
+
1
13
  ### 0.6.07 / 2018-05-29
2
14
  * [CHANGE] Method `GFGEarleyParser#parse` doesn't assume that the exact sequence of tokens to be known in advance.
3
15
  * [FIXED] Method `GFGParsing#nullable_rule`: in very specific cases a wrong parse entry was added to the parse chart.
@@ -3,7 +3,7 @@
3
3
 
4
4
  module Rley # Module used as a namespace
5
5
  # The version number of the gem.
6
- Version = '0.6.08'.freeze
6
+ Version = '0.6.09'.freeze
7
7
 
8
8
  # Brief description of the gem.
9
9
  Description = "Ruby implementation of the Earley's parsing algorithm".freeze
@@ -139,6 +139,10 @@ module Rley # This module is used as a namespace
139
139
  if first_time
140
140
  stack.push(Branching.new(visitee, curr_edge))
141
141
  curr_edge = stack.last.next_edge
142
+ elsif curr_edge.nil?
143
+ # Error probably caused by missing terminal symbol object
144
+ msg = "Undefined grammar symbol #{visitee.label.sub(/^\./, '')}"
145
+ raise StandardError, msg
142
146
  else
143
147
  # Skip both start and end vertices
144
148
  # Retrieve the corresponding return edge
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rley
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.08
4
+ version: 0.6.09
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dimitri Geshef
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-06-24 00:00:00.000000000 Z
11
+ date: 2018-10-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: coveralls