Comments (5)
We can easily support interpreting the CF annotations as best as possible within the (less sophisticated) NullAway type system. Actually enhancing the power of the type system would be more work and would require some further justification in terms of additional reliability in practice, etc.
For this one, I think by default we would just treat the field as @NonNull
. Are you looking for deeper support than that?
from nullaway.
Ah, I see. You're probably looking to not see reports of initialization errors on such fields, yes? If so, that can easily be handled using the -XepOpt:NullAway:ExcludedFieldAnnotations
option (see here).
from nullaway.
For this one, should we treat it in the following way,
If a field
I am currently focusing on eliminating all warnings on uninitialized fields.
from nullaway.
Yeah, for now you can handle this by passing -XepOpt:NullAway:ExcludedFieldAnnotations=MonotonicNonNullDecl
as an Error Prone / javac argument. For CF compatibility we should probably bake in support for this annotation.
from nullaway.
Neat. Thank you.
from nullaway.
Related Issues (20)
- Missing check for library models for lambdas with an expression body
- jdk Files false positive/wrong line HOT 3
- Update JSpecify package in docs HOT 1
- The combination of JSpecify + Lombok does not seem to work well HOT 6
- Method references of nullable instances are not detected HOT 1
- Detected NPE causes EP's Var rule to go nuts. HOT 5
- Validation of null in a switch-case with pattern matching does not work as expected. HOT 1
- False positive warning on switch statements with case null
- Build failure : 'options.compilerArgumentProviders.errorprone$0.name' is missing an input or output annotation. HOT 1
- Support org.apache.commons.lang3.StringUtils.isNotEmpty HOT 3
- Support for `collect()` in Streams API HOT 4
- Control flow analysis fails within a stream collector HOT 5
- Validation of null in a method used in a boolean expression does not work as expected. HOT 1
- `if (Foo.this.bar != null)` in nested class not properly analyzed HOT 1
- Rename the Jar Infer Flags `JarInferEnabled`,`JarInferUseReturnAnnotations`
- Variable checked non-null outside a `forEach` or `Stream` lambda triggers an error HOT 13
- `if` statement on a boolean does not prevent a dereferenced nullable error HOT 1
- Null `if` check and failing function to taken in account HOT 2
- Extract methods in StreamNullabilityPropagator
- ignoring generic Nullable on Supplier HOT 14
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nullaway.