Issue #2 resolved

multiple type handling with option raises error

Hyunjun Kim
created an issue

{{{

!python

import typequery

amp = typequery.GenericMethod('amp')

@amp.of(int) @amp.of(float) def amp(value, **options): try: amp_x = options['amp_x'] except KeyError: amp_x = 1 return value * amp_x

if name == 'main': print amp(1, amp_x=5) }}}

{{{

!pytb

$ python tp.py Traceback (most recent call last): File "tp.py", line 15, in <module> print amp(1, amp_x=5) File "~/venv/local/lib/python2.7/site-packages/TypeQuery-0.1.2-py2.7.egg/typequery.py", line 214, in call return f(args, *kwargs) TypeError: 'tuple' object is not callable }}}