Live data from Hacker News

Borgo is a statically typed language that compiles to Go

github.com

501–510 of 559 posts

Re: Borgo is a statically typed language that compiles to Go

#501

Earlier quoted context omitted.

Your comment could have been a nice opinion that proves to a drive-by reader that needs can differ drastically between programmers. But you ruined it with "fancy things" which shows offhand disregard and disrespect. A question like "what do you need these features for?" would have been a better contribution to the forum.

I actually really have a disrespect for them. I'm in a constant fight against developers that want to translate code in almost the same code but "only using language features from the Advanced book". I also wanted to add that I used inheritance only ONCE in all my years of writing Python in all other millions of lines of code inheritance was not the best solution. This is my daily struggle as a CTO. People using waaa…

    > This is my daily struggle as a CTO
This is a nice humblebrag. Why does it matter that you are a CTO for this comment? It doesn't. It would better written as: "This is my daily struggle with my team."

Re: Borgo is a statically typed language that compiles to Go

#502
post #496

Earlier quoted context omitted.

And you're panicking because the other commenters haven't helped recover for you. Try as you might, sadly they are not here to catch you. No need to throw a fit over it. You are not as exceptional as you think you are.

Dude you tried, there’s no need for 50000 word essay against a sentence

The output of software cares not for whether it be a sentence or even just a word. The output of software has no care at all. What lead you to believe otherwise?

Re: Borgo is a statically typed language that compiles to Go

#503
post #450
post #317

Earlier quoted context omitted.

Because if err != nil { return err } repeated all over the place, is the epitome of productivity!

It's a tradeoff. Alternatives like exception handling make control flow less obvious and shorthands like the ? operator lock you into a specific return type (Result in the case of Borgo or Rust).

What's bad about locking the programmer into using Result or Option? These are enough for many common use cases, and anyway, you're free to use something else and unwrap it manually.

Re: Borgo is a statically typed language that compiles to Go

#504

Earlier quoted context omitted.

libraries, and I thank God I don't have to work on Windows and thus don't know how smart Visual Studio Enterprise is, but IJ is world class in the number of bugs it'll catch

What? You don't have to work on Windows with .net either and there is an IntelliJ IDE for C#.

Apologies, I meant to draw the Windows distinction due to VS Enterprise, since I doubt very seriously VSE runs elsewhere (I'm aware of 2022 for Mac but it doesn't cite its "feature level"). Since I'm not a .NET-er, nor a VS-er, I can't say how smart their top-tier IDE is with their in-house language in order to have an apples-to-apples bake-off

Re: Borgo is a statically typed language that compiles to Go

#505

Earlier quoted context omitted.

The ? Operator in Rust?

More than just that, Result in general also prevents from accessing the value when there is an error and accessing an error when there is a value.

The absence of that safeguard in Go is a feature. It's used when the error isn't that critical and the program can merrily continue with the default value.

Of course, this is also scarily non-explicit.

Re: Borgo is a statically typed language that compiles to Go

#506

Earlier quoted context omitted.

The idea that error handling is "not part of the code" is silly though. My impression of people that hate Go's explicit error handling is that they don't want to deal with errors properly at all. "Just catch exceptions in main and print a stack trace, it's fine." Rust's error handling is clearly better than Go's, but Go's is better than exceptions and the complaints about verbosity are largely complaints about having…

> The idea that error handling is "not part of the code" is silly though. My impression of people that hate Go's explicit error handling is that they don't want to deal with errors properly at all. "Just catch exceptions in main and print a stack trace, it's fine." I'm honestly asking as someone neutral in this, what is the difference? What is the difference between building out a stack trace yourself by handling err…

> What is the difference between building out a stack trace yourself by handling errors manually, and just using exceptions?

You cannot force your dependencies to hand you a stack trace with every error. But in languages that use exceptions a stack trace can be provided for "free" -- not free in runtime cost, but certainly free in development cost.

Re: Borgo is a statically typed language that compiles to Go

#507
post #370

Earlier quoted context omitted.

True, as a non-native speaker: naming variables in a native language (that's not English) is objectively bad.

So if you have a concept that doesn't have an equivalent in English you just kinda translate it and add a comment for other people of your language to understand what it is?

You could also transliterate it into the English alphabet. Looks ugly but saves you from having to switch your keyboard layout.

Re: Borgo is a statically typed language that compiles to Go

#508
post #323

This looks like an interesting sweet spot. Rust is often praised for the borrow checker, but honestly I really only like rust for the type system and error handling. Go is praised for it's simplicity, but hated for it's error handling.

You can get Rust's type system in most ML derived languages, some of them even go beyond what Rust is capable of today.

Could you share a bit more?

Re: Borgo is a statically typed language that compiles to Go

#509
post #323

This looks like an interesting sweet spot. Rust is often praised for the borrow checker, but honestly I really only like rust for the type system and error handling. Go is praised for it's simplicity, but hated for it's error handling.

You can get Rust's type system in most ML derived languages, some of them even go beyond what Rust is capable of today.

Can you give some examples?

Re: Borgo is a statically typed language that compiles to Go

#510
post #442

Earlier quoted context omitted.

> Go is a very opinionated language from it's inception. True. > We could probably argue for all eternity about code formatting, for instance. But Go went and set it in stone. This is part of the story that Rob Pikes uses to justify how opinionated Go is, but it's a bit stupid given that most language do fine and I've never seen any debates about the code formatting after the very beginning of a project (where it's a…

> most language do fine No, they don't. Most languages turn dealing with code formatting, into an externality foisted upon either: • the release managers (who have to set up automation to enforce a house style — but first have to resolve interminable arguments about what the given project's house style should be , which creates a disincentive to doing this automation); or • the people reviewing code in the language.…

Ironic given how much effort is going into Bazel remote build executors.
Post reply on HN