<commit_before># Result builders

* Proposal: [SE-0289](0289-result-builders.md)
* Authors: [<NAME>](https://github.com/rjmccall), [<NAME>](https://github.com/DougGregor)
* Review Manager: [<NAME>](https://github.com/compnerd)
* Status: **Accepted**
* Implementation: Available in [development snapshots](https://swift.org/download/#snapshots) behind the underscored attribute `@_functionBuilder`.
* Previous Revisions: [1st](https://github.com/apple/swift-evolution/blob/51c99447562e749b23f82184c99c0ddfb07a71df/proposals/0289-function-builders.md)

Table of Contents
=================
   * [Result builders](#result-builders)
      * [Changes from the first revision](#changes-from-the-first-revision)
      * [Introduction](#introduction)
      * [Motivation](#motivation)
      * [Detailed design](#detailed-design)
         * [Result builder types](#result-builder-types)
         * [Result builder attributes](#result-builder-attributes)
         * [Result-building methods](#result-building-methods)
         * [The result builder transform](#the-result-builder-transform)
            * [Statement blocks](#statement-blocks)
            * [Declaration statements](#declaration-statements)
            * [Expression statements](#expression-statements)
            * [Assignments](#assignments)
            * [Selection statements](#selection-statements)
            * [Imperative control-flow statements](#imperative-control-flow-statements)
            * [Exception-handling statements](#exception-handling-statements)
            * [do statements](#do-statements)
            * [for..in loops](#forin-loops)
         * [Compiler Diagnostic Directives](#compiler-diagnostic-directives)
         * [Availability](#availability)
         * [<strong>Example</strong>](#example)
      * [Type inference](#type-inference)
         * [Result builder bodies](#result-builder-bodies)<commit_msg>SE-0289 is implemented in GitHub main for Swift 5.4 (#1199)<commit_after># Result builders

* Proposal: [SE-0289](0289-result-builders.md)
* Authors: [<NAME>](https://github.com/rjmccall), [<NAME>](https://github.com/DougGregor)
* Review Manager: [<NAME>](https://github.com/compnerd)
* Status: **Implemented (Swift 5.4)**
* Previous Revisions: [1st](https://github.com/apple/swift-evolution/blob/51c99447562e749b23f82184c99c0ddfb07a71df/proposals/0289-function-builders.md)

Table of Contents
=================
   * [Result builders](#result-builders)
      * [Changes from the first revision](#changes-from-the-first-revision)
      * [Introduction](#introduction)
      * [Motivation](#motivation)
      * [Detailed design](#detailed-design)
         * [Result builder types](#result-builder-types)
         * [Result builder attributes](#result-builder-attributes)
         * [Result-building methods](#result-building-methods)
         * [The result builder transform](#the-result-builder-transform)
            * [Statement blocks](#statement-blocks)
            * [Declaration statements](#declaration-statements)
            * [Expression statements](#expression-statements)
            * [Assignments](#assignments)
            * [Selection statements](#selection-statements)
            * [Imperative control-flow statements](#imperative-control-flow-statements)
            * [Exception-handling statements](#exception-handling-statements)
            * [do statements](#do-statements)
            * [for..in loops](#forin-loops)
         * [Compiler Diagnostic Directives](#compiler-diagnostic-directives)
         * [Availability](#availability)
         * [<strong>Example</strong>](#example)
      * [Type inference](#type-inference)
         * [Result builder bodies](#result-builder-bodies)
{'fraction_non_alphanumeric': 0.15482302080518778, 'fraction_numerical': 0.024858146446906242, 'mean_word_length': 3.6860759493670887, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, 'https://': 9, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7568430', 'n_tokens_mistral': 1156, 'n_tokens_neox': 994, 'n_words': 160}