From 2f4f5fb5aeeeaf42d23dd740de8e6d124c7499cb Mon Sep 17 00:00:00 2001 From: "Thomas A. Christensen II" <25492070+MillironX@users.noreply.github.com> Date: Tue, 3 Jan 2023 20:19:58 -0600 Subject: [PATCH] Mark `is_valid(::Variant)` as private function --- src/Variant.jl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Variant.jl b/src/Variant.jl index fd6cccb..6242a7c 100644 --- a/src/Variant.jl +++ b/src/Variant.jl @@ -10,7 +10,7 @@ end function Variant{S,T}(ref::S, edits::Vector{Edit{S,T}}) where {S<:BioSequence,T<:BioSymbol} sort!(edits; by=x -> x.pos) result = Variant{S,T}(ref, edits, Unsafe()) - is_valid(result) || error("TODO") # report what kind of error message? + _is_valid(result) || error("TODO") # report what kind of error message? return result end @@ -31,7 +31,7 @@ end # Validate: # A sequence is invalid if any of its operations are out of bounds, or the same position # is affected by multiple edits. -function is_valid(v::Variant) +function _is_valid(v::Variant) isempty(v.ref) && return false valid_positions = 1:length(v.ref) last_was_insert = false