<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "macCatalyst: 16.0.0 -",
    "macOS: 13.0.0 -",
    "tvOS: 16.0.0 -",
    "visionOS: -",
    "watchOS: 9.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Swift",
  "identifier" : "/documentation/RegexBuilder/AlternationBuilder/buildPartialBlock(first:)-1kh7h",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "RegexBuilder"
    ],
    "preciseIdentifier" : "s:12RegexBuilder011AlternationB0V17buildPartialBlock5firstAA8ChoiceOfVyq__q0_Sgq1_SgtGx_t17_StringProcessing0A9ComponentRzq__q0_q1_t0A6OutputRtzr2_lFZ"
  },
  "title" : "buildPartialBlock(first:)"
}
-->

# buildPartialBlock(first:)

```
static func buildPartialBlock<R, W, C1, C2>(first regex: R) -> ChoiceOf<(W, C1?, C2?)> where R : RegexComponent, R.RegexOutput == (W, C1, C2)
```

---

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)