Skip to content

Should String.format allow negative indices? #439

Description

@egranata

Python errors out here:

>>> "{-1}".format(1,2)
Traceback (most recent call last):
  File "<python-input-9>", line 1, in <module>
    "{-1}".format(1,2)
    ~~~~~~~~~~~~~^^^^^
KeyError: '-1'

Aria happily accepts the input:

〉"{-1}".format("a", "b")
b

Is this the right thing to do?

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions