3 ms·
> A programming language let's you avoid undefined behavior and stick to the defined abstraction provided by the language. Yes and no. It lets you avoid undefi
by dpark 6mo ago
> A programming language let's you avoid undefined behavior and stick to the defined abstraction provided by the language.
Yes and no. It lets you avoid undefined behavior traps. It lets you rely on endless implementation defined choices.
> Natural language does NOT let you do this, because words have no strict meaning, and the meaning of any sentence is undefined and up for interpretation and contextual clarification, etc, etc.
This is a fair criticism of natural language. It is less well defined. That doesn’t stop it from being an abstraction, though perhaps it fairly makes it a problematic abstraction.
> The LLM/agent that "ignored instructions" and deleted all the customer's data and backups wasn't "being bad" or "ignoring instructions"
That one was entirely human error. And not just “oops I trusted the AI too much”. That guy was sharing the DB volume across prod and staging so deleting the staging DB also took down prod.
If you run your business like that, eventually a human will do the same thing, because it’s catastrophically dumb.
- HarHarVeryFunny 6mo ago> It lets you avoid undefined behavior traps. It lets you rely on endless implementation defined choices. That's a strange way to think of a programming language specification. A programming language is an abstraction that mostly fully specifies behaviors that any compliant implementation must adhere to, and that you as a user of the language can therefore rely on. There may be a few details in a language specification that are specified as implementation defined, but that doesn't mean that are not specified, it just means they are specified by the implementation rather than the standard.
- dpark 6mo ago> A programming language is an abstraction that mostly fully specifies behaviors that any compliant implementation must adhere to, and that you as a user of the language can therefore rely on. This is true but hand waves over a lot of behavior. An implementation of Python could be 10x faster or 10x slower and still be fully compliant with the specification. There’s a reason that NumPy’s core is written in C and not Python. The implementation-specific details sometimes matter. The abstraction is leaky as soon as you care about anything not explicitly specified in the abstraction.