Virgil: A Fast and Lightweight Programming Language That Compiles to WASM

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

Our great sponsors
  • SonarLint - Clean code begins in your IDE with SonarLint
  • Scout APM - Less time debugging, more time building
  • SaaSHub - Software Alternatives and Reviews
  • virgil

    A fast and lightweight native programming language

    Terrific. Some really great ergonomic features. After a quick scan:

    --

    Invoking methods with tuples. https://github.com/titzer/virgil/blob/master/doc/tutorial/Tu...

    Just terrific. Similarly, I've wondered about the symmetry of maps (dictionaries) and named parameters, and the potential to invoke methods with maps.

    --

    "Functions are contravariant in their parameter type and covariant in their return type" https://github.com/titzer/virgil/blob/master/doc/tutorial/Va...

    Terrific. This "hole" in language design has always frustrated me. As a noob, I've been wondering:

    Do covariant return types resolve "the expression problem"? Thereby reducing the number of 'instanceof' type checks? https://en.wikipedia.org/wiki/Expression_problem

    Do covariant return types moot the need for using double dispatch when implementing Visitor (for statically typed languages)? If so, that'd close at least one ergonomic gap between dynamic and static languages.

    --

    Whinging:

    Virgil is practical. It uses modern techniques to address programmer's actual needs.

    I love both functional and imperative programming. Separately. I do not want multiparadigm. I do not want metaprogramming in my bog standard data processing code. I do not want exquisite puzzle boxes (inspired by Haskell and ML).

    For most of my code (done in anger), I want data centric, I want composition, I want static typing. To noob me, it appears Virgil is on the right path.

    For just one example, Java jumped the shark. Specifically annotations, optionals, and lambdas. (I grudgingly accept the rationale behind type erasure for generics; it was a different time, when backward compatibility reigned supreme.)

    We need features, often syntactic sugar, for the 98% of our daily work. String intrinsics (finally!), intrinsic regex expressions, intrinsic null-safe path expressions (not LINQ), tuples, multiple return values (destructuring), etc.

    I want concision without magic.

    In Java's defense, specifically, I love many of the JEPs of the last decade. Project Loom is a game changer. Switch expressions are great. Ditto values types and records. (There's more, but you get the idea.)

    Also, project Zig embraces the practicality vibe. And shout out to D language.

  • vigil

    Vigil, the eternal morally vigilant programming language

    Not to be confused with Vigil, an esolang by the great Munificent.

    https://github.com/munificent/vigil

  • SonarLint

    Clean code begins in your IDE with SonarLint. Up your coding game and discover issues early. SonarLint is a free plugin that helps you find & fix bugs and security issues from the moment you start writing code. Install from your favorite IDE marketplace today.

  • v86

    x86 virtualization in your browser, recompiling x86 to wasm on the fly

  • bfchroma

    Integrating Chroma syntax highlighter as a Blackfriday renderer

    I've used a markdown to html converter to convert my blog posts into HTML with very nice and customizable code samples... in my case I used Go's Blackfriday library with bfchroma[1] doing syntax highlighting with Chroma[2]. To add your language to Chroma you have to provide a lexer, which in turn is written in Pygments[3] syntax.

    [1] https://github.com/Depado/bfchroma/

    [2] https://github.com/alecthomas/chroma#supported-languages

    [3] https://pygments.org/docs/lexerdevelopment/

  • chroma

    A general purpose syntax highlighter in pure Go

    I've used a markdown to html converter to convert my blog posts into HTML with very nice and customizable code samples... in my case I used Go's Blackfriday library with bfchroma[1] doing syntax highlighting with Chroma[2]. To add your language to Chroma you have to provide a lexer, which in turn is written in Pygments[3] syntax.

    [1] https://github.com/Depado/bfchroma/

    [2] https://github.com/alecthomas/chroma#supported-languages

    [3] https://pygments.org/docs/lexerdevelopment/

  • rust

    Empowering everyone to build reliable and efficient software.

    Not only is a “heavyweights of the rust community”, he was literally one of the main designer of the language at Mozilla (he's still contributor #6 by commit[1] despite not having worked on it for the past 7 years!)

    [1]: https://github.com/rust-lang/rust/graphs/contributors

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts