Coeffect
Error Prone
Coeffect | Error Prone | |
---|---|---|
7 | 16 | |
14 | 6,731 | |
- | 0.5% | |
0.0 | 9.4 | |
almost 2 years ago | 4 days ago | |
Java | Java | |
Apache License 2.0 | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
Coeffect
-
How to create annotatino to restrict use of functions, similarly to `@Compose`
I created this exact plugin for Java (currently it is not ready for production because it uses preview features for Java's concurrency): https://github.com/Holo314/Coeffect
-
“Don’t listen to language designers”
I implemented a Coeffect system into Java, and encounter a problem with the 4th type system of Java (yes, there are 4 separate type systems in Java), the annotations type system. For the exact problem see this section. There are walk arounds, but they boil down to implement generics on the annotation level, which is a huge amount of work and I didn't have the time to implement it yet (and it doesn't help that ExtentValues weren't on the main branch when I made it, and they are still incubator now, with a different name)
-
Indentation limbo
I am not really active on public domain (all of my work is on private domain), but See this for example.
-
Why is `suspend` a language keyword, but @Composable and @Serializable are annotations
I am all in favour to more third side libraries adding functionalities, like Lombok, Manifold and error prone. As well as smaller projects like this shameless plug and what appears in this list
-
Better Java logging, inspired by Clojure and Rust
For Coeffects there is much less available material and most of it is much more mathematical heavy, but you can try to read about it here. I'll also have a shameless plug of my Java plugin that adds implicit parameter Coeffect into Java's type system
-
Adding Coeffect System to Java with Project Loom
Using the fact that ExtentLocals have a structured lifetime, I created a Coeffect Type System using Java Compiler Plugin. I would love some feedback
Error Prone
-
Any library you would like to recommend to others as it helps you a lot? For me, mapstruct is one of them. Hopefully I would hear some other nice libraries I never try.
error-prone is good for some extra static analysis.
-
How to use Java Records
A special kind of validation is enforcing that record fields are not null. (Un)fortunately, records do not have any special behavior regarding nullability. You can use tools like NullAway or Error Prone to prevent null in your code in general, or you can add checks to your records:
- Prusti: Static Analyzer for Rust
-
Why is `suspend` a language keyword, but @Composable and @Serializable are annotations
I am all in favour to more third side libraries adding functionalities, like Lombok, Manifold and error prone. As well as smaller projects like this shameless plug and what appears in this list
-
Picnic loves Error Prone: producing high-quality and consistent Java code
If only Google didn't suck when it came to Java9+ support... https://github.com/google/error-prone/issues/2649
-
What does the future hold for Project Amber?
I haven't used it. I use Google's ErrorProne + Lombok to prevent NPEs in java.
-
Plans for Compile-time Null Pointer Safety?
Take a look at NullAway, a plugin for Error Prone.
-
What I miss in Java, the perspective of a Kotlin developer
For some of this stuff, there are compiler extensions that allow extra type checking to be added e.g. Google Error-Prone: https://github.com/google/error-prone with stuff like: https://errorprone.info/bugpattern/ReturnMissingNullable.
Doesn't help you with third party libraries, but across an org applying that rule (and others!) typically ensures some consistency.
-
A guide on how to improve your coding skills with static code analysis.
How to build a static analysis plugin. Google has a framework for Java with a good tutorial.
- Error Prone 2.11.0 Released. Requires JDK11+
What are some alternatives?
PipelinR - PipelinR is a lightweight command processing pipeline ❍ ⇢ ❍ ⇢ ❍ for your Java awesome app.
Spotbugs - SpotBugs is FindBugs' successor. A tool for static analysis to look for bugs in Java code.
SonarQube - Continuous Inspection
PMD - An extensible multilanguage static code analyzer.
Checkstyle - Checkstyle is a development tool to help programmers write Java code that adheres to a coding standard. By default it supports the Google Java Style Guide and Sun Code Conventions, but is highly configurable. It can be invoked with an ANT task and a command line program.
FindBugs - The new home of the FindBugs project
infer - A static analyzer for Java, C, C++, and Objective-C
Lombok - Very spicy additions to the Java programming language.
NullAway - A tool to help eliminate NullPointerExceptions (NPEs) in your Java code with low build-time overhead
SonarJava - :coffee: SonarSource Static Analyzer for Java Code Quality and Security
Spoon - Spoon is a metaprogramming library to analyze and transform Java source code. :spoon: is made with :heart:, :beers: and :sparkles:. It parses source files to build a well-designed AST with powerful analysis and transformation API.
jQAssistant - Your Software. Your Structures. Your Rules.