diff --git a/src/algorithms/capture.mbt b/src/algorithms/capture.mbt index fbb7ae6..3aff322 100644 --- a/src/algorithms/capture.mbt +++ b/src/algorithms/capture.mbt @@ -21,7 +21,7 @@ /// /// A simple wrapper around Array[DiffOp] that implements the DiffHook interface /// This allows it to collect operations from any diff algorithm -type Capture Array[DiffOp] derive(Default) +struct Capture(Array[DiffOp]) derive(Default) /// ================================================================================ /// CONSTRUCTION METHODS diff --git a/src/algorithms/moon.pkg.json b/src/algorithms/moon.pkg.json index 78bccc1..84d8856 100644 --- a/src/algorithms/moon.pkg.json +++ b/src/algorithms/moon.pkg.json @@ -1,3 +1,3 @@ { - "warn-list": "-1-2-3-5-6-7-8-10-29" + "warn-list": "+a" } diff --git a/src/algorithms/range.mbt b/src/algorithms/range.mbt index 64a71b8..ff22602 100644 --- a/src/algorithms/range.mbt +++ b/src/algorithms/range.mbt @@ -98,26 +98,3 @@ pub fn Range::iter(self : Range) -> Iter[Int] { /// /// Additional utility methods that could be useful for range manipulation /// These are not currently used but demonstrate the mathematical properties - -///| Creates the intersection of two ranges -/// @return Range representing the overlap, or empty range if no overlap -fn Range::intersect(self : Range, other : Range) -> Range { - let start = @cmp.maximum(self.start, other.start) - let end = @cmp.minimum(self.end, other.end) - Range::new(start, end) -} - -///| Creates the union of two ranges (smallest range containing both) -/// @return Range spanning both input ranges -fn Range::union(self : Range, other : Range) -> Range { - let start = @cmp.minimum(self.start, other.start) - let end = @cmp.maximum(self.end, other.end) - Range::new(start, end) -} - -///| Splits the range at a given point -/// @param at The split point (must be within range) -/// @return Tuple of (left_range, right_range) -fn Range::split_at(self : Range, at : Int) -> (Range, Range) { - (Range::new(self.start, at), Range::new(at, self.end)) -} diff --git a/src/moon.pkg.json b/src/moon.pkg.json index f1bf2e0..3b99388 100644 --- a/src/moon.pkg.json +++ b/src/moon.pkg.json @@ -5,5 +5,5 @@ "alias": "algorithms" } ], - "warn-list": "-1-2-3-5-6-7-8-10-29" + "warn-list": "+a" }