Python: highlight future import (#2936)

* Python: highlight future import

* Use constant.builtin
This commit is contained in:
Santos Gallegos 2022-05-13 16:46:06 -05:00 committed by GitHub
parent 4d53ee5c05
commit f1373051e5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 0 deletions

View file

@ -224,6 +224,7 @@
] @keyword.return
(yield "from" @keyword.return)
(future_import_statement "from" @include "__future__" @constant.builtin)
(import_from_statement "from" @include)
"import" @include

View file

@ -0,0 +1,4 @@
from __future__ import print_function
# ^ @include
# ^ @constant.builtin
# ^ @include