Skip to content

Commit fc30eec

Browse files
committed
Update RDF::Literal::Decimal#round, #floor, #ceil to return integers along with RDF::Literal::Double variations. Previously, they returned the same type.
1 parent 4296e88 commit fc30eec

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

lib/rdf/model/literal/decimal.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def round
7676
#
7777
# @return [RDF::Literal::Integer]
7878
def ceil
79-
self.class.new(to_d.ceil)
79+
RDF::Literal::Integer.new(to_d.ceil)
8080
end
8181

8282
##
@@ -87,7 +87,7 @@ def ceil
8787
#
8888
# @return [RDF::Literal::Integer]
8989
def floor
90-
self.class.new(to_d.floor)
90+
RDF::Literal::Integer.new(to_d.floor)
9191
end
9292

9393
##

0 commit comments

Comments
 (0)