Skip to content

Introduce better expansion syntax for ranges #28

@EmilyGraceSeville7cf

Description

@EmilyGraceSeville7cf

Use parenthesis instead of .. for ranges: {int priority: (1, 10)}. Also add an ability to refer the first or the last range border inside expansions like {int priority: (10, $from + 20)}. In other words allow +, -, *, /, % operators and $from, $to variables inside ranges. Note that just one range border can have math expression, not both and it's not possible to refer to anything outside of the current range.

Notes

  • parenthesis should not be escaped
  • spacing doesn't matter

Examples

  • {/?file(1, 4) image} - expect from one to four images
  • {int priority: (1, 10)} - expect one priority value which is in [1..10] range

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions