py: Implement delete for property and descriptors.

Without this patch deleting a property, or class with descriptor, will
call the setter with a NULL value and lead to a crash.
This commit is contained in:
Damien George
2015-04-04 20:15:31 +01:00
parent 0528c5a22a
commit 56606f3475
2 changed files with 44 additions and 19 deletions

View File

@@ -69,6 +69,7 @@ Q(__str__)
#if MICROPY_PY_DESCRIPTORS
Q(__get__)
Q(__set__)
Q(__delete__)
#endif
Q(__getattr__)
Q(__del__)