We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 04220b0 commit cb3b42cCopy full SHA for cb3b42c
ices/80742.rs
@@ -0,0 +1,28 @@
1
+#![feature(const_evaluatable_checked)]
2
+#![feature(const_generics)]
3
+#![allow(incomplete_features)]
4
+
5
+use core::fmt::Debug;
6
+use core::marker::PhantomData;
7
8
+struct Inline<T>
9
+where
10
+ [u8; ::core::mem::size_of::<T>() + 1]: ,
11
+{
12
+ _phantom: PhantomData<T>,
13
+ buf: [u8; ::core::mem::size_of::<T>() + 1],
14
+}
15
16
+impl<T> Inline<T>
17
18
19
20
+ pub fn new(val: T) -> Inline<T> {
21
+ todo!()
22
+ }
23
24
25
+fn main() {
26
+ // let dst = Inline::<usize>::new(0); OK
27
+ let dst = Inline::<dyn Debug>::new(0); // BANG!
28
0 commit comments