Skip to content

Remove promoted intrinsics caller type checking from const context - #61493

Closed
vertexclique wants to merge 1 commit into
rust-lang:masterfrom
vertexclique:remove-promoted-intrinsics
Closed

vertexclique wants to merge 1 commit into
rust-lang:masterfrom
vertexclique:remove-promoted-intrinsics

Conversation

@vertexclique

@vertexclique vertexclique commented Jun 3, 2019 •

Copy link
Copy Markdown
Contributor

Removes promoting intrinsics that checks the caller type in const context. PR linked to issue defined in #61399 (comment)

@rust-highfive

Copy link
Copy Markdown
Contributor

r? @pnkfelix

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

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jun 3, 2019
@vertexclique

Copy link
Copy Markdown
Contributor Author

r? @oli-obk

@rust-highfive rust-highfive assigned oli-obk and unassigned pnkfelix Jun 3, 2019
@RalfJung

RalfJung commented Jun 3, 2019

Copy link
Copy Markdown
Member

So this does not fix the bug that we allow calling intrinsics in const fn, right?

@vertexclique

vertexclique commented Jun 3, 2019 •

Copy link
Copy Markdown
Contributor Author

So this does not fix the bug that we allow calling intrinsics in const fn, right?

Removed part will be added to

// no need to check feature gates, intrinsics are only callable
// from the libstd or with forever unstable feature gates
under visit_terminator_kind. That will fix the bug seems like.

=> return true,

_ => {}
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@oli-obk We still need a PR that fixes this code and adds a test.

@Dylan-DPC-zz

Copy link
Copy Markdown

ping from triage @eddyb @vertexclique @oli-obk any updates?

@vertexclique

Copy link
Copy Markdown
Contributor Author

This can be closed, we are not going to use this. We have different PR to solve this one.

@RalfJung

RalfJung commented Jul 2, 2019 •

Copy link
Copy Markdown
Member

@vertexclique which PR is that? Is it #61835 ?

@vertexclique

Copy link
Copy Markdown
Contributor Author

Yes, it's that. It will be here: #61835

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants