You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Let's say you have a typedef that looks like this:
typedef struct _A {
int a;
int b;
} A, *PA;
There are two variable declarations somewhere in the program:
PA p1 = foo();
and
PA p2 = bar();
In one scenario, both foo and bar are unconstrained and can be PTR. The re-writer could make one edit, in the typedef, to change the definition of PA to be ptr<struct _A> PA. Then this will just work.
However, let's say that the return value of foo is PTR but bar is constrained to not PTR. So one of these will be re-written to ptr and another won't. Can we do better? One option is to create a new typedef, but there are questions to be answered. What is this typedef called? How do we disambiguate it from the old one? And so on.
Come up with a spectrum of answers to this question and implement them.
The text was updated successfully, but these errors were encountered:
This issue was copied from checkedc/checkedc-clang#49
Let's say you have a typedef that looks like this:
There are two variable declarations somewhere in the program:
and
In one scenario, both
foo
andbar
are unconstrained and can bePTR
. The re-writer could make one edit, in the typedef, to change the definition ofPA
to beptr<struct _A> PA
. Then this will just work.However, let's say that the return value of
foo
isPTR
butbar
is constrained tonot PTR
. So one of these will be re-written to ptr and another won't. Can we do better? One option is to create a new typedef, but there are questions to be answered. What is this typedef called? How do we disambiguate it from the old one? And so on.Come up with a spectrum of answers to this question and implement them.
The text was updated successfully, but these errors were encountered: