Commit Graph

229 Commits

Author SHA1 Message Date
KtorZ 616dec8f03
Fix formatter getting rid of curly braces around multi-line constants. 2024-09-08 16:23:41 +02:00
KtorZ 0c0369ad61
Fix needed parentheses under trace-if-false disappearing when formatting. 2024-09-08 16:21:45 +02:00
KtorZ b6d99142f9
Fix formatting of multi-line alternative patterns. 2024-09-08 13:11:53 +02:00
KtorZ b7ea6ea391
Fix list-pattern formatting 2024-09-07 14:50:47 +02:00
KtorZ 19e30b10f9
Fix #1013 2024-09-06 12:28:12 +02:00
Matthias Benkort 1f692bc93e
Update CHANGELOG.md 2024-09-03 23:30:18 +02:00
KtorZ f60df16bc2
Preserve type-aliases during blueprint generation. 2024-09-03 16:39:50 +02:00
KtorZ 5414fd8f04
Fill-in CHANGELOG for zero-arg / super-const. 2024-08-30 18:41:06 +02:00
KtorZ 70e760cbaa
Fill-in CHANGELOG regarding last expect and tests now accepting Void. 2024-08-23 16:04:40 +02:00
KtorZ d1ee90a3a0
Update CHANGELOG.md 2024-08-23 10:41:20 +02:00
KtorZ 39c1b5a68a
Merge branch 'generated-docs-improvements' 2024-08-22 16:41:54 +02:00
Matthias Benkort 2bb2f11090
Update CHANGELOG.md 2024-08-14 10:03:42 +02:00
KtorZ 9d8fdf787c
Improve formatter on long-lines, in particular bin-ops. 2024-08-06 19:25:35 +02:00
KtorZ e3b1cf1093
Rework CHANGELOG to reflect reality.
We never released 1.0.30, so it's a bit misleading to have an entry for it in the CHANGELOG. So I merged its content with the ongoing release which is likely to be 1.1.0
2024-08-06 10:50:15 +02:00
KtorZ a07f8cbc58
Fill-in CHANGELOG. 2024-08-04 14:48:03 +02:00
KtorZ f14dfdf8e1
Allow pattern-matching on bytearrays
- Doesn't allow pattern-matching on G1/G2 elements and strings,
    because the use cases for those is unclear and it adds complexity to
    the feature.

  - We still _parse_ patterns on G1/G2 elements and strings, but emit an
    error in those cases.

  - The syntax is the same as for bytearray literals (i.e. supports hex,
    utf-8 strings or plain arrays of bytes).
2024-08-03 13:51:36 +02:00
KtorZ ea032c90f2
Add missing CHANGELOG entries. 2024-08-02 12:08:25 +02:00
KtorZ bf5a406ffb Remove clause guards.
Closes #886.
2024-08-02 00:16:27 -04:00
KtorZ b28d4a6e9f
Add input reference to ReferenceInputNotFound error.
Fixes #974.
2024-08-01 15:29:39 +02:00
KtorZ 91aa435f37
Fix 'multiline' truncating last character of each line.
Fixes #987.
2024-08-01 15:20:43 +02:00
KtorZ 327449e320
Update CHANGELOG, bump date, document latest fixes & optimizations 2024-07-25 09:54:03 +02:00
KtorZ 987a5fa779
Set a date for v1.0.30-alpha release. 2024-07-24 09:39:48 +02:00
rvcas 06ac851458
chore: update changelog 2024-07-23 11:20:42 -04:00
KtorZ 89890f3b4b
Fill-in CHANGELOG 2024-07-19 12:44:12 +02:00
KtorZ 976262c2e6
Allow discard in expect.
Fixes #967.
2024-07-17 18:11:09 +02:00
KtorZ 858dfccc82
Authorize complete patterns as function args.
This is mainly a syntactic trick/sugar, but it's been pretty annoying
  to me for a while that we can't simply pattern-match/destructure
  single-variant constructors directly from the args list. A classic
  example is when writing property tests:

  ```ak
  test foo(params via both(bytearray(), int())) {
    let (bytes, ix) = params
    ...
  }
  ```

  Now can be replaced simply with:

  ```
  test foo((bytes, ix) via both(bytearray(), int())) {
    ...
  }
  ```

  If feels natural, especially coming from the JavaScript, Haskell or
  Rust worlds and is mostly convenient. Behind the scene, the compiler
  does nothing more than re-writing the AST as the first form, with
  pre-generated arg names. Then, we fully rely on the existing
  type-checking capabilities and thus, works in a seamless way as if we
  were just pattern matching inline.
2024-06-07 15:42:25 +02:00
KtorZ 257bd23019
update changelog 2024-06-06 11:21:17 +02:00
KtorZ 87f4ed359b
Update changelog: set a release date. 2024-06-06 11:19:33 +02:00
KtorZ d7ec2131ef
Automatically merge import lines from same module.
I slightly altered the way we parse import definitions to ensure we
  merge imports from the same modules (that aren't aliased) together.

  This prevents an annoying warning with duplicated import lines and
  makes it just more convenient overall.

  As a trade-off, we can no longer interleave import definitions with
  other definitions. This should be a minor setback only since the
  formatter was already ensuring that all import definitions would be
  grouped at the top.

  ---

  Note that, I originally attempted to implement this in the formatter
  instead of the parser. As it felt more appropriate there. However, the
  formatter operates on (unmutable) borrowed definitions, which makes it
  annoyingly hard to perform any AST manipulations. The `Document`
  returns by the format carries a lifetime that prevents the creation of
  intermediate local values.

  So instead, slightly tweaking the parser felt like the right thing to
  do.
2024-06-04 10:48:42 +02:00
KtorZ 2070576e46
New LSP quickfix for 'use let' warning. 2024-05-30 19:30:41 +02:00
KtorZ 649e5163fc
Fix parsing of single hex-digits. 2024-05-30 17:19:48 +02:00
KtorZ 5694d9f9cb
Introduce 'fail once' and alter behavior of 'fail' keyword for properties. 2024-05-30 17:18:50 +02:00
rvcas 2605dc6aa4
chore: update changelog 2024-05-23 16:44:50 -04:00
rvcas 3f46559dbe
chore: update changelog 2024-05-23 16:21:16 -04:00
microproofs 2c8abe4a69 update changelog 2024-05-23 16:15:30 -04:00
KtorZ c48f15a957
revert #903 'feat: Emit keyword'
While we agree on the idea of having some ways of emitting events, the
  design hasn't been completely fleshed out and it is unclear whether
  events should have a well-defined format independent of the framework
  / compiler and what this format should be.

  So we need more time discussing and agreeing about what use case we
  are actually trying to solve with that.

  Irrespective of that, some cleanup was also needed on the UPLC side
  anyway since the PR introduced a lot of needless duplications.
2024-05-23 17:22:12 +02:00
KtorZ 5ce30b2632
Rename AList -> Pairs due to popular demand. 2024-05-23 16:45:40 +02:00
KtorZ 1ed4fa1c69
Show warning when ignoring modules + restyle warnings slightly
Fixes #916.
2024-05-14 13:27:19 +02:00
KtorZ 81219cfbdd
Check for data-type serialisability after generic instantiation
Fixes #939.
2024-05-14 10:58:58 +02:00
KtorZ 8c67be55ce
Fixes #921: top-level Miller-loop needs not to be serialisable
This is a bit tricky, but in a similar way where we allow functions to
  be returned by functions, this must also work for MillerLoopResult.
2024-05-10 13:52:23 +02:00
microproofs 30436a8a9c update changelog 2024-05-06 15:17:01 -04:00
KtorZ 925a11be69
Check for args length when comparing types. Duh!
Fixes #917.
2024-05-01 10:48:15 +02:00
rvcas 4f99c81dee
chore: update changelog 2024-04-12 21:43:28 -04:00
rvcas 23713ce6fa
chore: update changelog 2024-04-09 11:48:32 -04:00
rvcas fdbe811bf1
chore: update changelog 2024-04-02 19:49:30 -04:00
rvcas 0ba6d23efa
chore: update changelog 2024-04-02 17:56:53 -04:00
rvcas 98bd61a0cd
chore: update changelog 2024-03-29 11:38:22 -04:00
rvcas 54a89d3e69
chore: update changelog 2024-03-25 22:05:25 -04:00
KtorZ eee1d1bf1e
Fix release date for v1.0.25-alpha. 2024-03-22 16:07:29 +01:00
KtorZ 96387e3437
Fixes #767
Co-authored-by: @rvcas <x@rvcas.dev>
2024-03-22 16:05:32 +01:00