Hacker News new | past | comments | ask | show | jobs | submit login

> classic 8-bit era BASIC has functions

If you mean “functions” in a strict mathematical sense, sure, I remember those. I remember thinking they were useless and wondering what anyone would use them for – I never used them myself. The way to do any sensible subroutine things (in the BASICs I had access to) was to use GOSUB to line numbers, which was a method inherently too cumbersome to do anything complex with, which is why I was stalled when my programs reached a certain level of complexity. I was then mostly halted in my education and development as a programmer for many years, because the language did not make program composition easy. It was not until I had the opportunity to learn other languages with did have proper functions and other methods of program composition that I could break through the barrier, so to speak.

> BASIC is great because it's basically structurally like simple assembly language

And why would that be a good thing? Classic assembly language is basically living on borrowed time, since the memory and CPU model they assume and expose are long gone, and only emulated in microcode on today’s hardware.

Modern hardware platforms are multi-threaded multi-core systems with multiple levels of cache for memory, nothing of which is exposed to classic assembly language. Also, disks are no longer nearly as slow, nor is RAM always volatile. Not to mention that even memory mappings and protection rings, as old they are, weren’t always there in classic hardware, and, when present, were mostly hidden from the programmer, since the programmers of the time were used to systems without them.

Just like classic assembly in a way created C (commonly called a “portable assembler” for its closeness to the old machine model), I’d like to first see an “assembly language” for the modern architecture – something low-level which exposes all the multi-core, cache level, and protection ring complexity as inherent parts of the language. Then, if I dare dream, I’d like to see many high-level languages built directly on top of that low-level one – almost certainly a Lisp, but also maybe an Erlang. All other languages (except maybe Prolog) would probably be too hard (or too like an emulator) to map sensibly to the inherent multi-core model of modern hardware; you might need an entirely new language paradigm. And, sure, also a pony¹, why not.

1. http://www.gocomics.com/calvinandhobbes/1987/01/13




> The way to do any sensible subroutine things (in the BASICs I had access to) was to use GOSUB to line numbers,

True.

> which was a method inherently too cumbersome to do anything complex with,

It's really not. (Unless by “complex” you mean specifically “recursive (even indirectly), but not tail recursive”, in which case I'd have trouble disagreeing.)




Consider applying for YC's W25 batch! Applications are open till Nov 12.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: