---
title: "==(_:_:)"
framework: cryptokit
role: symbol
role_heading: Operator
path: "cryptokit/digest/==(_:_:)-7yz3z"
---

# ==(_:_:)

Determines whether a digest is equivalent to a collection of contiguous bytes.

## Declaration

```swift
static func == <D>(lhs: Self, rhs: D) -> Bool where D : DataProtocol
```

## Parameters

- `lhs`: A digest to compare.
- `rhs`: A collection of contiguous bytes to compare.

## Return Value

Return Value A Boolean value that’s true if the digest is equivalent to the collection of binary data.

## See Also

### Comparing digests

- [==(_:_:)](cryptokit/digest/==(_:_:)-6m59k.md)
