Closed
Description
I tried this code:
pub trait Machine<'a> {
/// Data type representing values passed to or returned from machine
type Datum<'b>
where
Self: 'b;
/// Function (for example returned by [`Compile::compile`])
/// which can be executed by the machine
type Function<'b>: Function<Datum = Self::Datum<'b>>
where
Self: 'b;
}
I expected rustdoc
to create proper documentation for these GATs.
Instead, rustdoc
created the following output:
pub trait Machine<'a> {
type Datum;
type Function: Function<Datum = Self::Datum>;
}
and
Associated Types
[src]
type Datum
Data type representing values passed to or returned from machine
[src]
type Function: Function<Datum = Self::Datum>
Function (for example returned by Compile::compile) which can be executed by the machine
The lifetime argument 'b
is missing in the documentation.
Meta
rustc --version --verbose
:
rustc 1.59.0-nightly (f8abed9ed 2021-12-26)
binary: rustc
commit-hash: f8abed9ed48bace6be0087bcd44ed534e239b8d8
commit-date: 2021-12-26
host: x86_64-unknown-freebsd
release: 1.59.0-nightly
LLVM version: 13.0.0
Metadata
Metadata
Assignees
Labels
Area: Generic associated types (GATs)Category: This is a bug.`#![feature(generic_associated_types)]` a.k.a. GATsIssues using the `generic_associated_types` feature that block stabilizationIssues using the `generic_associated_types` feature that have been triagedRelevant to the rustdoc team, which will review and decide on the PR/issue.