Live data from Hacker News

Ballerina Programing Language

ballerina.io

31–40 of 56 posts

Re: Ballerina Programing Language

#31
post #3

I have followed this language passively for ~1.5 years. I think it's revolutionary, and the big barrier for my adoption is the fact that I do not currently write services for the JVM. But the ability to define services as HTTP/Ingress endpoints, Docker containers, and Kubernetes/Openshift resources natively as part of the language is incredible. Add that to the fact that they have native support for things like tabul…

This is pretty cool: https://ballerina.io/v1-1/learn/by-example/docker-deployment...

Re: Ballerina Programing Language

#32

Earlier quoted context omitted.

The language has a lot of syntactic compromises, because it has a design goal of being familiar to users of C-family languages like C, JavaScript, Java, C#, etc.

I don't really buy that argument. Even Java has simple lambdas now, for example.

Ballerina has simple lambdas e.g. x => x + 1.

Re: Ballerina Programing Language

#33
post #7
post #3

I have followed this language passively for ~1.5 years. I think it's revolutionary, and the big barrier for my adoption is the fact that I do not currently write services for the JVM. But the ability to define services as HTTP/Ingress endpoints, Docker containers, and Kubernetes/Openshift resources natively as part of the language is incredible. Add that to the fact that they have native support for things like tabul…

I looked through examples and I don't see what's so revolutionary about it. This is specialized language suited for more or less one task that has nothing specialized for that task which cannot be rolled in Clojure in a day or two. Challenge me, give one example that can't be done as easily with Clojure.

I won't challenge you, but if you're looking for a Clojure/LISP language discourse you might be interested in what James Clark has to say about his language choices. James is behind Ballerina and was working on SGML and groff in his former life, had specified/implemented DSSSL, the transformation and stylesheet language for SGML based on Scheme, and later XSLT (based on his experience with DSSSL, although without LISP syntax).

Re: Ballerina Programing Language

#34
post #7

Earlier quoted context omitted.

I looked through examples and I don't see what's so revolutionary about it. This is specialized language suited for more or less one task that has nothing specialized for that task which cannot be rolled in Clojure in a day or two. Challenge me, give one example that can't be done as easily with Clojure.

Static typing

Love to get downvoted for something factually true that answers the explicit question above it

Re: Ballerina Programing Language

#35
post #5

So, the home page makes some big claims, but doesn't link to how Ballerina solves those issues. I'm not saying that it doesn't. I'm saying that it would be nice to have a link to what makes it different for that aspect. For example, "Structural, Open-by-Default Typing". It sounds really interesting, but the image next to it just looks like what you'd get in Go (except for nullability checks), C#, Kotlin, and many oth…

There’s lots of detail in the language spec:

https://ballerina.io/spec/lang/2019R3/

I also wrote a blog explaining what we are trying to achieve:

https://blog.jclark.com/2019/09/ballerina-programming-langua...

Re: Ballerina Programing Language

#36

I like the idea but I'm not impressed by the language. Syntactically there is a lot of noise (e.g. semicolons, function types are incredibly verbose). It seems to be missing generic types, pattern matching doesn't seem to express structural recursion, if is not an expression, etc. etc.

The language has a lot of syntactic compromises, because it has a design goal of being familiar to users of C-family languages like C, JavaScript, Java, C#, etc.

But several of the listed problems don't exist in many of the listed languages or close relatives (I wouldn't really call JavaScript C-family either, as, except maybe C-style for-loops, it has nothing that distinguishes C from other Algol-syntax languages, and other than Algol-style syntax it's more a blend of ideas from Lisp and Self than anything related to C), so those flaws cannot be necessary for familiarity to users of those languages (Java, C#, and several of JS’s statically-typed derivatives that are designed to be familiar to JS programmers, like TypeScript, have generics, so “missing generics” doesn't make sense as a familiarity compromise for users of those languages.)

Re: Ballerina Programing Language

#37
post #5

So, the home page makes some big claims, but doesn't link to how Ballerina solves those issues. I'm not saying that it doesn't. I'm saying that it would be nice to have a link to what makes it different for that aspect. For example, "Structural, Open-by-Default Typing". It sounds really interesting, but the image next to it just looks like what you'd get in Go (except for nullability checks), C#, Kotlin, and many oth…

There’s lots of detail in the language spec: https://ballerina.io/spec/lang/2019R3/ I also wrote a blog explaining what we are trying to achieve: https://blog.jclark.com/2019/09/ballerina-programming-langua...

Would be great to have that insight on the landing page. Most people (including me) will first make a judgement call looking at the landing page for a few seconds before deciding if they want to learn more and go through the specs & examples.

Re: Ballerina Programing Language

#38
post #23
post #5

So, the home page makes some big claims, but doesn't link to how Ballerina solves those issues. I'm not saying that it doesn't. I'm saying that it would be nice to have a link to what makes it different for that aspect. For example, "Structural, Open-by-Default Typing". It sounds really interesting, but the image next to it just looks like what you'd get in Go (except for nullability checks), C#, Kotlin, and many oth…

> For example, "Structural, Open-by-Default Typing". It sounds really interesting, but the image next to it just looks like what you'd get in Go (except for nullability checks), C#, Kotlin, and many other languages. Go types are structural. C# types are nominal. https://en.wikipedia.org/wiki/Structural_type_system "Open-by-Default" probably refers to the fact that structural types are more flexible to use.

>Go types are structural. C# types are nominal.

Go's type system is also nominal. If it were structural, it would allow you to have two types `type foo struct { id string }` and `type bar struct { id string }`, and let you assign a value of type `foo` to a binding of type `bar`, which it does not.

Re: Ballerina Programing Language

#39

Earlier quoted context omitted.

Static typing

Love to get downvoted for something factually true that answers the explicit question above it

I did not downvote you, but how is static typing in any sense revolutionary? It is certainly not a new concept and you know it, but your answer does not elaborate any of this at all.

It may be factual, but it is factually useless.

Re: Ballerina Programing Language

#40
post #7

Earlier quoted context omitted.

I looked through examples and I don't see what's so revolutionary about it. This is specialized language suited for more or less one task that has nothing specialized for that task which cannot be rolled in Clojure in a day or two. Challenge me, give one example that can't be done as easily with Clojure.

Static typing

Static typing is a property of the programming language, not something you "do". Do you mean your clients want static type something?

Static typing is a preference of the developer or development organization on whether they want speed or they need a bit of help to understand what they have before their eyes. It lets the compiler call you out on some of your transgressions at the cost of quirky type system and possibly having to need a bunch more code where a very simple solution would present itself when type system does not get in the way.

Static typing is neither bad or good. It "depends".

Post reply on HN