I very much concur with the view of programming being a projection of our understanding of something in the world (physical or otherwise) into executable code. Like you point out, much can be improved by eliminating the unnecessary dissonance between implementation and domain.
However, we can still do much more than that. Take your example of searching textually for a class / method. First, when we search by text we assume that code has no structure. Would it not be a significant optimization to have a search that allows you to be search semantically through your system?
Now, the problem is that a system is interesting from many different perspectives.
- For example, a security issue is most likely going to be crosscutting the domain. When we look for it, we would like to see a projection of the system specifically for our problem.
- Or take communicating with the domain specialists. Most often, that communication happens on the whiteboard. However, what is manually drawn on the whiteboard represents what the writer thinks, not necessarily what the system is. To see the system, we should want the system to draw itself on the whiteboard. Any manual intervention in this process introduces an interpretation that hinders the communication. So, we can start with writing on the whiteboard when the system does not exist, but as soon as it does exist, we should have the system draw its representation. That can enhance communication manyfold.
However, we can still do much more than that. Take your example of searching textually for a class / method. First, when we search by text we assume that code has no structure. Would it not be a significant optimization to have a search that allows you to be search semantically through your system?
Now, the problem is that a system is interesting from many different perspectives. - For example, a security issue is most likely going to be crosscutting the domain. When we look for it, we would like to see a projection of the system specifically for our problem. - Or take communicating with the domain specialists. Most often, that communication happens on the whiteboard. However, what is manually drawn on the whiteboard represents what the writer thinks, not necessarily what the system is. To see the system, we should want the system to draw itself on the whiteboard. Any manual intervention in this process introduces an interpretation that hinders the communication. So, we can start with writing on the whiteboard when the system does not exist, but as soon as it does exist, we should have the system draw its representation. That can enhance communication manyfold.