Skip to content
Permalink
Browse files

Merge pull request #750 from kachick/fix-hash-new_with-2arg

Hash.new should raise ArgumentError when passed both arguments
  • Loading branch information
alex committed Jun 11, 2013
2 parents b89ae9f + 3ab79d6 commit c0b8e89ab29e3ac7a91e0197b5e1bec56f020af9
Showing with 2 additions and 1 deletion.
  1. +0 −1 spec/tags/core/hash/new_tags.txt
  2. +2 −0 topaz/objects/hashobject.py

This file was deleted.

@@ -29,6 +29,8 @@ def method_try_convert(self, space, w_obj):
@check_frozen()
def method_initialize(self, space, w_default=None, block=None):
if w_default is not None:
if block is not None:
raise space.error(space.w_ArgumentError, "wrong number of arguments")
self.w_default = w_default
if block is not None:
self.default_proc = block

0 comments on commit c0b8e89

Please sign in to comment.