Skip to content

Add note to use nightly when using expr in const generics - #79374

Merged
bors merged 3 commits into
rust-lang:masterfrom
mendess:const-param-expr-diagnostic
Nov 24, 2020
Merged

Add note to use nightly when using expr in const generics#79374
bors merged 3 commits into
rust-lang:masterfrom
mendess:const-param-expr-diagnostic

Conversation

@mendess

Copy link
Copy Markdown
Contributor

As recommended by @icnr in #73899 and in zulip, I've added a note saying that const expressions can be used in nightly.

error: generic parameters may not be used in const operations
--> $DIR/issue-61935.rs:10:23
|
6 | Self:FooImpl<{N==0}>
| ^ cannot perform const operation using `N`
|
= help: const parameters may only be used as standalone arguments, i.e. `N`
= note: use feature(const_generics) and feature(const_evaluatable_checked) to enable this
error: aborting due to previous error

I hope the note is well written 😅

@rust-highfive

Copy link
Copy Markdown
Contributor

r? @petrochenkov

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

@rust-highfiverust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Nov 24, 2020
@lcnr

lcnr commented Nov 24, 2020

Copy link
Copy Markdown
Contributor

r? @lcnr

Comment threadcompiler/rustc_resolve/src/diagnostics.rs Outdated
Comment threadcompiler/rustc_resolve/src/diagnostics.rs Outdated
@mendess

mendess commented Nov 24, 2020

Copy link
Copy Markdown
ContributorAuthor

r? @lcnr

After this r=me 😅

is this what r=me means? I'm new to this 😅

@lcnr

lcnr commented Nov 24, 2020

Copy link
Copy Markdown
Contributor

r=me is used to signal that I will approve this PR using bors.

thanks 👍

@bors r+ rollup

@bors

bors commented Nov 24, 2020

Copy link
Copy Markdown
Collaborator

📌 Commit 888055e has been approved by lcnr

@borsbors 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 Nov 24, 2020
bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 24, 2020
…as-schievink
Rollup of 10 pull requests
Successful merges:
- rust-lang#76858 (Add exploit mitigations chapter to the rustc book)
- rust-lang#79310 (Make `fold_item_recur` non-nullable)
- rust-lang#79312 (Get rid of `doctree::Impl`)
- rust-lang#79321 (Accept '!' in intra-doc links)
- rust-lang#79346 (Allow using `-Z fewer-names=no` to retain value names)
- rust-lang#79351 (Fix typo in `keyword` docs for traits)
- rust-lang#79354 (BTreeMap: cut out the ceremony around BoxedNode)
- rust-lang#79358 (BTreeMap/BTreeSet: make public doc more consistent)
- rust-lang#79367 (Allow disabling TrapUnreachable via -Ztrap-unreachable=no)
- rust-lang#79374 (Add note to use nightly when using expr in const generics)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
@bors
bors merged commit f049b0b into rust-lang:masterNov 24, 2020
@rustbotrustbot added this to the 1.50.0 milestone Nov 24, 2020
@lcnrlcnr added the A-const-generics Area: const generics (parameters and arguments) label Aug 26, 2021
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-const-genericsArea: const generics (parameters and arguments)S-waiting-on-borsStatus: Waiting on bors to run and complete tests. Bors will change the label on completion.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants

@mendess@rust-highfive@lcnr@bors@petrochenkov@rustbot