Summary:
public
The analysis of the Buck project was failing because this script converts the aliases into their expanded target names. It turns out that for Buck, the name of the command is `buck` and the name of the alias is also `buck`, which led to conflicts. This is now fixed by only replacing the targets in the part of the command line that is after `build` in `buck build ...`
Reviewed By: sblackshear
Differential Revision: D2914446
fb-gh-sync-id: ddce4ed
shipit-source-id: ddce4ed
Summary:
public
The variable could be unitialized when the line number of an error is not in the base JSON report, which is currently the case for the errors in the test cases.
Reviewed By: jvillard
Differential Revision: D2913991
fb-gh-sync-id: d7e3857
shipit-source-id: d7e3857
Summary:
public
Java synthetic methods used to be inlined when a procedure was being analyzed.
This was done almost everywhere. A missing case was when a cfg is loaded during an existing analysis because on-demand needs access to a procedure.
Intead of trying to maintain an invariant in all access paths, we now inline them systematically before saving the cfg to disk.
A secondary consequence of this is that in debug mode the cfg dotty file will show the inlined cfg, so there's no difference between that view and what happens during analysis.
Reviewed By: jeremydubreil
Differential Revision: D2903366
fb-gh-sync-id: 252604c
Summary:
public
The PerformanceCritical Checker was not running on Buck project due to a conflict between the incremental mode and the ondemand mode.
Reviewed By: cristianoc
Differential Revision: D2891649
fb-gh-sync-id: 0a503d8
Summary:
public
This expression is used to value-initialize non-class types. Per definition of value initialization for non-class types:
1. If it's an array, value-initialize each of its elements
2. Otherwise, zero-initialize it
http://en.cppreference.com/w/cpp/language/value_initialization
I was unable to reproduce (1) in a way that produced CXXScalarValueInitExpr and so this diff
deals with case (2)
Reviewed By: jvillard
Differential Revision: D2901311
fb-gh-sync-id: beeafa2
Summary:
public Add typ information to trans_state.var_exp and use it
in constructor translation.
This information is necessary to call constructor of class Base on object with
different type (which is derived from Base)
Reviewed By: jberdine
Differential Revision: D2890850
fb-gh-sync-id: 8075db1
Summary:
public
Add type of return parameter to the context. It allows for better translation
of returnStmt and will be necessary for easy implementation of constructor init lists
Reviewed By: cristianoc
Differential Revision: D2890838
fb-gh-sync-id: e791c3d
Summary:
public
The "dotty" field in json reports is only used when reporting retain cycles. It
makes sense not to emit it by default (when it's `None`).
Reviewed By: akotulski
Differential Revision: D2891320
fb-gh-sync-id: 54292a9
Summary:
public
- add to json reports the location in the ocaml code of assertions raised
during the analysis
- only add when in debug mode. For this, add a flag to `InferPrint` that is
passed by the toplevel `infer` whenever `infer -g` is used.
Reviewed By: jeremydubreil
Differential Revision: D2891286
fb-gh-sync-id: ad4577c
Summary:
public
xvalues is concept introduced in C++11. While they are not same as lvalues, they have one common trait:
They have identity which means that:
> it's possible to determine whether the expression refers to the same entity as another expression, such as by comparing addresses of the objects or the functions they identify (obtained directly or indirectly);
It means that as far as backend is concerned, they should be treated in same way. Right now there is no concept of "move" in the backend and so we don't have
to differentiate between them.
Reference:
http://en.cppreference.com/w/cpp/language/value_category
Reviewed By: cristianoc
Differential Revision: D2895593
fb-gh-sync-id: 5101e28
Summary:
public
C++ allows for parameters with empty names (unused/default copy constructors). Make backend happy by assigning a non-empty
name to these variables
Reviewed By: jvillard
Differential Revision: D2895550
fb-gh-sync-id: b466397
Summary:
public
The env variables used by the Infer backend were only passed in multicore mode. They are now passed before the generation of clusters, whether in single core mode or in multicore mode.
Reviewed By: cristianoc
Differential Revision: D2891816
fb-gh-sync-id: 25074af
Summary:
public
It turns out that C-like structs in C++ may have methods generated by clang (constructors for example).
If struct has a method, it needs to have Sil.Class type - make all CXXRecordDecls Sil.Class types by default.
Reviewed By: cristianoc
Differential Revision: D2895567
fb-gh-sync-id: 8eb18c3
Summary:
public
These files are not supposed to be kept around - while it's convenient to not see them,
they are polluting infer directory and hard to get rid of.
Reviewed By: martinoluca
Differential Revision: D2895610
fb-gh-sync-id: c12a333
Summary:
The annotations won't work on Android unless you target JDK 1.7 (otherwise it can't DEX the app or library).
Closes https://github.com/facebook/infer/pull/257
Reviewed By: jeremydubreil
Differential Revision: D2889334
Pulled By: sblackshear
fb-gh-sync-id: c09adaa
Summary:
public
Backend needs to know whether parameter has Derived* type - otherwise subtyping in backend doesn't work. Skipping `DerivedToBase` does that
Reviewed By: dulmarod
Differential Revision: D2890673
fb-gh-sync-id: a79abbc
Summary:
public
Simplify our frontend by using information from clang.
It will also make default argument resolution more robust
with templates
Reviewed By: jvillard
Differential Revision: D2890451
fb-gh-sync-id: 9db4beb
Summary:
public
The Worklist module currently encapsulates a global data structure. Likewise for the global variables for the join state and pathset todo and visited.
This diff refactors the Worklist module into an API where instances of the record can be created and passed around. All the global state is included in the record.
The Worklist data structure never escapes the Interproc module.
Reviewed By: sblackshear
Differential Revision: D2887674
fb-gh-sync-id: 65cb234
Summary:
It has a similar lifecycle to activities and fragments, it would be nice to support `onCreate` as an initializer by default.
Closes https://github.com/facebook/infer/pull/258
Reviewed By: jeremydubreil
Differential Revision: D2887325
Pulled By: cristianoc
fb-gh-sync-id: ed31df5