diff options
author | Adam Stankiewicz <sheerun@sher.pl> | 2019-12-31 14:05:09 +0100 |
---|---|---|
committer | Adam Stankiewicz <sheerun@sher.pl> | 2019-12-31 14:05:09 +0100 |
commit | b8a5504021e0d21310bc603855ac8107828b5759 (patch) | |
tree | 2f2bf182b686597e7cc4c4f1b7d35881f9993f55 /syntax/terraform.vim | |
parent | cea0d08a062478503814e51aa21c6486a0dd1b21 (diff) | |
download | vim-polyglot-b8a5504021e0d21310bc603855ac8107828b5759.tar.gz vim-polyglot-b8a5504021e0d21310bc603855ac8107828b5759.zip |
Update
Diffstat (limited to 'syntax/terraform.vim')
-rw-r--r-- | syntax/terraform.vim | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/syntax/terraform.vim b/syntax/terraform.vim index 452329b9..03b20c2c 100644 --- a/syntax/terraform.vim +++ b/syntax/terraform.vim @@ -7,6 +7,9 @@ if exists('b:current_syntax') finish endif +let s:cpo_save = &cpo +set cpo&vim + " Identifiers are made up of alphanumeric characters, underscores, and " hyphens. if has('patch-7.4.1142') @@ -4863,9 +4866,8 @@ syn match terraValueDec "\<[0-9]\+\([kKmMgG]b\?\)\?\>" syn match terraValueHexaDec "\<0x[0-9a-f]\+\([kKmMgG]b\?\)\?\>" syn match terraBraces "[\[\]]" -""" skip \" in strings. -""" we may also want to pass \\" into a function to escape quotes. -syn region terraValueString start=/"/ skip=/\\\+"/ end=/"/ contains=terraStringInterp +""" skip \" and \\ in strings. +syn region terraValueString start=/"/ skip=/\\\\\|\\"/ end=/"/ contains=terraStringInterp syn region terraStringInterp matchgroup=terraBraces start=/\${/ end=/}/ contained contains=ALL syn region terraHereDocText start=/<<-\?\z([a-z0-9A-Z]\+\)/ end=/^\s*\z1/ contains=terraStringInterp @@ -4923,4 +4925,7 @@ hi def link terraValueNull Constant let b:current_syntax = 'terraform' +let &cpo = s:cpo_save +unlet s:cpo_save + endif |