[PATCH] Capability attributes on a typedef

Delesley Hutchins delesley at google.com
Mon Mar 24 12:08:06 PDT 2014


You can commit.  But I don't want to leave error messages in a weird
state for too long.


On Mon, Mar 24, 2014 at 9:57 AM, Aaron Ballman <aaron at aaronballman.com> wrote:
> On Mon, Mar 24, 2014 at 12:51 PM, Delesley Hutchins <delesley at google.com> wrote:
>> The patch looks good overall.  However, I'm a little bit concerned
>> about the error messages.  Since the attributes are defined through
>> macros, and the macro at google is still LOCKABLE, the message "...
>> annotated with 'capability' attribute ..." is likely to cause
>> confusion.  I seem to recall that somebody else implemented a system
>> to find out whether a macro had been defined for a given attribute.
>> Given the multiple spellings we now have for thread safety attributes,
>> it seems like a good idea to map warning messages to whatever macros
>> the user actually happens to be using.
>
> I definitely agree that capability diagnostics need a good round of
> love. Using the macros, if any, would be a good change. Also, we may
> need to pay attention to terminology like role vs mutex vs lock vs
> capability in our existing diagnostics.
>
> I'm assuming that these changes wouldn't block this particular commit,
> or is that something you'd like to see implemented prior to committing
> this patch?
>
> ~Aaron



-- 
DeLesley Hutchins | Software Engineer | delesley at google.com | 505-206-0315



More information about the cfe-commits mailing list