Python API

----------
Bugfix: make Constant mp_subscript method return key error if key not found
in dictionary.
This commit is contained in:
Ken Hughes
2006-12-26 21:12:34 +00:00
parent e6381a04d6
commit 7b14c36a18

View File

@@ -105,6 +105,8 @@ static PyObject *constantSubscript(BPy_constant *self, PyObject *key)
if(v) {
return EXPP_incr_ret(v);
}
return EXPP_ReturnPyObjError( PyExc_KeyError,
"key not found" );
}
return NULL;
}