Fix lexing of "!$".

See issues
    * https://github.com/google/jsonnet/issues/503
    * https://github.com/google/jsonnet/issues/572
This commit is contained in:
Stanisław Barzowski 2018-10-24 19:57:05 +02:00 committed by Dave Cunningham
parent 2999f7d4f6
commit 9a9954af24
4 changed files with 16 additions and 0 deletions

4
testdata/dollar_end.golden vendored Normal file
View File

@ -0,0 +1,4 @@
{
"bar": -42,
"foo": 42
}

4
testdata/dollar_end.jsonnet vendored Normal file
View File

@ -0,0 +1,4 @@
{
foo: 42,
bar: -$.foo
}

4
testdata/dollar_end2.golden vendored Normal file
View File

@ -0,0 +1,4 @@
{
"bar": true,
"foo": false
}

4
testdata/dollar_end2.jsonnet vendored Normal file
View File

@ -0,0 +1,4 @@
{
foo: false,
bar: !$.foo
}