chriseth
161f4d8181
Parse turbofish ( #1219 )
2024-04-04 16:31:11 +00:00
chriseth
3960f8c6e5
Make degree optional for namespace. ( #1235 )
2024-04-04 12:33:23 +00:00
chriseth
6096afb218
Patterns in let statements and function parameters ( #1214 )
...
Co-authored-by: Leo <leo@powdrlabs.com >
2024-04-03 18:39:19 +00:00
chriseth
4e5c464df4
Flexible array pattern ( #1208 )
...
Depends on #1205
Will document in https://github.com/powdr-labs/powdr/pull/1214
2024-04-03 11:48:07 +00:00
chriseth
f46d59dfe1
Basic version of patterns. ( #1205 )
...
Depends on #1187
Implements part of https://github.com/powdr-labs/powdr/issues/982
Will document in https://github.com/powdr-labs/powdr/pull/1214
2024-04-03 09:30:42 +00:00
chriseth
28f0bb9c1d
Statements in blocks and function annotations ( #1187 )
...
Adds statements at block level and introduces function kinds to be
either pure, constr or query.
closes https://github.com/powdr-labs/powdr/issues/960
---------
Co-authored-by: Leo <leo@powdrlabs.com >
2024-04-02 08:23:39 +00:00
chriseth
f91350e9da
Support the empty tuple. ( #1213 )
2024-04-01 17:22:23 +00:00
chriseth
989087634c
Some dependency cleanup. ( #1209 )
2024-03-28 12:23:35 +00:00
chriseth
f42ca35f83
Let statements in expressions. ( #1138 )
...
Allows braced blocks everywhere where expressions are expected.
The statements in those blocks can be `let x` or `let x = ...`.
The former declares a new witness column, the latter just binds a local
variable.
fixes #959
2024-03-25 21:08:45 +00:00
schaeff
8065794633
allow expression in degree statement
2024-03-22 19:20:29 +01:00
chriseth
3bc1ec0f90
Wrap match.
2024-03-21 16:27:13 +01:00
Georg Wiese
80fafbe19c
Spell-check
2024-03-20 16:12:55 +01:00
chriseth
ae8f8654b1
Merge pull request #1118 from powdr-labs/challenges
...
Challenges
2024-03-20 12:07:06 +00:00
chriseth
e1753fd88e
Challenges and stages.
2024-03-20 12:40:51 +01:00
Leandro Pacheco
edaf536500
Allow machines to be linked via permutation
...
by instructions and links using `~` instead of `=`.
Block machines must declare `call_selectors`.
2024-03-20 08:17:21 -03:00
Leo Alt
efe11f40fc
enum declarations
2024-03-18 22:09:44 +01:00
Leandro Pacheco
ff8fda1563
Expressions in instr/link params
...
allow for `link` and RHS of `instr` params to use full on expressions
2024-03-18 14:04:08 -03:00
chriseth
9366badcac
Rename format type name and remove Custom.
2024-03-12 11:16:02 +01:00
Leo
2db12b2374
Merge pull request #1149 from powdr-labs/parse_semicolons_as_part_of_statements
...
Parse semicolons as part of statements.
2024-03-11 17:29:34 +00:00
chriseth
dc05b9c56e
Use only one type type.
2024-03-11 18:01:40 +01:00
chriseth
ab7e4e9a3b
Parse semicolons as part of statements.
2024-03-11 17:49:15 +01:00
chriseth
349f9aa461
Parse numbers as integers.
2024-03-08 15:48:49 +01:00
chriseth
4024698b2a
Use ibig crate.
2024-03-08 07:31:27 +01:00
Lucas Clemente Vella
08ace88416
Nightly fix: ignoring env_logger on cargo udeps.
...
cargo udeps doesn't undertand why env_logger is needed on development
dependencies
2024-03-05 18:54:10 +00:00
chriseth
9f4f4776e8
Use powder_number::BigInt / BigUint everywhere instead of num_bigint.
2024-03-05 15:32:39 +01:00
chriseth
ba64512321
Rename AbstractNumberType to BigUint.
2024-03-05 15:24:21 +01:00
Leo
88c9d735b7
Merge pull request #1070 from powdr-labs/link_params
...
Move `link` params to RHS
2024-03-04 13:40:25 +00:00
Leandro Pacheco
f3e1802787
move link params to RHS and simplify the code
...
- added more checks for pc machines / constrained machines
- improve example and docs
2024-03-04 09:55:37 -03:00
chriseth
97ed14c48b
Type checking.
2024-03-01 17:36:54 +01:00
chriseth
daffb65c0c
Add type schemes.
2024-02-22 13:39:39 +01:00
Leandro Pacheco
2e1a8571a7
instr param mapping
...
allow RHS of `instr` declarations to control the usage of write and assignment
registers.
2024-02-14 13:31:19 -03:00
chriseth
8f6cd49969
Introduce identity operator.
2024-02-07 16:04:55 +01:00
chriseth
97007261d0
Clippy fixes.
2024-02-07 08:25:28 +01:00
Leandro Pacheco
36c3a78fe7
move LinkDeclaration SourceRef to enum (like other variants)
2024-02-06 10:13:11 -03:00
Lucas Clemente Vella
df14ab8be0
Merge pull request #1015 from powdr-labs/lazy_parsers
...
Lazy parsers
2024-02-06 12:03:21 +00:00
chriseth
2765e59a9f
Add types.
2024-02-06 10:25:04 +01:00
Leandro Pacheco
cbec66e130
fix impl Display for ASMProgram
...
- have `FieldElement` printed as non-negative
- print constrained machine arguments
- fix related tests
2024-02-05 18:40:00 -03:00
Leandro Pacheco
39c5c62028
AST parsing and impl Display fixes
...
- `instr x = y` statements must end with semicolon
- fixed Display implementation for AST objects such that
source->AST->source->AST works properly
- tests for the above
2024-02-05 18:40:00 -03:00
chriseth
ec75819cc0
Re-use parsers.
2024-02-05 17:16:45 +01:00
Leo Alt
3daf9d90be
add package info
2024-01-29 18:35:32 +01:00
chriseth
fda565e703
Make conversions safer.
2024-01-25 16:12:55 +01:00
chriseth
73ecd745d1
Print builtin
2024-01-24 12:59:20 +01:00
chriseth
f2ddf7f64d
Introduce special identifiers.
2024-01-24 12:54:55 +01:00
chriseth
ef8c9140e3
Require dot in front of debug.
2024-01-24 09:31:11 +01:00
Leo Alt
607c0043d7
add powdr- prefix to all crates
2024-01-23 18:51:29 +01:00
Leo
2055ac51a8
Merge pull request #930 from powdr-labs/unary_plus
...
Remove unary plus.
2024-01-23 13:20:06 +00:00
Leandro Pacheco
c4b4f35771
make parser generate SourceRefs
...
also added a way for analyzing PILFile's directly without having to re-parse
from a string
2024-01-23 08:45:47 -03:00
chriseth
a288549b4b
Remove unary plus.
2024-01-23 08:59:55 +01:00
chriseth
252eaa070c
Support pil at module level.
2024-01-15 10:03:38 +01:00
chriseth
3a292ae1fd
Indent parsed pil.
2024-01-12 16:08:35 +01:00