News for hackers. Stuff that matters.
Re:Why we write elementary apps in Vala (2014) by mythz on Saturday September 10, 2022 @01:42AM (#32788126)
A similar language that was created to make creating GUIs more pleasant is Jakt [1] for SerenityOS which is Impressive to see how fast they've been able to develop a pleasant modern native language, went from 0 to rust-based then self-hosting compiler inc. VS Code static analysis & intelli-sense in weeks.

Like most of SerenityOS you can follow much of its development is on YouTube [2]. A good video series that captures the language ergonomics is in the "Jaktness Monster" series which goes through creating a NES Emulator from scratch [3].

[1] https://github.com/SerenityOS/jakt

[2] https://youtu.be/RXp2T_iAhWc

[3] https://youtu.be/47svsnd7HIQ

Re:Why we write elementary apps in Vala (2014) by CraigJPerry on Saturday September 10, 2022 @03:39AM (#32788686)
Jakt looks pretty interesting. Would “rust without the productivity sapping affine types / lifetimes / borrow checker, but with zig’s take on comptime” be a fair summary or am i doing an injustice?
Re:Why we write elementary apps in Vala (2014) by mythz on Saturday September 10, 2022 @03:47AM (#32788714)
For me it looks like a more pleasant, productive and safer native language than C++ with emphasis on readability and safety. It's definitely inspired by other languages with similar goals but I wouldn't consider it defined by them.

One of its Co Creators @jntrnr was on both the Rust core language and TypeScript language teams which was how they were able to build the first rust based compiler + VSCode static analysis so quickly. Once the language was capable enough they rewrote the compiler in Jakt where it's now self hosting.

Excited to track its trajectory given how fast they were able to develop it, which already has a nice development experience in VSCode.

[1] https://twitter.com/jntrnr

Re:Why we write elementary apps in Vala (2014) by gardaani on Saturday September 10, 2022 @11:16AM (#32791383)
Jakt looks very much like Swift. Objects are reference counted, structs are always value types, all function arguments require labels, no semicolons.. it's clear that Kling has worked for Apple.

I like the language! It is so much more readable than Rust. I might switch from Rust to Jakt once version 1.0 has been published.

Re:Why we write elementary apps in Vala (2014) by Yoric on Saturday September 10, 2022 @08:43AM (#32790106)
Funny, because I feel that affine types make me much more productive in Rust :)

Comptime would be nice to have, though!

Re:Why we write elementary apps in Vala (2014) by Kukumber on Sunday September 11, 2022 @08:13AM (#32798969)
So they made Swift and slapped a new name to it
Re:Why we write elementary apps in Vala (2014) by ceceron on Sunday September 11, 2022 @11:48AM (#32800631)
Exactly my thought. Looks like a poor man's swift (poor because many features from Swift are still only in planning).

The one difference is that jakt is transpiled to C++ (IMHO it's a disadvantage, but could be useful).

Re:Why we write elementary apps in Vala (2014) by mythz on Sunday September 11, 2022 @10:16PM (#32805293)
Obviously Swift is going to have more features given Lattner started first developing it in 2010, but it's built on flawed foundation given many years after release valid syntax would kill both the compiler and bring down Xcode as well.

Having experienced compiler engineers from the start is important for how well designed the language is syntactically and how strong its foundation is which helps with correctness and development velocity. Swift is always going to be the primary choice for Mac/iOS Apps but it sees relatively little usage elsewhere, either way it's going to be interesting to track Jakt's progress given how well designed it is and how fast they've been able to develop it.

Re:Why we write elementary apps in Vala (2014) by forgotpwd16 on Saturday September 10, 2022 @04:07AM (#32788804)
>was created to make creating GUIs more pleasant

Checking through the repo and videos, I don't see how this is the case. It seems a pleasant language but there isn't something GUI specific. That said the last one seems to have an issue frequently attributed to Rust, specifically requiring much effort to wrap an "unsafe" library for usage on "safe" language.

Re:Why we write elementary apps in Vala (2014) by mythz on Saturday September 10, 2022 @04:39AM (#32788933)
In his videos Andreas mentions the motivation for creating Jakt was wanting a safe productive language for developing SereneityOS and its GUI Apps for the long term future as he didn't believe the trajectory of C++ was going to be suitable and found other languages unsuitable for adoption in SerenityOS so he teamed up with JT to create a new one without C++'s unsafe footguns, initially transpiling to C++ so it's easily integrated into SerenityOS build system and able to access their existing C++ libraries.

They're still actively developing inheritance support which I believe is the last remaining feature before they can start creating SerenityOS's (OOP) GUI Apps with it [1].

[1] https://youtu.be/47svsnd7HIQ

Re:Why we write elementary apps in Vala (2014) by Dylan16807 on Saturday September 10, 2022 @03:30AM (#32788648)
Any idea what kind of effort it would take to get Jakt working on another OS?
Re:Why we write elementary apps in Vala (2014) by mythz on Saturday September 10, 2022 @03:36AM (#32788674)
It already can, as it currently just transpiles to C++ it just needs clang to build [1].

Even though it doesn't require SerenityOS, even SerenityOS GUI apps can be ported to run on Linux, Andreas already has ported its Ladybird Browser that wraps SerenityOS LibWeb engine in a QT App [2] to Linux, his last video shows "Abstracting the event loop so Ladybird can be fast & responsive on Linux" [3]

[1] https://github.com/SerenityOS/jakt#usage

[2] https://github.com/SerenityOS/ladybird

[3] https://youtu.be/S8lXroxngYo

Re:Why we write elementary apps in Vala (2014) by YesWeWill on Saturday September 10, 2022 @03:33AM (#32788659)
They're making it as a transpiler to their dialect of C++. On other OS it can also work because they have the Serenity Browser engine running on Linux. So probably take some parts of the build chain there and off you go.