A literal string type for Python
A literal string type for Python
Posted Apr 19, 2022 11:06 UTC (Tue) by mathstuf (subscriber, #69389)In reply to: A literal string type for Python by NYKevin
Parent article: A literal string type for Python
> you *can't* write s[:7] or something like that
If there were LiteralNumber, one might be able to do that, but without, there's no difference between a literal 7 and a 7 coming in from "the outside" through a variable. Though there are a number of other methods that take SupportsIndex that might now be suspicious to me…
