From 7f62e450f4c5d7688133fecd10572cb0c54e6dce Mon Sep 17 00:00:00 2001 From: murphy Date: Sun, 7 Jun 2009 14:40:21 +0000 Subject: Fixed an issue with predefined idents in the Python Scanner. * @file=@ should not be recognized as the predefined method @file@. --- lib/coderay/scanners/python.rb | 1 + 1 file changed, 1 insertion(+) (limited to 'lib/coderay/scanners/python.rb') diff --git a/lib/coderay/scanners/python.rb b/lib/coderay/scanners/python.rb index 6e86b88..f72a29e 100644 --- a/lib/coderay/scanners/python.rb +++ b/lib/coderay/scanners/python.rb @@ -129,6 +129,7 @@ module Scanners # TODO: keyword arguments kind = :ident if last_token_dot kind = check(/\(/) ? :ident : :keyword if kind == :old_keyword + kind = :ident if kind == :predefined && check(/=/) elsif scan(/@[a-zA-Z0-9_.]+[lL]?/) kind = :decorator -- cgit v1.2.1