r196828 - Objective-C: Improve on various diagnostics related to

Jordan Rose jordan_rose at apple.com
Tue Dec 10 13:25:07 PST 2013


On Dec 10, 2013, at 11:29 , jahanian <fjahanian at apple.com> wrote:

> 
> On Dec 10, 2013, at 9:20 AM, Jordan Rose <jordan_rose at apple.com> wrote:
> 
>> Thanks, this is better. Still have some comments though.
>> 
>> On Dec 9, 2013, at 14:04 , Fariborz Jahanian <fjahanian at apple.com> wrote:
>> 
>>> + def err_objc_bridged_related_unknown_method : Error<
>>> + "you can't convert %0 to %1, without using an existing "
>>> + "%select{class|instance}2 method for this conversion">;
>> 
>> I still don't see what this diagnostic adds. If the framework doesn't have a method name for one of the conversion directions, that probably means there's no one good way to perform this conversion. There may be no way to perform the conversion, although it's strange that they would be marked related, then.
>> 
>> Also, diagnostics generally don't have "you" except in the fix-it bit ("did you mean...").
>> 
>> How about just "%0 cannot be directly converted to %1”?
> 
> I improved the text. I also want to mention that user may have forgotten to specify a selector name in the attribute.

I just don't think that's correct. The person who is seeing the error is most likely not the person who wrote the attribute, in which case a missing selector means that that conversion can't be performed.

Maybe we should have people explicitly write "0" or "NO" or something for missing pieces?

Jordan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20131210/af3a4d66/attachment.html>


More information about the cfe-commits mailing list