« first day (3322 days earlier)      last day (458 days later) » 

1:56 AM
I may have proposed it before, but what if optional assignments were foo/: value? Then func [x/ /y] [...] could take the place of meaning func [x [<opt> any-value!] /y] [...]
In any case I have booted a system that uses VOID! for unset variables, and makes unused refinements null and not blank. Mechanically it looks like a win on the whole.
 
 
6 hours later…
7:53 AM
In an interesting development, the combination of these choices is bringing about a simplification in the C code, simpler than R3-Alpha... if ARG(xxx) on the natives is changed to return nullptr on nulled cells, you can eliminate REF(xxx). That's... rather cool. It's nice to see places where Ren-C has streamlined the history. I did not think of this when thinking of the move to null for unused refinements, but now that I see it, that's rather compelling.
if (ARG(xxx)) can be a way in the C of testing if that refinement was supplied, e.g. the native need not discern refinements and arguments, due to the falsity of C's null/0
But you'd still need to be able to get at the cell address if you're going to overwrite it as temporary storage. That's a rarer operation. CEL(xxx)? Hmmm. mutable_ARG(xxx) ?
 
 
5 hours later…
1:11 PM
@rgchris Learned that Perl6 is now called Raku.
 
I just realized that the NULL specialization of arguments already has a solution. specialize 'append/part [part: null]. If we do the implementation like @ingo and I talked about where you can name any argument in a path, e.g. for reordering, such that append-value-series: :append/series which creates an APPEND variant which puts its series after the value, that could cover the same idea for specializing optional plain arguments.
 
 
6 hours later…
7:35 PM
The set/unset/void question is pretty deep and the solution is mechanically complex...I want to maintain the language that a null variable is the true "not set". Yet at the same time I don't want reading variables that are null to cause errors. You have to explicitly poison a variable with a value that triggers errors to get that. And that is what "voidification" is, a poisoning.
And that is what happens when a binding process sees references to words before an assignment--which may or may not be a typo. Without some kind of poison values, then typos would not be errors. Calling this void state "unset" is consistent with history (it is the state which requires a GET-WORD! to bypass erroring) and it is a value...but there's something wrong in my mind if you don't say "a variable that has no reified value is 'unset'"
I think we can bypass the issue for the most part...we don't even need an UNSET native, since void assignments are allowed. x: y: z: void, convenient. x: y: z: null, convenient.
I think I like the idea of SET? and UNSET? continuing to be questions asked of variables about their null-or-not state. So even though context expansions are using VOID! so that typos remain errors/etc...I think I prefer "set to void" to conflating with "has no value" or "unset". if voided? 'var [...] isn't merely me being difficult, I meant what I said
 
 
2 hours later…
9:30 PM
1015
Q: What is the difference between null and undefined in JavaScript?

user605334I want to know what the difference is between null and undefined in JavaScript.

 
 
1 hour later…
10:49 PM
I think we can square this circle if we distinguish an UNSET variable (one that is null, and has no value, e.g. its contents are not an ANY-VALUE!) from one that is UNDEFINED (one that has a value of type VOID!). People coming from other languages--in particular JavaScript--would be happy enough to have the UNDEFINED? as the test on a WORD!/PATH! for if accessing it would error, and not get worked up over the fact that UNSET? tests something different.
 
11:02 PM
With this change, if GET/ANY was the only way to get VOID! variables by word or path, how many people would be upset? That would mean if you ever saw a GET-WORD! or GET-PATH! you'd know it was for disarming a function.
 

« first day (3322 days earlier)      last day (458 days later) »