Correctly recognize defined spans.

Without this change, the `to_range` method method returns `None` even when spans
are enabled.
This commit is contained in:
Jim Blandy
2021-09-14 17:04:16 -07:00
committed by Dzmitry Malyshau
parent d31121df77
commit e5ba11332f

View File

@@ -54,7 +54,7 @@ impl Span {
/// Check wether `self` was defined or is a default/unknown span
fn is_defined(&self) -> bool {
*self == Self::default()
*self != Self::default()
}
}