A built-in scripting language. The TI-83 line of calculators have an app programming language that requires you to side-load code from another computer, but they also have TI-BASIC, which allows you to write a wide variety of scripts right on the calculator itself. This should be standard on all 'smart' devices. It's so stupid to have gigahertz of computing power in your pocket and not be able to do anything without writing the app on another machine.
I know Termux for Android exists and that's a good start, but I'd like to see something baked right into the OS that has access to all my device's cool sensors and gizmos. The camera, the microphone, the aux port, the usb port, the accelerometer, the bluetooth antenna... all of those things should be exposed to the user. This would be a really good use case for 'visual' programming ala Scratch, since you could assemble a script right from a touch screen instead of having to plug in a keyboard.