[PATCH 1/7] docs: rust: Fix a few grammatical errors

Joel Fernandes posted 7 patches 3 months, 3 weeks ago
[PATCH 1/7] docs: rust: Fix a few grammatical errors
Posted by Joel Fernandes 3 months, 3 weeks ago
Fix two grammatical errors in the Rust coding guidelines document.

Signed-off-by: Joel Fernandes <joelagnelf@nvidia.com>
---
 Documentation/rust/coding-guidelines.rst | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/Documentation/rust/coding-guidelines.rst b/Documentation/rust/coding-guidelines.rst
index 6ff9e754755d..d556f0db042b 100644
--- a/Documentation/rust/coding-guidelines.rst
+++ b/Documentation/rust/coding-guidelines.rst
@@ -97,7 +97,7 @@ should still be used. For instance:
 	// TODO: ...
 	fn f() {}
 
-One special kind of comments are the ``// SAFETY:`` comments. These must appear
+One special kind of comment is the ``// SAFETY:`` comment. These must appear
 before every ``unsafe`` block, and they explain why the code inside the block is
 correct/sound, i.e. why it cannot trigger undefined behavior in any case, e.g.:
 
@@ -166,7 +166,7 @@ in the kernel:
 - While not shown here, if a function may panic, the conditions under which
   that happens must be described under a ``# Panics`` section.
 
-  Please note that panicking should be very rare and used only with a good
+  Please note that panicking should be very rare and used only for a good
   reason. In almost all cases, a fallible approach should be used, typically
   returning a ``Result``.
 
-- 
2.34.1
Re: [PATCH 1/7] docs: rust: Fix a few grammatical errors
Posted by Miguel Ojeda 3 months, 3 weeks ago
On Mon, Oct 20, 2025 at 8:55 PM Joel Fernandes <joelagnelf@nvidia.com> wrote:
>
> Fix two grammatical errors in the Rust coding guidelines document.
>
> Signed-off-by: Joel Fernandes <joelagnelf@nvidia.com>

In general, please submit independent patches like this one
independently, e.g. this should go through the Rust tree.

Thanks!

Cheers,
Miguel
Re: [PATCH 1/7] docs: rust: Fix a few grammatical errors
Posted by Joel Fernandes 3 months, 3 weeks ago

On 10/20/2025 5:33 PM, Miguel Ojeda wrote:
> On Mon, Oct 20, 2025 at 8:55 PM Joel Fernandes <joelagnelf@nvidia.com> wrote:
>>
>> Fix two grammatical errors in the Rust coding guidelines document.
>>
>> Signed-off-by: Joel Fernandes <joelagnelf@nvidia.com>
> 
> In general, please submit independent patches like this one
> independently, e.g. this should go through the Rust tree.

Ack, I will do that. Thanks.
Re: [PATCH 1/7] docs: rust: Fix a few grammatical errors
Posted by John Hubbard 3 months, 3 weeks ago
On 10/20/25 11:55 AM, Joel Fernandes wrote:
> Fix two grammatical errors in the Rust coding guidelines document.
> 
> Signed-off-by: Joel Fernandes <joelagnelf@nvidia.com>
> ---
>  Documentation/rust/coding-guidelines.rst | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 

Reviewed-by: John Hubbard <jhubbard@nvidia.com>


thanks,
-- 
John Hubbard


> diff --git a/Documentation/rust/coding-guidelines.rst b/Documentation/rust/coding-guidelines.rst
> index 6ff9e754755d..d556f0db042b 100644
> --- a/Documentation/rust/coding-guidelines.rst
> +++ b/Documentation/rust/coding-guidelines.rst
> @@ -97,7 +97,7 @@ should still be used. For instance:
>  	// TODO: ...
>  	fn f() {}
>  
> -One special kind of comments are the ``// SAFETY:`` comments. These must appear
> +One special kind of comment is the ``// SAFETY:`` comment. These must appear
>  before every ``unsafe`` block, and they explain why the code inside the block is
>  correct/sound, i.e. why it cannot trigger undefined behavior in any case, e.g.:
>  
> @@ -166,7 +166,7 @@ in the kernel:
>  - While not shown here, if a function may panic, the conditions under which
>    that happens must be described under a ``# Panics`` section.
>  
> -  Please note that panicking should be very rare and used only with a good
> +  Please note that panicking should be very rare and used only for a good
>    reason. In almost all cases, a fallible approach should be used, typically
>    returning a ``Result``.
>