whitespace and code style
This commit is contained in:
@ -122,8 +122,7 @@ module Typed
|
||||
raise "create_method #{type.inspect} is not a Type" unless type.is_a? Parfait::Type
|
||||
raise "Args must be Hash #{args}" unless args.is_a?(Hash)
|
||||
raise "create_method #{method_name}.#{method_name.class}" unless method_name.is_a? Symbol
|
||||
arguments = Parfait::Type.for_hash( type.object_class , args )
|
||||
@method = type.create_method( method_name , arguments)
|
||||
@method = type.create_method( method_name , args)
|
||||
self
|
||||
end
|
||||
|
||||
|
@ -211,7 +211,7 @@ module Parfait
|
||||
# Word from string
|
||||
def self.new_word( string )
|
||||
string = string.to_s if string.is_a? Symbol
|
||||
word = Parfait::Word.new( string.length )
|
||||
word = Word.new( string.length )
|
||||
string.codepoints.each_with_index do |code , index |
|
||||
word.set_char(index + 1 , code)
|
||||
end
|
||||
|
Reference in New Issue
Block a user