diff options
Diffstat (limited to 'bitbake/lib/ply/lex.py')
-rw-r--r-- | bitbake/lib/ply/lex.py | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/bitbake/lib/ply/lex.py b/bitbake/lib/ply/lex.py index 267ec100fc..182f2e8377 100644 --- a/bitbake/lib/ply/lex.py +++ b/bitbake/lib/ply/lex.py | |||
@@ -705,11 +705,7 @@ class LexerReflect(object): | |||
705 | 705 | ||
706 | # Sort the functions by line number | 706 | # Sort the functions by line number |
707 | for f in self.funcsym.values(): | 707 | for f in self.funcsym.values(): |
708 | if sys.version_info[0] < 3: | 708 | f.sort(key=lambda x: func_code(x[1]).co_firstlineno) |
709 | f.sort(lambda x,y: cmp(func_code(x[1]).co_firstlineno,func_code(y[1]).co_firstlineno)) | ||
710 | else: | ||
711 | # Python 3.0 | ||
712 | f.sort(key=lambda x: func_code(x[1]).co_firstlineno) | ||
713 | 709 | ||
714 | # Sort the strings by regular expression length | 710 | # Sort the strings by regular expression length |
715 | for s in self.strsym.values(): | 711 | for s in self.strsym.values(): |