My favorites | Sign in
Project Home Downloads Wiki Issues Source
READ-ONLY: This project has been archived. For more information see this post.
Search
for
  Advanced search   Search tips   Subscriptions
Issue 1: yaml-language-spec: map-key is evaluated inside a quoted string
1 person starred this issue and may be notified of changes. Back to list
Status:  New
Owner:  ----


 
Reported by CT.JBaker, Nov 5, 2010
Map key evaluation isn't respecting quoted strings, unlike all other type evaluations. It does, however, respect block notation.

Reproduction steps:
1. Open a new file.
2. Type the following text:
Some key: "This doesn't function as expected: the left side is a key, the right side is a string."
Second key: 'Not even single quotes save us: this is also two parts.'
Another key: |
  However, this functions correctly: all of the text within the block is a string, even if we use anchors like &thisOne, aliases like *thisOne, and comments like #this one.
A third key >
  This also functions as we expect: everything is one big string until we break out of it.

3. Switch the highlight mode to YAML. This step can be performed before or after typing the text.

Expected behavior:
"Some key" and "Second key" appear as `def:keyword`, all quoted text appears as `def:string`.

Behavior experienced:
* "Some key:" and '"This doesn't function as expected:' appear as `def:keyword`.
* "Second key:" and "'Not even single quotes save us:" appear as `def:keyword`.
* 'left is a key, right is a string."' appears as `def:string`.

Version:
* yaml.lang version 2.0
* gEdit version 2.30.3


Powered by Google Project Hosting