ยปCore Development>Code coverage>Lib/lib2to3/fixes/fix_long.py

Python code coverage for Lib/lib2to3/fixes/fix_long.py

#countcontent
1n/a# Copyright 2006 Google, Inc. All Rights Reserved.
2n/a# Licensed to PSF under a Contributor Agreement.
3n/a
4n/a"""Fixer that turns 'long' into 'int' everywhere.
5n/a"""
6n/a
7n/a# Local imports
8n/afrom lib2to3 import fixer_base
9n/afrom lib2to3.fixer_util import is_probably_builtin
10n/a
11n/a
12n/aclass FixLong(fixer_base.BaseFix):
13n/a BM_compatible = True
14n/a PATTERN = "'long'"
15n/a
16n/a def transform(self, node, results):
17n/a if is_probably_builtin(node):
18n/a node.value = "int"
19n/a node.changed()