[cython] Simplify COMPILED variables
This commit is contained in:
parent
0c26044a63
commit
e037cea726
@ -17,13 +17,10 @@
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
import cython
|
import cython
|
||||||
|
|
||||||
COMPILED = cython.compiled
|
|
||||||
except (AttributeError, ImportError):
|
except (AttributeError, ImportError):
|
||||||
# if cython not installed, use mock module with no-op decorators and types
|
# if cython not installed, use mock module with no-op decorators and types
|
||||||
from fontTools.misc import cython
|
from fontTools.misc import cython
|
||||||
|
COMPILED = cython.compiled
|
||||||
COMPILED = False
|
|
||||||
|
|
||||||
import math
|
import math
|
||||||
|
|
||||||
|
@ -9,13 +9,10 @@ from collections import namedtuple
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
import cython
|
import cython
|
||||||
|
|
||||||
COMPILED = cython.compiled
|
|
||||||
except (AttributeError, ImportError):
|
except (AttributeError, ImportError):
|
||||||
# if cython not installed, use mock module with no-op decorators and types
|
# if cython not installed, use mock module with no-op decorators and types
|
||||||
from fontTools.misc import cython
|
from fontTools.misc import cython
|
||||||
|
COMPILED = cython.compiled
|
||||||
COMPILED = False
|
|
||||||
|
|
||||||
|
|
||||||
EPSILON = 1e-9
|
EPSILON = 1e-9
|
||||||
|
@ -121,13 +121,10 @@ def printGreenPen(penName, funcs, file=sys.stdout, docstring=None):
|
|||||||
"""from fontTools.pens.basePen import BasePen, OpenContourError
|
"""from fontTools.pens.basePen import BasePen, OpenContourError
|
||||||
try:
|
try:
|
||||||
import cython
|
import cython
|
||||||
|
|
||||||
COMPILED = cython.compiled
|
|
||||||
except (AttributeError, ImportError):
|
except (AttributeError, ImportError):
|
||||||
# if cython not installed, use mock module with no-op decorators and types
|
# if cython not installed, use mock module with no-op decorators and types
|
||||||
from fontTools.misc import cython
|
from fontTools.misc import cython
|
||||||
|
COMPILED = cython.compiled
|
||||||
COMPILED = False
|
|
||||||
|
|
||||||
|
|
||||||
__all__ = ["%s"]
|
__all__ = ["%s"]
|
||||||
|
@ -2,13 +2,10 @@ from fontTools.pens.basePen import BasePen, OpenContourError
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
import cython
|
import cython
|
||||||
|
|
||||||
COMPILED = cython.compiled
|
|
||||||
except (AttributeError, ImportError):
|
except (AttributeError, ImportError):
|
||||||
# if cython not installed, use mock module with no-op decorators and types
|
# if cython not installed, use mock module with no-op decorators and types
|
||||||
from fontTools.misc import cython
|
from fontTools.misc import cython
|
||||||
|
COMPILED = cython.compiled
|
||||||
COMPILED = False
|
|
||||||
|
|
||||||
|
|
||||||
__all__ = ["MomentsPen"]
|
__all__ = ["MomentsPen"]
|
||||||
|
@ -18,13 +18,10 @@
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
import cython
|
import cython
|
||||||
|
|
||||||
COMPILED = cython.compiled
|
|
||||||
except (AttributeError, ImportError):
|
except (AttributeError, ImportError):
|
||||||
# if cython not installed, use mock module with no-op decorators and types
|
# if cython not installed, use mock module with no-op decorators and types
|
||||||
from fontTools.misc import cython
|
from fontTools.misc import cython
|
||||||
|
COMPILED = cython.compiled
|
||||||
COMPILED = False
|
|
||||||
|
|
||||||
from fontTools.misc.bezierTools import splitCubicAtTC
|
from fontTools.misc.bezierTools import splitCubicAtTC
|
||||||
from collections import namedtuple
|
from collections import namedtuple
|
||||||
|
@ -1,12 +1,9 @@
|
|||||||
try:
|
try:
|
||||||
import cython
|
import cython
|
||||||
|
|
||||||
COMPILED = cython.compiled
|
|
||||||
except (AttributeError, ImportError):
|
except (AttributeError, ImportError):
|
||||||
# if cython not installed, use mock module with no-op decorators and types
|
# if cython not installed, use mock module with no-op decorators and types
|
||||||
from fontTools.misc import cython
|
from fontTools.misc import cython
|
||||||
|
COMPILED = cython.compiled
|
||||||
COMPILED = False
|
|
||||||
|
|
||||||
from typing import (
|
from typing import (
|
||||||
Sequence,
|
Sequence,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user