Python builtin - add indexing support to std::unordered_set

This commit is contained in:
William S Fulton 2018-09-21 19:30:31 +01:00
commit 146998ce81
2 changed files with 3 additions and 0 deletions

View file

@ -45,8 +45,10 @@
#if defined(SWIGPYTHON_BUILTIN)
%feature("python:slot", "sq_contains", functype="objobjproc") __contains__;
%feature("python:slot", "mp_subscript", functype="binaryfunc") __getitem__;
#endif
%extend {
void append(value_type x) {
self->insert(x);