[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [cdt-dev] Some questions about CDT
|
I don't think we need to make changes to the ICPPEvaluation code for this, but it's possible I'm overlooking something.
Is there a particular test case that is giving you trouble with C++ code?
Thanks,
Nate
________________________________________
From: cdt-dev-bounces@xxxxxxxxxxx <cdt-dev-bounces@xxxxxxxxxxx> on behalf of marco <marco.stornelli@xxxxxxxxx>
Sent: July 13, 2019 7:07 AM
To: cdt-dev@xxxxxxxxxxx
Subject: Re: [cdt-dev] Some questions about CDT
Nathan, I'm trying to work on this topic. Changing the ValueFactory to
evaluate only const variables is easy, but I'm having problems for C++
because the ICPPEvaluation code is involved and it's not really clear to
me where it's needed to modify the check, i.e. if we have a single point
of check or we need to modify several classes. Can you point me in the
right direction? Thanks.
Il 19/06/19 20:02, Nathan Ridge ha scritto:
>> 1) Bug 545877 - Don't take into account init var values in CFG: CDT
>> Codan doesn't implement a data flow analysis, it means some checks like
>> variable initialization, always true/false conditions, dead code, can't
>> be properly detected. With my commit I just restricted the "scope",
>> Codan is more reliable about these cases because at the end it takes
>> these decisions only if the variable is const. Sometimes ago Elena
>> Laskavaia said that she was not really agree with this kind of policy,
>> but it seems Elena abandoned CDT project (if you read this message, your
>> feedback is welcome!). Actually I'm not agree with her point of view but
>> it's just my opinion. So the question: what we want to do here? If the
>> current policy is ok for the community I can abandon my commit.
>
> My opinion on this is that we should only report the initial value of a variable as its current value if the variable is constant, and that we should do this consistently, rather than having conditional logic to e.g. only do this for CFG building.
>
> If anyone feels strongly that the status quo behaviour (where we always report the initial value of a variable as its current value) is preferable, please speak up in this thread.
>
> Thanks,
> Nate
> _______________________________________________
> cdt-dev mailing list
> cdt-dev@xxxxxxxxxxx
> To change your delivery options, retrieve your password, or unsubscribe from this list, visit
> https://www.eclipse.org/mailman/listinfo/cdt-dev
>
_______________________________________________
cdt-dev mailing list
cdt-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/cdt-dev