Skip to content

Add single-deriving-parens #385

@pbrisbin

Description

@pbrisbin

Describe the option you'd like to add

single-deriving-parens: always|auto|never, to be consistent with single-constraint-parens but for deriving stanzas.

Show a code example exemplifying the different option settings

single-deriving-parens: always (default):

-- Given
data X = X
  deriving stock Show

data Y = Y
  deriving stock (Show)

-- Formats too
data X = X
  deriving stock (Show)

data Y = Y
  deriving stock (Show)

single-deriving-parens: auto:

-- Given
data X = X
  deriving stock Show

data Y = Y
  deriving stock (Show)

-- Formats too
data X = X
  deriving stock Show

data Y = Y
  deriving stock (Show)

single-deriving-parens: never:

-- Given
data X = X
  deriving stock Show

data Y = Y
  deriving stock (Show)

-- Formats too
data X = X
  deriving stock Show

data Y = Y
  deriving stock Show

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions