[rustdoc] Do not take doc(cfg()) into account when filtering doctests - #159014
Open
GuillaumeGomez wants to merge 5 commits into
Open
[rustdoc] Do not take doc(cfg()) into account when filtering doctests#159014GuillaumeGomez wants to merge 5 commits into
doc(cfg()) into account when filtering doctests#159014GuillaumeGomez wants to merge 5 commits into
Conversation
This comment has been minimized.
This comment has been minimized.
Member
Author
|
And now it fails because we (doc) inlined some functions. Fixing that then. :) |
This comment has been minimized.
This comment has been minimized.
GuillaumeGomez
force-pushed
the
doc-cfg-filter-doctest
branch
from
July 9, 2026 14:58
f5059c8 to
062cfea
Compare
This comment has been minimized.
This comment has been minimized.
GuillaumeGomez
force-pushed
the
doc-cfg-filter-doctest
branch
from
July 9, 2026 15:43
062cfea to
1d5692c
Compare
Member
Author
|
Fixed CI \o/ |
fmease
reviewed
Jul 14, 2026
GuillaumeGomez
force-pushed
the
doc-cfg-filter-doctest
branch
from
July 15, 2026 13:10
1d5692c to
a0bf3c9
Compare
This comment has been minimized.
This comment has been minimized.
Member
Author
|
Reverted changes I made to |
This comment has been minimized.
This comment has been minimized.
Member
Author
|
Ah, new stuff gets added. |
GuillaumeGomez
force-pushed
the
doc-cfg-filter-doctest
branch
from
July 15, 2026 14:50
a0bf3c9 to
59a72c3
Compare
Collaborator
|
cc @Amanieu, @folkertdev, @sayantn |
GuillaumeGomez
force-pushed
the
doc-cfg-filter-doctest
branch
from
July 15, 2026 15:53
59a72c3 to
885af7e
Compare
This comment has been minimized.
This comment has been minimized.
GuillaumeGomez
force-pushed
the
doc-cfg-filter-doctest
branch
from
July 15, 2026 20:35
885af7e to
21e8051
Compare
Member
Author
|
Seems like CI is happy now. |
Member
Author
|
Setting a new reviewer as fmease seems busy. r? @Urgau |
This comment has been minimized.
This comment has been minimized.
rust-bors Bot
pushed a commit
that referenced
this pull request
Aug 3, 2026
[rustdoc] Do not take `doc(cfg())` into account when filtering doctests try-job: x86_64-msvc-1 try-job: pr-check-2
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
GuillaumeGomez
force-pushed
the
doc-cfg-filter-doctest
branch
from
August 3, 2026 22:24
c154b1e to
c3f66e2
Compare
Member
Author
|
@bors try jobs=x86_64-msvc-1,pr-check-2 |
This comment has been minimized.
This comment has been minimized.
rust-bors Bot
pushed a commit
that referenced
this pull request
Aug 3, 2026
[rustdoc] Do not take `doc(cfg())` into account when filtering doctests try-job: x86_64-msvc-1 try-job: pr-check-2
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Contributor
|
💔 Test for 38cc34c failed: CI. Failed job:
|
GuillaumeGomez
force-pushed
the
doc-cfg-filter-doctest
branch
from
August 4, 2026 09:25
c3f66e2 to
691f045
Compare
Member
Author
|
@bors try jobs=x86_64-msvc-1,pr-check-2 |
This comment has been minimized.
This comment has been minimized.
rust-bors Bot
pushed a commit
that referenced
this pull request
Aug 4, 2026
[rustdoc] Do not take `doc(cfg())` into account when filtering doctests try-job: x86_64-msvc-1 try-job: pr-check-2
Contributor
Member
Author
|
Ah finally. @bors r=Urgau |
Contributor
JonathanBrouwer
added a commit
to JonathanBrouwer/rust
that referenced
this pull request
Aug 4, 2026
…est, r=Urgau [rustdoc] Do not take `doc(cfg())` into account when filtering doctests Part of rust-lang#147033. Because it was using the `extract_cfg_from_attrs` common function, it was taking into account the `doc(cfg())` attributes the same as if they were a `cfg`. I didn't mark this PR as "fix" because I didn't handle the case of the doctest not being marked as ignored because I'm not sure if we should revisit the fact that we ignore these doctests or if we should just mark them as ignored (because of `target_feature(enable = "...")`). Setting @fmease as reviewer as they are likely the only one with context about this issue. 😆 r? @fmease
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
View all comments
Part of #147033.
Because it was using the
extract_cfg_from_attrscommon function, it was taking into account thedoc(cfg())attributes the same as if they were acfg.I didn't mark this PR as "fix" because I didn't handle the case of the doctest not being marked as ignored because I'm not sure if we should revisit the fact that we ignore these doctests or if we should just mark them as ignored (because of
target_feature(enable = "...")).Setting @fmease as reviewer as they are likely the only one with context about this issue. 😆
r? @fmease