This adds power assertions to Pkl!
This implements the SPICE described in
https://github.com/apple/pkl-evolution/pull/29
This follows the power assertions style of reporting also found in
Groovy, Kotlin, and others.
* Literal values are not emitted in the diagram
* Stdlib constructors of literals like `List(1, 2)` are also considered
literals
Power assertions are added to:
* Failing type constraints
* Failing test facts
Power assertions are implemented as a truffle instrument to observe
execution.
When an assertion fails, the instrument is created and the assertion is
run again to observe facts.
This incurs runtime overhead to collect facts, but has no impact on code
in the non-error case.
---------
Co-authored-by: Islon Scherer <islonscherer@gmail.com>
Adds convenience methods `isNotEmpty` and `isNotBlank`. This borrows the
same methods from Kotlin.
This helps users write more fluent constraints, for example,
`foo.isNotEmpty.implies(bar)`.
Adds:
* List#isNotEmpty
* Map#isNotEmpty
* Set#isNotEmpty
* Mapping#isNotEmpty
* Listing#isNotEmpty
* String#isNotEmpty
* String#isNotBlank
If an operator chain or method call is multiline, keep those newlines
in the formatted output.
Help preserve code like:
```
foo
|> (it) -> it + 2
|> (it) -> it / 2
```
Also, fixes an issue where forced single-line formatting would break for if/else
and let expressions
---------
Co-authored-by: Islon Scherer <islonscherer@gmail.com>
The current version of the kotlin-gradle plugin is not compatible with
Gradle 9.1, causing error `java.lang.NoSuchMethodError:
'org.gradle.api.Project org.gradle.api.artifacts.ProjectDependency.getDependencyProject()'`
Also, the Kotlin 2.0 language target is deprecated as of Kotlin 2.2.
This adds release notes for 0.26.
Also:
* Adjust IJ settings to ignore certain http: strings
* Add note about http introduced in 0.26 in message passing api
Co-authored-by: Philip K.F. Hölzenspies <holzensp@gmail.com>