4 ms·
Tangent because this the first I’ve heard of Virgil. From the main README, what do you mean when you say you would like programs written in Virgil to be depend
by whoisburbansky 5y ago
Tangent because this the first I’ve heard of Virgil. From the main README, what do you mean when you say you would like programs written in Virgil to be dependency-free?
- titzer 5y agoYou can write programs that depend on no libraries at all, not even an SDK. They just need a compiler binary (and a machine to run that--x86-linux, x86-darwin, jvm, or even a Wasm engine) to compile, and compile to a binary that also only needs a machine to run--no shared objects, external jars, etc. The language has no builtin classes, interfaces, or functions. In contrast to say, Java, where the language (and compiler) know about java.lang.Object, java.lang.String, etc. The compiler knows how to compile classes, but it doesn't know the name of any built-in ones. Virgil is really designed to build the lowest level of software. Thus all my focus on low-level things like calling the kernel and mapping stacks, etc. The only thing that depends on more than just the kernel is the test suite, which uses bash and a little bit of C.
- whoisburbansky 5y agoAh, that's really cool. The clarification about it targeting the lowest level really helps explain the motivation, thanks, and all the best!
- kragen 5y agoInteresting! Virgil looks really cool! I've been looking for something like it since about the time you started working on it, and I'm glad I've finally found it. For others reading this thread, to clarify the "no builtin functions" claim, although Virgil doesn't have any builtin values which refer to methods, it does have some built-in operations: ==, !=, +, -, *, /, %, <<, >>, >>>, &, |, and ^, as well as data structuring facilities like arrays and tuples and operations to access them.