Release 2.0.2
-
Adding this documentation might help clarify pattern matching within
RDF::Query::Pattern
, too. -
do not fail with Encoding::CompatibilityError when normalizing unicode IRIs.
-
Fix
RDF::List#==
comparisons toRDF::Values
Ruby 2.3.0 changed the behavior of
Comparable#==
to avoid hiding errors. This led toNoMethodError
s for comparisons that returnfalse
for previous Rubies.This introduces a custom
RDF::List#==
implementation for explicitly
supported comparisons betweenRDF::Value
classes. We returnfalse
immediately forRDF::Value
s which are not#list?
; falling back on
Comparable
for other types.Further,
RDF::List
s with three elements that happen to coincide with
the terms of an RDF::Statement would previously returntrue
. E.g.:
RDF::List[:s, :p, :o] == RDF::Statement(:s, :p, :o)
. This unusual edge
case is patched by way of the changes described above. -
Adjust
List#<=>
to avoid error casesUsing
Array(other)
instead ofother.to_a
avoids throwing errors when
comparing. This minor tweak slightly improves the solution to #304 given
in #305.