diff options
| author | Damien George | 2014-06-10 23:07:56 +0100 |
|---|---|---|
| committer | Damien George | 2014-06-10 23:07:56 +0100 |
| commit | 58cbb4d661ee40af5ef2b6a6a7f15b1b2ee5b4e5 (patch) | |
| tree | 924c497329cff6482fdf3829dedd5ecda232b9dd /py/objtype.c | |
| parent | 62f7ba7a815f34fb49967e925ac28ea340a46777 (diff) | |
py: Implement __contains__ special method.
Diffstat (limited to 'py/objtype.c')
| -rw-r--r-- | py/objtype.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/py/objtype.c b/py/objtype.c index f96a29beb..80f39d7f1 100644 --- a/py/objtype.c +++ b/py/objtype.c @@ -384,7 +384,9 @@ STATIC const qstr binary_op_method_name[] = { MP_BINARY_OP_LESS_EQUAL, MP_BINARY_OP_MORE_EQUAL, MP_BINARY_OP_NOT_EQUAL, - MP_BINARY_OP_IN, + */ + [MP_BINARY_OP_IN] = MP_QSTR___contains__, + /* MP_BINARY_OP_IS, */ [MP_BINARY_OP_EXCEPTION_MATCH] = MP_QSTR_, // not implemented, used to make sure array has full size |
