From c04d241062d3954de5c36f4f6452c10e48358b09 Mon Sep 17 00:00:00 2001 From: Kirill Mikhailov Date: Fri, 10 Jan 2025 14:21:06 +0100 Subject: [PATCH 1/2] Legalize `C-QUESTION-MARK` violation --- documentation/API-GUIDELINES.md | 1 + 1 file changed, 1 insertion(+) diff --git a/documentation/API-GUIDELINES.md b/documentation/API-GUIDELINES.md index 717d238065..c614619939 100644 --- a/documentation/API-GUIDELINES.md +++ b/documentation/API-GUIDELINES.md @@ -13,6 +13,7 @@ In general, the [Rust API Guidelines](https://rust-lang.github.io/api-guidelines ## Amendments to the Rust API Guidelines - `C-RW-VALUE` and `C-SERDE` do not apply. +- `C-QUESTION-MARK`: `?` is not applicable in the context of the `main` function in our driver, documentation example makes no sense. - `C-COMMON-TRAITS`: The set of traits to implement depend on the type and use case. In esp-hal, we can highlight a few such use cases and provide recommendations what should be implemented. If nothing here applies, use your best judgement. - Driver structures: `Debug` From 43408b403a772df872f5fbf35da4cef6af8fbd1f Mon Sep 17 00:00:00 2001 From: Kirill Mikhailov Date: Fri, 10 Jan 2025 14:25:42 +0100 Subject: [PATCH 2/2] sure... --- documentation/API-GUIDELINES.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/documentation/API-GUIDELINES.md b/documentation/API-GUIDELINES.md index c614619939..98f64d2a51 100644 --- a/documentation/API-GUIDELINES.md +++ b/documentation/API-GUIDELINES.md @@ -13,7 +13,7 @@ In general, the [Rust API Guidelines](https://rust-lang.github.io/api-guidelines ## Amendments to the Rust API Guidelines - `C-RW-VALUE` and `C-SERDE` do not apply. -- `C-QUESTION-MARK`: `?` is not applicable in the context of the `main` function in our driver, documentation example makes no sense. +- `C-QUESTION-MARK`: `?` is not applicable in the context of the `main` function in our driver. - `C-COMMON-TRAITS`: The set of traits to implement depend on the type and use case. In esp-hal, we can highlight a few such use cases and provide recommendations what should be implemented. If nothing here applies, use your best judgement. - Driver structures: `Debug`