From 4e63e52758daa7ef27782b4f129b7e55fa73de43 Mon Sep 17 00:00:00 2001 From: Vincent Rouvreau Date: Mon, 28 Feb 2022 09:50:08 +0100 Subject: code review: use 'isinstance' instead of 'type' --- src/python/gudhi/simplex_tree.pyx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/python/gudhi/simplex_tree.pyx') diff --git a/src/python/gudhi/simplex_tree.pyx b/src/python/gudhi/simplex_tree.pyx index e1685ded..711796d4 100644 --- a/src/python/gudhi/simplex_tree.pyx +++ b/src/python/gudhi/simplex_tree.pyx @@ -56,7 +56,7 @@ cdef class SimplexTree: def __cinit__(self, other = None): cdef SimplexTree ostr if other: - if type(other) is SimplexTree: + if isinstance(other, SimplexTree): ostr = other self.thisptr = (new Simplex_tree_interface_full_featured(dereference(ostr.get_ptr()))) else: -- cgit v1.2.3