or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Do you want to remove this version name and description?
Syncing
xxxxxxxxxx
types team 2024 roadmap
fn codegen_select_candidate
Not on roadmap:
unsoundness
https://github.com/rust-lang/rust/issues?q=is%3Aissue+is%3Aopen+label%3AI-unsound+label%3AT-types
Last year: https://hackmd.io/nNC_Z6nVSpW-ANkpJdSgpg?both (https://i.imgur.com/1zqc2pc.jpg)
- fixed by https://github.com/rust-lang/rust/pull/115008, oli to summarize + FCP
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →E-mentor
tagFollowup: Niko and Jack to put together an initial draft of unsoundess on a roadmap
niko digresses onto a question around outlives
This used to be true:
fn(&'a u32): 'static
But we wanted
T::Item: 'x
ifT: 'x
and…But we could say that if a lifetime is used in contravariant position then it's not constrained.
I wish we could change the current behavior. If we could do this, doing it over an edition might be the way. It would be nice if
T: 'static
would always mean thatT
doesn't contain any data by reference.This is related to:
– Rust allows impl Fn(T<'a>) -> T<'b> to be : 'static, which is unsound #112905
Issue with
TypeId
:fn(&'a u32): 'static
means you can convertBox<fn(&'a u32)>
toBox<dyn Any>
, downcast toBox<fn(&'static u32)>
.playing with 112905
https://github.com/rust-lang/rust/issues/112905
The heart of 112905 is leverage the dyn trait loophole to convert a…
F<'a, 'b>
toF<'a, 'static>
. Which lets you call the function and convert anything into'static
.Suppose we had an explicit notation:
what if the type were
is that a soundness hole? It IS possible to have
Another view of #112905 is that, in this code…
https://play.rust-lang.org/?version=nightly&mode=debug&edition=2021&gist=dc541ebd1502a24cc3885a63ac8c83ce
Writing the implied
where 'a: 'b
bound correctly gives you this error:https://play.rust-lang.org/?version=nightly&mode=debug&edition=2021&gist=4a1f612ca7b8c76b3b7795ea4242be14
message:
will not compile
In summary…
NM: Not convinced this bug blocks semantic
'static
.NM: Am convinced that our implied bounds rules need work.
Fuzzing
Resources:
Deriving Soundness Proofs and Efficient Checkers