Crosscut

Daily Thought - 2024-12-31

Hey, I'm Hanno! These are my daily thoughts on Crosscut, the programming language I'm creating. If you have any questions, comments, or feedback, please get in touch!

< back to list

Source code is traditionally expressed in terms of plain text. A code database changes that: it stores source code in a structured format, and that structured format becomes the source code. That it is a structured format means, that you can no longer just type it in using a text editor.

I can think of two approaches for editing such a code database. The first one is to "check out" a unit of code (maybe a function, or a module), converting it into plain text code that you can edit. Then check it in again, converting your edited plain text back into the structured format. The second one would be to use a special editor, that knows how to edit the code database directly.

Either way, the code you enter would be partially compiled (I call this "pre-compilation") as it makes its way into the code database. This pre-compilation step would include function resolution, type inference, and any other compiler passes that aid the developer's understanding of the code. But it would leave out the final step of translating that code into machine code.

<< previous thoughtnext thought >>

Hey, you! Want to subscribe to my daily thoughts? Just let me know (maybe include a nice message, if you're up for it), and I'll send you an email whenever I post a new one.