-
-
Save yvt/2fec54f8012d512c59216b5d2ef82d63 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Because Gist doesn't support subdirectories... | |
mkdir -p lib1/src | |
mkdir -p lib2/src | |
mv lib1-src-lib.rs lib1/src/lib.rs | |
mv lib1-Cargo.toml lib1/Cargo.toml | |
mv lib2-src-lib.rs lib2/src/lib.rs | |
mv lib2-Cargo.toml lib2/Cargo.toml |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[package] | |
name = "lib1" | |
version = "0.1.0" | |
edition = "2018" | |
[dependencies] | |
lib2 = { path = "../lib2" } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fn unused_function(_: <lib2::GenericType<42> as lib2::TypeFn>::Output) {} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[package] | |
name = "lib2" | |
version = "0.1.0" | |
edition = "2018" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#![feature(const_generics)] | |
pub trait TypeFn { | |
type Output; | |
} | |
pub struct GenericType<const B: i8>; | |
// Removing braces around `42` resolves the crash | |
impl TypeFn for GenericType<{ 42 }> { | |
type Output = (); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment