llvm-project icon indicating copy to clipboard operation
llvm-project copied to clipboard

Annotate more functions in std:: for statement-local analysis

Open mgehre opened this issue 6 years ago • 1 comments

We could annotate functions such as std::min and similar to enable analysis of

int v = 3;
int &i = std::max(v+1, v);

We can either

  1. Add appropriate annotations to libc++
  2. Hardcode the specific annotations in clang (i.e. lifetime(ret, {a, b}))
  3. Hardcode the fact that inferred annotations are correct, and then infer annotations

mgehre avatar Aug 12 '19 07:08 mgehre

fyi @Xazax-hun

mgehre avatar Aug 12 '19 07:08 mgehre