SublimeText / PackageDev

Tools to ease the creation of snippets, syntax definitions, etc. for Sublime Text.
MIT License
436 stars 83 forks source link

pop: true completion should be pop: 1 in version: 2 syntaxes #354

Closed keith-hall closed 2 years ago

keith-hall commented 3 years ago

PackageDev currently always offers a completion of pop: true, but when the sublime-syntax file specifies version: 2, pop: 1 is preferred, so it would be nice if PackageDev would check the version and offer the relevant default pop value based on that :)

UltraInstinct05 commented 3 years ago

I guess, even with version: 2, we should not impose pop: 1. Maybe after pop: | <- caret, we could present an additional AC of true & 1, with default to 1 ? We could get even advanced and have 1 selected with an ability to increment if you press up/down (since pop supports knocking off arbitrary no. of contexts off the stack now in ST4)

FichteFoll commented 3 years ago

pop: ${1:1} is what I would go with.