bosatsu icon indicating copy to clipboard operation
bosatsu copied to clipboard

A python-ish pure and total functional programming language

Results 132 bosatsu issues
Sort by recently updated
recently updated
newest added

One interesting idea would be the ability to make unions of enum branches. Like: ``` enum Foo: Bar, Baz, Quux def bar_baz(a: Bar | Baz): match a: case Bar: "bar"...

Pattern matching a bit poorer in strings because you can't match a single character.

Wax is a low-level lisp language that can emit code in many other languages. Compiling to wax could be a great intermediate language to reach many other backends. see https://github.com/LingDong-/wax/issues/14

I was reminded today that elm has extensible records which can be useful for functions that apply to a set of types. I got to wondering what the bosatsu equivalent...

the types were discarded when building the matchless AST. To generate monomorphic code, that seems like it was a mistake. We don't need it to generate python, js, or similar...

In a package import, `Foo as Bar` gets you the ability to talk about Bar as a type, constructor function, and in a pattern match. if you do `foo =...

I'll take another pass and simplify this later but I thought I'd post this in case the solution is obvious This code: ``` package RecordSet enum RowEntry[w]: REBool(value: w[Bool]) REInt(value:...

type system

One significant deviation of bosatsu from python is that we call "modules" by the name "package" and we normally write the package name into the file. Next, we deviate from...

We only allow substructural recursion in bosatsu, and the only way to get a substructure is to do a pattern match where we can verify that we have a substructure:...

Instead of a lambda being marked by `\` we would use `->` as a postfix operator to imply a lambda. This may be tricky for multi-arg functions: `\a, b, c...