From cc4fba4455b44dece432105e827773fdfb7ac686 Mon Sep 17 00:00:00 2001 From: Mike Voronov Date: Wed, 29 Jun 2022 22:23:33 +0300 Subject: [PATCH] Document import scheme and doc comment style (#268) --- docs/developer-notes.md | 40 +++++++++++++++++++++++++++++++++++++++- 1 file changed, 39 insertions(+), 1 deletion(-) diff --git a/docs/developer-notes.md b/docs/developer-notes.md index 9682db01..06ad0357 100644 --- a/docs/developer-notes.md +++ b/docs/developer-notes.md @@ -1,5 +1,43 @@ -In the AquaVM we use the following conventions for PR reviewing: +PR reviewing conventions +---------------------- + +In the AquaVM repo the following conventions for PR reviewing is used: - **Concept ACK** - agree with the idea and overall concept, but haven't reviewed the code changes or tested them, - **utACK (untested ACK)** - reviewed and agree with the code changes but haven't actually tested them, - **Tested ACK** - reviewed the code changes and have verified the functionality or a bug fix, - **NACK** - disagree with the code changes/concept, should be accompanied by an explanation. + +Coding style +---------------------- + +__Import scheme__ +We follow this import scheme: + - imports from local project (crate::/super::) + - newline + - other imports from non-std + - newline + - imports from std + +If there are not so many imports newlines could be omitted. + +Example: +```rust +use super::ExecutionCtx; +use super::ExecutionResult; + +use air_parser::ast; +use air_parser::ast::Fail; + +use std::rc::Rc; +``` + +__Doc comment style__ + +```rust +/// This is a doc comment with a dot at the end. +``` + +```rust +/// Comments could also be multi-line and +/// should also end with a dot. +```