Skip to content

Commit 4ced551

Browse files
committed
Revert "Multiple rhs (#23)"
This reverts commit d1ac9d4.
1 parent f0f4173 commit 4ced551

26 files changed

+2419
-1553
lines changed

TODO

Lines changed: 22 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,35 @@
44

55
things like max heap size should be settable ... maybe pres are useful?
66

7-
- lcomps leave stray unreffed symbols in "list unresolved"
7+
- add multiple definitions, finish function argument destructuring
88

9-
Image_transform_item.Resize_item.Size_within_item.action.within ($SAVEDIR/start/Image.def:509) refers to undefined symbol h
10-
Image_transform_item.Resize_item.Size_within_item.action.within ($SAVEDIR/start/Image.def:509) refers to undefined symbol w
9+
sym has a field for "next definition", initially NULL
1110

12-
- rework pattern matching in lcomps
11+
` add_defining looks for an existing sym with this name, if it finds
12+
one, add a new sym called "{name}-$$4" or whatever
1313

14-
- what does the programming window do for multiple defs?
14+
chase to the end of "next definition" on the existing sym, append our
15+
new sym
1516

16-
probably need to follow next_def and concatenate them all
17+
during compile, generate code like
1718

18-
- dir should hide $$vars
19+
fred a b c
20+
= destructured_fred, args_match
21+
= fred-$$1 a b c
22+
{
23+
destructured_fred = rhs of fred
24+
args_match = a_matches && b_matches && c_matches
25+
}
26+
27+
if a func has many RHS and the last RHS uses destrucuring, generate a
28+
final def with
1929

20-
- programming window is showing generated syms, like $$pattern_lhs0?
30+
fred a b c
31+
= error "no def of fred matches args a b c";
2132

22-
- ban patterns in class parameters
33+
- error if more than one def of fred has no destructuring
34+
- error if defs don't all have the same number of args
35+
- error if a def with no destructuring isn't the last def
2336

2437
- try < > in the image titlebar
2538

meson.build

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
project('nip4', 'c',
22
# ie. a major after nip2 8.9 for workspace save file versioning
3-
version: '9.0.15',
3+
version: '9.0.14',
44
license: 'GPL',
55
meson_version: '>=0.64',
66
default_options: [

0 commit comments

Comments
 (0)