<!--
{
  "availability" : [
    "iOS: 4.0.0 -",
    "iPadOS: 4.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.6.0 -",
    "tvOS: -",
    "visionOS: 1.0.0 -",
    "watchOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Dispatch",
  "identifier" : "/documentation/Dispatch/dispatch_source_merge_data",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Dispatch"
    ],
    "preciseIdentifier" : "c:@F@dispatch_source_merge_data"
  },
  "title" : "dispatch_source_merge_data"
}
-->

# dispatch_source_merge_data

Merges data into a dispatch source and submits its event handler block to its target queue.

```
extern void dispatch_source_merge_data(dispatch_source_t source, uintptr_t value);
```

## Parameters

`source`

This parameter cannot be `NULL`.

`value`

The value to coalesce with the pending data using a logical OR or an ADD as specified by the dispatch source type. A value of zero has no effect and does not result in the submission of the event handler block.

## Discussion

Your application can use this function to indicate that an event has occurred on one of the application-defined dispatch event sources of type [`DISPATCH_SOURCE_TYPE_DATA_ADD`](/documentation/Dispatch/DISPATCH_SOURCE_TYPE_DATA_ADD) or [`DISPATCH_SOURCE_TYPE_DATA_OR`](/documentation/Dispatch/DISPATCH_SOURCE_TYPE_DATA_OR).

---

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)