genType
Idris2
genType | Idris2 | |
---|---|---|
5 | 39 | |
759 | 2,503 | |
- | 0.8% | |
0.0 | 9.4 | |
11 months ago | 7 days ago | |
OCaml | Idris | |
MIT License | GNU General Public License v3.0 or later |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
genType
-
ts-belt - Fast, modern, and practical utility library for FP in TypeScript / Flow / JavaScript. (Faster than ramda, rambda, remeda and lodash/fp.)
I don't really use ts-belt to be certain, but by looking at the source, it seems that it's using genType, which can generate TS types from ReScript values, and that makes interop work really well.
-
ReScript 10.0
They discuss this in their docs.
https://rescript-lang.org/docs/manual/latest/introduction#di...
Seems like a type system for Javascript, built with a differing set of opinions than Typescript.
Looks like they also offer some form of TS interop:
https://rescript-lang.org/docs/gentype/latest/introduction
- From TypeScript to ReScript
-
TS Belt - fast, modern, and practical utility library for FP in TypeScript
TS Belt has been built with ReScript (and its Belt stdlib). ReScript generates highly performant JavaScript code, and with genType it also automatically generates TypeScript types. Moreover, I've added a few codemods to the building process to provide even more code optimizations and cleaner TypeScript signatures.
-
How I Switched from TypeScript to ReScript
To interoperate with TypeScript with proper type information you’ll use third-party genType. Add it as a devDependency and annotate the module export you want to generate with @genType (in previous versions you’d surround annotations with square brackets).
Idris2
- Idris2: A purely functional programming language with first class types
-
Lean4 helped Terence Tao discover a small bug in his recent paper
Have you looked into Idris2 at all. While looking into these theorum provers, it always felt like they had an impedance mismatch with normal programming.
Idris2 portends to a general purpose language that also has a more advanced type system for the theorum proving.
https://github.com/idris-lang/Idris2
-
How to Keep Lambda Calculus Simple
The original paper also does plain STLC first in section 2, and then adds dependent types in section 3. (And finally it adds the naturals in section 4.)
In the Idris2 github repository, Guillaume Allais goes a step further and shows a well-named version. There the types of terms and values are indexed by the list of names in the environment and the compiler checks that the manipulation of deBruin levels and indices is correct:
https://github.com/idris-lang/Idris2/blob/main/libs/papers/L...
-
What are the current hot topics in type theory and static analysis?
Most of the proof assistants out there: Lean, Coq, Dafny, Isabelle, F*, Idris 2, and Agda. And the main concepts are dependent types, Homotopy Type Theory AKA HoTT, and Category Theory. Warning: HoTT and Category Theory are really dense, you're going to really need to research them.
- New video! 2022 in Programming Languages
-
How to avoid right intendation?
Idris2 has a great syntax for this, see e.g. node018:
-
Data types with Negation
I asked because it just baffles me any time I see a dependently typed language using unary numbers. I think to myself, "are these people even educated? Do they know about number systems?" I mean, cavemen were the last group using unary number system as their mainstay, and that was during the Paleolithic. Then they have issues open like this when they discuss optimizing those damn unaries. But this shouldn't even have been a problem for anyone even remotely related to programming! It's giving a terrible impression of dependently-typed languages. Getting rid of those should be the first step of popularizing them.
- I've learned this from Conor McBride on an SPLV'19 bus ride. A literary reference would be welcome.
-
Altering behavior of runElab and macros outside of source code
addOne : Int -> EitherT String IO Int addOne x = pure $ x + 1 add : Int -> Int -> EitherT String IO Int add x y = pure $ x + y main : IO () main = do exportFn `{add} the (IO ()) $ exportFn `{addOne} -- `the (IO ())` is needed due to issue https://github.com/idris-lang/Idris2/issues/2851
-
Managing world state for a imperative language with pure functions
The idea of world state is an attraction of the state that side effects change. I got the idea from Idris internals: https://github.com/idris-lang/Idris2/blob/main/libs/prelude/PrimIO.idr
What are some alternatives?
melange - A mixture of tooling combined to produce JavaScript from OCaml & Reason
purescript - A strongly-typed language that compiles to JavaScript
zod - TypeScript-first schema validation with static type inference
rust-ordered-float
from-typescript-to-rescript - Frontend of https://Inhyped.com written in TypeScript and rewritten in ReScript
lang-team - Home of the Rust lang team
lwt - OCaml promises and concurrent I/O
idris - A Dependently Typed Functional Programming Language
bolt - Bolt is a language with in-built data-race freedom!
rust - Empowering everyone to build reliable and efficient software.
ts-belt - 🔧 Fast, modern, and practical utility library for FP in TypeScript.
smalltt - Demo for high-performance type theory elaboration