How programming should be

To write a program, we should need to write a minimum of instructions. To display an image in a window, Image("myfile.jpg").show() should be enough for reasonable default behaviour. For a slightly more involved piece of software, the first step is to write the program in an imaginary language which allows you to specify only what really needs to be specfied (not ten tons of #inclues, or class {...} boilerplate if it isn't needed).

In modern times, we have LLVM as a backend. On this backend, there needs to be a library of basic object types and data structures which, importantly, can be passed between programs reliably and securely (that is, without security implications) using simple memory mapping. This avoids the need to serialise/deserialise when passing objects between processes in the same hardware memory space. Performance only needs to be as good as the data structures one finds in the core of, say, Python or Lua. (Structures which need significantly better will always need an implementation which is at least partially application specific.) There also needs to be a library for constructing and compiling programs.

The infrastructure for constructing and compiling programs needs to move away from the text file dominated methods we have at present. If we really do want to compile a standard C file, the program to do it is essentially:

prog = Program.parse(C,"myfile.c") prog.compile("myfile") # binary output
On the other hand, with things like C++, we ought to have things so that
class = Class("MrFlibble",parent=HexVision) class.addMethod("hello") class.method("hello").code = begin: step1() step2() etc() prog = Program("test") prog.globals.addObject("wax",class,...constructor args...) # etc. prog.compile("testout",arch=["x64","armv8"])

John

Doctor John Allsup (from Exeter)