# Create a new Unit object. Can be initialized using a String, a Hash, an Array, Time, DateTime
#
# @example Valid options include:
# ...
# [1, 'kg']
# {:scalar => 1, :numerator=>'kg'}
def initialize(*options)
The latter doesn't work as promised:
2.2.2 :012 > Unit.new({:scalar => 1, :numerator=>'kg'})
TypeError: no implicit conversion of Array into String
from /home/nowaker/.rvm/gems/ruby-2.2.2/gems/ruby-units-2.0.0/lib/ruby_units/unit.rb:410:in `+'
from /home/nowaker/.rvm/gems/ruby-2.2.2/gems/ruby-units-2.0.0/lib/ruby_units/unit.rb:410:in `is_base?'
from /home/nowaker/.rvm/gems/ruby-2.2.2/gems/ruby-units-2.0.0/lib/ruby_units/unit.rb:1246:in `update_base_scalar'
from /home/nowaker/.rvm/gems/ruby-2.2.2/gems/ruby-units-2.0.0/lib/ruby_units/unit.rb:344:in `initialize'
The latter doesn't work as promised: