Skip to content

Commit

Permalink
build: 更改ChartDataSet使期可以在xcode14上Run
Browse files Browse the repository at this point in the history
  • Loading branch information
CMChadHsu committed Sep 15, 2022
1 parent bebb011 commit f9e807c
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -528,6 +528,12 @@ extension ChartDataSet: RandomAccessCollection {

// MARK: RangeReplaceableCollection
extension ChartDataSet: RangeReplaceableCollection {

public func replaceSubrange<C>(_ subrange: Swift.Range<Index>, with newElements: C) where C : Collection, Element == C.Element {
entries.replaceSubrange(subrange, with: newElements)
notifyDataSetChanged()
}

public func append(_ newElement: Element) {
calcMinMax(entry: newElement)
entries.append(newElement)
Expand Down

0 comments on commit f9e807c

Please sign in to comment.