github-linguist-grammars 4.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (335) hide show
  1. checksums.yaml +7 -0
  2. data/grammars/file.lasso.json +713 -0
  3. data/grammars/module.ceylon.json +54 -0
  4. data/grammars/objdump.x86asm.json +73 -0
  5. data/grammars/source.Inform7.json +45 -0
  6. data/grammars/source.Kotlin.json +774 -0
  7. data/grammars/source.LS.json +104 -0
  8. data/grammars/source.MCPOST.json +68 -0
  9. data/grammars/source.MOD.json +70 -0
  10. data/grammars/source.abap.json +176 -0
  11. data/grammars/source.abl.json +138 -0
  12. data/grammars/source.actionscript.3.json +1571 -0
  13. data/grammars/source.acucobol.json +16 -0
  14. data/grammars/source.ada.json +140 -0
  15. data/grammars/source.agda.json +254 -0
  16. data/grammars/source.ahk.json +171 -0
  17. data/grammars/source.alloy.json +44 -0
  18. data/grammars/source.ampl.json +157 -0
  19. data/grammars/source.antlr.json +300 -0
  20. data/grammars/source.apache-config.json +352 -0
  21. data/grammars/source.apache-config.mod_perl.json +70 -0
  22. data/grammars/source.apl.json +442 -0
  23. data/grammars/source.applescript.json +1385 -0
  24. data/grammars/source.apt.json +25 -0
  25. data/grammars/source.asm.x86.json +182 -0
  26. data/grammars/source.asp.json +157 -0
  27. data/grammars/source.aspectj.json +963 -0
  28. data/grammars/source.ats.json +170 -0
  29. data/grammars/source.autoit.3.json +132 -0
  30. data/grammars/source.awk.json +388 -0
  31. data/grammars/source.befunge.json +38 -0
  32. data/grammars/source.bf.json +36 -0
  33. data/grammars/source.bison.json +59 -0
  34. data/grammars/source.blitzmax.json +912 -0
  35. data/grammars/source.boo.json +452 -0
  36. data/grammars/source.brightauthorproject.json +29 -0
  37. data/grammars/source.brightscript.json +158 -0
  38. data/grammars/source.bro.json +409 -0
  39. data/grammars/source.bsv.json +283 -0
  40. data/grammars/source.c++.json +364 -0
  41. data/grammars/source.c++.qt.json +37 -0
  42. data/grammars/source.c.ec.json +39 -0
  43. data/grammars/source.c.json +727 -0
  44. data/grammars/source.c.platform.json +154 -0
  45. data/grammars/source.cache.cmake.json +75 -0
  46. data/grammars/source.cake.json +16 -0
  47. data/grammars/source.camlp4.ocaml.json +63 -0
  48. data/grammars/source.capnp.json +93 -0
  49. data/grammars/source.ceylon.json +77 -0
  50. data/grammars/source.cfscript.cfc.json +170 -0
  51. data/grammars/source.cfscript.json +744 -0
  52. data/grammars/source.chapel.json +240 -0
  53. data/grammars/source.cirru.json +66 -0
  54. data/grammars/source.clarion.json +159 -0
  55. data/grammars/source.clips.json +80 -0
  56. data/grammars/source.clojure.json +397 -0
  57. data/grammars/source.cm.json +54 -0
  58. data/grammars/source.cmake.json +181 -0
  59. data/grammars/source.cobol.json +528 -0
  60. data/grammars/source.coffee.json +678 -0
  61. data/grammars/source.compiled-papyrus.json +11 -0
  62. data/grammars/source.cool.json +103 -0
  63. data/grammars/source.coq.json +62 -0
  64. data/grammars/source.crystal.json +2760 -0
  65. data/grammars/source.cs.json +556 -0
  66. data/grammars/source.css.json +630 -0
  67. data/grammars/source.css.less.json +276 -0
  68. data/grammars/source.css.mss.json +256 -0
  69. data/grammars/source.csx.json +16 -0
  70. data/grammars/source.cuda-c++.json +137 -0
  71. data/grammars/source.cython.json +2108 -0
  72. data/grammars/source.d.json +722 -0
  73. data/grammars/source.dart.json +763 -0
  74. data/grammars/source.desktop.json +90 -0
  75. data/grammars/source.diff.json +162 -0
  76. data/grammars/source.dockerfile.json +89 -0
  77. data/grammars/source.dosbatch.json +70 -0
  78. data/grammars/source.dot.json +126 -0
  79. data/grammars/source.dylan.json +217 -0
  80. data/grammars/source.eiffel.json +138 -0
  81. data/grammars/source.elixir.json +737 -0
  82. data/grammars/source.elm.json +355 -0
  83. data/grammars/source.erazor.json +126 -0
  84. data/grammars/source.erlang.json +1674 -0
  85. data/grammars/source.essl.json +50 -0
  86. data/grammars/source.factor.json +260 -0
  87. data/grammars/source.fan.json +188 -0
  88. data/grammars/source.fancy.json +270 -0
  89. data/grammars/source.fish.json +214 -0
  90. data/grammars/source.forth.json +101 -0
  91. data/grammars/source.fortran.json +499 -0
  92. data/grammars/source.fortran.modern.json +226 -0
  93. data/grammars/source.fsharp.json +403 -0
  94. data/grammars/source.gap.json +167 -0
  95. data/grammars/source.gcode.json +25 -0
  96. data/grammars/source.gdscript.json +154 -0
  97. data/grammars/source.gfm.json +1270 -0
  98. data/grammars/source.glsl.json +71 -0
  99. data/grammars/source.gnuplot.json +276 -0
  100. data/grammars/source.go.json +552 -0
  101. data/grammars/source.golo.json +182 -0
  102. data/grammars/source.gosu.2.json +163 -0
  103. data/grammars/source.grace.json +679 -0
  104. data/grammars/source.groovy.gradle.json +73 -0
  105. data/grammars/source.groovy.json +1385 -0
  106. data/grammars/source.harbour.json +450 -0
  107. data/grammars/source.haskell.json +449 -0
  108. data/grammars/source.haxe.2.json +1243 -0
  109. data/grammars/source.hss.1.json +464 -0
  110. data/grammars/source.httpspec.json +287 -0
  111. data/grammars/source.hxml.json +26 -0
  112. data/grammars/source.hy.json +270 -0
  113. data/grammars/source.idl-dlm.json +112 -0
  114. data/grammars/source.idl.json +267 -0
  115. data/grammars/source.idris.json +537 -0
  116. data/grammars/source.ini.json +113 -0
  117. data/grammars/source.inno.json +65 -0
  118. data/grammars/source.io.json +164 -0
  119. data/grammars/source.ioke.json +272 -0
  120. data/grammars/source.isabelle.root.json +68 -0
  121. data/grammars/source.isabelle.theory.json +106 -0
  122. data/grammars/source.j.json +49 -0
  123. data/grammars/source.jade.json +1009 -0
  124. data/grammars/source.jasmin.json +299 -0
  125. data/grammars/source.java-properties.json +97 -0
  126. data/grammars/source.java.json +1026 -0
  127. data/grammars/source.jcl.json +49 -0
  128. data/grammars/source.jflex.json +490 -0
  129. data/grammars/source.jq.json +218 -0
  130. data/grammars/source.js.json +948 -0
  131. data/grammars/source.js.jsx.json +2937 -0
  132. data/grammars/source.js.objj.json +424 -0
  133. data/grammars/source.js.regexp.json +150 -0
  134. data/grammars/source.js.regexp.replacement.json +30 -0
  135. data/grammars/source.json.json +149 -0
  136. data/grammars/source.julia.json +407 -0
  137. data/grammars/source.lean.json +145 -0
  138. data/grammars/source.lid.json +23 -0
  139. data/grammars/source.lilypond.json +623 -0
  140. data/grammars/source.lisp.json +111 -0
  141. data/grammars/source.litcoffee.json +669 -0
  142. data/grammars/source.livescript.json +616 -0
  143. data/grammars/source.llvm.json +71 -0
  144. data/grammars/source.logos.json +31 -0
  145. data/grammars/source.logtalk.json +315 -0
  146. data/grammars/source.loomscript.json +214 -0
  147. data/grammars/source.lsl.json +216 -0
  148. data/grammars/source.lua.json +191 -0
  149. data/grammars/source.makefile.json +474 -0
  150. data/grammars/source.makegen.json +13 -0
  151. data/grammars/source.man.json +53 -0
  152. data/grammars/source.mask.json +701 -0
  153. data/grammars/source.mata.json +133 -0
  154. data/grammars/source.mathematica.json +429 -0
  155. data/grammars/source.matlab.json +776 -0
  156. data/grammars/source.mercury.json +251 -0
  157. data/grammars/source.ml.json +291 -0
  158. data/grammars/source.modelica.json +142 -0
  159. data/grammars/source.modula2.json +103 -0
  160. data/grammars/source.monkey.json +701 -0
  161. data/grammars/source.moonscript.json +149 -0
  162. data/grammars/source.mupad.json +149 -0
  163. data/grammars/source.nant-build.json +86 -0
  164. data/grammars/source.ncl.json +66 -0
  165. data/grammars/source.nemerle.json +137 -0
  166. data/grammars/source.nesc.json +27 -0
  167. data/grammars/source.netlinx.erb.json +47 -0
  168. data/grammars/source.netlinx.json +768 -0
  169. data/grammars/source.nginx.json +797 -0
  170. data/grammars/source.nim.json +1150 -0
  171. data/grammars/source.nim_filter.json +133 -0
  172. data/grammars/source.nimcfg.json +116 -0
  173. data/grammars/source.ninja.json +66 -0
  174. data/grammars/source.nit.json +238 -0
  175. data/grammars/source.nix.json +1200 -0
  176. data/grammars/source.nmml.json +87 -0
  177. data/grammars/source.nsis.json +150 -0
  178. data/grammars/source.objc++.json +19 -0
  179. data/grammars/source.objc.json +918 -0
  180. data/grammars/source.objc.platform.json +277 -0
  181. data/grammars/source.ocaml.json +1426 -0
  182. data/grammars/source.ocamllex.json +305 -0
  183. data/grammars/source.ocamlyacc.json +346 -0
  184. data/grammars/source.octave.json +451 -0
  185. data/grammars/source.ooc.json +692 -0
  186. data/grammars/source.opa.json +206 -0
  187. data/grammars/source.opal.json +415 -0
  188. data/grammars/source.opalsysdefs.json +70 -0
  189. data/grammars/source.opencobol.json +65 -0
  190. data/grammars/source.ox.json +97 -0
  191. data/grammars/source.oz.json +84 -0
  192. data/grammars/source.papyrus-assembly.json +266 -0
  193. data/grammars/source.papyrus.json +231 -0
  194. data/grammars/source.parrot.pir.json +117 -0
  195. data/grammars/source.pascal.json +150 -0
  196. data/grammars/source.perl.6.json +310 -0
  197. data/grammars/source.perl.json +2413 -0
  198. data/grammars/source.php.zephir.json +362 -0
  199. data/grammars/source.pig_latin.json +172 -0
  200. data/grammars/source.pike.json +62 -0
  201. data/grammars/source.plsql.oracle.json +642 -0
  202. data/grammars/source.po.json +232 -0
  203. data/grammars/source.pogoscript.json +85 -0
  204. data/grammars/source.postscript.json +231 -0
  205. data/grammars/source.powershell.json +755 -0
  206. data/grammars/source.processing.json +885 -0
  207. data/grammars/source.prolog.eclipse.json +206 -0
  208. data/grammars/source.prolog.json +292 -0
  209. data/grammars/source.protobuf.json +395 -0
  210. data/grammars/source.pubspec.json +13 -0
  211. data/grammars/source.puppet.json +494 -0
  212. data/grammars/source.purescript.json +818 -0
  213. data/grammars/source.pyjade.json +1010 -0
  214. data/grammars/source.python.django.json +34 -0
  215. data/grammars/source.python.json +1960 -0
  216. data/grammars/source.python.salt.json +13 -0
  217. data/grammars/source.qmake.json +217 -0
  218. data/grammars/source.qml.json +195 -0
  219. data/grammars/source.r.json +203 -0
  220. data/grammars/source.racket.json +119 -0
  221. data/grammars/source.rebol.json +647 -0
  222. data/grammars/source.red.json +652 -0
  223. data/grammars/source.regexp.babel.json +190 -0
  224. data/grammars/source.regexp.python.json +187 -0
  225. data/grammars/source.regexp.spin.json +188 -0
  226. data/grammars/source.ruby.json +1956 -0
  227. data/grammars/source.ruby.rspec.cucumber.steps.json +274 -0
  228. data/grammars/source.rust.json +269 -0
  229. data/grammars/source.sas.json +322 -0
  230. data/grammars/source.sas_log.json +26 -0
  231. data/grammars/source.sass.json +248 -0
  232. data/grammars/source.sbt.json +36 -0
  233. data/grammars/source.scad.json +152 -0
  234. data/grammars/source.scala.json +739 -0
  235. data/grammars/source.scaml.json +466 -0
  236. data/grammars/source.scheme.json +370 -0
  237. data/grammars/source.scilab.json +103 -0
  238. data/grammars/source.scss.json +1321 -0
  239. data/grammars/source.shell.json +1212 -0
  240. data/grammars/source.smali.json +1668 -0
  241. data/grammars/source.smalltalk.json +135 -0
  242. data/grammars/source.smt.json +173 -0
  243. data/grammars/source.sp.json +118 -0
  244. data/grammars/source.sparql.json +23 -0
  245. data/grammars/source.spin.json +936 -0
  246. data/grammars/source.sqf.json +112 -0
  247. data/grammars/source.sql.json +473 -0
  248. data/grammars/source.stata.json +208 -0
  249. data/grammars/source.strings.json +53 -0
  250. data/grammars/source.stylus.json +1021 -0
  251. data/grammars/source.swift.json +965 -0
  252. data/grammars/source.systemverilog.json +1050 -0
  253. data/grammars/source.tcl.json +277 -0
  254. data/grammars/source.tea.json +180 -0
  255. data/grammars/source.thrift.json +704 -0
  256. data/grammars/source.toml.json +327 -0
  257. data/grammars/source.ts.json +1094 -0
  258. data/grammars/source.tsx.json +1324 -0
  259. data/grammars/source.turtle.json +505 -0
  260. data/grammars/source.txl.json +62 -0
  261. data/grammars/source.ucfconstraints.json +72 -0
  262. data/grammars/source.vala.json +814 -0
  263. data/grammars/source.varnish.vcl.json +343 -0
  264. data/grammars/source.vbnet.json +338 -0
  265. data/grammars/source.verilog.json +302 -0
  266. data/grammars/source.vhdl.json +1349 -0
  267. data/grammars/source.viml.json +224 -0
  268. data/grammars/source.webidl.json +814 -0
  269. data/grammars/source.x10.json +68 -0
  270. data/grammars/source.x86asm.json +47 -0
  271. data/grammars/source.xc.json +379 -0
  272. data/grammars/source.xq.json +241 -0
  273. data/grammars/source.xquery.json +193 -0
  274. data/grammars/source.xtend.json +733 -0
  275. data/grammars/source.yaml.json +334 -0
  276. data/grammars/source.yaml.salt.json +348 -0
  277. data/grammars/text.bibtex.json +251 -0
  278. data/grammars/text.cfml.basic.json +736 -0
  279. data/grammars/text.dart-analysis-output.json +162 -0
  280. data/grammars/text.dart-doccomments.json +19 -0
  281. data/grammars/text.elixir.json +45 -0
  282. data/grammars/text.gherkin.feature.json +135 -0
  283. data/grammars/text.groff.json +113 -0
  284. data/grammars/text.haml.json +299 -0
  285. data/grammars/text.html.abl.json +24 -0
  286. data/grammars/text.html.asciidoc.json +492 -0
  287. data/grammars/text.html.asdoc.json +541 -0
  288. data/grammars/text.html.asp.json +58 -0
  289. data/grammars/text.html.basic.json +552 -0
  290. data/grammars/text.html.cfm.json +811 -0
  291. data/grammars/text.html.creole.json +329 -0
  292. data/grammars/text.html.django.json +69 -0
  293. data/grammars/text.html.elixir.json +18 -0
  294. data/grammars/text.html.erb.json +157 -0
  295. data/grammars/text.html.erlang.yaws.json +72 -0
  296. data/grammars/text.html.factor.json +27 -0
  297. data/grammars/text.html.handlebars.json +783 -0
  298. data/grammars/text.html.jsp.json +1203 -0
  299. data/grammars/text.html.liquid.json +35 -0
  300. data/grammars/text.html.mako.json +729 -0
  301. data/grammars/text.html.markdown.source.gfm.apib.json +1297 -0
  302. data/grammars/text.html.markdown.source.gfm.mson.json +1165 -0
  303. data/grammars/text.html.mediawiki.json +972 -0
  304. data/grammars/text.html.php.json +2607 -0
  305. data/grammars/text.html.slash.json +313 -0
  306. data/grammars/text.html.smarty.json +216 -0
  307. data/grammars/text.html.ssp.json +49 -0
  308. data/grammars/text.html.tcl.json +44 -0
  309. data/grammars/text.html.twig.json +1353 -0
  310. data/grammars/text.html.vue.json +642 -0
  311. data/grammars/text.idl-idldoc.json +14 -0
  312. data/grammars/text.junit-test-report.json +92 -0
  313. data/grammars/text.log.latex.json +86 -0
  314. data/grammars/text.python.console.json +25 -0
  315. data/grammars/text.python.traceback.json +46 -0
  316. data/grammars/text.rdoc.json +48 -0
  317. data/grammars/text.restructuredtext.json +561 -0
  318. data/grammars/text.robot.json +73 -0
  319. data/grammars/text.shell-session.json +48 -0
  320. data/grammars/text.slim.json +527 -0
  321. data/grammars/text.tex.json +271 -0
  322. data/grammars/text.tex.latex.beamer.json +63 -0
  323. data/grammars/text.tex.latex.haskell.json +56 -0
  324. data/grammars/text.tex.latex.json +1013 -0
  325. data/grammars/text.tex.latex.memoir.json +99 -0
  326. data/grammars/text.tex.latex.rd.json +117 -0
  327. data/grammars/text.xml.ant.json +202 -0
  328. data/grammars/text.xml.flex-config.json +2634 -0
  329. data/grammars/text.xml.genshi.json +34 -0
  330. data/grammars/text.xml.json +364 -0
  331. data/grammars/text.xml.pom.json +774 -0
  332. data/grammars/text.xml.xsl.json +94 -0
  333. data/grammars/text.zone_file.json +72 -0
  334. data/lib/linguist/grammars.rb +13 -0
  335. metadata +389 -0
@@ -0,0 +1,34 @@
1
+ {
2
+ "fileTypes": [
3
+
4
+ ],
5
+ "keyEquivalent": "^~P",
6
+ "name": "Python Django",
7
+ "patterns": [
8
+ {
9
+ "match": "(meta|models)\\.(Admin|AutoField|BooleanField|CharField|CommaSeparatedIntegerField|DateField|DateTimeField|DecimalField|EmailField|FileField|FilePathField|FloatField|ForeignKey|ImageField|IntegerField|IPAddressField|ManyToManyField|NullBooleanField|OneToOneField|PhoneNumberField|PositiveIntegerField|PositiveSmallIntegerField|SlugField|SmallIntegerField|TextField|TimeField|URLField|USStateField|XMLField)",
10
+ "name": "support.type.django.model"
11
+ },
12
+ {
13
+ "match": "django(\\.[a-z]+){1,} ",
14
+ "name": "support.other.django.module"
15
+ },
16
+ {
17
+ "match": "(ABSOLUTE_URL_OVERRIDES|ADMIN_FOR|ADMIN_MEDIA_PREFIX|ADMINS|ALLOWED_INCLUDE_ROOTS|APPEND_SLASH|AUTHENTICATION_BACKENDS|AUTH_PROFILE_MODULE|CACHE_BACKEND|CACHE_MIDDLEWARE_KEY_PREFIX|CACHE_MIDDLEWARE_SECONDS|DATABASE_ENGINE|DATABASE_HOST|DATABASE_NAME|DATABASE_OPTIONS|DATABASE_PASSWORD|DATABASE_PORT|DATABASE_USER|DATE_FORMAT|DATETIME_FORMAT|DEBUG|DEFAULT_CHARSET|DEFAULT_CONTENT_TYPE|DEFAULT_FROM_EMAIL|DEFAULT_TABLESPACE|DEFAULT_INDEX_TABLESPACE|DISALLOWED_USER_AGENTS|EMAIL_HOST_PASSWORD|EMAIL_HOST_USER|EMAIL_HOST|EMAIL_PORT|EMAIL_SUBJECT_PREFIX|EMAIL_USE_TLS|FILE_CHARSET|FIXTURE_DIRS|IGNORABLE_404_ENDS|IGNORABLE_404_STARTS|INSTALLED_APPS|INTERNAL_IPS|JING_PATH|LANGUAGE_CODE|LANGUAGE_COOKIE_NAME|LANGUAGES|LOCALE_PATHS|LOGIN_REDIRECT_URL|LOGIN_URL|LOGOUT_URL|MANAGERS|MEDIA_ROOT|MEDIA_URL|MIDDLEWARE_CLASSES|MONTH_DAY_FORMAT|PREPEND_WWW|PROFANITIES_LIST|ROOT_URLCONF|SECRET_KEY|SEND_BROKEN_LINK_EMAILS|SERIALIZATION_MODULES|SERVER_EMAIL|SESSION_ENGINE|SESSION_COOKIE_AGE|SESSION_COOKIE_DOMAIN|SESSION_COOKIE_NAME|SESSION_COOKIE_PATH|SESSION_COOKIE_SECURE|SESSION_EXPIRE_AT_BROWSER_CLOSE|SESSION_FILE_PATH|SESSION_SAVE_EVERY_REQUEST|SITE_ID|TEMPLATE_CONTEXT_PROCESSORS|TEMPLATE_DEBUG|TEMPLATE_DIRS|TEMPLATE_LOADERS|TEMPLATE_STRING_IF_INVALID|TEST_DATABASE_CHARSET|TEST_DATABASE_COLLATION|TEST_DATABASE_NAME|TEST_RUNNER|TIME_FORMAT|TIME_ZONE|URL_VALIDATOR_USER_AGENT|USE_ETAGS|USE_I18N|YEAR_MONTH_FORMAT)",
18
+ "name": "variable.other.django.settings"
19
+ },
20
+ {
21
+ "match": "(get_list_or_404|get_object_or_404|load_and_render|loader|render_to_response)",
22
+ "name": "support.function.django.view"
23
+ },
24
+ {
25
+ "match": "[a-z_]+\\.get_(object|list|iterator|count|values|values_iterator|in_bulk)",
26
+ "name": "support.function.django.model"
27
+ },
28
+ {
29
+ "include": "source.python"
30
+ }
31
+ ],
32
+ "scopeName": "source.python.django",
33
+ "uuid": "5326D56C-6F76-4758-8DB7-D818527919AC"
34
+ }
@@ -0,0 +1,1960 @@
1
+ {
2
+ "scopeName": "source.python",
3
+ "name": "Python",
4
+ "fileTypes": [
5
+ "cpy",
6
+ "gyp",
7
+ "gypi",
8
+ "kv",
9
+ "py",
10
+ "pyw",
11
+ "rpy",
12
+ "SConscript",
13
+ "SConstruct",
14
+ "Sconstruct",
15
+ "sconstruct",
16
+ "Snakefile",
17
+ "tac",
18
+ "wsgi"
19
+ ],
20
+ "firstLineMatch": "^#!/.*\\bpython[\\d\\.]*\\b",
21
+ "patterns": [
22
+ {
23
+ "include": "#line_comments"
24
+ },
25
+ {
26
+ "match": "\\b(?i:(0x\\h*)L)",
27
+ "name": "constant.numeric.integer.long.hexadecimal.python"
28
+ },
29
+ {
30
+ "match": "\\b(?i:(0x\\h*))",
31
+ "name": "constant.numeric.integer.hexadecimal.python"
32
+ },
33
+ {
34
+ "match": "\\b(?i:(0o?[0-7]+)L)",
35
+ "name": "constant.numeric.integer.long.octal.python"
36
+ },
37
+ {
38
+ "match": "\\b(?i:(0o?[0-7]+))",
39
+ "name": "constant.numeric.integer.octal.python"
40
+ },
41
+ {
42
+ "match": "\\b(?i:(0b[01]+)L)",
43
+ "name": "constant.numeric.integer.long.binary.python"
44
+ },
45
+ {
46
+ "match": "\\b(?i:(0b[01]+))",
47
+ "name": "constant.numeric.integer.binary.python"
48
+ },
49
+ {
50
+ "match": "\\b(?i:(((\\d+(\\.(?=[^a-zA-Z_])\\d*)?|(?<=[^0-9a-zA-Z_])\\.\\d+)(e[\\-\\+]?\\d+)?))J)",
51
+ "name": "constant.numeric.complex.python"
52
+ },
53
+ {
54
+ "match": "\\b(?i:(\\d+\\.\\d*(e[\\-\\+]?\\d+)?))(?=[^a-zA-Z_])",
55
+ "name": "constant.numeric.float.python"
56
+ },
57
+ {
58
+ "match": "(?<=[^0-9a-zA-Z_])(?i:(\\.\\d+(e[\\-\\+]?\\d+)?))",
59
+ "name": "constant.numeric.float.python"
60
+ },
61
+ {
62
+ "match": "\\b(?i:(\\d+e[\\-\\+]?\\d+))",
63
+ "name": "constant.numeric.float.python"
64
+ },
65
+ {
66
+ "match": "\\b(?i:([1-9]+[0-9]*|0)L)",
67
+ "name": "constant.numeric.integer.long.decimal.python"
68
+ },
69
+ {
70
+ "match": "\\b([1-9]+[0-9]*|0)",
71
+ "name": "constant.numeric.integer.decimal.python"
72
+ },
73
+ {
74
+ "captures": {
75
+ "1": {
76
+ "name": "storage.modifier.global.python"
77
+ }
78
+ },
79
+ "match": "\\b(global)\\b"
80
+ },
81
+ {
82
+ "captures": {
83
+ "1": {
84
+ "name": "storage.modifier.nonlocal.python"
85
+ }
86
+ },
87
+ "match": "\\b(nonlocal)\\b"
88
+ },
89
+ {
90
+ "captures": {
91
+ "1": {
92
+ "name": "keyword.control.import.python"
93
+ },
94
+ "2": {
95
+ "name": "keyword.control.import.from.python"
96
+ }
97
+ },
98
+ "match": "\\b(?:(import)|(from))\\b"
99
+ },
100
+ {
101
+ "comment": "keywords that delimit flow conditionals",
102
+ "name": "keyword.control.conditional.python",
103
+ "match": "\\b(if|elif|else)\\b"
104
+ },
105
+ {
106
+ "comment": "keywords that delimit an exception",
107
+ "name": "keyword.control.exception.python",
108
+ "match": "\\b(except|finally|try|raise)\\b"
109
+ },
110
+ {
111
+ "comment": "keywords that delimit loops",
112
+ "name": "keyword.control.repeat.python",
113
+ "match": "\\b(for|while)\\b"
114
+ },
115
+ {
116
+ "comment": "keywords that alter flow from within a block",
117
+ "name": "keyword.control.statement.python",
118
+ "match": "\\b(with|break|continue|pass|return|yield)\\b"
119
+ },
120
+ {
121
+ "comment": "keyword operators that evaluate to True or False",
122
+ "match": "\\b(and|in|is|not|or)\\b",
123
+ "name": "keyword.operator.logical.python"
124
+ },
125
+ {
126
+ "captures": {
127
+ "1": {
128
+ "name": "keyword.other.python"
129
+ }
130
+ },
131
+ "comment": "keywords that haven't fit into other groups (yet).",
132
+ "match": "\\b(as|assert|del|exec|print)\\b"
133
+ },
134
+ {
135
+ "match": "<>",
136
+ "name": "invalid.deprecated.operator.python"
137
+ },
138
+ {
139
+ "match": "<\\=|>\\=|\\=\\=|<|>|\\!\\=",
140
+ "name": "keyword.operator.comparison.python"
141
+ },
142
+ {
143
+ "match": "\\+\\=|-\\=|\\*\\=|/\\=|//\\=|%\\=|&\\=|\\|\\=|\\^\\=|>>\\=|<<\\=|\\*\\*\\=",
144
+ "name": "keyword.operator.assignment.augmented.python"
145
+ },
146
+ {
147
+ "match": "\\+|\\-|\\*|\\*\\*|/|//|%|<<|>>|&|\\||\\^|~",
148
+ "name": "keyword.operator.arithmetic.python"
149
+ },
150
+ {
151
+ "match": "\\=",
152
+ "name": "keyword.operator.assignment.python"
153
+ },
154
+ {
155
+ "begin": "^\\s*(class)\\s+(?=[a-zA-Z_][a-zA-Z_0-9]*\\s*\\:)",
156
+ "beginCaptures": {
157
+ "1": {
158
+ "name": "storage.type.class.python"
159
+ }
160
+ },
161
+ "contentName": "entity.name.type.class.python",
162
+ "end": "\\s*(:)",
163
+ "endCaptures": {
164
+ "1": {
165
+ "name": "punctuation.section.class.begin.python"
166
+ }
167
+ },
168
+ "name": "meta.class.old-style.python",
169
+ "patterns": [
170
+ {
171
+ "include": "#entity_name_class"
172
+ }
173
+ ]
174
+ },
175
+ {
176
+ "begin": "^\\s*(class)\\s+(?=[a-zA-Z_][a-zA-Z_0-9]*\\s*\\()",
177
+ "beginCaptures": {
178
+ "1": {
179
+ "name": "storage.type.class.python"
180
+ }
181
+ },
182
+ "end": "(\\))\\s*(?:(\\:)|(.*$\\n?))",
183
+ "endCaptures": {
184
+ "1": {
185
+ "name": "punctuation.definition.inheritance.end.python"
186
+ },
187
+ "2": {
188
+ "name": "punctuation.section.class.begin.python"
189
+ },
190
+ "3": {
191
+ "name": "invalid.illegal.missing-section-begin.python"
192
+ }
193
+ },
194
+ "name": "meta.class.python",
195
+ "patterns": [
196
+ {
197
+ "begin": "(?=[A-Za-z_][A-Za-z0-9_]*)",
198
+ "contentName": "entity.name.type.class.python",
199
+ "end": "(?![A-Za-z0-9_])",
200
+ "patterns": [
201
+ {
202
+ "include": "#entity_name_class"
203
+ }
204
+ ]
205
+ },
206
+ {
207
+ "begin": "(\\()",
208
+ "beginCaptures": {
209
+ "1": {
210
+ "name": "punctuation.definition.inheritance.begin.python"
211
+ }
212
+ },
213
+ "contentName": "meta.class.inheritance.python",
214
+ "end": "(?=\\)|:)",
215
+ "patterns": [
216
+ {
217
+ "begin": "(?<=\\(|,)\\s*",
218
+ "contentName": "entity.other.inherited-class.python",
219
+ "end": "\\s*(?:(,)|(?=\\)))",
220
+ "endCaptures": {
221
+ "1": {
222
+ "name": "punctuation.separator.inheritance.python"
223
+ }
224
+ },
225
+ "patterns": [
226
+ {
227
+ "include": "$self"
228
+ }
229
+ ]
230
+ }
231
+ ]
232
+ }
233
+ ]
234
+ },
235
+ {
236
+ "begin": "^\\s*(class)\\s+(?=[a-zA-Z_][a-zA-Z_0-9])",
237
+ "beginCaptures": {
238
+ "1": {
239
+ "name": "storage.type.class.python"
240
+ }
241
+ },
242
+ "end": "(\\()|(\\s*$\\n?|#.*$\\n?)",
243
+ "endCaptures": {
244
+ "1": {
245
+ "name": "punctuation.definition.inheritance.begin.python"
246
+ },
247
+ "2": {
248
+ "name": "invalid.illegal.missing-inheritance.python"
249
+ }
250
+ },
251
+ "name": "meta.class.python",
252
+ "patterns": [
253
+ {
254
+ "begin": "(?=[A-Za-z_][A-Za-z0-9_]*)",
255
+ "contentName": "entity.name.type.class.python",
256
+ "end": "(?![A-Za-z0-9_])",
257
+ "patterns": [
258
+ {
259
+ "include": "#entity_name_function"
260
+ }
261
+ ]
262
+ }
263
+ ]
264
+ },
265
+ {
266
+ "begin": "^\\s*(def)\\s+(?=[A-Za-z_][A-Za-z0-9_]*\\s*\\()",
267
+ "beginCaptures": {
268
+ "1": {
269
+ "name": "storage.type.function.python"
270
+ }
271
+ },
272
+ "end": "(\\))\\s*(?:(\\:)|(.*$\\n?))",
273
+ "endCaptures": {
274
+ "1": {
275
+ "name": "punctuation.definition.parameters.end.python"
276
+ },
277
+ "2": {
278
+ "name": "punctuation.section.function.begin.python"
279
+ },
280
+ "3": {
281
+ "name": "invalid.illegal.missing-section-begin.python"
282
+ }
283
+ },
284
+ "name": "meta.function.python",
285
+ "patterns": [
286
+ {
287
+ "begin": "(?=[A-Za-z_][A-Za-z0-9_]*)",
288
+ "contentName": "entity.name.function.python",
289
+ "end": "(?![A-Za-z0-9_])",
290
+ "patterns": [
291
+ {
292
+ "include": "#entity_name_function"
293
+ }
294
+ ]
295
+ },
296
+ {
297
+ "begin": "(\\()",
298
+ "beginCaptures": {
299
+ "1": {
300
+ "name": "punctuation.definition.parameters.begin.python"
301
+ }
302
+ },
303
+ "contentName": "meta.function.parameters.python",
304
+ "end": "(?=\\)\\s*\\:)",
305
+ "patterns": [
306
+ {
307
+ "include": "#line_comments"
308
+ },
309
+ {
310
+ "include": "#keyword_arguments"
311
+ },
312
+ {
313
+ "captures": {
314
+ "1": {
315
+ "name": "variable.parameter.function.python"
316
+ },
317
+ "2": {
318
+ "name": "punctuation.separator.parameters.python"
319
+ }
320
+ },
321
+ "match": "\\b([a-zA-Z_][a-zA-Z_0-9]*)\\s*(?:(,)|(?=[\\n\\)]))"
322
+ }
323
+ ]
324
+ }
325
+ ]
326
+ },
327
+ {
328
+ "begin": "^\\s*(def)\\s+(?=[A-Za-z_][A-Za-z0-9_]*)",
329
+ "beginCaptures": {
330
+ "1": {
331
+ "name": "storage.type.function.python"
332
+ }
333
+ },
334
+ "end": "(\\()|\\s*($\\n?|#.*$\\n?)",
335
+ "endCaptures": {
336
+ "1": {
337
+ "name": "punctuation.definition.parameters.begin.python"
338
+ },
339
+ "2": {
340
+ "name": "invalid.illegal.missing-parameters.python"
341
+ }
342
+ },
343
+ "name": "meta.function.python",
344
+ "patterns": [
345
+ {
346
+ "begin": "(?=[A-Za-z_][A-Za-z0-9_]*)",
347
+ "contentName": "entity.name.function.python",
348
+ "end": "(?![A-Za-z0-9_])",
349
+ "patterns": [
350
+ {
351
+ "include": "#entity_name_function"
352
+ }
353
+ ]
354
+ }
355
+ ]
356
+ },
357
+ {
358
+ "begin": "(lambda)(?=\\s+)",
359
+ "beginCaptures": {
360
+ "1": {
361
+ "name": "storage.type.function.inline.python"
362
+ }
363
+ },
364
+ "end": "(\\:)",
365
+ "endCaptures": {
366
+ "1": {
367
+ "name": "punctuation.definition.parameters.end.python"
368
+ },
369
+ "2": {
370
+ "name": "punctuation.section.function.begin.python"
371
+ },
372
+ "3": {
373
+ "name": "invalid.illegal.missing-section-begin.python"
374
+ }
375
+ },
376
+ "name": "meta.function.inline.python",
377
+ "patterns": [
378
+ {
379
+ "begin": "\\s+",
380
+ "contentName": "meta.function.inline.parameters.python",
381
+ "end": "(?=\\:)",
382
+ "patterns": [
383
+ {
384
+ "include": "#keyword_arguments"
385
+ },
386
+ {
387
+ "captures": {
388
+ "1": {
389
+ "name": "variable.parameter.function.python"
390
+ },
391
+ "2": {
392
+ "name": "punctuation.separator.parameters.python"
393
+ }
394
+ },
395
+ "match": "\\b([a-zA-Z_][a-zA-Z_0-9]*)\\s*(?:(,)|(?=[\\n\\)\\:]))"
396
+ }
397
+ ]
398
+ }
399
+ ]
400
+ },
401
+ {
402
+ "begin": "^\\s*(?=@\\s*[A-Za-z_][A-Za-z0-9_]*(?:\\.[a-zA-Z_][a-zA-Z_0-9]*)*\\s*\\()",
403
+ "comment": "a decorator may be a function call which returns a decorator.",
404
+ "end": "(\\))",
405
+ "endCaptures": {
406
+ "1": {
407
+ "name": "punctuation.definition.arguments.end.python"
408
+ }
409
+ },
410
+ "name": "meta.function.decorator.python",
411
+ "patterns": [
412
+ {
413
+ "begin": "(?=(@)\\s*[A-Za-z_][A-Za-z0-9_]*(?:\\.[A-Za-z_][A-Za-z0-9_]*)*\\s*\\()",
414
+ "beginCaptures": {
415
+ "1": {
416
+ "name": "punctuation.definition.decorator.python"
417
+ }
418
+ },
419
+ "contentName": "entity.name.function.decorator.python",
420
+ "end": "(?=\\s*\\()",
421
+ "patterns": [
422
+ {
423
+ "include": "#dotted_name"
424
+ }
425
+ ]
426
+ },
427
+ {
428
+ "begin": "(\\()",
429
+ "beginCaptures": {
430
+ "1": {
431
+ "name": "punctuation.definition.arguments.begin.python"
432
+ }
433
+ },
434
+ "contentName": "meta.function.decorator.arguments.python",
435
+ "end": "(?=\\))",
436
+ "patterns": [
437
+ {
438
+ "include": "#keyword_arguments"
439
+ },
440
+ {
441
+ "include": "$self"
442
+ }
443
+ ]
444
+ }
445
+ ]
446
+ },
447
+ {
448
+ "begin": "^\\s*(?=@\\s*[A-Za-z_][A-Za-z0-9_]*(?:\\.[a-zA-Z_][a-zA-Z_0-9]*)*)",
449
+ "contentName": "entity.name.function.decorator.python",
450
+ "end": "(?=\\s|$\\n?|#)",
451
+ "name": "meta.function.decorator.python",
452
+ "patterns": [
453
+ {
454
+ "begin": "(?=(@)\\s*[A-Za-z_][A-Za-z0-9_]*(\\.[A-Za-z_][A-Za-z0-9_]*)*)",
455
+ "beginCaptures": {
456
+ "1": {
457
+ "name": "punctuation.definition.decorator.python"
458
+ }
459
+ },
460
+ "end": "(?=\\s|$\\n?|#)",
461
+ "patterns": [
462
+ {
463
+ "include": "#dotted_name"
464
+ }
465
+ ]
466
+ }
467
+ ]
468
+ },
469
+ {
470
+ "begin": "(?<=\\)|\\])\\s*(\\()",
471
+ "beginCaptures": {
472
+ "1": {
473
+ "name": "punctuation.definition.arguments.begin.python"
474
+ }
475
+ },
476
+ "contentName": "meta.function-call.arguments.python",
477
+ "end": "(\\))",
478
+ "endCaptures": {
479
+ "1": {
480
+ "name": "punctuation.definition.arguments.end.python"
481
+ }
482
+ },
483
+ "name": "meta.function-call.python",
484
+ "patterns": [
485
+ {
486
+ "include": "#keyword_arguments"
487
+ },
488
+ {
489
+ "include": "$self"
490
+ }
491
+ ]
492
+ },
493
+ {
494
+ "begin": "(?=[A-Za-z_][A-Za-z0-9_]*(?:\\.[a-zA-Z_][a-zA-Z_0-9]*)*\\s*\\()",
495
+ "end": "(\\))",
496
+ "endCaptures": {
497
+ "1": {
498
+ "name": "punctuation.definition.arguments.end.python"
499
+ }
500
+ },
501
+ "name": "meta.function-call.python",
502
+ "patterns": [
503
+ {
504
+ "begin": "(?=[A-Za-z_][A-Za-z0-9_]*(?:\\.[A-Za-z_][A-Za-z0-9_]*)*\\s*\\()",
505
+ "end": "(?=\\s*\\()",
506
+ "patterns": [
507
+ {
508
+ "include": "#dotted_name"
509
+ }
510
+ ]
511
+ },
512
+ {
513
+ "begin": "(\\()",
514
+ "beginCaptures": {
515
+ "1": {
516
+ "name": "punctuation.definition.arguments.begin.python"
517
+ }
518
+ },
519
+ "contentName": "meta.function-call.arguments.python",
520
+ "end": "(?=\\))",
521
+ "patterns": [
522
+ {
523
+ "include": "#keyword_arguments"
524
+ },
525
+ {
526
+ "include": "$self"
527
+ }
528
+ ]
529
+ }
530
+ ]
531
+ },
532
+ {
533
+ "begin": "(?=[A-Za-z_][A-Za-z0-9_]*(?:\\.[a-zA-Z_][a-zA-Z_0-9]*)*\\s*\\[)",
534
+ "end": "(\\])",
535
+ "endCaptures": {
536
+ "1": {
537
+ "name": "punctuation.definition.arguments.end.python"
538
+ }
539
+ },
540
+ "name": "meta.item-access.python",
541
+ "patterns": [
542
+ {
543
+ "begin": "(?=[A-Za-z_][A-Za-z0-9_]*(?:\\.[A-Za-z_][A-Za-z0-9_]*)*\\s*\\[)",
544
+ "end": "(?=\\s*\\[)",
545
+ "patterns": [
546
+ {
547
+ "include": "#dotted_name"
548
+ }
549
+ ]
550
+ },
551
+ {
552
+ "begin": "(\\[)",
553
+ "beginCaptures": {
554
+ "1": {
555
+ "name": "punctuation.definition.arguments.begin.python"
556
+ }
557
+ },
558
+ "contentName": "meta.item-access.arguments.python",
559
+ "end": "(?=\\])",
560
+ "patterns": [
561
+ {
562
+ "include": "$self"
563
+ }
564
+ ]
565
+ }
566
+ ]
567
+ },
568
+ {
569
+ "begin": "(?<=\\)|\\])\\s+(\\[)",
570
+ "beginCaptures": {
571
+ "1": {
572
+ "name": "punctuation.definition.arguments.begin.python"
573
+ }
574
+ },
575
+ "contentName": "meta.item-access.arguments.python",
576
+ "end": "(\\])",
577
+ "endCaptures": {
578
+ "1": {
579
+ "name": "punctuation.definition.arguments.end.python"
580
+ }
581
+ },
582
+ "name": "meta.item-access.python",
583
+ "patterns": [
584
+ {
585
+ "include": "$self"
586
+ }
587
+ ]
588
+ },
589
+ {
590
+ "captures": {
591
+ "1": {
592
+ "name": "storage.type.function.python"
593
+ }
594
+ },
595
+ "match": "\\b(def|lambda)\\b"
596
+ },
597
+ {
598
+ "captures": {
599
+ "1": {
600
+ "name": "storage.type.class.python"
601
+ }
602
+ },
603
+ "match": "\\b(class)\\b"
604
+ },
605
+ {
606
+ "include": "#line_continuation"
607
+ },
608
+ {
609
+ "match": "\\b(None|True|False|Ellipsis|NotImplemented)\\b",
610
+ "name": "constant.language.python"
611
+ },
612
+ {
613
+ "include": "#string_quoted_single"
614
+ },
615
+ {
616
+ "include": "#string_quoted_double"
617
+ },
618
+ {
619
+ "include": "#dotted_name"
620
+ },
621
+ {
622
+ "include": "#language_variables"
623
+ },
624
+ {
625
+ "begin": "(\\()",
626
+ "end": "(\\))",
627
+ "patterns": [
628
+ {
629
+ "include": "$self"
630
+ }
631
+ ]
632
+ },
633
+ {
634
+ "captures": {
635
+ "1": {
636
+ "name": "punctuation.definition.list.begin.python"
637
+ },
638
+ "2": {
639
+ "name": "meta.empty-list.python"
640
+ },
641
+ "3": {
642
+ "name": "punctuation.definition.list.end.python"
643
+ }
644
+ },
645
+ "match": "(\\[)(\\s*(\\]))\\b"
646
+ },
647
+ {
648
+ "begin": "(\\[)",
649
+ "beginCaptures": {
650
+ "1": {
651
+ "name": "punctuation.definition.list.begin.python"
652
+ }
653
+ },
654
+ "end": "(\\])",
655
+ "endCaptures": {
656
+ "1": {
657
+ "name": "punctuation.definition.list.end.python"
658
+ }
659
+ },
660
+ "name": "meta.structure.list.python",
661
+ "patterns": [
662
+ {
663
+ "begin": "(?<=\\[|\\,)\\s*(?![\\],])",
664
+ "contentName": "meta.structure.list.item.python",
665
+ "end": "\\s*(?:(,)|(?=\\]))",
666
+ "endCaptures": {
667
+ "1": {
668
+ "name": "punctuation.separator.list.python"
669
+ }
670
+ },
671
+ "patterns": [
672
+ {
673
+ "include": "$self"
674
+ }
675
+ ]
676
+ }
677
+ ]
678
+ },
679
+ {
680
+ "captures": {
681
+ "1": {
682
+ "name": "punctuation.definition.tuple.begin.python"
683
+ },
684
+ "2": {
685
+ "name": "meta.empty-tuple.python"
686
+ },
687
+ "3": {
688
+ "name": "punctuation.definition.tuple.end.python"
689
+ }
690
+ },
691
+ "match": "(\\()(\\s*(\\)))",
692
+ "name": "meta.structure.tuple.python"
693
+ },
694
+ {
695
+ "captures": {
696
+ "1": {
697
+ "name": "punctuation.definition.dictionary.begin.python"
698
+ },
699
+ "2": {
700
+ "name": "meta.empty-dictionary.python"
701
+ },
702
+ "3": {
703
+ "name": "punctuation.definition.dictionary.end.python"
704
+ }
705
+ },
706
+ "match": "(\\{)(\\s*(\\}))",
707
+ "name": "meta.structure.dictionary.python"
708
+ },
709
+ {
710
+ "begin": "(\\{)",
711
+ "beginCaptures": {
712
+ "1": {
713
+ "name": "punctuation.definition.dictionary.begin.python"
714
+ }
715
+ },
716
+ "end": "(\\})",
717
+ "endCaptures": {
718
+ "1": {
719
+ "name": "punctuation.definition.dictionary.end.python"
720
+ }
721
+ },
722
+ "name": "meta.structure.dictionary.python",
723
+ "patterns": [
724
+ {
725
+ "begin": "(?<=\\{|\\,|^)\\s*(?![\\},])",
726
+ "contentName": "meta.structure.dictionary.key.python",
727
+ "end": "\\s*(?:(?=\\})|(\\:))",
728
+ "endCaptures": {
729
+ "1": {
730
+ "name": "punctuation.separator.valuepair.dictionary.python"
731
+ }
732
+ },
733
+ "patterns": [
734
+ {
735
+ "include": "$self"
736
+ }
737
+ ]
738
+ },
739
+ {
740
+ "begin": "(?<=\\:|^)\\s*",
741
+ "contentName": "meta.structure.dictionary.value.python",
742
+ "end": "\\s*(?:(?=\\})|(,))",
743
+ "endCaptures": {
744
+ "1": {
745
+ "name": "punctuation.separator.dictionary.python"
746
+ }
747
+ },
748
+ "patterns": [
749
+ {
750
+ "include": "$self"
751
+ }
752
+ ]
753
+ }
754
+ ]
755
+ }
756
+ ],
757
+ "repository": {
758
+ "builtin_exceptions": {
759
+ "match": "(?x)\\b(\n\t\t\t\t(\n\t\t\t\t\tArithmetic|Assertion|Attribute|BlockingIO|BrokenPipe|Buffer|ChildProcess|\n\t\t\t\t\tConnection(Aborted|Refused|Reset)?|EOF|Environment|FileExists|\n\t\t\t\t\tFileNotFound|FloatingPoint|Interrupted|IO|IsADirectoryError|\n\t\t\t\t\tImport|Indentation|Index|Key|Lookup|Memory|Name|NotADirectory|\n\t\t\t\t\tNotImplemented|OS|Overflow|Permission|ProcessLookup|Reference|\n\t\t\t\t\tRuntime|Standard|Syntax|System|Tab|Timeout|Type|UnboundLocal|\n\t\t\t\t\tUnicode(Encode|Decode|Translate)?|Value|VMS|Windows|ZeroDivision\n\t\t\t\t)Error|\n\t\t\t\t((Pending)?Deprecation|Runtime|Syntax|User|Future|Import|Unicode|Bytes)?Warning|\n\t\t\t\t(Base)?Exception|\n\t\t\t\tSystemExit|StopIteration|NotImplemented|KeyboardInterrupt|GeneratorExit\n\t\t\t)\\b",
760
+ "name": "support.type.exception.python"
761
+ },
762
+ "builtin_functions": {
763
+ "match": "(?x)\\b(__import__|abs|all|any|ascii|bin|bool|bytearray|bytes|callable|chr|classmethod|compile|complex|delattr|dict|dir|divmod|enumerate|eval|exec|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|isinstance|issubclass|iter|len|list|locals|map|max|memoryview|min|next|object|oct|open|ord|pow|print|property|range|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|vars|zip|file|long|raw_input|reduce|reload|unichr|unicode|xrange|apply|buffer|coerce|intern)\\b",
764
+ "name": "support.function.builtin.python"
765
+ },
766
+ "builtin_types": {
767
+ "match": "(?x)\\b(\n\t\t\t\tbasestring|bool|buffer|bytearray|bytes|complex|dict|float|frozenset|int|\n\t\t\t\tlist|long|memoryview|object|range|set|slice|str|tuple|unicode|xrange\n\t\t\t)\\b",
768
+ "name": "support.type.python"
769
+ },
770
+ "constant_placeholder": {
771
+ "match": "(?i:(%(\\([a-z_]+\\))?#?0?\\-?[ ]?\\+?([0-9]*|\\*)(\\.([0-9]*|\\*))?([hL][a-z]|[a-z%]))|(\\{([!\\[\\].:\\w ]+)?\\}))",
772
+ "name": "constant.other.placeholder.python"
773
+ },
774
+ "docstrings": {
775
+ "patterns": [
776
+ {
777
+ "begin": "^\\s*(?=[uU]?[rR]?\"\"\")",
778
+ "end": "(?<=\"\"\")",
779
+ "name": "comment.block.python",
780
+ "patterns": [
781
+ {
782
+ "include": "#string_quoted_double"
783
+ }
784
+ ]
785
+ },
786
+ {
787
+ "begin": "^\\s*(?=[uU]?[rR]?''')",
788
+ "end": "(?<=''')",
789
+ "name": "comment.block.python",
790
+ "patterns": [
791
+ {
792
+ "include": "#string_quoted_single"
793
+ }
794
+ ]
795
+ }
796
+ ]
797
+ },
798
+ "line_comments": {
799
+ "begin": "(^[ \\t]+)?(?=#)",
800
+ "beginCaptures": {
801
+ "1": {
802
+ "name": "punctuation.whitespace.comment.leading.python"
803
+ }
804
+ },
805
+ "end": "(?!\\G)",
806
+ "patterns": [
807
+ {
808
+ "begin": "#",
809
+ "beginCaptures": {
810
+ "0": {
811
+ "name": "punctuation.definition.comment.python"
812
+ }
813
+ },
814
+ "end": "\\n",
815
+ "name": "comment.line.number-sign.python"
816
+ }
817
+ ]
818
+ },
819
+ "dotted_name": {
820
+ "begin": "(?=[A-Za-z_][A-Za-z0-9_]*(?:\\.[A-Za-z_][A-Za-z0-9_]*)*)",
821
+ "end": "(?![A-Za-z0-9_\\.])",
822
+ "patterns": [
823
+ {
824
+ "begin": "(\\.)(?=[A-Za-z_][A-Za-z0-9_]*)",
825
+ "end": "(?![A-Za-z0-9_])",
826
+ "patterns": [
827
+ {
828
+ "include": "#magic_function_names"
829
+ },
830
+ {
831
+ "include": "#magic_variable_names"
832
+ },
833
+ {
834
+ "include": "#illegal_names"
835
+ },
836
+ {
837
+ "include": "#generic_names"
838
+ }
839
+ ]
840
+ },
841
+ {
842
+ "begin": "(?<!\\.)(?=[A-Za-z_][A-Za-z0-9_]*)",
843
+ "end": "(?![A-Za-z0-9_])",
844
+ "patterns": [
845
+ {
846
+ "include": "#builtin_functions"
847
+ },
848
+ {
849
+ "include": "#builtin_types"
850
+ },
851
+ {
852
+ "include": "#builtin_exceptions"
853
+ },
854
+ {
855
+ "include": "#illegal_names"
856
+ },
857
+ {
858
+ "include": "#magic_function_names"
859
+ },
860
+ {
861
+ "include": "#magic_variable_names"
862
+ },
863
+ {
864
+ "include": "#language_variables"
865
+ },
866
+ {
867
+ "include": "#generic_names"
868
+ }
869
+ ]
870
+ }
871
+ ]
872
+ },
873
+ "entity_name_class": {
874
+ "patterns": [
875
+ {
876
+ "include": "#illegal_names"
877
+ },
878
+ {
879
+ "include": "#generic_names"
880
+ }
881
+ ]
882
+ },
883
+ "entity_name_function": {
884
+ "patterns": [
885
+ {
886
+ "include": "#magic_function_names"
887
+ },
888
+ {
889
+ "include": "#illegal_names"
890
+ },
891
+ {
892
+ "include": "#generic_names"
893
+ }
894
+ ]
895
+ },
896
+ "escaped_char": {
897
+ "captures": {
898
+ "1": {
899
+ "name": "constant.character.escape.hex.python"
900
+ },
901
+ "2": {
902
+ "name": "constant.character.escape.octal.python"
903
+ },
904
+ "3": {
905
+ "name": "constant.character.escape.newline.python"
906
+ },
907
+ "4": {
908
+ "name": "constant.character.escape.backlash.python"
909
+ },
910
+ "5": {
911
+ "name": "constant.character.escape.double-quote.python"
912
+ },
913
+ "6": {
914
+ "name": "constant.character.escape.single-quote.python"
915
+ },
916
+ "7": {
917
+ "name": "constant.character.escape.bell.python"
918
+ },
919
+ "8": {
920
+ "name": "constant.character.escape.backspace.python"
921
+ },
922
+ "9": {
923
+ "name": "constant.character.escape.formfeed.python"
924
+ },
925
+ "10": {
926
+ "name": "constant.character.escape.linefeed.python"
927
+ },
928
+ "11": {
929
+ "name": "constant.character.escape.return.python"
930
+ },
931
+ "12": {
932
+ "name": "constant.character.escape.tab.python"
933
+ },
934
+ "13": {
935
+ "name": "constant.character.escape.vertical-tab.python"
936
+ }
937
+ },
938
+ "match": "(\\\\x[0-9A-F]{2})|(\\\\[0-7]{3})|(\\\\\\n)|(\\\\\\\\)|(\\\\\\\")|(\\\\')|(\\\\a)|(\\\\b)|(\\\\f)|(\\\\n)|(\\\\r)|(\\\\t)|(\\\\v)"
939
+ },
940
+ "escaped_unicode_char": {
941
+ "captures": {
942
+ "1": {
943
+ "name": "constant.character.escape.unicode.16-bit-hex.python"
944
+ },
945
+ "2": {
946
+ "name": "constant.character.escape.unicode.32-bit-hex.python"
947
+ },
948
+ "3": {
949
+ "name": "constant.character.escape.unicode.name.python"
950
+ }
951
+ },
952
+ "match": "(\\\\U[0-9A-Fa-f]{8})|(\\\\u[0-9A-Fa-f]{4})|(\\\\N\\{[a-zA-Z ]+\\})"
953
+ },
954
+ "function_name": {
955
+ "patterns": [
956
+ {
957
+ "include": "#magic_function_names"
958
+ },
959
+ {
960
+ "include": "#magic_variable_names"
961
+ },
962
+ {
963
+ "include": "#builtin_exceptions"
964
+ },
965
+ {
966
+ "include": "#builtin_functions"
967
+ },
968
+ {
969
+ "include": "#builtin_types"
970
+ },
971
+ {
972
+ "include": "#generic_names"
973
+ }
974
+ ]
975
+ },
976
+ "generic_names": {
977
+ "match": "[A-Za-z_][A-Za-z0-9_]*"
978
+ },
979
+ "illegal_names": {
980
+ "match": "\\b(and|as|assert|break|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\\b",
981
+ "name": "invalid.illegal.name.python"
982
+ },
983
+ "keyword_arguments": {
984
+ "begin": "\\b([a-zA-Z_][a-zA-Z_0-9]*)\\s*(=)(?!=)",
985
+ "beginCaptures": {
986
+ "1": {
987
+ "name": "variable.parameter.function.python"
988
+ },
989
+ "2": {
990
+ "name": "keyword.operator.assignment.python"
991
+ }
992
+ },
993
+ "end": "\\s*(?:(,)|(?=$\\n?|[\\)\\:]))",
994
+ "endCaptures": {
995
+ "1": {
996
+ "name": "punctuation.separator.parameters.python"
997
+ }
998
+ },
999
+ "patterns": [
1000
+ {
1001
+ "include": "$self"
1002
+ }
1003
+ ]
1004
+ },
1005
+ "language_variables": {
1006
+ "match": "\\b(self|cls)\\b",
1007
+ "name": "variable.language.python"
1008
+ },
1009
+ "line_continuation": {
1010
+ "captures": {
1011
+ "1": {
1012
+ "name": "punctuation.separator.continuation.line.python"
1013
+ },
1014
+ "2": {
1015
+ "name": "invalid.illegal.unexpected-text.python"
1016
+ }
1017
+ },
1018
+ "match": "(\\\\)(.*)$\\n?"
1019
+ },
1020
+ "magic_function_names": {
1021
+ "comment": "these methods have magic interpretation by python and are generally called indirectly through syntactic constructs",
1022
+ "match": "(?x)\\b(__(?:abs|add|and|bool|bytes|call|cmp|coerce|complex|contains|del|delattr|delete|delitem|delslice|dir|div|divmod|enter|eq|exit|float|floordiv|format|ge|get|getattr|getattribute|getitem|getslice|gt|hash|hex|iadd|iand|idiv|ifloordiv|ilshift|imatmul|imod|imul|index|init|instancecheck|int|invert|ior|ipow|irshift|isub|iter|itruediv|ixor|le|len|length_hint|long|lshift|lt|matmul|missing|mod|mul|ne|neg|next|new|nonzero|oct|or|pos|pow|radd|rand|rdiv|rdivmod|repr|reversed|rfloordiv|rlshift|rmatmul|rmod|rmul|ror|round|rpow|rrshift|rshift|rsub|rtruediv|rxor|set|setattr|setitem|setslice|str|sub|subclasscheck|truediv|unicode|xor)__)\\b",
1023
+ "name": "support.function.magic.python"
1024
+ },
1025
+ "magic_variable_names": {
1026
+ "comment": "magic variables which a class/module may have.",
1027
+ "match": "\\b__(all|annotations|bases|class|closure|code|debug|dict|doc|file|func|globals|kwdefaults|members|metaclass|methods|module|name|qualname|self|slots|weakref)__\\b",
1028
+ "name": "support.variable.magic.python"
1029
+ },
1030
+ "regular_expressions": {
1031
+ "comment": "Changed disabled to 1 to turn off syntax highlighting in “r” strings.",
1032
+ "disabled": 0,
1033
+ "patterns": [
1034
+ {
1035
+ "include": "source.regexp.python"
1036
+ }
1037
+ ]
1038
+ },
1039
+ "string_quoted_double": {
1040
+ "patterns": [
1041
+ {
1042
+ "begin": "([uU]r)(\"\"\")",
1043
+ "beginCaptures": {
1044
+ "1": {
1045
+ "name": "storage.type.string.python"
1046
+ },
1047
+ "2": {
1048
+ "name": "punctuation.definition.string.begin.python"
1049
+ }
1050
+ },
1051
+ "comment": "single quoted unicode-raw string",
1052
+ "end": "((?<=\"\"\")(\")\"\"|\"\"\")",
1053
+ "endCaptures": {
1054
+ "1": {
1055
+ "name": "punctuation.definition.string.end.python"
1056
+ },
1057
+ "2": {
1058
+ "name": "meta.empty-string.double.python"
1059
+ }
1060
+ },
1061
+ "name": "string.quoted.double.block.unicode-raw-regex.python",
1062
+ "patterns": [
1063
+ {
1064
+ "include": "#constant_placeholder"
1065
+ },
1066
+ {
1067
+ "include": "#escaped_unicode_char"
1068
+ },
1069
+ {
1070
+ "include": "#escaped_char"
1071
+ },
1072
+ {
1073
+ "include": "#regular_expressions"
1074
+ }
1075
+ ]
1076
+ },
1077
+ {
1078
+ "begin": "([uU]R)(\"\"\")",
1079
+ "beginCaptures": {
1080
+ "1": {
1081
+ "name": "storage.type.string.python"
1082
+ },
1083
+ "2": {
1084
+ "name": "punctuation.definition.string.begin.python"
1085
+ }
1086
+ },
1087
+ "comment": "single quoted unicode-raw string without regular expression highlighting",
1088
+ "end": "((?<=\"\"\")(\")\"\"|\"\"\")",
1089
+ "endCaptures": {
1090
+ "1": {
1091
+ "name": "punctuation.definition.string.end.python"
1092
+ },
1093
+ "2": {
1094
+ "name": "meta.empty-string.double.python"
1095
+ }
1096
+ },
1097
+ "name": "string.quoted.double.block.unicode-raw.python",
1098
+ "patterns": [
1099
+ {
1100
+ "include": "#constant_placeholder"
1101
+ },
1102
+ {
1103
+ "include": "#escaped_unicode_char"
1104
+ },
1105
+ {
1106
+ "include": "#escaped_char"
1107
+ }
1108
+ ]
1109
+ },
1110
+ {
1111
+ "begin": "(r)(\"\"\")",
1112
+ "beginCaptures": {
1113
+ "1": {
1114
+ "name": "storage.type.string.python"
1115
+ },
1116
+ "2": {
1117
+ "name": "punctuation.definition.string.begin.python"
1118
+ }
1119
+ },
1120
+ "comment": "double quoted raw string",
1121
+ "end": "((?<=\"\"\")(\")\"\"|\"\"\")",
1122
+ "endCaptures": {
1123
+ "1": {
1124
+ "name": "punctuation.definition.string.end.python"
1125
+ },
1126
+ "2": {
1127
+ "name": "meta.empty-string.double.python"
1128
+ }
1129
+ },
1130
+ "name": "string.quoted.double.block.raw-regex.python",
1131
+ "patterns": [
1132
+ {
1133
+ "include": "#constant_placeholder"
1134
+ },
1135
+ {
1136
+ "include": "#escaped_char"
1137
+ },
1138
+ {
1139
+ "include": "#regular_expressions"
1140
+ }
1141
+ ]
1142
+ },
1143
+ {
1144
+ "begin": "(R)(\"\"\")",
1145
+ "beginCaptures": {
1146
+ "1": {
1147
+ "name": "storage.type.string.python"
1148
+ },
1149
+ "2": {
1150
+ "name": "punctuation.definition.string.begin.python"
1151
+ }
1152
+ },
1153
+ "comment": "double quoted raw string",
1154
+ "end": "((?<=\"\"\")(\")\"\"|\"\"\")",
1155
+ "endCaptures": {
1156
+ "1": {
1157
+ "name": "punctuation.definition.string.end.python"
1158
+ },
1159
+ "2": {
1160
+ "name": "meta.empty-string.double.python"
1161
+ }
1162
+ },
1163
+ "name": "string.quoted.double.block.raw.python",
1164
+ "patterns": [
1165
+ {
1166
+ "include": "#constant_placeholder"
1167
+ },
1168
+ {
1169
+ "include": "#escaped_char"
1170
+ }
1171
+ ]
1172
+ },
1173
+ {
1174
+ "begin": "([uU])(\"\"\")",
1175
+ "beginCaptures": {
1176
+ "1": {
1177
+ "name": "storage.type.string.python"
1178
+ },
1179
+ "2": {
1180
+ "name": "punctuation.definition.string.begin.python"
1181
+ }
1182
+ },
1183
+ "comment": "double quoted unicode string",
1184
+ "end": "((?<=\"\"\")(\")\"\"|\"\"\")",
1185
+ "endCaptures": {
1186
+ "1": {
1187
+ "name": "punctuation.definition.string.end.python"
1188
+ },
1189
+ "2": {
1190
+ "name": "meta.empty-string.double.python"
1191
+ }
1192
+ },
1193
+ "name": "string.quoted.double.block.unicode.python",
1194
+ "patterns": [
1195
+ {
1196
+ "include": "#constant_placeholder"
1197
+ },
1198
+ {
1199
+ "include": "#escaped_unicode_char"
1200
+ },
1201
+ {
1202
+ "include": "#escaped_char"
1203
+ }
1204
+ ]
1205
+ },
1206
+ {
1207
+ "captures": {
1208
+ "1": {
1209
+ "name": "storage.type.string.python"
1210
+ },
1211
+ "2": {
1212
+ "name": "punctuation.definition.string.begin.python"
1213
+ },
1214
+ "3": {
1215
+ "patterns": [
1216
+ {
1217
+ "include": "#constant_placeholder"
1218
+ },
1219
+ {
1220
+ "include": "#escaped_unicode_char"
1221
+ },
1222
+ {
1223
+ "include": "#escaped_char"
1224
+ },
1225
+ {
1226
+ "include": "#regular_expressions"
1227
+ }
1228
+ ]
1229
+ },
1230
+ "4": {
1231
+ "name": "punctuation.definition.string.end.python"
1232
+ }
1233
+ },
1234
+ "comment": "double-quoted raw string",
1235
+ "match": "([uU]r)(\")((?:[^\"\\\\]|\\\\.)*)(\")",
1236
+ "name": "string.quoted.double.single-line.unicode-raw-regex.python"
1237
+ },
1238
+ {
1239
+ "begin": "([uU]R)(\")",
1240
+ "beginCaptures": {
1241
+ "1": {
1242
+ "name": "storage.type.string.python"
1243
+ },
1244
+ "2": {
1245
+ "name": "punctuation.definition.string.begin.python"
1246
+ }
1247
+ },
1248
+ "comment": "double-quoted raw string",
1249
+ "end": "((?<=\")(\")|\")|(\\n)",
1250
+ "endCaptures": {
1251
+ "1": {
1252
+ "name": "punctuation.definition.string.end.python"
1253
+ },
1254
+ "2": {
1255
+ "name": "meta.empty-string.double.python"
1256
+ },
1257
+ "3": {
1258
+ "name": "invalid.illegal.unclosed-string.python"
1259
+ }
1260
+ },
1261
+ "name": "string.quoted.double.single-line.unicode-raw.python",
1262
+ "patterns": [
1263
+ {
1264
+ "include": "#constant_placeholder"
1265
+ },
1266
+ {
1267
+ "include": "#escaped_unicode_char"
1268
+ },
1269
+ {
1270
+ "include": "#escaped_char"
1271
+ }
1272
+ ]
1273
+ },
1274
+ {
1275
+ "captures": {
1276
+ "1": {
1277
+ "name": "storage.type.string.python"
1278
+ },
1279
+ "2": {
1280
+ "name": "punctuation.definition.string.begin.python"
1281
+ },
1282
+ "3": {
1283
+ "patterns": [
1284
+ {
1285
+ "include": "#constant_placeholder"
1286
+ },
1287
+ {
1288
+ "include": "#escaped_char"
1289
+ },
1290
+ {
1291
+ "include": "#regular_expressions"
1292
+ }
1293
+ ]
1294
+ },
1295
+ "4": {
1296
+ "name": "punctuation.definition.string.end.python"
1297
+ }
1298
+ },
1299
+ "comment": "double-quoted raw string",
1300
+ "match": "(r)(\")((?:[^\"\\\\]|\\\\.)*)(\")",
1301
+ "name": "string.quoted.double.single-line.raw-regex.python"
1302
+ },
1303
+ {
1304
+ "begin": "(R)(\")",
1305
+ "beginCaptures": {
1306
+ "1": {
1307
+ "name": "storage.type.string.python"
1308
+ },
1309
+ "2": {
1310
+ "name": "punctuation.definition.string.begin.python"
1311
+ }
1312
+ },
1313
+ "comment": "double-quoted raw string",
1314
+ "end": "((?<=\")(\")|\")|(\\n)",
1315
+ "endCaptures": {
1316
+ "1": {
1317
+ "name": "punctuation.definition.string.end.python"
1318
+ },
1319
+ "2": {
1320
+ "name": "meta.empty-string.double.python"
1321
+ },
1322
+ "3": {
1323
+ "name": "invalid.illegal.unclosed-string.python"
1324
+ }
1325
+ },
1326
+ "name": "string.quoted.double.single-line.raw.python",
1327
+ "patterns": [
1328
+ {
1329
+ "include": "#constant_placeholder"
1330
+ },
1331
+ {
1332
+ "include": "#escaped_char"
1333
+ }
1334
+ ]
1335
+ },
1336
+ {
1337
+ "begin": "([uU])(\")",
1338
+ "beginCaptures": {
1339
+ "1": {
1340
+ "name": "storage.type.string.python"
1341
+ },
1342
+ "2": {
1343
+ "name": "punctuation.definition.string.begin.python"
1344
+ }
1345
+ },
1346
+ "comment": "double quoted unicode string",
1347
+ "end": "((?<=\")(\")|\")|(\\n)",
1348
+ "endCaptures": {
1349
+ "1": {
1350
+ "name": "punctuation.definition.string.end.python"
1351
+ },
1352
+ "2": {
1353
+ "name": "meta.empty-string.double.python"
1354
+ },
1355
+ "3": {
1356
+ "name": "invalid.illegal.unclosed-string.python"
1357
+ }
1358
+ },
1359
+ "name": "string.quoted.double.single-line.unicode.python",
1360
+ "patterns": [
1361
+ {
1362
+ "include": "#constant_placeholder"
1363
+ },
1364
+ {
1365
+ "include": "#escaped_unicode_char"
1366
+ },
1367
+ {
1368
+ "include": "#escaped_char"
1369
+ }
1370
+ ]
1371
+ },
1372
+ {
1373
+ "begin": "(\"\"\")(?=\\s*(SELECT|INSERT|UPDATE|DELETE|CREATE|REPLACE|ALTER))",
1374
+ "beginCaptures": {
1375
+ "1": {
1376
+ "name": "punctuation.definition.string.begin.python"
1377
+ }
1378
+ },
1379
+ "comment": "double quoted string",
1380
+ "end": "((?<=\"\"\")(\")\"\"|\"\"\")",
1381
+ "endCaptures": {
1382
+ "1": {
1383
+ "name": "punctuation.definition.string.end.python"
1384
+ },
1385
+ "2": {
1386
+ "name": "meta.empty-string.double.python"
1387
+ }
1388
+ },
1389
+ "name": "string.quoted.double.block.sql.python",
1390
+ "patterns": [
1391
+ {
1392
+ "include": "#constant_placeholder"
1393
+ },
1394
+ {
1395
+ "include": "#escaped_char"
1396
+ },
1397
+ {
1398
+ "include": "source.sql"
1399
+ }
1400
+ ]
1401
+ },
1402
+ {
1403
+ "begin": "(\")(?=\\s*(SELECT|INSERT|UPDATE|DELETE|CREATE|REPLACE|ALTER))",
1404
+ "beginCaptures": {
1405
+ "1": {
1406
+ "name": "punctuation.definition.string.begin.python"
1407
+ }
1408
+ },
1409
+ "comment": "double quoted string",
1410
+ "end": "((?<=\")(\")|\")|(\\n)",
1411
+ "endCaptures": {
1412
+ "1": {
1413
+ "name": "punctuation.definition.string.end.python"
1414
+ },
1415
+ "2": {
1416
+ "name": "meta.empty-string.double.python"
1417
+ },
1418
+ "3": {
1419
+ "name": "invalid.illegal.unclosed-string.python"
1420
+ }
1421
+ },
1422
+ "name": "string.quoted.double.single-line.sql.python",
1423
+ "patterns": [
1424
+ {
1425
+ "include": "#constant_placeholder"
1426
+ },
1427
+ {
1428
+ "include": "#escaped_char"
1429
+ },
1430
+ {
1431
+ "include": "source.sql"
1432
+ }
1433
+ ]
1434
+ },
1435
+ {
1436
+ "begin": "(\"\"\")",
1437
+ "beginCaptures": {
1438
+ "1": {
1439
+ "name": "punctuation.definition.string.begin.python"
1440
+ }
1441
+ },
1442
+ "comment": "double quoted string",
1443
+ "end": "((?<=\"\"\")(\")\"\"|\"\"\")",
1444
+ "endCaptures": {
1445
+ "1": {
1446
+ "name": "punctuation.definition.string.end.python"
1447
+ },
1448
+ "2": {
1449
+ "name": "meta.empty-string.double.python"
1450
+ }
1451
+ },
1452
+ "name": "string.quoted.double.block.python",
1453
+ "patterns": [
1454
+ {
1455
+ "include": "#constant_placeholder"
1456
+ },
1457
+ {
1458
+ "include": "#escaped_char"
1459
+ }
1460
+ ]
1461
+ },
1462
+ {
1463
+ "begin": "(\")",
1464
+ "beginCaptures": {
1465
+ "1": {
1466
+ "name": "punctuation.definition.string.begin.python"
1467
+ }
1468
+ },
1469
+ "comment": "double quoted string",
1470
+ "end": "((?<=\")(\")|\")|(\\n)",
1471
+ "endCaptures": {
1472
+ "1": {
1473
+ "name": "punctuation.definition.string.end.python"
1474
+ },
1475
+ "2": {
1476
+ "name": "meta.empty-string.double.python"
1477
+ },
1478
+ "3": {
1479
+ "name": "invalid.illegal.unclosed-string.python"
1480
+ }
1481
+ },
1482
+ "name": "string.quoted.double.single-line.python",
1483
+ "patterns": [
1484
+ {
1485
+ "include": "#constant_placeholder"
1486
+ },
1487
+ {
1488
+ "include": "#escaped_char"
1489
+ }
1490
+ ]
1491
+ }
1492
+ ]
1493
+ },
1494
+ "string_quoted_single": {
1495
+ "patterns": [
1496
+ {
1497
+ "captures": {
1498
+ "1": {
1499
+ "name": "punctuation.definition.string.begin.python"
1500
+ },
1501
+ "2": {
1502
+ "name": "punctuation.definition.string.end.python"
1503
+ },
1504
+ "3": {
1505
+ "name": "meta.empty-string.single.python"
1506
+ }
1507
+ },
1508
+ "match": "(?<!')(')(('))(?!')",
1509
+ "name": "string.quoted.single.single-line.python"
1510
+ },
1511
+ {
1512
+ "begin": "([uU]r)(''')",
1513
+ "beginCaptures": {
1514
+ "1": {
1515
+ "name": "storage.type.string.python"
1516
+ },
1517
+ "2": {
1518
+ "name": "punctuation.definition.string.begin.python"
1519
+ }
1520
+ },
1521
+ "comment": "single quoted unicode-raw string",
1522
+ "end": "((?<=''')(')''|''')",
1523
+ "endCaptures": {
1524
+ "1": {
1525
+ "name": "punctuation.definition.string.end.python"
1526
+ },
1527
+ "2": {
1528
+ "name": "meta.empty-string.single.python"
1529
+ }
1530
+ },
1531
+ "name": "string.quoted.single.block.unicode-raw-regex.python",
1532
+ "patterns": [
1533
+ {
1534
+ "include": "#constant_placeholder"
1535
+ },
1536
+ {
1537
+ "include": "#escaped_unicode_char"
1538
+ },
1539
+ {
1540
+ "include": "#escaped_char"
1541
+ },
1542
+ {
1543
+ "include": "#regular_expressions"
1544
+ }
1545
+ ]
1546
+ },
1547
+ {
1548
+ "begin": "([uU]R)(''')",
1549
+ "beginCaptures": {
1550
+ "1": {
1551
+ "name": "storage.type.string.python"
1552
+ },
1553
+ "2": {
1554
+ "name": "punctuation.definition.string.begin.python"
1555
+ }
1556
+ },
1557
+ "comment": "single quoted unicode-raw string",
1558
+ "end": "((?<=''')(')''|''')",
1559
+ "endCaptures": {
1560
+ "1": {
1561
+ "name": "punctuation.definition.string.end.python"
1562
+ },
1563
+ "2": {
1564
+ "name": "meta.empty-string.single.python"
1565
+ }
1566
+ },
1567
+ "name": "string.quoted.single.block.unicode-raw.python",
1568
+ "patterns": [
1569
+ {
1570
+ "include": "#constant_placeholder"
1571
+ },
1572
+ {
1573
+ "include": "#escaped_unicode_char"
1574
+ },
1575
+ {
1576
+ "include": "#escaped_char"
1577
+ }
1578
+ ]
1579
+ },
1580
+ {
1581
+ "begin": "(r)(''')",
1582
+ "beginCaptures": {
1583
+ "1": {
1584
+ "name": "storage.type.string.python"
1585
+ },
1586
+ "2": {
1587
+ "name": "punctuation.definition.string.begin.python"
1588
+ }
1589
+ },
1590
+ "comment": "single quoted raw string",
1591
+ "end": "((?<=''')(')''|''')",
1592
+ "endCaptures": {
1593
+ "1": {
1594
+ "name": "punctuation.definition.string.end.python"
1595
+ },
1596
+ "2": {
1597
+ "name": "meta.empty-string.single.python"
1598
+ }
1599
+ },
1600
+ "name": "string.quoted.single.block.raw-regex.python",
1601
+ "patterns": [
1602
+ {
1603
+ "include": "#constant_placeholder"
1604
+ },
1605
+ {
1606
+ "include": "#escaped_char"
1607
+ },
1608
+ {
1609
+ "include": "#regular_expressions"
1610
+ }
1611
+ ]
1612
+ },
1613
+ {
1614
+ "begin": "(R)(''')",
1615
+ "beginCaptures": {
1616
+ "1": {
1617
+ "name": "storage.type.string.python"
1618
+ },
1619
+ "2": {
1620
+ "name": "punctuation.definition.string.begin.python"
1621
+ }
1622
+ },
1623
+ "comment": "single quoted raw string",
1624
+ "end": "((?<=''')(')''|''')",
1625
+ "endCaptures": {
1626
+ "1": {
1627
+ "name": "punctuation.definition.string.end.python"
1628
+ },
1629
+ "2": {
1630
+ "name": "meta.empty-string.single.python"
1631
+ }
1632
+ },
1633
+ "name": "string.quoted.single.block.raw.python",
1634
+ "patterns": [
1635
+ {
1636
+ "include": "#constant_placeholder"
1637
+ },
1638
+ {
1639
+ "include": "#escaped_char"
1640
+ }
1641
+ ]
1642
+ },
1643
+ {
1644
+ "begin": "([uU])(''')",
1645
+ "beginCaptures": {
1646
+ "1": {
1647
+ "name": "storage.type.string.python"
1648
+ },
1649
+ "2": {
1650
+ "name": "punctuation.definition.string.begin.python"
1651
+ }
1652
+ },
1653
+ "comment": "single quoted unicode string",
1654
+ "end": "((?<=''')(')''|''')",
1655
+ "endCaptures": {
1656
+ "1": {
1657
+ "name": "punctuation.definition.string.end.python"
1658
+ },
1659
+ "2": {
1660
+ "name": "meta.empty-string.single.python"
1661
+ }
1662
+ },
1663
+ "name": "string.quoted.single.block.unicode.python",
1664
+ "patterns": [
1665
+ {
1666
+ "include": "#constant_placeholder"
1667
+ },
1668
+ {
1669
+ "include": "#escaped_unicode_char"
1670
+ },
1671
+ {
1672
+ "include": "#escaped_char"
1673
+ }
1674
+ ]
1675
+ },
1676
+ {
1677
+ "captures": {
1678
+ "1": {
1679
+ "name": "storage.type.string.python"
1680
+ },
1681
+ "2": {
1682
+ "name": "punctuation.definition.string.begin.python"
1683
+ },
1684
+ "3": {
1685
+ "patterns": [
1686
+ {
1687
+ "include": "#constant_placeholder"
1688
+ },
1689
+ {
1690
+ "include": "#escaped_unicode_char"
1691
+ },
1692
+ {
1693
+ "include": "#escaped_char"
1694
+ },
1695
+ {
1696
+ "include": "#regular_expressions"
1697
+ }
1698
+ ]
1699
+ },
1700
+ "4": {
1701
+ "name": "punctuation.definition.string.end.python"
1702
+ }
1703
+ },
1704
+ "comment": "single quoted raw string",
1705
+ "match": "([uU]r)(')((?:[^'\\\\]|\\\\.)*)(')",
1706
+ "name": "string.quoted.single.single-line.unicode-raw-regex.python"
1707
+ },
1708
+ {
1709
+ "begin": "([uU]R)(')",
1710
+ "beginCaptures": {
1711
+ "1": {
1712
+ "name": "storage.type.string.python"
1713
+ },
1714
+ "2": {
1715
+ "name": "punctuation.definition.string.begin.python"
1716
+ }
1717
+ },
1718
+ "comment": "single quoted raw string",
1719
+ "end": "(')|(\\n)",
1720
+ "endCaptures": {
1721
+ "1": {
1722
+ "name": "punctuation.definition.string.end.python"
1723
+ },
1724
+ "2": {
1725
+ "name": "invalid.illegal.unclosed-string.python"
1726
+ }
1727
+ },
1728
+ "name": "string.quoted.single.single-line.unicode-raw.python",
1729
+ "patterns": [
1730
+ {
1731
+ "include": "#constant_placeholder"
1732
+ },
1733
+ {
1734
+ "include": "#escaped_unicode_char"
1735
+ },
1736
+ {
1737
+ "include": "#escaped_char"
1738
+ }
1739
+ ]
1740
+ },
1741
+ {
1742
+ "captures": {
1743
+ "1": {
1744
+ "name": "storage.type.string.python"
1745
+ },
1746
+ "2": {
1747
+ "name": "punctuation.definition.string.begin.python"
1748
+ },
1749
+ "3": {
1750
+ "patterns": [
1751
+ {
1752
+ "include": "#constant_placeholder"
1753
+ },
1754
+ {
1755
+ "include": "#escaped_char"
1756
+ },
1757
+ {
1758
+ "include": "#regular_expressions"
1759
+ }
1760
+ ]
1761
+ },
1762
+ "4": {
1763
+ "name": "punctuation.definition.string.end.python"
1764
+ }
1765
+ },
1766
+ "comment": "single quoted raw string",
1767
+ "match": "(r)(')((?:[^'\\\\]|\\\\.)*)(')",
1768
+ "name": "string.quoted.single.single-line.raw-regex.python"
1769
+ },
1770
+ {
1771
+ "begin": "(R)(')",
1772
+ "beginCaptures": {
1773
+ "1": {
1774
+ "name": "storage.type.string.python"
1775
+ },
1776
+ "2": {
1777
+ "name": "punctuation.definition.string.begin.python"
1778
+ }
1779
+ },
1780
+ "comment": "single quoted raw string",
1781
+ "end": "(')|(\\n)",
1782
+ "endCaptures": {
1783
+ "1": {
1784
+ "name": "punctuation.definition.string.end.python"
1785
+ },
1786
+ "2": {
1787
+ "name": "invalid.illegal.unclosed-string.python"
1788
+ }
1789
+ },
1790
+ "name": "string.quoted.single.single-line.raw.python",
1791
+ "patterns": [
1792
+ {
1793
+ "include": "#constant_placeholder"
1794
+ },
1795
+ {
1796
+ "include": "#escaped_char"
1797
+ }
1798
+ ]
1799
+ },
1800
+ {
1801
+ "begin": "([uU])(')",
1802
+ "beginCaptures": {
1803
+ "1": {
1804
+ "name": "storage.type.string.python"
1805
+ },
1806
+ "2": {
1807
+ "name": "punctuation.definition.string.begin.python"
1808
+ }
1809
+ },
1810
+ "comment": "single quoted unicode string",
1811
+ "end": "(')|(\\n)",
1812
+ "endCaptures": {
1813
+ "1": {
1814
+ "name": "punctuation.definition.string.end.python"
1815
+ },
1816
+ "2": {
1817
+ "name": "invalid.illegal.unclosed-string.python"
1818
+ }
1819
+ },
1820
+ "name": "string.quoted.single.single-line.unicode.python",
1821
+ "patterns": [
1822
+ {
1823
+ "include": "#constant_placeholder"
1824
+ },
1825
+ {
1826
+ "include": "#escaped_unicode_char"
1827
+ },
1828
+ {
1829
+ "include": "#escaped_char"
1830
+ }
1831
+ ]
1832
+ },
1833
+ {
1834
+ "begin": "(''')(?=\\s*(SELECT|INSERT|UPDATE|DELETE|CREATE|REPLACE|ALTER))",
1835
+ "beginCaptures": {
1836
+ "1": {
1837
+ "name": "punctuation.definition.string.begin.python"
1838
+ }
1839
+ },
1840
+ "comment": "single quoted string",
1841
+ "end": "((?<=''')(')''|''')",
1842
+ "endCaptures": {
1843
+ "1": {
1844
+ "name": "punctuation.definition.string.end.python"
1845
+ },
1846
+ "2": {
1847
+ "name": "meta.empty-string.single.python"
1848
+ }
1849
+ },
1850
+ "name": "string.quoted.single.block.python",
1851
+ "patterns": [
1852
+ {
1853
+ "include": "#constant_placeholder"
1854
+ },
1855
+ {
1856
+ "include": "#escaped_char"
1857
+ },
1858
+ {
1859
+ "include": "source.sql"
1860
+ }
1861
+ ]
1862
+ },
1863
+ {
1864
+ "begin": "(')(?=\\s*(SELECT|INSERT|UPDATE|DELETE|CREATE|REPLACE|ALTER))",
1865
+ "beginCaptures": {
1866
+ "1": {
1867
+ "name": "punctuation.definition.string.begin.python"
1868
+ }
1869
+ },
1870
+ "comment": "single quoted string",
1871
+ "end": "(')|(\\n)",
1872
+ "endCaptures": {
1873
+ "1": {
1874
+ "name": "punctuation.definition.string.end.python"
1875
+ },
1876
+ "2": {
1877
+ "name": "invalid.illegal.unclosed-string.python"
1878
+ }
1879
+ },
1880
+ "name": "string.quoted.single.single-line.python",
1881
+ "patterns": [
1882
+ {
1883
+ "include": "#constant_placeholder"
1884
+ },
1885
+ {
1886
+ "include": "#escaped_char"
1887
+ },
1888
+ {
1889
+ "include": "source.sql"
1890
+ }
1891
+ ]
1892
+ },
1893
+ {
1894
+ "begin": "(''')",
1895
+ "beginCaptures": {
1896
+ "1": {
1897
+ "name": "punctuation.definition.string.begin.python"
1898
+ }
1899
+ },
1900
+ "comment": "single quoted string",
1901
+ "end": "((?<=''')(')''|''')",
1902
+ "endCaptures": {
1903
+ "1": {
1904
+ "name": "punctuation.definition.string.end.python"
1905
+ },
1906
+ "2": {
1907
+ "name": "meta.empty-string.single.python"
1908
+ }
1909
+ },
1910
+ "name": "string.quoted.single.block.python",
1911
+ "patterns": [
1912
+ {
1913
+ "include": "#constant_placeholder"
1914
+ },
1915
+ {
1916
+ "include": "#escaped_char"
1917
+ }
1918
+ ]
1919
+ },
1920
+ {
1921
+ "begin": "(')",
1922
+ "beginCaptures": {
1923
+ "1": {
1924
+ "name": "punctuation.definition.string.begin.python"
1925
+ }
1926
+ },
1927
+ "comment": "single quoted string",
1928
+ "end": "(')|(\\n)",
1929
+ "endCaptures": {
1930
+ "1": {
1931
+ "name": "punctuation.definition.string.end.python"
1932
+ },
1933
+ "2": {
1934
+ "name": "invalid.illegal.unclosed-string.python"
1935
+ }
1936
+ },
1937
+ "name": "string.quoted.single.single-line.python",
1938
+ "patterns": [
1939
+ {
1940
+ "include": "#constant_placeholder"
1941
+ },
1942
+ {
1943
+ "include": "#escaped_char"
1944
+ }
1945
+ ]
1946
+ }
1947
+ ]
1948
+ },
1949
+ "strings": {
1950
+ "patterns": [
1951
+ {
1952
+ "include": "#string_quoted_double"
1953
+ },
1954
+ {
1955
+ "include": "#string_quoted_single"
1956
+ }
1957
+ ]
1958
+ }
1959
+ }
1960
+ }