Readit News logoReadit News
xwowsersx · 2 years ago
The general negativity and tone of "tell me precisely what the point of this is right now!" in the comments here deviates so completely from the spirit of play, tinkering, and experimentation inherent in the hacker ethos, at least as I see it, and I'm really disappointed to see it here. You can have your qualms with this language, you might feel personally overloaded by languages at the current moment, maybe you even have legitimate questions about the intended audience of this language — fine. None of those feelings or questions justify the kind of rude, interrogatory "How dare you do this! Show me why I should care!" attitude reflected in many of the comments here.
lhorie · 2 years ago
Adding my two cents of positivity:

I love seeing language projects that implement their own compiler backends. There really aren't enough of these around. Anything that helps bridge the knowledge gap between newbies and production grade compilers is a net positive in my books.

And extra brownie points for writing it in C. Think whatever about memory safety and language age but C code is abundantly explicit about what's going on with the code, which is something I really appreciate when approaching some new code to learn stuff.

__loam · 2 years ago
I think it's pretty fair to ask the question of "why should I use this?" I don't think it's rude to ask what this offers over other systems languages like Rust, Nim, Zig, or Go. All of those languages have been around for a while now and have some ecosystem and inertia. This language is claiming to bring back the joy of programming but frankly it looks like another c like language. Do we really need that?

It's an impressive project for one person to make but if we're talking about it as a prospective general purpose language, that naturally invites comparisons and criticism. I haven't read the comments but I think most people have good intentions when they share their view on this project and aren't personally attacking the author.

xwowsersx · 2 years ago
I have no problem with genuine questions like "Who do you think should or would use this?" That's not what I'm addressing.
corethree · 2 years ago
What also pisses me off is fake excessive positivity. If there are genuine things that are bad or negative people should feel free to voice those opinions even if it hurts someones feelings.

Facts and truth are more important then feelings. We shouldn't lie or be fake just to cater to someones feelings. Ultimately the truth is better in the long term.

Because this is a real thing. Who would use this when there are other more popular languages out there that have basically the same syntax? What does this language excel at above all others ? If the author wants his language to have any chance or shot at real success he needs to address this.

If we just took your advice and didn't be negative in the spirit of "tinkering", "play" and "experimentation" then ultimately that advice is more poisonous than the negativity. You need to identify and test your product for it to be successful. Your advice is to blind him.

Seriously just looking at the web site my first thought was why wouldn't I just use python?

throwaway17_17 · 2 years ago
To answer your last question first: Nature seems to be an ahead of time compiled language with direct memory access vs. python’s being an interpreted strictly GC’d language. So the immediate conclusion would be, you would not use Python in a performer critical environment, i.e. game engine development for modern 3d video games (an area the author has commented several times is a personal use case).

Also, you are assuming some desire by the language designer to have the language be successful (whatever that may mean). One of the stated goals to raise user’s “joy” when programming. I think taking on a challenging problem and crafting a personally desired solution, and doing so well from a brief look at the implementation, is certainly something, that sounds like the kind of activity that could provide a great source of enjoyment/fulfillment/…. So a programmer developing a language they like and enjoy, then wanting to share that makes sense.

The main negatives I have seen expressed are ‘there are already too many programming languages, why add another, that’s a waste’ or ‘what is going to sell this language, the docs don’t make a big sales pitch’, etc. I have not seen any real criticism addressing the semantics and other than some mentions of significant white space vs. curly braces, I haven’t seen criticism related to the syntax.

So, if your negatives, which are so much more important than feelings or if the truths you referenced are substantive criticisms of the actual artifact, I would say lay them out and maybe have a conversation. But I don’t see anything substantial, just complaints about a person pursuing something they choose to pursue and making, what seems to be, a darn good effort in the process.

weiwenhao · 2 years ago
I'm not entirely sure if Hacker News scoring system includes a boost for comments, but it seems that controversy and criticism are not necessarily bad things. They may actually help keep the post on the front page for a longer period of time.
raytopia · 2 years ago
Wish there were online communities without that attitude and snark but it seems nearly everywhere.
gorjusborg · 2 years ago
My guess is that the snark comes from unhappiness, which strongly correlates with percentage of time spent online, which strongly correlates with probability one posts.
yungporko · 2 years ago
this is most responses to anything anybody makes on here, it's a reddit-tier cesspit.
booleandilemma · 2 years ago
I don't know. I feel like the language space is very crowded right now.

While that's a great thing for everybody, it does mean if you're going to be pushing a new language, you need to be clear about what sets your language apart from the dozens of others clamoring for attention.

weiwenhao · 2 years ago
I'm the creator of the Nature programming language, and I'm incredibly thrilled to see my project featured on the front page of Hacker News. I've been developing this project in my spare time; initially, I focused on building the compiler back-end, which is something I'm deeply passionate about. That alone took me roughly 3 years of part-time effort. Only in the past year have I started to design and implement the front-end of the programming language.

I'm not one to give up halfway, and even though breaking into the programming language market is exceedingly difficult, I'm still committed to investing my enthusiasm and time into making this work.

The first goal for Nature right now is to reach a minimum viable product stage. The second goal is to "stand on the shoulders of giants"(go/rust). The third goal is to incorporate more innovative ideas and possibilities.

Even if Nature doesn't gain a user base, I will still use it to build interesting things.

starkrights · 2 years ago
Hey, that’s a neat story! Genuinely, I’m not trying to be sarcastic with that- but you didn’t answer his question at all.

What’s the point? Your goal is an “MVP stage”- what is your MVP? What are the minimum requisite features that are the core features of the language, and why are they important / better than any other languages, and in what specific ways?

If the answer is just “because I like these syntax/feature choices and i just want to make a language, that’s okay- you’re allowed to do whatever you want on the internet lol- but answer the original question directly and specify it as such.

The goals “get an MVP”, “stand on the shoulders of giants” and “innovate”, mean and say literally nothing- it’s just a smash of buzzwords that says nothing about your intents. They translate literally to “I want to make my thing work”, “i vaguely want recognition for being like xyz things”, and “I want to make it have more things”

What does “make it work” mean? Why does “be popular like rust and go” matter to anyone/what does it mean for your product? Why are you talking about innovating more things when you haven’t even told us what the first thing is?

These questions aren’t meant to be mean / dismissive- you made a programming language, and that’s cool (to me at least!) I wanna know!! If you want to stand on the shoulders of giants, you have to know what you’re doing- or if you do, be able to explain it lol.

Mountain_Skies · 2 years ago
Something to consider to get some attention: start a Nature leaderboard for Advent of Code in December. Lots of people who participate in AoC are looking for a new language to learn while solving each day's problems.
UncleOxidant · 2 years ago
What was the main problem you were trying to solve with Nature? What did you find missing in other languages that motivated you to create Nature?
klyrs · 2 years ago
Not every language needs a marketing department. This looks like a fun project.
ljm · 2 years ago
From another perspective, I think designing and building your own programming language is an incredible way to gain depth of knowledge and not simply breadth.
bwanab · 2 years ago
I agree. Tell me what motivated the language. What does it do that other languages in the same space don't do well?
rdevsrex · 2 years ago
That's true, but not every language has to cater to the whims of industry. Sometimes it can just be for fun.
zubairq · 2 years ago
Totally agree. I wish that new languages would state the 3 things that are unique about them
nmz · 2 years ago
if ++languages>1500 { error "too many languages" }
donpdonp · 2 years ago
The syntax choices are really nice here. It has a lot of what I would pick for a language. The one-liner test cases are awesome, <> for generics is comfortable since I use rust, sum types like elm are awesome. If I were to add something (well take it away really) its to use whitespace for array element separators. Eliminates the whole trailing comma issue and looks cleaner, though I admit it might create parsing ambiguities. 'try expr', returning (val,err) is curious and I think I like it better already than try {} catch {}.
munificent · 2 years ago
> If I were to add something (well take it away really) its to use whitespace for array element separators. Eliminates the whole trailing comma issue and looks cleaner, though I admit it might create parsing ambiguities.

Indeed:

    var array = [
      5
      - 3
    ]
Does that produce [5, -3] or [2]?

jrajav · 2 years ago
I've sometimes wondered why not make `-` whitespace dependent to resolve this one. Signed numbers store the sign bit in their representation, so enforcing the sign character to be in the same word also seems reasonable - and is there anyone who would mind actually having to put at least one space around binary arithmetic operators? We've all agreed that that's the sane way to write them by now, yes?
dmoy · 2 years ago
Or ["5", "-", "2"] even
archargelod · 2 years ago
> If I were to add something its to use whitespace for array element separators. Eliminates the whole trailing comma issue...

I like how Nim solves this problem: just allow trailing comma on last element. It makes easier to copy paste elements, move them around and even sort (e.g. in vim).

```

var list = @[

  a,

  b,

  c,
]

```

KerrAvon · 2 years ago
Using the C for loop syntax is looney tunes, though. Do range support and leave that 70's stuff in the dust.
donpdonp · 2 years ago
its got 'for k in list {}' (https://nature-lang.org/docs/the-basics/control-flow#iterati...) though array.for_each(lambda) is a better way to go, imho.
tikhonj · 2 years ago
The Nix language uses whitespace in lists and I'm not the biggest fan—it works well when list elements are simple expressions (individual identifiers, numbers... etc) but gets awkward and confusing if you want to have more complex expressions. It's worse in Nix because Nix also uses whitespace for function application, so even function calls require extra parentheses, but I'm not a fan of it in any non-Lisp syntax I've used.
irq-1 · 2 years ago
I'd like: drop 'try' and always allow and error to be returned, and ignored or checked at the users discretion. Optionally add "@error" or such, and let the tooling add or remove the annotation.

An FFI like luajit is asking alot, but inspired by it would be nice.

ozyschmozy · 2 years ago
The one liner test cases drew my attention as well, it's pretty neat. Does any other language provide this sort of thing? I guess it wouldn't be hard to implement decorators for this in python
zoogeny · 2 years ago
I like the feel of the syntax on first glance.

I have been thinking recently that all of the new powerful features showing up in language (Typescrpt, Go, Rust, Elixir, Kotlin, etc.) have been exposing programmers to combinations of programming language features that were not widely available before. I mean, I grew up with Pascal, Basic, C/C++ and Lisp but kids these days are growing up with Python, Typescript, Rust, Go, Haskel, Kotlin, Dart, Swift, C#.

Specifically I was thinking about how I avoid classes now for almost all of my code. I used to be a OOP first guy. Now I want value semantics and abstract data types. I have always hated exceptions (or any non-local control flow in general) and I love guards and defer-like semantics. I love the idea of CSP and Erlang but I also want full low-level control of bits. I want custom allocators and no GC, except maybe when I want a GC for some reason.

I love that people are just experimenting by taking the bits and pieces they like from the multitude of available high-quality languages and they are mixing them up into strange new soups.

giancarlostoro · 2 years ago
I do dream of some serious Erlang alternative that runs on its own without needing an entire runtime, but in all honesty Elixir / Erlang are insanely optimized, it blows my mind. I think I'm too used to the C#'s and Pythons of today, I too used Basic and a little bit of Pascal back in the day. I'm always excited by D but it gets overshadowed by Go and Rust it feels like, despite having really good features and a familiar syntax for anyone coming from C# / Java / C-like languages in my opinion.
zoogeny · 2 years ago
I'm glad you mentioned D and I literally paused while writing the above to consider if I should include it. Back when I was writing a lot of C++ (decades ago now) my greatest hope was that D would catch on. It is hard to say why it didn't and I think all of the hype on the C++ successor goes to Rust these days. Zig is probably the most likely candidate for a C replacement even though D has a subset termed as Better C.

It really is the case that there is an endless list of programming languages now that serve as inspiration for almost every use case. I mean, I didn't even mention Clojure or Julia or Lua ... the list of truly interesting language and approaches is almost endless.

drannex · 2 years ago
I don't think you can have a serious Erlang alternative without an entire runtime, but if you are interested in the (better) C-style syntax, then you miht be interested in Gleam[1] which is a seriously cool Erlang based language that is built with standard styling and ideas (type-safe, concurrency (actor-based), C-style, immutable, you can even compile out to javascript and run in the browser)

Think Elixir, access to the entire Erlang VM (and any other language/package built on it) with the syntax of C and you are there.

[1] https://gleam.run/

Too · 2 years ago
I like the feel of the syntax, short, concise, clear, powerful and understandable even on first read. Combining the best of all worlds together.

Is that enough to give up the ecosystem from any other more established language? Most likely no.

For this to take off, it needs seamless interop with some other more established language or it needs to have some other major unique selling point. Rust had borrow checker. Go had goroutines. Both backed by big companies btw. Just 10% better syntax or 10% faster speed, without an ecosystem behind, is not going to be enough to tip anyone over, except the curious hobbyist explorers.

Hopefully some ideas from here will spread to other mainstream languages.

kuchenbecker · 2 years ago
I use classes as syntactic sugar to a pure functions. People like their objects, but if you treat them as immutable struct data everyone is happy.. well at least less unhappy.
Leo_Germond · 2 years ago
If you care about visibility control and minimalistic API design, then the most basic OOP features also provide a set of simple but powerful features: encapsulation, and contextual info on overload resolution (A.foo() is the foo() from A's type, no just any foo that can take A)
johngossman · 2 years ago
There is a 1963 RAND paper where they considered whether it was time to standardize on a programming language (Not yet, was their conclusion). It contains one of my favorite quotes: “About the same time, however, a further complicating factor arose--the designing of programming languages became fashionable. Now the proliferation of languages increased rapidly as almost every user who developed a minor variant on one of the early languages rushed into publication, with the resultant sharp increase in acronyms. In addition, some languages were designed practically in vacuo. They did not grow out of the needs of a particular user, but were designed as someone's "best guess" as to what the user needed (in some cases they appeared to be designed for the sake of designing).”

Personally, I find nothing wrong with designing for the sake of designing.

johngossman · 2 years ago
One thing I miss about the Internet of just a few years ago is that such papers were freely available. Alas, now behind a paywall.

https://www.rand.org/pubs/research_memoranda/RM3447.html

gloria_mundi · 2 years ago
It is, of course, still freely available if you plug the title into your favourite search engine.

From the US Defense Technical Information Center: https://apps.dtic.mil/sti/tr/pdf/AD0296046.pdf

Also in the Internet Archive: https://archive.org/details/DTIC_AD0296046

The mentioned quote is on page 22.

munro · 2 years ago
A pleasant little language, it looks like weiwenhao started working on it back in 2021. It looks great!

I couldn't find anything novel the programmer wanted to try out in this language-- seems like they just want to capture the zeitgeist, and condense it into a simpler form.

It does make me wonder, how many other interesting languages are programmers toiling on out there? Wish there was a way to sort by newest repo, but this does start revealing some interesting underground langs:

https://github.com/topics/programming-language?o=desc&s=upda...

lifeisstillgood · 2 years ago
I have a joy of programming in bash. Another language might be fun but the real joy lies in expressing oneself, solving a problem, getting the bon mot - its past bedtime and I have for the first time in a year found myself doing salaried work after hours for the fun of it
askiiart · 2 years ago
I started programming I'm bash a few months ago, and also found it enjoyable. But the part I found enjoyable wasn't just programming in bash. The part I loved was making scripts to automate all kinds of stuff and make my life easier—automate updating my yum repo, automate building my Docker images, make some install scripts for whatever I need when I distrohop, and little scripts to backing up and restoring my dotfiles.

If another language/shell, like zsh or fish was the preinstalled default, I'd program in that instead, but because of its basically-universal install base, I program in bash.

dtgriscom · 2 years ago
Oh, yeah. Bash rules. (Perhaps because I don't know zsh or fish, but hey! it rules for me.)
lifeisstillgood · 2 years ago
I guess I meant joy, even in something like bash... the joy lies in coding not in the language
dindobre · 2 years ago
Allow me a shallow opinion since we are in "joy of programming" territory: after python anything with curly brackets feels "uh". Give me python with typescript typing
qwerty456127 · 2 years ago
After any good functional language like F# or Scala (also CommonLisp but it's less straightforward to start doing meaningful practical things in), anything else feels uh. My first experience with Scala was a shock about how concise and how bug-free programming can actually be. You just write what you mean and as soon as it builds successfully, it works and does what you expected it to do. Scala is easier to start with for those accustomed to the curly braces style languages and allow limitless expression. F# looks and feels more cool (although less familiar/intuitive for the majority, necessarily requiring some introduction) anyway and doesn't incentivize wizardy. To me F# essentially feels like "better Python" while Scala obviously is "better Java".

Any good interactive visualization or gpio library also opens another dimension of joy. QuickBASIC with LPT (which did the GPIO's job back in the days) access and drawing functions was a lot of joy already.

I am going to give this Nature language a try anyway. It indeed doesn't look super special at the first glance so it probably has some meaningful coolness hidden deeper - this is intriguing.

throwaway_08932 · 2 years ago
Nim does basically this.
Uptrenda · 2 years ago
Nim looks beautiful and seems to have impressive platform support already. Good taste / 10.
cies · 2 years ago
I hear you. I like Elm, Haskell and Ruby for syntax, as a personal preference, and no curlies-for-scoping.

But then I think the language models/paradigms are more interesting about these languages.

Too · 2 years ago
Typescript and Python actually have very similar typing models already. Given you run it through mypy or pyright of course.

Anything in particular you were thinking about missing?

Deleted Comment