about summary refs log tree commit diff stats
path: root/011load.cc
Commit message (Collapse)AuthorAgeFilesLines
* 2712Kartik K. Agaram2016-02-261-9/+9
|
* 2709Kartik K. Agaram2016-02-251-1/+0
| | | | | Only Hide_errors when strictly necessary. In other places let test failures directly show the unexpected error.
* 2704 - eradicate all mention of warnings from coreKartik K. Agaram2016-02-251-9/+9
|
* 2702Kartik K. Agaram2016-02-251-12/+12
|
* 2681 - drop reagent types from reagent propertiesKartik K. Agaram2016-02-211-42/+35
| | | | | | | | | | | | | | | | | All my attempts at staging this change failed with this humongous commit that took all day and involved debugging three monstrous bugs. Two of the bugs had to do with forgetting to check the type name in the implementation of shape-shifting recipes. Bug #2 in particular would cause core tests in layer 59 to fail -- only when I loaded up edit/! It got me to just hack directly on mu.cc until I figured out the cause (snapshot saved in mu.cc.modified). The problem turned out to be that I accidentally saved a type ingredient in the Type table during specialization. Now I know that that can be very bad. I've checked the traces for any stray type numbers (rather than names). I also found what might be a bug from last November (labeled TODO), but we'll verify after this commit.
* 2689 - consistently use s-exp syntax in tracesKartik K. Agaram2016-02-191-4/+4
|
* 2686Kartik K. Agaram2016-02-191-1/+1
|
* 2685Kartik K. Agaram2016-02-191-4/+4
| | | | | | | | | | | | | | | | Stack of plans for cleaning up replace_type_ingredients() and a couple of other things, from main problem to subproblems: include type names in the type_tree rather than in the separate properties vector make type_tree and string_tree real cons cells, with separate leaf nodes redo the vocabulary for dumping various objects: do we really need to_string and debug_string? can we have a version with *all* information? can we have to_string not call debug_string? This commit nibbles at the edges of the final task, switching from member method syntax to global function like almost everything else. I'm mostly using methods just for STL in this project.
* 2648Kartik K. Agaram2016-02-111-0/+1
|
* 2643Kartik K. Agaram2016-02-101-2/+2
|
* 2617 - better error messagesKartik K. Agaram2016-01-301-1/+3
| | | | | | | | | | | | | | | | | | When we stash a value, mu does several levels of work for us: a) First it inserts instructions above the stash to convert the value to text using to-text-line. b) to-text-line calls to-text. Both are shape-shifting, so multiple levels of specialization happen. To give a good error message, we track the 'stack' of current specializations at the time of the error, and also check if the offending instruction at the top-most level looks like it was inserted while rewriting stash instructions. Manual example (since booleans can't be stashed at the moment): x:boolean <- copy 1/true stash x
* 2603 - bugfix: defining main with commandline argsKartik K. Agaram2016-01-251-1/+1
| | | | Pretty hacky fix: we simply suppress static dispatch for main.
* 2553 - keep failed specializations from generating spurious errorsKartik K. Agaram2015-12-281-2/+0
| | | | Thanks Caleb Couch.
* three bugs fixedKartik K. Agaram2015-12-151-8/+13
| | | | | | | | | | | | | | | | | - notes bug in edit/ triggers in immutable but not master branch bug triggered by changes to layer 059: we're finding an unspecialized call to 'length' in 'append_6' hard to debug because trace isn't complete just bring out the big hammer: use a new log file length_2 from recipes.mu is not being deleted (bug #1) so reload doesn't switch length to length_2 when variant_already_exists (bug #2) so we end up saving in Recipe for a primitive ordinal so no valid specialization is found for 'length' (bug #3) why doesn't it trigger in a non-interactive scenario? argh, wasn't checking for an empty line at end. ok, confidence restored.
* 2622Kartik K. Agaram2015-12-131-9/+9
|
* 2615Kartik K. Agaram2015-12-021-4/+16
| | | | | | We don't actually need skip_whitespace_AND_comments_BUT_NOT_newline anywhere except next_word(). Perhaps what I should really do is split the definition of next_word() into two variants..
* 2614 - still fixing bugs with missing '['Kartik K. Agaram2015-12-021-27/+9
| | | | | | When skipping past some text (usually whitespace, but also commas and comments) I need to always be aware of whether it's ok to switch to the next line or not.
* 2454Kartik K. Agaram2015-11-171-13/+13
| | | | | | Another gotcha uncovered in the process of sorting out the previous commit: I keep using eof() but forgetting that there are two other states an istream can get into. Just never use eof().
* 2407 - bugfix: parsing recipe headersKartik K. Agaram2015-11-091-1/+3
|
* 2384 - tests pass until layer 54Kartik K. Agaram2015-11-071-1/+2
|
* 2379 - further improvements to map operationsKartik K. Agaram2015-11-061-1/+1
| | | | | | | Commands run: $ sed -i 's/\([^. (]*\)\.find(\([^)]*\)) != [^.]*\.end()/contains_key(\1, \2)/g' 0[^0]*cc $ sed -i 's/\([^. (]*\)\.find(\([^)]*\)) == [^.]*\.end()/!contains_key(\1, \2)/g' 0[^0]*cc
* 2378Kartik K. Agaram2015-11-061-1/+1
| | | | | | Now we're starting to run up against the misbehavior introduced by generics: Type tries to insert rows for type ingredients. That is a no-no.
* 2377 - stop using operator[] in mapKartik K. Agaram2015-11-061-7/+7
| | | | | | | | | | | | | | | | I'm still seeing all sorts of failures in turning on layer 11 of edit/, so I'm backing away and nailing down every culprit I run into. First up: stop accidentally inserting empty objects into maps during lookups. Commands run: $ sed -i 's/\(Recipe_ordinal\|Recipe\|Type_ordinal\|Type\|Memory\)\[\([^]]*\)\] = \(.*\);/put(\1, \2, \3);/' 0[1-9]* $ vi 075scenario_console.cc # manually fix up Memory[Memory[CONSOLE]] $ sed -i 's/\(Memory\)\[\([^]]*\)\]/get_or_insert(\1, \2)/' 0[1-9]* $ sed -i 's/\(Recipe_ordinal\|Type_ordinal\)\[\([^]]*\)\]/get(\1, \2)/' 0[1-9]* $ sed -i 's/\(Recipe\|Type\)\[\([^]]*\)\]/get(\1, \2)/' 0[1-9]* Now mu dies pretty quickly because of all the places I try to lookup a missing value.
* 2334Kartik K. Agaram2015-10-311-0/+2
|
* 2323 - static dispatch!Kartik K. Agaram2015-10-291-1/+1
|
* 2321 - more preparations for static dispatchKartik K. Agaram2015-10-291-9/+2
| | | | | Deduce operation id from name during transform rather than load, so that earlier transforms have a chance to modify the name.
* 2316 - preparing for static dispatchKartik K. Agaram2015-10-291-14/+15
|
* 2314 - final tweaks to traceKartik K. Agaram2015-10-291-1/+1
| | | | | | | | I checked these commands: $ mu x.mu $ grep "===" .traces/interactive $ grep "===\|---" .traces/interactive
* 2310 - add some more tracingKartik K. Agaram2015-10-291-4/+7
| | | | | | | | | | | I've been growing lax on white-box testing when it's one of the three big thrusts of this whole effort. Perhaps it was because I got too obsessed with keeping traces stable and didn't notice that stable doesn't mean "not changing". Or perhaps it's because I still don't have a zoomable trace browser that can parse traces from disk. Or perhaps $trace-browser is too clunky and discourages me from using it. Regardless, I need to make the trace useable again before I work much more on the next few rewriting transforms.
* 2306 - recipe headersKartik K. Agaram2015-10-281-8/+7
| | | | | | | | | | Once a student has gotten used to recipes and ingredients using the staged 'next-ingredient' approach there's no reason to avoid conventional function headers. As an added bonus we can now: a) check that all 'reply' instructions in a recipe are consistent b) deduce what to reply without needing to say so everytime c) start thinking about type parameters for recipes (generic functions!)
* 2293Kartik K. Agaram2015-10-271-3/+3
|
* 2287 - new lexing rulesKartik K. Agaram2015-10-271-5/+14
| | | | | Now we always consider words to be terminated at () and {}. We also always skip commas.
* 2286Kartik K. Agaram2015-10-271-1/+2
|
* 2285Kartik K. Agaram2015-10-261-2/+3
| | | | Still trying to come up with clean lexing rules.
* 2283 - represent each /property as a treeKartik K. Agaram2015-10-261-7/+2
|
* 2282Kartik K. Agaram2015-10-261-28/+28
| | | | | Switch format for tracing reagents in preparation for trees rather than arrays of properties.
* 2277 - reagents now have a tree of typesKartik K. Agaram2015-10-251-3/+4
|
* 2276Kartik K. Agaram2015-10-251-1/+1
|
* 2274Kartik K. Agaram2015-10-251-3/+0
|
* 2273 - start expanding the type systemKartik K. Agaram2015-10-251-6/+0
| | | | | | | | | | | | | | Current plan: parsing {x: foo, y: bar} syntax for reagents parsing s-expr syntax for properties supporting reverse instructions (<-) parsing s-expr syntax for recipe headers (recipe number number -> number) static dispatch generic functions type-checking higher-order functions type of delimited continuations? need more type information First step is done, and the second partially so.
* 2258 - separate warnings from errorsKartik K. Agaram2015-10-061-11/+11
| | | | | | | At the lowest level I'm reluctantly starting to see the need for errors that stop the program in its tracks. Only way to avoid memory corruption and security issues. But beyond that core I still want to be as lenient as possible at higher levels of abstraction.
* 2193Kartik K. Agaram2015-09-141-2/+2
|
* 2154 - check types only after loading all layersKartik K. Agaram2015-09-051-1/+0
| | | | | Follow-up to 2147, which switched transform_all to only run once, after loading all layers.
* 2150 - recipe! to explicitly redefineKartik K. Agaram2015-09-051-16/+46
| | | | | This will let me create separate 'main' recipes at each layer so people can interact with less featureful versions.
* 2149Kartik K. Agaram2015-09-051-2/+2
|
* 2134 - bugfix: comment terminated by eofKartik K. Agaram2015-09-021-5/+17
| | | | | I ran into this inside 'reload' when I left a trailing comment at the end of the editor.
* 2095Kartik K. Agaram2015-08-281-17/+0
| | | | | | | | | | | | Finally terminate the experiment of keeping debug prints around. I'm also going to give up on maintaining counts. What we really need is two kinds of tracing: a) For tests, just the domain-specific facts, organized by labels. b) For debugging, just transient dumps to stdout. b) only works if stdout is clean by default. Hmm, I think this means 'stash' should be the transient kind of trace.
* 2054Kartik K. Agaram2015-08-211-0/+1
|
* 2039 - warn on unbalanced '['Kartik K. Agaram2015-08-191-14/+34
|
* 2022 - run sandboxes in separate routinesKartik K. Agaram2015-08-161-3/+4
|
;id=63b94083336684c011e2fcdd23226043d0cf6bb7'>^
762b099e ^
90560d71 ^

762b099e ^
d44123ca ^
76755b28 ^

90560d71 ^

76755b28 ^





d5d908dd ^


67db19a0 ^
76755b28 ^
76755b28 ^
dcc060c7 ^
67db19a0 ^





76755b28 ^







76755b28 ^
dcc060c7 ^
76755b28 ^




db1f56c8 ^
67db19a0 ^






76755b28 ^

90560d71 ^





d009e158 ^

0e4a335e ^
90560d71 ^


d009e158 ^
dcc060c7 ^
d009e158 ^
90560d71 ^
dcc060c7 ^
90560d71 ^

67db19a0 ^
90560d71 ^
dcc060c7 ^
76755b28 ^


0e4a335e ^

d009e158 ^
0e4a335e ^
d009e158 ^

0e4a335e ^


90560d71 ^


76755b28 ^




90560d71 ^








76755b28 ^




90560d71 ^








76755b28 ^




90560d71 ^







dcc060c7 ^
90560d71 ^
dcc060c7 ^
76755b28 ^
dcc060c7 ^
76755b28 ^

90560d71 ^
dcc060c7 ^
90560d71 ^
dcc060c7 ^
90560d71 ^



76755b28 ^
90560d71 ^
76755b28 ^




90560d71 ^
76755b28 ^


90560d71 ^


76755b28 ^











90560d71 ^

db1f56c8 ^
d5d908dd ^

d009e158 ^


d5d908dd ^



db1f56c8 ^
d5d908dd ^

d009e158 ^



d5d908dd ^
d009e158 ^

d5d908dd ^




76755b28 ^
d5d908dd ^
76755b28 ^
d009e158 ^
76755b28 ^
d009e158 ^

d5d908dd ^
76755b28 ^
d5d908dd ^



76755b28 ^




d009e158 ^
76755b28 ^

d009e158 ^
76755b28 ^


d5d908dd ^
67db19a0 ^











d009e158 ^

67db19a0 ^










d5d908dd ^
90560d71 ^
d5d908dd ^
90560d71 ^
d5d908dd ^
90560d71 ^

d5d908dd ^

90560d71 ^
d5d908dd ^
90560d71 ^
d5d908dd ^
90560d71 ^


4fe9f5e8 ^
dcc060c7 ^
4fe9f5e8 ^
90560d71 ^
76755b28 ^
4fe9f5e8 ^

d5d908dd ^
9542bb11 ^
d5d908dd ^



90560d71 ^
76755b28 ^
d5d908dd ^

90560d71 ^
d44123ca ^

d5d908dd ^
d44123ca ^

90560d71 ^

d44123ca ^

90560d71 ^
76755b28 ^
d44123ca ^
d44123ca ^

d44123ca ^


90560d71 ^
d44123ca ^

76755b28 ^
9542bb11 ^
d5d908dd ^

dcc060c7 ^
76755b28 ^


dcc060c7 ^
76755b28 ^









90560d71 ^
d5d908dd ^
90560d71 ^
76755b28 ^
d5d908dd ^
90560d71 ^
d5d908dd ^
0e4a335e ^
76755b28 ^
0e4a335e ^










d5d908dd ^
d44123ca ^
d5d908dd ^
dcc060c7 ^
76755b28 ^
d44123ca ^
d5d908dd ^
d44123ca ^
76755b28 ^

90560d71 ^
76755b28 ^
dcc060c7 ^
9542bb11 ^

76755b28 ^

9542bb11 ^

76755b28 ^



0e4a335e ^
67db19a0 ^
dcc060c7 ^
67db19a0 ^

0e4a335e ^
db1f56c8 ^
db1f56c8 ^


9e91a21e ^
db1f56c8 ^
db1f56c8 ^

67db19a0 ^
67db19a0 ^

db1f56c8 ^
67db19a0 ^
90560d71 ^
67db19a0 ^
76755b28 ^

90560d71 ^
db1f56c8 ^


90560d71 ^
d5d908dd ^
9542bb11 ^
76755b28 ^
d5d908dd ^
dcc060c7 ^
76755b28 ^
d44123ca ^

76755b28 ^



d009e158 ^
76755b28 ^





67db19a0 ^








d009e158 ^
67db19a0 ^















d44123ca ^



1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568