---
title: "lastIndex(where:)"
framework: swift-package-manager
role: symbol
role_heading: Instance Method
path: "swift-package-manager/documentation/packageplugin/filelist/lastindex(where:)"
---

# lastIndex(where:)

Inherited from BidirectionalCollection.lastIndex(where:).

## Declaration

```swift
func lastIndex(where predicate: (Self.Element) throws -> Bool) rethrows -> Self.Index?
```
