From 32221f6856505e61f8cb1e136452f7aa47def20e Mon Sep 17 00:00:00 2001 From: Arthur Milchior Date: Mon, 26 Feb 2024 05:11:54 +0100 Subject: [PATCH 1/2] Use different type in an example MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sentences such as «without the argument u32» were ambiguous, as there were two distincts u32. Having a single one, the one in the monomorphization of the type, remove the ambiguity. --- src/ty.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ty.md b/src/ty.md index b7a2ba8e4..d831094d8 100644 --- a/src/ty.md +++ b/src/ty.md @@ -281,7 +281,7 @@ modules choose to import a larger or smaller set of names explicitly. Let's consider the example of a type like `MyStruct`, where `MyStruct` is defined like so: ```rust,ignore -struct MyStruct { x: u32, y: T } +struct MyStruct { x: str, y: T } ``` The type `MyStruct` would be an instance of `TyKind::Adt`: From 7c77ff5b76298c678369b9465fa43528d53ccfd2 Mon Sep 17 00:00:00 2001 From: Nilstrieb <48135649+Nilstrieb@users.noreply.github.com> Date: Fri, 1 Mar 2024 23:25:38 +0100 Subject: [PATCH 2/2] Update src/ty.md --- src/ty.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ty.md b/src/ty.md index d831094d8..7680bdf88 100644 --- a/src/ty.md +++ b/src/ty.md @@ -281,7 +281,7 @@ modules choose to import a larger or smaller set of names explicitly. Let's consider the example of a type like `MyStruct`, where `MyStruct` is defined like so: ```rust,ignore -struct MyStruct { x: str, y: T } +struct MyStruct { x: u8, y: T } ``` The type `MyStruct` would be an instance of `TyKind::Adt`: