Skip to content

inconsistent indenting for multi-lined requires clauses #3679

@burblebee

Description

@burblebee
Contributor

We're inconsistent when indenting requires clauses which span multiple lines.
Most indent subsequent lines to match up with what follows the requires keyword;
some indent 2 spaces (under the 'q' of the requires keyword).

Activity

JohelEGP

JohelEGP commented on Feb 21, 2020

@JohelEGP
Contributor

The motions add many of those within parentheses, at least one even preceded by !. The decision needs to include wether these should be further indented after the parentheses:

requires (forward_iterator<I> || random_access_iterator<O>) &&
         indirectly_copyable<I, O> &&

And a generalization of that rule:

    concept @\defexposconcept{convertible-to-non-slicing}@ =                    // \expos
      convertible_to<From, To> &&
      !(is_pointer_v<decay_t<From>> &&
      is_pointer_v<decay_t<To>> &&
added
decision-requiredA decision of the editorial group (or the Project Editor) is required.
on Jan 3, 2021
jensmaurer

jensmaurer commented on May 28, 2021

@jensmaurer
Member

Editorial meeting: <algorithm> indents to after the "requires" token. Tentatively agreed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    decision-requiredA decision of the editorial group (or the Project Editor) is required.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @burblebee@JohelEGP@jensmaurer

        Issue actions

          inconsistent indenting for multi-lined requires clauses · Issue #3679 · cplusplus/draft