Skip to content

mark a doctest with UB as no_run #120366

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 1 commit into from
Jan 27, 2024

Conversation

RalfJung
Copy link
Member

#119911 added a doctest with UB. That one shouldn't be run, or else Miri will complain.

@rustbot
Copy link
Collaborator

rustbot commented Jan 26, 2024

r? @cuviper

(rustbot has picked a reviewer for you, use r? to override)

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Jan 26, 2024
@compiler-errors
Copy link
Member

compiler-errors commented Jan 26, 2024

How is this test UB? If the test is UB, should we just remove it, or fix it?

edit: lmao, nvm, I read the whole thing. Yeah, seems like an oversight in the PR to add no_run here.

@cuviper
Copy link
Member

cuviper commented Jan 26, 2024

The example is intentionally demonstrating, "don't do this because it's UB!"

@cuviper
Copy link
Member

cuviper commented Jan 26, 2024

@bors r+ rollup

@bors
Copy link
Collaborator

bors commented Jan 26, 2024

📌 Commit 5dd6418 has been approved by cuviper

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 26, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request Jan 27, 2024
…iaskrgr

Rollup of 12 pull requests

Successful merges:

 - rust-lang#103522 (stabilise array methods)
 - rust-lang#113489 (impl `From<&[T; N]>` for `Cow<[T]>`)
 - rust-lang#119342 (Emit suggestion when trying to write exclusive ranges as `..<`)
 - rust-lang#119562 (Rename `pointer` field on `Pin`)
 - rust-lang#119800 (Document `rustc_index::vec::IndexVec`)
 - rust-lang#120205 (std: make `HEAP` initializer never inline)
 - rust-lang#120277 (Normalize field types before checking validity)
 - rust-lang#120311 (core: add `From<core::ascii::Char>` implementations)
 - rust-lang#120366 (mark a doctest with UB as no_run)
 - rust-lang#120378 (always normalize `LoweredTy` in the new solver)
 - rust-lang#120382 (Classify closure arguments in refutable pattern in argument error)
 - rust-lang#120389 (Add fmease to the compiler review rotation)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit a7f5bde into rust-lang:master Jan 27, 2024
@rustbot rustbot added this to the 1.77.0 milestone Jan 27, 2024
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Jan 27, 2024
Rollup merge of rust-lang#120366 - RalfJung:is_val_statically_known, r=cuviper

mark a doctest with UB as no_run

rust-lang#119911 added a doctest with UB. That one shouldn't be run, or else Miri will complain.
@RalfJung RalfJung deleted the is_val_statically_known branch January 27, 2024 11:53
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-libs Relevant to the library team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants