drawAngles[j] crash in PieChartRenderer using custom PieChartView in Xcode 11+
- Dominant language
- Swift
- Stars
- 28k
- Forks
- 6k
- PR merge metrics
- No merged PRs in 30d
Description
I am using a custom `PieChartView`, overriding the functions I need to create a custom pie chart. I am using the latest version of Charts from master.
Everything was working fine in Xcode 10.3, but when upgrading to **Xcode 11**, a crash occurred with `drawAngles[j]` in `PieChartRenderer`, because `drawAngles` has a size of 0:

The cause for this is due to `PieRadarChartViewBase::notifyDataSetChanged()`, which calls `calcMinMax()`, which as a result calls `PieChartView::calcMinMax()` in **Xcode 11**:

However in **Xcode 10.3**, `PieRadarChartViewBase::notifyDataSetChanged()` calls `calcMinMax()`, which correctly calls my custom overridden `CustomPieChartView::calcMinMax()`, resulting in the correct size for `drawAngles`, leading to no crash when `drawAngles` is accessed in `PieChartRenderer`:

This cannot be reproduce in the demo because there's no custom `PieChartView` example.
Is anyone using a custom `PieChartView` know what in Xcode 11 is causing this issue and how to resolve?
Thanks!
Contributor guide
Assessment
This issue has not been assessed yet.