Skip to content

Remove commas from trait inheritance list #4061

Closed
@brson

Description

@brson

The trait inheritance list is a list of type bounds, but for traits. These two constructs mean very similar, if not the same, things, 'in order for a type to be Foo it must be Bar'.

fn f<Foo: Bar>() { }

trait Foo: Bar { }

but the syntaxes suggest dissimilarity with more than one bound:

fn f<Foo: Bar Baz>() { }

trait Foo: Bar, Baz { }

Using space instead of comma in the trait declaration would be more consistent and looks fine.

fn f<Foo: Bar Baz>() { }

trait Foo: Bar Baz { }

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions