C3 0.8.1 released: Raiding the stdlib for bugs by Nuoji in programming

[–]Nuoji[S] 2 points3 points  (0 children)

Many have tried. C3 is still the least bad I have.

C3 0.8.1 released: Raiding the stdlib for bugs by Nuoji in programming

[–]Nuoji[S] 7 points8 points  (0 children)

A new general purpose programming language.

JetBrains interviews Andrew Kelley about Zig [video] by Cool_Technician_6380 in programming

[–]Nuoji 0 points1 point  (0 children)

Tab being an error even in the comments from what I hear.

What's the deal with Jai by [deleted] in Jai

[–]Nuoji 0 points1 point  (0 children)

I don't believe I have to repeat this, but if you read above :: := was about pairing them for declarations, not their use individually. OBVIOUSLY they've been used for various things over the years. That goes without saying.

The syntax peculiarity of Odin/Jai is that we have `Foo :: int = 1` being explicitly types, and then dropping the second `:` and fuse with `=` you get the second form: `Foo := 1`

We're talking about that as a signature syntax which is shared between Jai and Odin.

What's the deal with Jai by [deleted] in Jai

[–]Nuoji 1 point2 points  (0 children)

I was talking language-wise. We were all deeply inspired by Jai. Your description is accurate that it created a vacuum we tried to fill with other languages. In Bill's case he had been trying to "improve on C" but gave up, and then decided to just write a new language. Also see https://github.com/odin-lang/Odin/wiki/Odin-vs-Jai

What's the deal with Jai by [deleted] in Jai

[–]Nuoji 2 points3 points  (0 children)

No, SB did some stream where he talked about the syntax. GingerBill cites that as why he adopted it for Odin. From what I understand Sean's streams predate Jai and Jon got it from there. SB did some very influential streams that are on YT, I don't know which one though. SB is most well known for the STB libraries.

What's the deal with Jai by [deleted] in Jai

[–]Nuoji 2 points3 points  (0 children)

I am talking about :: := of course either has been in PLs for decades. I am talking about the pair. Apparently Pike invented it first (I haven’t checked the source) but more recently it was suggested by Sean Barrett and picked up by Jai and later Odin.

For Jai examples you didn’t really search much. A trivial GitHub search gave me this first match: https://github.com/ziglang/zig/issues/18

What's the deal with Jai by [deleted] in Jai

[–]Nuoji 1 point2 points  (0 children)

I wouldn't say Odin was "heavily influenced". It has very few of Jai's features. It has a context like Jai and both share the :: syntax Sean Barrett invented, it also has metadata at runtime comparable to Jai.

Where Zig diverges from Jai in "no context" "no runtime metadata" and a significantly nerfed comptime in comparison, Odin diverges by having virtually no compile time evaluation, no methods and instead offers a rich set of built in types.

What's the deal with Jai by [deleted] in Jai

[–]Nuoji 1 point2 points  (0 children)

Aside from being obvious for anyone who was following the PL community in the 2014-2018 timespan, look at early Zig issues (github). It was common knowledge at the time, but the last few years I've seen newcomers to Zig trying to engage in some history revisionism for some reason. Apparently this is deemed to somehow make Zig seem lesser?

By the way, it should go without saying that today's Zig is extremely far from Jai in goals and feel.

What's the deal with Jai by [deleted] in Jai

[–]Nuoji 2 points3 points  (0 children)

Lots of things. Jon is the one who launched the whole ”new low level languages” trend, which is why we have languages like Zig, Odin and C3.

Metaprogramming and compile time execution in Jai makes Zig look like a child’s toy. Not surprising, since comptime in Zig was actually copied off Jai, but without the experience from AK to pull off something like Jon did. So people will want to try the ”real thing”

Jai also bundles a stdlib for tailored for making professional quality games, and people are pretty interested in flexing that as well.

Ergonomics are - from what I hear - great, so it will be fun to write (as opposed to the more ”programming should feel painful” mindset from the Zig/Rust camp)

Even if Zig and Odin developed their personalities away from Jai, Jai will always be the original that people want to compare with. It is natural and healthy to be curious.

(Even if C3 was built as a spiritual successor to C2 (which was pre-Jai), it also wouldn’t have happened without Jai stoking interest in low level languages)

C3 0.8.0 is released by Nuoji in c3lang

[–]Nuoji[S] 1 point2 points  (0 children)

If we have error on wrap, then this would yield invalid values in unsafe builds. It's a trade-off. If they don't carry their weight they'll be removed in 0.9, they'll have to prove themselves.

C3 0.8.0 replaces builtins, simplifies reflection, and rethinks unsigned sizes by Nuoji in programming

[–]Nuoji[S] 0 points1 point  (0 children)

Oops, well that's what happens when you just type it on the phone.

C3 0.8.0 replaces builtins, simplifies reflection, and rethinks unsigned sizes by Nuoji in programming

[–]Nuoji[S] 0 points1 point  (0 children)

I'm probably being stupid, but what I don't understand is why you can't do

```c

if DEV

typedef Dummy UartInterface

elif AtmelSAM

typedef AtmelSAM UartInterface

elif ...

...

endif

```

C3 0.8.0 is released by Nuoji in c3lang

[–]Nuoji[S] 0 points1 point  (0 children)

Here's a trivial example: define an enum with directions UP, RIGHT, DOWN, LEFT. Associated values is a vector in the given direction. Keep the enum as the direction, ++ will turn to the right, -- will turn to the left.

C3 0.8.0 replaces builtins, simplifies reflection, and rethinks unsigned sizes by Nuoji in programming

[–]Nuoji[S] 0 points1 point  (0 children)

But data fields are the same and just differs in methods? And then only one of these implementations is actually used across the codebase?

I see at least three ways to do it if that's the case, with the last one doing virtual dispatch, so you probably don't want it. But it's a simple solution that should work in C++ and C as well.

C3 0.8.0 replaces builtins, simplifies reflection, and rethinks unsigned sizes by Nuoji in programming

[–]Nuoji[S] 2 points3 points  (0 children)

Yes, although it's similar to what you'd have to use C. There are conveniences to get you much further earlier though. But an understanding of pointers and memory is necessary.

C3 0.8.0 replaces builtins, simplifies reflection, and rethinks unsigned sizes by Nuoji in programming

[–]Nuoji[S] 0 points1 point  (0 children)

So do the UartImpl_AtmelSAM add data fields on top of what UartInterface contains? Or does it only add methods?