<!--
{
  "availability" : [
    "iOS: 4.3.0 -",
    "iPadOS: 4.3.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.7.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "ObjectiveC",
  "identifier" : "/documentation/ObjectiveC/imp_removeBlock(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Objective-C Runtime"
    ],
    "preciseIdentifier" : "c:@F@imp_removeBlock"
  },
  "title" : "imp_removeBlock(_:)"
}
-->

# imp_removeBlock(_:)

Disassociates a block from an `IMP` that was created using [`imp_implementationWithBlock(_:)`](/documentation/ObjectiveC/imp_implementationWithBlock(_:)), and releases the copy of the block that was created.

```
func imp_removeBlock(_ anImp: IMP) -> Bool
```

## Parameters

`anImp`

An [`IMP`](/documentation/ObjectiveC/IMP) that was created using the [`imp_implementationWithBlock(_:)`](/documentation/ObjectiveC/imp_implementationWithBlock(_:)) function.

## Return Value

[`YES`](/documentation/ObjectiveC/YES) if the block was released successfully; otherwise, [`NO`](/documentation/ObjectiveC/NO) (for example, the function returns [`NO`](/documentation/ObjectiveC/NO) if the block was not used to create `anImp` previously).

## Discussion

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)