Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
jorkadeen
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
8 ms
·
31.
▲
by
jorkadeen
3y ago
We may consider WASM as support for GC, tail calls, and multi-threading arrive.
32.
▲
by
jorkadeen
3y ago
In short yes. We plan to leverage the effect system for this. Stay tuned.
33.
▲
by
jorkadeen
3y ago
The Flix compiler is written in Scala. The Flix Standard Library and runtime, which includes a Datalog JIT, is written in Flix. GitHub does not yet recognize .flix, so the numbers reported are an inaccurate representation of the actual code
34.
▲
by
jorkadeen
3y ago
The implementation language does not affect the target "machine". Also Flix is implemented in both Scala and Flix (but GitHub does not yet recognize Flix code). Flix targets Java 11, but is moving to target Java 21, and will take
35.
▲
by
jorkadeen
3y ago
The situation here is not unlike the problem with null: If you allow null in your language, you will have NullPointerExceptions at runtime. Unused local variables (and other unused constructs) are known to be correlated with bugs (see e.g.,
36.
▲
by
jorkadeen
3y ago
I think the most controversial feature is actually its effect system. Unlike division-by-zero, which is typically a rare occurrence, the effect system permeates the language and must be learned before one can write useable programs. This re
37.
▲
by
jorkadeen
3y ago
The website is infrequently updated, so let me provide some information about what we are currently working on: - We are trying to make the entire compiler resilient (error-tolerant), incremental, and parallel. We have managed to make every
38.
▲
by
jorkadeen
3y ago
What's the issue? Bug reports are most welcome.
39.
▲
by
jorkadeen
3y ago
You might be interested in Flix which has first-class Datalog program values: https://flix.dev/ https://doc.flix.dev/fixpoints.html (I am one of the developers of Flix)
40.
▲
by
jorkadeen
3y ago
Thanks for the kind words. Yes, I would definitely consider it a language in the ML-family. Its core is based on Hindley-Milner (like StandardML, OCaml, and Haskell) which I think is the hallmark of ML-family languages. Flix sits neatly bet
41.
▲
by
jorkadeen
3y ago
An alternative to OCaml is Flix ( https://flix.dev/ ) which attempts to address some of the critiques in the post. For example: > Bad standard library A particular goal of Flix is to have a consistent standard library base
42.
▲
by
jorkadeen
4y ago
Thanks for the kind words! To try to answer your questions: - We are debating whether to allow a limited form of overlapping instances. No decision has been made yet. - Flix uses the Options and Errors. Flix also has monadic let* making it
43.
▲
by
jorkadeen
4y ago
You are spot on. Its because we reserve `:` for type and kind ascriptions. For example, `42 : Int` or `true : Bool`. But we also have `Bool : Type`, i.e. `true : Bool : Type`. While kinds are not that common in every day code, we aim for co
44.
▲
by
jorkadeen
4y ago
Datalog programs are values. You can store them in local variables, pass them as arguments, and return them. If you have two Datalog values you can combine them into one (effectively it's just the union of them). This allows you to wri
45.
▲
by
jorkadeen
4y ago
The color of your function can be "effect polymorphic". In other words, e.g. List.map works with both pure and impure functions. You don't have to write two versions of List.map.
46.
▲
by
jorkadeen
4y ago
At the moment the effect system only distinguishes between pure and impure (and effect polymorphic) expressions, but we are working towards a richer system. For example, we will soon be able to express something like: def swap!(a: Array
47.
▲
by
jorkadeen
4y ago
Be sure to check out https://flix.dev/ and https://github.com/flix/flix/tree/master/examples for more examples. (I am one of the authors of Flix.)
48.
▲
In Defense of Programming Languages
(flix.dev)
4 points
by
jorkadeen
5y ago
|
1 comments
49.
▲
by
jorkadeen
6y ago
In Flix, Datalog constraints are first-class values . This is strictly more powerful than a macro system. For example, the Datalog programs that are constructed can depend on input values to the program. This is not the case for macros whi
50.
▲
by
jorkadeen
6y ago
My understanding is that there are 15+ papers that formalize and prove soundness of various aspects of the DOT type system, but that the "full" type system implemented in Dotty today is still unsound. Hopefully this situation wi
51.
▲
by
jorkadeen
6y ago
I think you would want both: algebraic effects and very fine-grained effect reasoning. For example, in all most all languages it is vital that functions such as "equal" and "hash" are pure. It is an open problem how to c
52.
▲
by
jorkadeen
6y ago
Thanks- I will try to get it fixed!
53.
▲
by
jorkadeen
6y ago
The alternatives are: - Division must be impure (because it can throw an exception, crash the program, etc.) - Division must be partial - i.e. return Option[Int]. Both seem worse compared to defining division by zero as zero. Coq, Lean, and
54.
▲
by
jorkadeen
6y ago
I don't think that is true. For example, Java beats OCaml on some benchmarks at: https://benchmarksgame-team.pages.debian.net/benchmarksgame/... It seems that the situation is not as clear cut as your post suggest
55.
▲
by
jorkadeen
6y ago
Adding to that: effect inference and polymorphism, unboxed primitives, full tail call elimination, extensible records, first-class Datalog constraints, CSP style concurrency, a multitude of different design choices. (I am one of the authors
56.
▲
by
jorkadeen
6y ago
The Datalog implementation in Racket is neat, but does not support stratified negation nor are the Datalog constraint first-class. Both features make it significantly more practical to work with Datalog. Also, the Flix type system ensures -
57.
▲
by
jorkadeen
6y ago
We are still figuring out the details about array impurity. But in a nutshell if something is pure it should support substitution. For example: let x = 123; let y = (x, x) If you substitute x into the pair you get the same result. So far, s
58.
▲
by
jorkadeen
6y ago
For example: Given the type List[Int] the cons cells of each list contain a primitive integer and a pointer to the next cons cell. (In Java, you would instead have List[Integer] where each element of the list is a boxed/wrapped Integer
59.
▲
by
jorkadeen
6y ago
I think your comment is covered in the FAQ: https://flix.dev/faq/ > Can we just stop building new programming languages? We build new programming languages and we do research on programming languages because we want
60.
▲
by
jorkadeen
6y ago
At the moment it uses a technique called "Impure Functional Objects" - which are a form of reusable stack frames. In the future we may switch to trampolines and eventually if Project Loom succeeds we will try to use whatever infra
More ›