---
title: object_dispose
framework: objectivec
role: symbol
role_heading: Function
path: objectivec/object_dispose
---

# object_dispose

Frees the memory occupied by a given object.

## Declaration

```occ
extern idobject_dispose(id obj);
```

## Parameters

- `obj`: An Objective-C object.

## Return Value

Return Value nil.

## See Also

### Working with Instances

- [object_copy](objectivec/object_copy.md)
- [object_setInstanceVariable](objectivec/object_setinstancevariable.md)
- [object_getInstanceVariable](objectivec/object_getinstancevariable.md)
- [object_getIndexedIvars(_:)](objectivec/object_getindexedivars(_:).md)
- [object_getIvar(_:_:)](objectivec/object_getivar(_:_:).md)
- [object_setIvar(_:_:_:)](objectivec/object_setivar(_:_:_:).md)
- [object_getClassName(_:)](objectivec/object_getclassname(_:).md)
- [object_getClass(_:)](objectivec/object_getclass(_:).md)
- [object_setClass(_:_:)](objectivec/object_setclass(_:_:).md)
