Elektrine lite

← Feed

@poundquerydotinfo@forum.virctuary.com

Post #1915993

2026-04-24 16:32 UTC

I kinda like the idea of "!" FWIW, though I wouldn't use it ;-) I'm old fashioned so the third option is not what I'd want to do. I gather at least one language writer added that after being lambasted by people claiming JS "proved" you don't "need" it. No, JS proved that the compiler doesn't necessarily need it if you limit syntax in general. It doesn't prove anything beyond that. Code should always be explicit. It's not just the compiler that reads it.

Replies (1)

  • Related: Any language that allows you to type something like: x = [1, 2, 3]; should also allow you to type: x = [1, 2, 3,]; Oddly PHP is the only language I've used that accepts this. It looks a little ugly, but it becomes really necessary when you have something like this: people = [ { name: "Alice", age: 42 }, { name: "Bob", age: 29 }, { name: "Carol", age: 35 }, ]; The cut, paste, and tweak when adding Dan just got less fiddly.

    Open ##1915994