Skip to content

Releases: noir-lang/noir

nightly-2024-10-13: chore: regression test for #5462 (#6286)

13 Oct 02:30
ae87d28
Compare
Choose a tag to compare
# Description

## Problem\*

Regression test for github.com/noir-lang/noir/issues/5462

## Summary\*

- Added the test from [5462](github.com/noir-lang/noir/issues/5462)
- Updated the issue needed to re-enable the `array_regex` execution test

## Additional Context



## Documentation\*

Check one:
- [x] No documentation needed.
- [ ] Documentation included in this PR.
- [ ] **[For Experimental Features]** Documentation to be submitted in a
separate PR.

# PR Checklist\*

- [x] I have tested the changes locally.
- [x] I have formatted the changes with [Prettier](https://prettier.io/)
and/or `cargo fmt` on default settings.

nightly-2024-10-12: chore: regression test for #5462 (#6286)

12 Oct 02:25
ae87d28
Compare
Choose a tag to compare
# Description

## Problem\*

Regression test for github.com/noir-lang/noir/issues/5462

## Summary\*

- Added the test from [5462](github.com/noir-lang/noir/issues/5462)
- Updated the issue needed to re-enable the `array_regex` execution test

## Additional Context



## Documentation\*

Check one:
- [x] No documentation needed.
- [ ] Documentation included in this PR.
- [ ] **[For Experimental Features]** Documentation to be submitted in a
separate PR.

# PR Checklist\*

- [x] I have tested the changes locally.
- [x] I have formatted the changes with [Prettier](https://prettier.io/)
and/or `cargo fmt` on default settings.

nightly-2024-10-11: feat: slightly improve "unexpected token" error message (#6279)

11 Oct 02:28
8232bfa
Compare
Choose a tag to compare
# Description

## Problem

Tokens appear like `]` or `)` in error messages where showing them as
`']'` or `')'` might be clearer.

## Summary



## Additional Context



## Documentation

Check one:
- [x] No documentation needed.
- [ ] Documentation included in this PR.
- [ ] **[For Experimental Features]** Documentation to be submitted in a
separate PR.

# PR Checklist

- [x] I have tested the changes locally.
- [x] I have formatted the changes with [Prettier](https://prettier.io/)
and/or `cargo fmt` on default settings.

nightly-2024-10-10: fix: visibility for impl methods (#6261)

10 Oct 02:28
70cbeb4
Compare
Choose a tag to compare
# Description

## Problem

Part of #4515

Apparently in #6179 I only made it work for calls like `foo::Bar::baz()`
but no checks were done for method calls (where `self` is involved).

## Summary

This PR now warns when calling private or `pub(crate)` methods, either
on structs or primitive types, when they are not accessible from the
current module.

We also now don't suggest non-accessible methods from LSP.

## Additional Context


I also removed an unused global that was introduced some time ago.

## Documentation

Check one:
- [x] No documentation needed.
- [ ] Documentation included in this PR.
- [ ] **[For Experimental Features]** Documentation to be submitted in a
separate PR.

# PR Checklist

- [x] I have tested the changes locally.
- [x] I have formatted the changes with [Prettier](https://prettier.io/)
and/or `cargo fmt` on default settings.

nightly-2024-10-09: fix: homogeneous input points for EC ADD (#6241)

09 Oct 02:27
f6a7306
Compare
Choose a tag to compare
# Description

## Problem\*

Resolves https://github.com/AztecProtocol/barretenberg/issues/1108

## Summary\*
Barretenberg does not support points that are not all constant or all
witness in EC ADD opcode.


## Additional Context



## Documentation\*

Check one:
- [X] No documentation needed.
- [ ] Documentation included in this PR.
- [ ] **[For Experimental Features]** Documentation to be submitted in a
separate PR.

# PR Checklist\*

- [X] I have tested the changes locally.
- [ ] I have formatted the changes with [Prettier](https://prettier.io/)
and/or `cargo fmt` on default settings.

nightly-2024-10-08: feat: handwritten parser (#6180)

08 Oct 02:29
c4273a0
Compare
Choose a tag to compare
# Description

Resolves https://github.com/noir-lang/noir/issues/853

## Problem

There are some issues with the current parser:
- it leads to "stack overflow" with small programs that should probably
compile (like a program with a chanin of 17 `if-else-if`)
- it leads to some of us not being able to run the noric_frontend tests
because of linker errors, and sometimes making changes to the parser
will lead to linker errors that we have to workaround
- it's (very) slow

## Summary

This PR implements a hand-written parser. It parses any program with
just one look-ahead token. It has very good error-recovery.

I tested the parser's performance by copying the contents of
`noir-contracts/contracts/avm_test_contract/src/main.nr` in
Aztec-Packages 100 times to a single file. That ends up with a file of
about 57K lines. The times:
- chumsky parser: 1.52 **seconds**
- handwritten parser: 52.97 **milliseconds**

Some other benefits:
- The linker errors are gone!
- Compiling noirc_frontend is slightly faster
- Macro code also becomes faster (`quote { ... }.as_expr()`, etc, invoke
the parser). For example
`test_programs/noir_test_success/comptime_expr/src/main.nr` takes around
one second with chumsky and 140ms with the handwritten parser (to do
`nargo compile`)
- Even though the parser is handwritten, I think the parsing code is
relatively simple. It's just "check if we get this token, then do this"
or sometimes "check if we get this token followed by this one (or not
followed by this one). Also also the `impl`s and `traits` that we needed
for chumsky (and the lifetimes, and passing parsers around, and cloning
them, and calling `boxed()`, etc.) are gone, which I believe make the
code much simpler. That said, chumsky has great helpers to be able to
parse things separated by, say, a comma, and this PR at least has that
too (`parse_many`).
- Compiling an empty program is faster (goes from 650ms to 140ms)
- Compiing any program is much faster
- Tests run faster (it would become feasible to run tests locally before
pushing to CI to avoid CI cycles):
  - Running noirc_frontend tests:
    - before: 1:03 minute
    - after: 6 seconds
  - Running lsp tests: 
    - before: 55 seconds
    - after: 6 seconds
  - Running nargo_cli tests:
    - before: 2:47 minutes
    - after: 38 seconds
- CI runs faster (for example each of the four partitions take 1 minute
instead of 4 minutes
- Building the compiler is faster:
  - before: 1:29 minutes
- after: 1:19 minutes (so building noirc_frontend is 10 seconds faster
because that's the only thing changed in this PR)
- Better parsing recovery and more fine-grained control over the errors
we report

I tested this parser by running `./boostrap.sh` on the Aztec-Packages
contracts and they compile file (of course they didn't compile right
away, I had to fix some bugs to get there).

## Additional Context

## Documentation

Check one:
- [x] No documentation needed.
- [ ] Documentation included in this PR.
- [ ] **[For Experimental Features]** Documentation to be submitted in a
separate PR.

# PR Checklist

- [x] I have tested the changes locally.
- [x] I have formatted the changes with [Prettier](https://prettier.io/)
and/or `cargo fmt` on default settings.

---------

Co-authored-by: Tom French <[email protected]>
Co-authored-by: jfecher <[email protected]>

nightly-2024-10-07

07 Oct 02:30
999071b
Compare
Choose a tag to compare
nightly-2024-10-07 Pre-release
Pre-release
feat(perf): Follow array sets backwards in array set from get optimiz…

nightly-2024-10-06

06 Oct 02:30
999071b
Compare
Choose a tag to compare
nightly-2024-10-06 Pre-release
Pre-release
feat(perf): Follow array sets backwards in array set from get optimiz…

nightly-2024-10-05

05 Oct 02:27
999071b
Compare
Choose a tag to compare
nightly-2024-10-05 Pre-release
Pre-release
feat(perf): Follow array sets backwards in array set from get optimiz…

v0.35.0

03 Oct 00:41
2a0d211
Compare
Choose a tag to compare

0.35.0 (2024-10-03)

⚠ BREAKING CHANGES

Features

Read more