我想知道可能的原因是什么? mAutoCommentLabel.text是nil还是cellFont是nil?
UIFont* cellFont = mAutoCommentLabel.font;
NSAttributedString *attrStr = [[NSAttributedString alloc] initWithString:mAutoCommentLabel.text attributes:@{NSFontAttributeName: cellFont}];
CGRect rect =
[attrStr boundingRectWithSize:CGSizeMake(withWidth, CGFLOAT_MAX)
options:(NSStringDrawingUsesLineFragmentOrigin|NSStringDrawingUsesFontLeading)
context:nil];
int commentHeight = rect.size.height;