Skip to content

Conversation

@xbonnetain
Copy link

Rule 5 is currently written as a suggestion:

The tool rustfmt can be used to ensure...

This is the only rule written this way, and it defeats its purpose.

This PR changes "can" to "must".

Other approaches

There are other possibilities, for example:

  • Removing this rule
  • Adding a "Suggestion/Best practice" block for non-mandatory things

@danielhenrymantilla
Copy link
Contributor

Forcing the usage of a specific formatter feels contrived, though. Maybe "an autoformatting tool (e.g. rustfmt) must be used". This way the phrasing remains open to alternative formatters that may arise.

> ### Règle {{#check DENV-FORMAT | Utilisation d'un outil de formatage (rustfmt)}}
>
> L'outil de formatage `rustfmt` peut être utilisé pour assurer le respect de
> L'outil de formatage `rustfmt` doit être utilisé pour assurer le respect de
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Je comprends le principe d'imposer le verbe "devoir" dans la rédaction des règles.

Par contre, pour un guide sur les bonnes pratiques de sécurité, je me pose la question d'imposer un formatage au code.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

L’uniformité de formatage facilite la lecture, donc peut simplifier la contribution avec relecture par pair et les audits. Mais même en tenant compte de ce fait, je m’attendrais plutôt à trouver un (double1) should qu’un must.

Footnotes

  1. Un outil de formatage devrait être utilisé ; celui-ci devrait être rustfmt.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants