nicklockwood / Euclid

A Swift library for creating and manipulating 3D geometry
MIT License
644 stars 53 forks source link

Assertion #46

Closed gin66 closed 3 years ago

gin66 commented 3 years ago

While performing text("Hello World!") the code hits the assertion in Paths.swift:

internal extension Path {
    init(unchecked points: [PathPoint], plane: Plane?, subpathIndices: [Int]?) {
        assert(sanitizePoints(points) == points) <======
        self.points = points
        self.isClosed = pointsAreClosed(unchecked: points)

Triggering character is "!".

BTW: Running on iOS

gin66 commented 3 years ago

Failed test case is here for reference

nicklockwood commented 3 years ago

@gin66 fixed in 0.4.5