| The Idea | ToDo |
Coding guidelines suffer even worse: placement of braces, how big is a TAB, do I write "if (guard)" or "if( guard )". By storing the code in a hierarchical way (including semantics), layout is merely a View onto a Model (a la MVC). Note: this doesn't hold as much for Ruby, since it doesn't use very many braces and the languages enforces placement part of the time.
Naturally, anything integrated in an IDE (and things not yet integrated) can be helped by these semantics.
<license id="lgpl" name="GNU Lesser General Public License"
url="http://www.gnu.org/licenses/lgpl.html"/>
<code since="v0.0.1" license="lgpl">
def hello(str)
puts "Hello, #{str}!"
end
</code>
Very simple, leaves code intact.
<code method="hello", implements_feature_request="1" params="str"
author="Kero" copyright="Kero" impl="puts \"Hello, #{str}\""/>
Adds a bit of semantics to the code snippet.
<method name="hello" params="str">
<statement solves_bug="42" code="puts \"Hello, #{str}\""/>
</method>
xml element is <method>, which takes it all to a different
semantic level. You'd also have <while> (and maybe things like
<new_thread>?).
| The Idea | ToDo |