---
title: "passRetained(_:)"
framework: swift
role: symbol
role_heading: Type Method
path: "swift/unmanaged/passretained(_:)"
---

# passRetained(_:)

Creates an unmanaged reference with an unbalanced retain.

## Declaration

```swift
static func passRetained(_ value: Instance) -> Unmanaged<Instance>
```

## Parameters

- `value`: A class instance.

## Return Value

Return Value An unmanaged reference to the object passed as value.

## Discussion

Discussion The instance passed as value will leak if nothing eventually balances the retain. This is useful when passing an object to an API which Swift does not know the ownership rules for, but you know that the API expects you to pass the object at +1.
