Skip to content

Commit fdefcff

Browse files
committed
Update README.md
1 parent 327666d commit fdefcff

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ let arr = ["A", "B", "C"]
1818
arr[0] // "A"
1919
arr[100] // fatal error: Array index out of range 😟
2020

21-
arr[^0] // Optional("A")
22-
arr[^100] // nil 😄
21+
arr[safe: 0] // Optional("A")
22+
arr[safe: 100] // nil 😄
2323
```
2424

2525

@@ -29,13 +29,13 @@ Installation
2929
- **For iOS 8+ projects** with [CocoaPods](https://cocoapods.org):
3030

3131
```ruby
32-
pod 'SafeIndex', '~> 1.0'
32+
pod 'SafeIndex'
3333
```
3434

3535
- **For iOS 8+ projects** with [Carthage](https://github.com/Carthage/Carthage):
3636

3737
```
38-
github "devxoul/SafeIndex" ~> 1.0
38+
github "devxoul/SafeIndex"
3939
```
4040

4141
- **Using [Swift Package Manager](https://swift.org/package-manager)**:

0 commit comments

Comments
 (0)