Skip to content

symboly argument names in lambdas lacking parens #5317

@aryairani

Description

@aryairani
test.laws.associativity.doc : Doc
test.laws.associativity.doc =
  {{
  Checks the associativity property of a binary operation.

  `` associativity gen f `` checks that for all elements `x`, `y`, and `z`
  returned by `gen`, `f x (f y z)` is equal to `f (f x y) z`.

  For example, if `f` is {Nat.+}, then {{ docExample 4 do x (+) y z -> x + y + z
  }} is equal to {{ docExample 4 do (+) x y z -> x + y + z }}.
  }}

renders as

test.laws.associativity.doc : Doc
test.laws.associativity.doc =
  {{
  Checks the associativity property of a binary operation.

  `` associativity gen f `` checks that for all elements `x`, `y`, and `z`
  returned by `gen`, `f x (f y z)` is equal to `f (f x y) z`.

  For example, if `f` is {Nat.+}, then {{ docExample 4 do x + y z -> x + y + z
  }} is equal to {{ docExample 4 do + x y z -> x + y + z }}.
  }}

which doesn't parse.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions