6 ms·
I think whatever the language of the future will be, it's likely that we're going to have to give up editing a bunch of text files. Much of modern programming t
by bane 12y ago
I think whatever the language of the future will be, it's likely that we're going to have to give up editing a bunch of text files. Much of modern programming these days is really about workflow of large teams. It'd be nice to have richer editing areas that allow for things like embedded diagrams and videos as comments, annotations, hypertext links out to documentation and from documentation into code, review comments (similar to MS-Word), font size; colors; background colors etc. time-tracking for payroll, etc.
IDEs try to provide some of this layer on top of the piles of text files we use today, often supplemented with out-of-band config files and folder structure littering stuff all over the place. But there continues to be a proliferation of hacked on comment systems to handle things like method descriptions, code changes, reviews. People make changes in some code, then leave a comment in the code with the change they made, their name and email address so 2 years later somebody can try and track them down to remember the 2-line change they made 2 years prior. It's kind of absurd.
Imagine if I could just draw a box around a section of code, make the box dashed and fill the background with red and have a call-out annotation around it that says something like "highly performance sensitive, do not touch, see bane for problems" and "bane" was a link to my bug tracker page where you could immediately file an issue with that code?
And you knew the code had a problem because right above it, instead of some vague interpretive ASCII art describing the algorithm as a comment, there was a familiar vector graphic diagram and a set of equations all of us domain expert programmers know by heart. Only you noticed an error in the way I translated it from the textbook to code. You also tagged the couple lines I screwed up and wrote up a review comment in the sidebar (like in MS-Word) letting me know what you thought was wrong, that way when I go to my bug tracker, click the link that takes me directly to the code you wanted me to see, I see your review comment right next to the code in question, only it's not mixed up in the rest of the code comments explaining how the code works since it's semantically a separate thing.
I check out the problem and see that you're correct, I leave a response comment (which automatically notifies you via e-mail with a link to the bug tracker and to the code in question. When I go back out to the bug tracker the amount of time I was reviewing the issue is automatically logged, a diff is stored for review so everybody knows what I changed and the review comment and reply are automatically filled out in the tracker. My boss wants to check out the entire exchange, clicks my reply, is taken directly to the block of code in question and sees that I spent a reasonable amount of time doing the change (which he can see since the changes were tracked in the diff). I close the case and the review comments disappear from the code, leaving behind only good clean code and explanatory comments.
Now a year later, somebody turns on "see old bugs" and they see there was a problem there, the discussion, what the bug tracker #s were (with links they can follow), they can even play back time and see the 3 other edits that happened since then by simply moving a slider left to right.
- taeric 12y agoMy main problem with this is the odd implication that text files are anything more than just a form of art. With rules. And, typically, well agreed meaning. You even refer to them as "interpretive ASCII art." That is to say. Sure, I can not literally draw a box around some code. I can, however, put "boxes" around many parts of code. Be it by shuffling them away to another repository/file/namespace/whatever. Or simply appending "thinkThrice" to the function names. More, it is easily argued that all art is "interpretive" at some level. The odd believe that a set of well agreed upon sets of interpretations (you know, the alphabet) are somehow less appropriate than mere free form lines on a wall is interesting.
- overgard 12y agoI like this vision, but I just don't see it catching on. (Unless it has an obvious fallback to text). There are just so many tools that operate on text that you'd have to replace. I can't imagine people dropping, say, Git so that they can have videos as comments. At best you're probably dealing with some sort of markdown-esque meta-language that you embed in the comments. The only significant language I can think of that shirked the code-as-files paradigm was smalltalk. Arguably that did not do the language a lot of favors, in that one of the main problems with smalltalk was that it always felt like a walled garden. It was definitely a very /nice/ garden, but interacting with the rest of the system was a very alien experience.
- bblach 12y ago"Imagine if I could just draw a box around a section of code, make the box dashed and fill the background with red and have a call-out annotation around it that says something like "highly performance sensitive, do not touch, see bane for problems" and "bane" was a link to my bug tracker page where you could immediately file an issue with that code?" I really like this imagination.
- brudgers 12y agoThat's a lot of baked in dependencies for a language.
- ajuc 12y agoVersion control system commit comments are already very useful for many common development tasks, if done right (jira ticket number in each commit, commits divided properly, good commit messages with reasons for change). I wish there was more metadata there (like which tests failed during automatic build after each commit). But I disagree using text as underlying data format is a problem. It's godsend. Text can be grepped, copy-pasted, diffed and versioned easily. I cringe when I have to work with versioned word or excel documents. Working with versioned code is much easier. you may think big red arrow would be nice to put in code, but how do I later search for all red arrows related to X, added by John between 3 and 4 months ago? I have specification divided into 100s of versioned office documents. When I want to grep I have to know where to look (or zipgrep the underlying xml, which sometimes work sometimes doesn't). If it was in a text format I could grep and see real differences, not edit history. If it had embedded video I would need to watch the whole thing. And no - adding keywords isn't much help. I want to be able to search by content.