Xcode: Strings Files Don’t Give Good Error Messages When Missing Semicolons

Originator:SlaunchaMan
Number:rdar://26606353 Date Originated:02-Jun-2016 03:22 PM
Status:Duplicate/15075484/Open Resolved:
Product:Developer Tools Product Version:Xcode Version 7.3.1 (7D1014)
Classification:UI/Usability Reproducible:Always
 
Summary:
In Xcode, we get good error messages when a line of Objective-C doesn’t end with a semicolon (and should). For a .strings file, there is no such message, just a failed build step with this error:

error: read failed: The data couldn’t be read because it isn’t in the correct format.

Steps to Reproduce:
1. Create an Xcode project that uses a .strings file (see attached sample project).
2. Omit a semicolon in one of the strings.

Expected Results:
Xcode will give a warning and tell you you’re missing a semicolon.

Actual Results:
Xcode fails with the error “error: read failed: The data couldn’t be read because it isn’t in the correct format.”

Version:
Xcode Version 7.3.1 (7D1014)
OS X Version 10.11.5 (15F34)

Comments

Sample Project

Sample project here: https://github.com/SlaunchaMan/RadarSampleProjects/tree/master/26606353/ThoseDarnSemicolons

By SlaunchaMan at June 2, 2016, 7:28 p.m. (reply...)

Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!