<!--
{
  "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/Local",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "RegexBuilder"
    ],
    "preciseIdentifier" : "s:12RegexBuilder5LocalV"
  },
  "title" : "Local"
}
-->

# Local

A regex component that represents an atomic group.

```
struct Local<Output>
```

## Overview

An atomic group opens a local backtracking scope which, upon successful
exit, discards any remaining backtracking points from within the scope.

## Topics

### Initializers

[`init(some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-190tm)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5, C6, C7, C8>(() -> some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-1pqmw)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5, C6, C7>(some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-1z8ep)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4>(some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-2682m)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5, C6>(() -> some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-3bh2x)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3>(some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-3igqu)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5>(() -> some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-3s7fi)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5, C6, C7, C8, C9, C10>(() -> some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-53gbl)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5, C6, C7>(() -> some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-54x6o)

Creates an atomic group with the given regex component.

[`init<W, C1>(some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-5xekw)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5>(some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-6dp02)

Creates an atomic group with the given regex component.

[`init(() -> some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-75o5i)

Creates an atomic group with the given regex component.

[`init<W, C1, C2>(() -> some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-7an8x)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4>(() -> some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-7b0cb)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3>(() -> some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-7c8wv)

Creates an atomic group with the given regex component.

[`init<W, C1>(() -> some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-7o3al)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5, C6, C7, C8, C9>(() -> some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-8bmi6)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5, C6, C7, C8, C9>(some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-8hppy)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5, C6>(some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-8i5e6)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5, C6, C7, C8>(some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-8nf0w)

Creates an atomic group with the given regex component.

[`init<W, C1, C2>(some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-8xd9f)

Creates an atomic group with the given regex component.

[`init<W, C1, C2, C3, C4, C5, C6, C7, C8, C9, C10>(some RegexComponent)`](/documentation/RegexBuilder/Local/init(_:)-anqj)

Creates an atomic group with the given regex component.

## Relationships

### Conforms To

[`RegexComponent`](/documentation/Swift/RegexComponent)

[`Copyable`](/documentation/Swift/Copyable)

[`Escapable`](/documentation/Swift/Escapable)

---

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)