Live data from Hacker News

Show HN: Ki Programming Language

github.com

51–60 of 80 posts

Re: Show HN: Ki Programming Language

#51

> let num : u8 = 5; Can we please knock it off with reinventing different ways to declare a variable? This also irritates me about Rust. There’s nothing wrong with having syntax that looks like languages that have existed before. How about [modifiers] [type] [variable name] = [initial value]; What I want in a programming language is not arbitrary new grammars, I want drop-in improvements to languages that already exi…

"let bindings" were present in ML in the 70s; I'm not sure whether they originated there or go back further. They've been used in many languages since, particularly those drawing on ML as a significant inspiration. It's not new, it's just borrowing from something you're unfamiliar with.

Re: Show HN: Ki Programming Language

#52

Reference counting is garbage collection. I mention this because the site claims no GC nut you claim I'm this thread that ref counting is sometimes used, which makes sense because borrowing sometimes isn't enough.

While reference counting is technically a method of collecting garbage, in modern parlance the phrase "garbage collector" is mainly used for systems capable of collecting garbage of an arbitrary reference graphs, which reference counting by itself cannot do (cyclic references).

Anyone worried about tracing garbage collection is worried about unpredictable costs of automatic reclamation. Even naive reference counting has unbounded pathological cases like this, like an infinite list with only one reference that dies, which triggers a cascade of infinite free ops.

You can do some gymnastics like various types of deferrals to amortise the cost, but now you're getting into more sophisticated tracing-like runtime behaviour which has it's own unpredictability.

There's no free lunch. Better static analysis that can aggregate various allocation into arenas/regions seems like the only way to make this trade-off better.

Re: Show HN: Ki Programming Language

#53
post #19

Earlier quoted context omitted.

V-lang doesn't have GC, and how it compares to it?

I think v-lang is faster than ki, rust, go. But their memory management isnt waterproof. Also, they have been in development for a really long time and there isnt much progress. They should have reached 1.0 by now, but they havent and i think it's because the language might have problems. oh and, v-lang does have GC. they use boehm gc.

[deleted]

Re: Show HN: Ki Programming Language

#54
post #34

Earlier quoted context omitted.

V-lang is vaporware, designed to get Patreon bux off of gullible enthusiasts. See this post [0] from 2019. Things don't seem to have got much better in recent years [1] [2] [3]. [0] https://xeiaso.net/blog/v-vaporware-2019-06-23 [1] https://news.ycombinator.com/item?id=20230351 [2] https://news.ycombinator.com/item?id=20229632 [3] https://news.ycombinator.com/item?id=31793554

I've got no particular interest in V, but the hate it gets from a certain group of people here is really perplexing and I don't think it's at all warranted from what I've seen.

I've had similar sentiment when I first seen V. However, after a brief and unpleasant conversation with the developer who was extremely defensive against any, even valid, criticism - especially related to the false advertising! - made me change my mind. Alex knows very well what he's doing, he's a grifter who is collecting money off of smoke and mirrors, and his language still hasn't reached any remotely usable state.

Re: Show HN: Ki Programming Language

#55
post #3

Confused by the "C#: We do not use languages that expect you to install a 20GB IDE just to compile a 'hello world'." note, the .NET SDK is ~200MB last I checked, and Visual Studio is not required to compile C#. Seems like the https://ki-lang.dev/dist/download/linux/x64/latest build from Ki is ~40MB, so similarly sized.

i'll remove it ^_^ it seemed like they want you to use Visual studio and for me it was like 10GB+ for a minimal setup. idk.

That is the IDE, but it is not required for compiling. You should actually use C# .NET 6 and see what they are doing to prevent null exceptions. You must explicitly require the assignment of null or you will get warnings in the IDE and compiler. Here is an example:

public MyClass Students { get; set; }

You will need to create a new object before you leave the class or you will get an error. Or, you can use MyClass? instead, and it will give warnings any time you try to use Students without checking for null first. This is done before compiling so you can check for these null references through the IDE. This is a big change for C# and can effectively eliminate null references (object reference not set to an instance of an object) exceptions throughout your application.

Re: Show HN: Ki Programming Language

#56

Why would someone choose this over Rust?

at the moment, if you want a non gc language with automatic memory management, rust is your only choice. ki is an alternative, but my goal is to make it a much simpler than rust. I need to spend some more time writing rust & ki in order to answer your question with full certainty.

Re: Show HN: Ki Programming Language

#58

> let num : u8 = 5; Can we please knock it off with reinventing different ways to declare a variable? This also irritates me about Rust. There’s nothing wrong with having syntax that looks like languages that have existed before. How about [modifiers] [type] [variable name] = [initial value]; What I want in a programming language is not arbitrary new grammars, I want drop-in improvements to languages that already exi…

Types before the name have several problems. And "let" is, like, one of the most common ways to declare variables.

Re: Show HN: Ki Programming Language

#59
post #43

Another brand new language with curly braces and semicolons... emphasizing line noise over information /sigh OK, ok, I'll show myself out.

What would you suggest instead? Please do not say Python. Using spaces for syntax is madness.

You never make use of horizontal spacing when, say, making notes on paper?

Re: Show HN: Ki Programming Language

#60

> let num : u8 = 5; Can we please knock it off with reinventing different ways to declare a variable? This also irritates me about Rust. There’s nothing wrong with having syntax that looks like languages that have existed before. How about [modifiers] [type] [variable name] = [initial value]; What I want in a programming language is not arbitrary new grammars, I want drop-in improvements to languages that already exi…

As another commenter said, types before the variable has problems.

I don't like `let` because it's an extra four characters every time. But the

    [variable name]: [modifiers] [type] = [initial value];
only has one extra character and avoids all of the problems.
Post reply on HN