From 39196ec91e5f1fd6cb7ef4058f3ea3bffc5e869a Mon Sep 17 00:00:00 2001 From: Marius Gedminas <marius@gedmin.as> Date: Thu, 27 Aug 2015 09:20:35 +0300 Subject: [PATCH] Drop the L suffix on numerical constants Python has had automatic int-to-long promotion for a long long time now. Even Python 2.4 does that automatically. Python 3 drops support for the L suffix altogether. --- lib/ansible/plugins/filter/mathstuff.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/ansible/plugins/filter/mathstuff.py b/lib/ansible/plugins/filter/mathstuff.py index 6029ed03007..341c2aa2d8c 100644 --- a/lib/ansible/plugins/filter/mathstuff.py +++ b/lib/ansible/plugins/filter/mathstuff.py @@ -107,13 +107,13 @@ def human_readable(size, isbits=False, unit=None): suffix = '' ranges = ( - (1<<70L, 'Z'), - (1<<60L, 'E'), - (1<<50L, 'P'), - (1<<40L, 'T'), - (1<<30L, 'G'), - (1<<20L, 'M'), - (1<<10L, 'K'), + (1<<70, 'Z'), + (1<<60, 'E'), + (1<<50, 'P'), + (1<<40, 'T'), + (1<<30, 'G'), + (1<<20, 'M'), + (1<<10, 'K'), (1, base) )