# HG changeset patch # User Pulkit Goyal <7895pulkit@gmail.com> # Date 1519390431 -19800 # Node ID 24b4816682939607d00cd0ed26fa6fc7d2d8d796 # Parent b4d1c09b754b36d6ba4f10ada26178314378230b py3: replace types.NoneType with type(None) types.NoneType is not present in Python 3. diff -r b4d1c09b754b -r 24b481668293 mercurial/fancyopts.py --- a/mercurial/fancyopts.py Fri Feb 23 18:12:20 2018 +0530 +++ b/mercurial/fancyopts.py Fri Feb 23 18:23:51 2018 +0530 @@ -9,7 +9,6 @@ import abc import functools -import types from .i18n import _ from . import ( @@ -222,7 +221,7 @@ class _simpleopt(customopt): def _isboolopt(self): - return isinstance(self.defaultvalue, (bool, types.NoneType)) + return isinstance(self.defaultvalue, (bool, type(None))) def newstate(self, oldstate, newparam, abort): return newparam