Skip to content

Commit 6836d01

Browse files
2 parents 2b05bf3 + 08badfd commit 6836d01

File tree

229 files changed

+3673
-3788
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

229 files changed

+3673
-3788
lines changed

.git-blame-ignore-revs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
012a81397062e33d44d9dbc5974c44483ca4763b

.github/workflows/maven.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ name: Java CI with Maven
1010

1111
on:
1212
push:
13-
branches: [ "master" ]
13+
branches: [ "main" ]
1414
pull_request:
15-
branches: [ "master" ]
15+
branches: [ "main" ]
16+
1617

17-
1818

1919
jobs:
2020
build:

.pre-commit-config.yaml

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,15 @@
1+
# See https://pre-commit.com for more information
2+
# See https://pre-commit.com/hooks.html for more hooks
13
repos:
2-
- repo: https://github.com/ejba/pre-commit-maven
3-
rev: v0.3.3
4-
hooks:
5-
- id: maven
6-
args: [clean compile]
4+
- repo: https://github.com/pre-commit/pre-commit-hooks
5+
rev: v5.0.0
6+
hooks:
7+
- id: trailing-whitespace
8+
- id: end-of-file-fixer
9+
- id: check-yaml
10+
- id: check-added-large-files
11+
- repo: https://github.com/macisamuele/language-formatters-pre-commit-hooks
12+
rev: v2.14.0
13+
hooks:
14+
- id: pretty-format-java
15+
args: [--palantir, --autofix]

.vscode/settings.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
22
"java.configuration.updateBuildConfiguration": "automatic"
3-
}
3+
}

README.md

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -2,65 +2,65 @@
22

33
![LiquidJava Banner](docs/design/figs/banner.gif)
44

5+
## Welcome to LiquidJava
56

6-
### Welcome to LiquidJava!
7-
8-
LiquidJava is an additional typechecker for Java that supports liquid types and typestate.
7+
LiquidJava is an additional type checker for Java that based on liquid types and typestates.
98

109
Simple example:
1110

12-
1311
```java
1412
@Refinement("a > 0")
1513
int a = 3; // okay
1614
a = -8; // type error!
1715
```
1816

19-
This project has the LiquidJava verifier, the api and some examples for testing.
17+
This project has the LiquidJava verifier, the API and some examples for testing.
2018
You can find out more about LiquidJava in the following resources:
2119

2220
* [Website](https://catarinagamboa.github.io/liquidjava.html)
2321
* [Examples of LiquidJava](https://github.com/CatarinaGamboa/liquidjava-examples)
24-
* [LiquidJava Specification of Java StdLib](https://github.com/CatarinaGamboa/liquid-java-external-libs)
22+
* [LiquidJava Specification of the Java Standard Library](https://github.com/CatarinaGamboa/liquid-java-external-libs)
2523
* [VSCode plugin for LiquidJava](https://github.com/CatarinaGamboa/vscode-liquidjava)
2624
<!-- * [Formalization of LiquidJava](https://github.com/CatarinaGamboa/liquidjava-formalization) - not opensource yet -->
2725

28-
2926
## Setup the project
27+
3028
1. Clone the repository;
3129
2. Run `setup.sh`, some dependencies include using `Java 20` or newer and using `Maven`.
3230
3. Open the project in your favorite IDE (we have used Eclipse and VSCode)
33-
4. Use the `.pom` in `liquidjava-umbrella` to `compile` and run the `tests`
31+
4. Use the `pom.xml` in the root directory (which your IDE may have renamed to`liquidjava-umbrella`) to compile and run the tests.
3432

3533
## Run verification
36-
#### In a specific project
34+
35+
### In a specific project
36+
3737
Run the file `liquidjava-verifier\api\CommandLineLaucher` with the path to the target project for verification.
3838
If there are no arguments given, the application verifies the project on the path `liquidjava-example\src\main\java`.
3939

40-
4140
## Testing
42-
Run `mvn test` to run all the tests in liquidjava.
4341

44-
The starter test file is `TestExamples.java` which uses the test suite under the `liquidjava-examples/testSuite`.
42+
Run `mvn test` to run all the tests in LiquidJava.
43+
44+
The starter test file is `TestExamples.java` which uses the test suite under the `liquidjava-examples/testSuite`.
45+
46+
Paths in the test suite are considered test cases if:
4547

46-
Paths in the testSuite are considered test cases if:
4748
1. File that start with `Correct` or `Error` (e.g, "CorrectRecursion.java")
4849
2. Package/Folder that contains the word `correct` or `error`.
4950

5051
Therefore, files/folders that do not pass this description are not verified.
5152

5253
## Project structure
53-
- **docs**: documents used for the design of the language. The folder includes a readme to a full artifact used in the design process, here are some initial documents used to prepare the design of the refinements language at its evaluation
54-
- **liquidjava-api**: inlcudes the annotations that can be introduced in the Java programs to add the refinements
55-
- **liquidjava-examples**: includes a main folder with the current example that the verifier is testing; the test suite that is used in maven test is under the `testSuite` folder
56-
- **liquidjava-verifier**: has the project for verification of the classes
57-
- *api*: classes that test the verifier. Includes the `CommandLineLauncher` that runs the verification on a given class or on the main folder of `liquidjava-examples` if no argument is given. This package includes the JUnit tests to verify if the examples in `liquidjava-example/tests` are correctly verified.
58-
- *ast*: represents the abstract syntax tree of the refinement's language.
59-
- *errors*: package for reporting the errors.
60-
- *processor*: package that handles the type checking.
61-
- *rj_language*: handles the processing of the strings with refinements.
62-
- *smt*: package that handles the translation to the smt solver and the processing of the results the smt solver produces.
63-
- *utils*: includes useful methods for all the previous packages.
64-
- *test/java/liquidjava/api/tests* contains the `TestExamples` class used for running the testSuite
65-
6654

55+
* **docs**: documents used for the design of the language. The folder includes a readme to a full artifact used in the design process, here are some initial documents used to prepare the design of the refinements language at its evaluation
56+
* **liquidjava-api**: inlcudes the annotations that can be introduced in the Java programs to add the refinements
57+
* **liquidjava-examples**: includes a main folder with the current example that the verifier is testing; the test suite that is used in maven test is under the `testSuite` folder
58+
* **liquidjava-verifier**: has the project for verification of the classes
59+
* *api*: classes that test the verifier. Includes the `CommandLineLauncher` that runs the verification on a given class or on the main folder of `liquidjava-examples` if no argument is given. This package includes the JUnit tests to verify if the examples in `liquidjava-example/tests` are correctly verified.
60+
* *ast*: represents the abstract syntax tree of the refinement's language.
61+
* *errors*: package for reporting the errors.
62+
* *processor*: package that handles the type checking.
63+
* *rj_language*: handles the processing of the strings with refinements.
64+
* *smt*: package that handles the translation to the SMT solver and the processing of the results the SMT solver produces.
65+
* *utils*: includes useful methods for all the previous packages.
66+
* *test/java/liquidjava/api/tests* contains the `TestExamples` class used for running the test suite.

0 commit comments

Comments
 (0)