|
|
|
|
|
by dsfsdfd
3841 days ago
|
|
No one is going to listen to this - but what the hell: The solution is totally obvious. The code we write has a form defined by it's input->output mapping over all possible inputs. Write a function and you immediately define this input output mapping. All you have to do at this point is search through all previously written functions to find the one that most resembles the one you are trying to write. Trying to write a nested for loop to pull out pixel values from a jpeg? Start writing it, shit you get it wrong - but the input output mapping is close enough to the cluster of previously written solutions that the correct code pops onto the screen. Structure aware code search across all open source code would make a lot of the pain just go away. |
|
1. specify with enough precision your requirements 2. search through all code for matches 3. vet those matches 4. incorporate it into your code-base
and in the end you don't want a bunch of spaghetti - you want a consistent and digestible architecture.
But I do think this type of coding will become mainstream within a few years. As you say, it's obvious.