Why not throw an error if file not exist when Xcode project building

e.g.

UIImage *image = [UIimage imageNamed:@"abc"];


NSString *file = [NSString stringWithFormat:@"%@/efg.png", [[NSBundle mainBundle] resourcePath]];
UIImage *thumbnail = [UIImage imageWithContentsOfFile:file];


like this, if 'abc.png' or 'efg.png' not exist, Xcode can throw an error when project are building.


It will help us clean some extra resource file if it's does not work.