commit | 77a8cd65bed54ac07b264cd8eb26bc0da4d60130 | [log] [tgz] |
---|---|---|
author | Yury Selivanov <yselivanov@sprymix.com> | Tue Aug 18 14:20:00 2015 -0400 |
committer | Yury Selivanov <yselivanov@sprymix.com> | Tue Aug 18 14:20:00 2015 -0400 |
tree | 4505972d1ec398336ab59f2c6bf9512a0d7ebde7 | |
parent | f5e0c41d6d143b16af4b9d97d5ce39eaa9e32df3 [diff] [blame] |
Issue #23572: Fixed functools.singledispatch on classes with falsy metaclasses. Patch by Ethan Furman.
diff --git a/Lib/functools.py b/Lib/functools.py index 09df068..06a4ff1 100644 --- a/Lib/functools.py +++ b/Lib/functools.py
@@ -567,7 +567,7 @@ break # reject the current head, it appears later else: break - if not candidate: + if candidate is None: raise RuntimeError("Inconsistent hierarchy") result.append(candidate) # remove the chosen candidate