[Fatal Error]UILabel crash only above iOS 18

Demo project link https://cdn.pokekara.com/int/other/1737343007_fbcdee810da429552b12ffa2644d928c.zip

FB16168030 No response

No one is going to download a random zip file. Post your code, properly formatted, here, and we'll have a look at it.

let desc = "曲に歌ってみた!\n聴いてみてね‎✿ڿڰۣ—\n作詞 " let font = UIFont(name: "HiraginoSans-W3", size: 17)! let paragraphStyle = NSMutableParagraphStyle() paragraphStyle.lineBreakMode = NSLineBreakMode.byTruncatingTail

    let label = UILabel(frame: CGRect(x: 0, y: 100, width: 340, height: 80))
    label.font = font
    label.textAlignment = .left
    label.numberOfLines = 2
    label.lineBreakMode = .byTruncatingTail
    label.backgroundColor = UIColor.red
    label.attributedText = NSAttributedString(string: desc, attributes: [
        NSAttributedString.Key.font: font,
        NSAttributedString.Key.kern: 1,
        NSAttributedString.Key.paragraphStyle: paragraphStyle,
    ])
    
    self.view.addSubview(label)
    print(desc)
    let desc = "曲に歌ってみた!\n聴いてみてね‎✿ڿڰۣ—\n作詞  "
    let font = UIFont(name: "HiraginoSans-W3", size: 17)!
    let paragraphStyle = NSMutableParagraphStyle()
    paragraphStyle.lineBreakMode = NSLineBreakMode.byTruncatingTail
    
    let label = UILabel(frame: CGRect(x: 0, y: 100, width: 340, height: 80))
    label.font = font
    label.textAlignment = .left
    label.numberOfLines = 2
    label.lineBreakMode = .byTruncatingTail
    label.backgroundColor = UIColor.red
    label.attributedText = NSAttributedString(string: desc, attributes: [
        NSAttributedString.Key.font: font,
        NSAttributedString.Key.kern: 1,
        NSAttributedString.Key.paragraphStyle: paragraphStyle,
    ])
    
    self.view.addSubview(label)
    print(desc)
[Fatal Error]UILabel crash only above iOS 18
 
 
Q