Closed
Description
The following code, reduced from glean-core 31.4.0, fails to compile on current master:
pub struct DebugOption<T, F = fn(T) -> Option<T>> {
t: T,
f: F,
}
The error is:
error: unmatched angle bracket
--> src/lib.rs:1:49
|
1 | pub struct DebugOption<T, F = fn(T) -> Option<T>> {
| ^^ help: remove extra angle bracket
The last nightly that rustup allows me to install (rustc 1.49.0-nightly (ffa2e7a 2020-10-24)) compiles it fine.
Interestingly, this doesn't happen with:
pub struct DebugOption<T, F = fn(T) -> Option<T>>(T, F);