Skip to content

Commit 8474ae3

Browse files
BasThomasDougGregor
authored andcommitted
Fix a typo (swiftlang#1112)
1 parent fc161e8 commit 8474ae3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

proposals/0275-allow-more-characters-like-whitespaces-and-punctuations-for-escaped-identifiers.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ As part of that, escaped identifiers are adopted to allow usage of reserved keyw
1616
This proposal wants to extend the character allowance for escaped identifiers with more Unicode scalars, like whitespace and punctuation.
1717
It will enable to have method names (or other identifiers) with a more readable and natural language like the following:
1818
```swift
19-
func `test validation should succeed when input is less then ten`()
19+
func `test validation should succeed when input is less than ten`()
2020
```
2121
## Motivation
2222
Naming could be hard and having descriptive methods, like in tests, may result in declarations that are hard to read because of its lack of whitespace and punctuations or other symbols. Enabling natural language would improve readability.
@@ -30,13 +30,13 @@ This proposal wants to extend the current grammar for every escaped identifier (
3030

3131
A declaration to an escaped identifier will follow the existing back-ticked syntax.
3232
```swift
33-
func `test validation should succeed when input is less then ten`()
33+
func `test validation should succeed when input is less than ten`()
3434
var `some var` = 0
3535
```
3636

3737
As per referencing.
3838
```swift
39-
`test validation should succeed when input is less then ten`()
39+
`test validation should succeed when input is less than ten`()
4040
foo.`property with space`
4141
```
4242
In fact, by allowing a larger set of characters, we will remove current limitations and, as an example, we will enable us to reference an operator, which currently produces an error.

0 commit comments

Comments
 (0)