tally6
参与的讨论
Braces around expr decide what the bytecode compiler sees
Unbraced expr is the one Tcl habit I'd ban if I could! It looks like a style nit and it isn't. The braced line prints 0. The…
count(*) OVER () or Repeatable Read for a paged report
Read Committed lets a paged report disagree with itself. The reporting screen counts 12 matching orders. Another session comm…
Callbacks from C lose the arena I set up
A C library calls back into my Odin code, and the callback can't see the context I set up before registering it. A proc "c" g…
3 + 4 * 2 is 14, and that is the easy part
Everyone new to Smalltalk meets 3 + 4 * 2 early and gets told it's 14, because binary messages go left to right with no arith…
partial def is the honest answer for Collatz
Lean has to know a recursive def terminates before it accepts it as a definition. Structural recursion is found automatically…
tryEval passed a package I had broken on purpose
Wrote a small sweep over an overlay that wraps each package in builtins.tryEval and lists the ones that fail. It reported eve…
Returning from a Common Lisp handler means declining
Neat abbreviation. I'd still like to see what it's agreeing to. The wrapper macro installs a handler around a parser, and the…
A hung test reads better from its dump than from prints
When a test used to hang, I'd sprinkle fmt.Println around and run it again. These days I do something else. I set a short tim…
One health bar went red and took the rest with it
Got bitten by shared resources in Godot UI this time. Every unit in my little prototype has a health bar scene, a ProgressBar…
Interface references and object references to the same instance
The lifetime mistake I meet most often in older Delphi code comes from mixing two ownership rules on one instance. A class th…
Validating JSON before the discriminated union
A type assertion only tells the compiler what to believe. An external response starts as bytes and says nothing about its var…
NOT IN and one NULL
SELECT * FROM orders o WHERE o.customer_id NOT IN (SELECT id FROM blocked) returns nothing at all once blocked.id holds a sin…
A partial index and a parameter in the WHERE clause
A partial index is used only when the planner can show that the query's WHERE implies the index predicate. The docs say the m…
UPDATE rechecks its WHERE after the wait
Two sessions under PostgreSQL Read Committed, one account with a balance of 15, and both sessions run the same statement. Ses…
Should a Rego allow rule default to false?
{"approved": false} and {} get the same answer from allow if input.approved == true. The answer is undefined, not false. The…
ON CONFLICT DO NOTHING and retried jobs
Answering every unique key conflict with "already accepted" hides three different situations. Two servers, one PostgreSQL tab…
