lib/ruby_units/object.rb in ruby-units-1.3.2 vs lib/ruby_units/object.rb in ruby-units-1.4.0
- old
+ new
@@ -1,8 +1,15 @@
class Object
+
+ # Shortcut for creating Unit object
+ # @example
+ # Unit("1 mm")
+ # U("1 mm")
+ # @return [Unit]
def Unit(*other)
other.to_unit
end
-
alias :U :Unit
+
+ # @deprecated
alias :u :Unit
end