[cfe-dev] JSONCompilationDB Parser

Manuel Klimek klimek at google.com
Thu Nov 29 11:31:27 PST 2012


On Thu, Nov 29, 2012 at 11:25 AM, Tobias Grosser <tobias at grosser.es> wrote:

> On 11/29/2012 06:44 PM, Manuel Klimek wrote:
>
>> Hi Ramneek,
>>
>> On Thu, Nov 29, 2012 at 7:19 AM, Ramneek Handa <ramneekhanda at gmail.com
>> <mailto:ramneekhanda at gmail.com**>> wrote:
>>
>>     Why is it so strict? I am trying to write an ide backend would like
>>     to use the compilation commands file to contain some extra
>>     information so that i don't have to keep multiple files. the
>>     following code in parse message doesn't allow me to keep any other
>>     key but directory, command and file.
>>
>>     else {
>>              ErrorMessage = ("Unknown key: \"" +
>>                              KeyString->getRawValue() + "\"").str();
>>              return false;
>>            }
>>
>>     Could this be removed?
>>
>> In my experience being strict is better in the long run. It allows us to
>> extend the format without the need to worry about clashing names with
>> other mixed formats, and it surfaces errors early instead of hiding them.
>>
>> Is there a reason why having multiple files is a problem?
>>
>
> Hi Manuel,
>
> I see your point. However, being strict has one large problem. If we at
> some point decide to add additional information to the compilation
> database, all previously released libclang tools will break. This means,
> this restriction makes it even for ourselves unnecessarily hard and
> disruptive to extend the compilation db format.
> If possible, I would be very much in favor of removing this restriction
> even before clang 3.2.
>

If multiple people vote for it, I can most certainly be convinced
otherwise...

Cheers,
/Manuel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20121129/d2526796/attachment.html>


More information about the cfe-dev mailing list