Peter Gentry wrote:

> ... how the heck does the code know what your intentions are
> and what is an "error" in your source.

(wearing my professional hat for a moment)

in the programing languages I use and teach, the answer is:

    "from static type declarations".

I declare types of identifiers exactly
for the purpose of documenting my intentions.
Then the compiler *can* figure out
whether my source corresponds to these intentions.
This gives me machine-checked documentation.
What more could we hope for? ..

In lilypond, bar checks is one such way of documenting an intention,
and have it machine-checked (at run-time, but nevertheless).
I can easily imagine more here, e.g.,
specify the total length of a music expression,
or that music expressions (inside << .. >>) should have equal lengths.

- J.W.

_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to