---
title: "CFSetReplaceValue(_:_:)"
framework: corefoundation
role: symbol
role_heading: Function
path: "corefoundation/cfsetreplacevalue(_:_:)"
---

# CFSetReplaceValue(_:_:)

Replaces a value in a CFMutableSet object.

## Declaration

```swift
func CFSetReplaceValue(_ theSet: CFMutableSet!, _ value: UnsafeRawPointer!)
```

## Parameters

- `theSet`: The set to modify.
- `value`: The value to replace in theSet. If this value does not already exist in theSet, the function does nothing. You may pass the value itself instead of a pointer if it is pointer-size or less. The equal callback provided when theSet was created is used to compare. If the equal callback was NULL, pointer equality (in C, ==) is used. If value, or any other value in theSet, is not understood by the equal callback, the behavior is undefined.

## See Also

### CFMutableSet Miscellaneous Functions

- [CFSetAddValue(_:_:)](corefoundation/cfsetaddvalue(_:_:).md)
- [CFSetCreateMutable(_:_:_:)](corefoundation/cfsetcreatemutable(_:_:_:).md)
- [CFSetCreateMutableCopy(_:_:_:)](corefoundation/cfsetcreatemutablecopy(_:_:_:).md)
- [CFSetRemoveAllValues(_:)](corefoundation/cfsetremoveallvalues(_:).md)
- [CFSetRemoveValue(_:_:)](corefoundation/cfsetremovevalue(_:_:).md)
- [CFSetSetValue(_:_:)](corefoundation/cfsetsetvalue(_:_:).md)
