From 1cb0ad38524696a733f6134092ffd998f76fb142 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kat=20March=C3=A1n?= Date: Tue, 3 Aug 2021 12:52:40 -0700 Subject: [PATCH] feat(span): make span end optional --- src/protocol.rs | 4 ++-- tests/reporter.rs | 6 +----- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/src/protocol.rs b/src/protocol.rs index a797507..57f951a 100644 --- a/src/protocol.rs +++ b/src/protocol.rs @@ -102,8 +102,8 @@ pub struct SourceSpan { pub label: String, /// The start of the span. pub start: SourceLocation, - /// The end of the span. - pub end: SourceLocation, + /// The end of the span. Optional + pub end: Option, } /** diff --git a/tests/reporter.rs b/tests/reporter.rs index ed7cb78..91c0cc7 100644 --- a/tests/reporter.rs +++ b/tests/reporter.rs @@ -64,11 +64,7 @@ fn fancy() -> io::Result<()> { column: 0, offset: 0, }, - end: SourceLocation { - line: 0, - column: 4, - offset: 4, - }, + end: None, }, }], };