News for hackers. Stuff that matters.
Re:Typing Nix by atemerev on Friday June 23, 2017 @08:50AM (#14618744)
I love Nix. NixOS is my primary development operating system. However, the Nix language itself is syntactically ugly, and this proposal makes it even uglier. Parentheses, sigils and special characters (esp. semicolons) are line noise — the less of it the better.

Why they wouldn't take the most (syntactically) beautiful functional programming language out there — Standard ML? It would work perfectly for such a task. Or the second contender — Haskell. If C-like syntax is desired, the best contendant is probably Swift.

I cringe every time I have to edit a .nix file (and I have to do it a lot).

Re:Typing Nix by mbrock on Friday June 23, 2017 @10:24AM (#14619338)
I love the Nix language and I generally distrust aesthetic feelings about programming languages.

Neither SML nor Haskell are optimized for expressing deeply nested records with many string literals, for example. The multiline interpolated strings in Nix are extremely much better than in SML or Haskell. The way records and arrays are written is great: SML and Haskell both suffer from the tedious problem of using separators between items instead of after each one; in Nix each item can always be moved without messing with separators.

I think Nix is an engineering marvel up to and including the language design. If you can make a better surface syntax and demonstrate it by translating some significant part of Nixpkgs, I'd be very interested, but I think in general the language is the way it is because that's what made most sense for the system's designers.

Re:Typing Nix by codemac on Friday June 23, 2017 @11:44AM (#14619975)
> If you can make a better surface syntax

... http://gnu.org/s/guix

Lisp is pretty good at lists.

The only important language is the derivation language sent to the daemon. Nix spends so much time building up inputs... for shell scripts. I always felt like they would have been so much more successful if they chose some other, more popular language to generate derivation.

Re:Typing Nix by mbrock on Friday June 23, 2017 @01:11PM (#14620814)
I dig Guix, but Lisp is also one of the most commonly reviled syntaxes, so it's hard to say it's clearly better, or that Nix would enjoy more adoption with S-expressions.
Re:Typing Nix by wcummings on Sunday June 25, 2017 @11:49AM (#14630560)
Reviled by people who have never used it.
Re:Typing Nix by gkya on Friday June 23, 2017 @02:18PM (#14621394)
Most commonly and with lots ans lots of prejudice.
Re:Typing Nix by jancsika on Friday June 23, 2017 @06:47PM (#14623343)
Is it possible to write a guix package that includes code which redefines the package object?
Re:Typing Nix by codemac on Wednesday June 28, 2017 @06:39PM (#14659169)
Yes!

http://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/...

You'll see here that the package emacs-minimal actually inherits from the emacs package definition, and then all fields afterwards are essentially overwrites of whatever was in the emacs package.

Unfortunately, I just noticed that the manual alludes to this, but actually never explicitly documents it in the "Defining Packages" section :/

Re:Typing Nix by KirinDave on Tuesday June 27, 2017 @11:32AM (#14646319)
> Neither SML nor Haskell are optimized for expressing deeply nested records with many string literals, for example.

Purescript's extensible row types handle this process elegantly and if Nix takes a cue from that, it will work great.

Re:Typing Nix by qznc on Friday June 23, 2017 @02:16PM (#14621385)
So, JavaScript? The records literals are JSON, which is the most popular syntax for this at the moment anyways.
Re:Typing Nix by cwp on Friday June 23, 2017 @02:44PM (#14621641)
No, Nix syntax is much nicer than Javascript. Consider, for example, the similarity between a let expression and an attribute set (NOT JSON by the way):

  let
    foo = 42;
    bar = "a string";
  in {
    baz = "deja";
    quux = "vu";
  }
Javascript:

  const foo = 42;
  const bar = "a string";
  return {
    baz: "similar",
    quux: "but different"
  };
You find this kind of thing all over the place. Nix is a much smaller and simpler language syntactically, and more pleasant to write.
Re:Typing Nix by mbrock on Friday June 23, 2017 @02:57PM (#14621764)
Also, recursive definitions using "rec" which become nasty in JavaScript.
Re:Typing Nix by mbrock on Friday June 23, 2017 @02:34PM (#14621528)
I tend to write JavaScript that looks a bit like Nix... but in general, the imperative constructs aren't suitable to the lazy evaluation strategy of Nix.
Re:Typing Nix by pmahoney on Friday June 23, 2017 @11:03AM (#14619664)
I may be in the minority, but I like the Nix language.

I don't have extensive ML or Haskell experience, coming from Ruby/Java background.

I think the Nix language works great as a configuration language, and I greatly prefer it to JSON, YAML, or Ruby, which are often used for similar purposes. The way arguments are passed in, merging of attribute sets, the library from Nixpkgs with various list and set operators and other utilities, and great multiline string support make it far superior to those other config languages in my opinion.

My biggest gripe is that the Emacs mode isn't very strong, so I'm often applying indentation manually.

I recently learned about Jsonnet[1] which has some similarity with Nix.

[1] http://jsonnet.org/

Re:Typing Nix by dtwhitney on Friday June 23, 2017 @09:47AM (#14619094)
I could not agree with you more! I use nix daily, and every time I go to edit it a nix file a voice in the back of my head says, "you should really start that Haskell to Nix compiler you've been thinking about." [edit] ha! just notice the next comment talking about hnix. Great minds... :)
Re:Typing Nix by regnat on Friday June 23, 2017 @10:06AM (#14619224)
You might be interested in dhall[0] and dhal-to-nix[1] which provides a really neat haskell-like language that compiles to nix.

[0]: https://github.com/Gabriel439/Haskell-Dhall-Library [1]: https://github.com/Gabriel439/Haskell-Dhall-Library

Re:Typing Nix by atemerev on Friday June 23, 2017 @10:15AM (#14619276)
If only Haskellers knew that "a blog post" and "type definitions in Hackage" are not documentation...

Also, the comma-first syntax like

{ foo = "bar"

, baz = "qux"

}

drives me nuts. In the name of all good things in the world, why?

Re:Typing Nix by radarsat1 on Friday June 23, 2017 @10:44AM (#14619512)
> comma-first syntax

oooh but this is one of those trivial things that I really liked in my brief days of using Haskell, and that has sometimes carried over to my C++, e.g. in initializer lists. I find it super useful because everything lines up nicely, and from the point of view of version control you don't have to edit the previous line to change '}' to ',' when adding a new line.

Re:Typing Nix by weberc2 on Friday June 23, 2017 @12:23PM (#14620326)
Go solves this problem by permitting

    foo := Foo{
        x: 10,
        y: 24,
    }
Re:Typing Nix by mercurial on Friday June 23, 2017 @03:13PM (#14621925)
Also Perl, Python, Javascript and Rust.
Re:Typing Nix by weberc2 on Friday June 23, 2017 @05:56PM (#14623085)
JavaScript doesn't (didn't?) let you put a trailing comma in function parameter lists, annoyingly.
Re:Typing Nix by Arnavion on Friday June 23, 2017 @07:45PM (#14623590)
Made legal in ES2017.
Re:Typing Nix by teddyh on Tuesday July 04, 2017 @08:12AM (#14695369)
But not in JSON, since that is based on ECMA-262 3rd Edition from December 1999.
Re:Typing Nix by teddyh on Friday June 23, 2017 @03:10PM (#14621896)
Python does this, too.
Re:Typing Nix by coldtea on Friday June 23, 2017 @11:24AM (#14619800)
How about allowing for bloody danging commas?
Re:Typing Nix by wereHamster on Friday June 23, 2017 @11:54AM (#14620053)
Is there any real disadvantage to comma-first, other than aesthetics (which is entirely a personal preference)?
Re:Typing Nix by ykler on Friday June 23, 2017 @12:30PM (#14620413)
Yes, when the commas are at the beginning of the line they are really obvious. I have used commas-first style in JavaScript, and it definitely reduced the amount of times I forgot a comma.

I wonder if people's aversion to commas first has something to do with the fact that commas have a very familiar use in ordinary writing, and there they always follow a word. It is very common to see BNF grammars written with leading vertical bars, and no one seems to mind that -- in fact it would be unusual to use trailing vertical bars.

By the way, a bunch of languages permit a trailing comma after the last element of a list. This is also nice because it means that if you put each list item on a line, the list items all have the same format (thing plus comma). With the Haskell syntax, you lose this, but there is no reason a language couldn't support a leading comma before the first element of a list.

Re:Typing Nix by icebraining on Friday June 23, 2017 @01:28PM (#14620958)
My aversion has to do with the fact that the first element doesn't have one. The irregularity is annoying not just aesthetically, but also if you want to swap lines around, etc.
Re:Typing Nix by cwyers on Friday June 23, 2017 @03:55PM (#14622243)
But there's always a line without a comma -- comma-last has it on the last line instead of the first. So you can have the same line-swapping problem in either arrangement. Comma first just makes it easier to spot.
Re:Typing Nix by icebraining on Friday June 23, 2017 @04:19PM (#14622420)
But there's always a line without a comma -- comma-last has it on the last line instead of the first.

Not if the language allows trailing commas on the last line, like Python and Go do.

Re:Typing Nix by coldtea on Saturday June 24, 2017 @06:20AM (#14625104)
Not if you allow dangling commas (trailing commas as the sibling comment calls them, I think it's the more generic term)...

Then you have a comma at the end in ALL lines, including the last one, without an issue. That was what I proposed above (and lots of languages do it, I think JS is adding it too).

Re:Typing Nix by coldtea on Friday June 23, 2017 @12:40PM (#14620499)
The wrath of God that it imposes on people who think it's acceptable, for one...
Re:Typing Nix by weberc2 on Friday June 23, 2017 @12:30PM (#14620409)
It's another thing to learn, and the total learning curve is the product of all of these idiosyncrasies (and features) (not the sum). And there's absolutely no advantage to comma-first.
Re:Typing Nix by Jweb_Guru on Friday June 23, 2017 @02:29PM (#14621480)
It makes git diffs inaccurate compared to trailing commas.
Re:Typing Nix by mbrock on Friday June 23, 2017 @02:58PM (#14621772)
How so?
Re:Typing Nix by viraptor on Friday June 23, 2017 @09:19PM (#14623895)
Inserting a new element with comma-first changes 2 lines:

   - { old-one
   + { new-one
   + , old-one
While trailing commas allow you to insert an element anywhere with just one line addition.

This doesn't break anything, but it makes looking at "git blame" so much easier.

Re:Typing Nix by dragonwriter on Friday June 23, 2017 @09:37PM (#14623957)
This is only true if you insert at the head. And it's not really leading comma placement but the choice to put the first element in the line with the brace that is the culprit, though both are typical of comma-first.
Re:Typing Nix by viraptor on Saturday June 24, 2017 @05:20AM (#14624992)
With separating comma, it either affects the first or the last position, depending on where you put the commas. But those are the most common places you modify lists.
Re:Typing Nix by ben0x539 on Friday June 23, 2017 @10:42AM (#14619488)
Wow, I'm doing the opposite where I'm staring at all these other DSLs and configuration files and have to hold myself back from writing a bunch of nix to autogenerate them from.
Re:Typing Nix by nv-vn on Friday June 23, 2017 @02:53PM (#14621720)
Haha same here, I've been considering writing Nix expressions for window manager configurations for quite some time now, but some config files are so complex that it would take ages.
Re:Typing Nix by zimbatm on Friday June 23, 2017 @10:02AM (#14619199)
If I only look at the language properties then Nix makes sense to me. The fact that Nix is lazily evaluated allows for easy composability. This is used a lot in nixpkgs to allow overrides and build up packaging layers. And because the language is interpreted, only the files that are being used need to be evaluated. It wouldn't be very practical to hold all of nixpkgs in memory. It also allow to do things like dynamically import code from another git repo. And finally, the language only allows side-effects through derivations.

None of the above language have all these properties combined.

Re:Typing Nix by atemerev on Friday June 23, 2017 @10:17AM (#14619292)
I am only talking about the syntax. Semantically, Nix absolutely rocks.
Re:Typing Nix by jajern on Friday June 23, 2017 @09:21AM (#14618941)
It's one of those languages that a developer can look at and think "Oh, so this is how non-developers see code".
Re:Typing Nix by joombaga on Friday June 23, 2017 @09:42AM (#14619064)
It looks like someone threw a pinch of erlang in a Chef recipe. Like bash, but every English word operator has been replaced by space ships, angry squids, ternary operators, && all the other things that make code hard to read.

But... I still love Nix, and you get used to it.

Re:Typing Nix by atemerev on Friday June 23, 2017 @09:45AM (#14619084)
Bash is still worse. Probably. I know it is ubiquitous, but if I can avoid writing Bash scripts, I do.
Re:Typing Nix by kmicklas on Friday June 23, 2017 @02:19PM (#14621401)
I have no idea why you would think that. It's pretty standard usage of punctuation like (){}[] etc. If it's hard to read that's because the libraries and infrastructure for writing derivations is not simple or well-documented. But that's not a language issue.
Re:Typing Nix by regnat on Friday June 23, 2017 @09:33AM (#14619027)
Hi, author here. While I agree that the language could be improved, I wonder why you say that this makes it uglier, and how you'd imagine a better solution (this is still in development, and any idea is welcome).
Re:Typing Nix by atemerev on Friday June 23, 2017 @09:41AM (#14619060)
Is there any option to break source-level compatibility? (Automatic translation to old syntax will still be possible and seamless, of course).

If yes, I can draft a proposal.

Re:Typing Nix by regnat on Friday June 23, 2017 @09:49AM (#14619109)
Unfortunately no, except maybe for some very minor tweaks that have a chance to be included in vanilla nix, but otherwise this would most probably either mean the death of this project or a split in the (already small) community, which I both don't want to see
Re:Typing Nix by atemerev on Friday June 23, 2017 @10:07AM (#14619227)
Community could be larger if all these petty things were resolved :) But I understand, forking is definitely not an option.

So, if only gradual changes are allowed, I would have started with:

- making semicolons optional

- commas for implicit array literals (e.g. "a", "b", "c" in lieu of ["a" "b" "c"]

- something to do with 'with' / 'in' syntax.

In fact, I can live with anything, except non-optional semicolons. Is there a possibility to infer them?

Re:Typing Nix by regnat on Friday June 23, 2017 @10:35AM (#14619426)
The only place where I think we could make the semicolons optional is at the end of a let-binding or a record (like json does iirc), which would indeed be a small but blessed change.

For the array litterals, I don't really see which improvements your syntax brings (except suppressing the space-separated list, which conflicts with the syntax for function application). Is it used somewhere else ?

Re:Typing Nix by atemerev on Friday June 23, 2017 @11:21AM (#14619778)
(I can't reply to the previous message regarding no-semicolon syntax, so I have to do it here. I definitely do not want to propose whitespace-sensitive syntax — just newline-sensitive, like in Scala, Swift, modern ECMAscript, or just any modern programming language with C-like syntax. Semicolons are allowed, BTW — they are just optional and inferred from newlines).
Re:Typing Nix by atemerev on Friday June 23, 2017 @10:55AM (#14619617)
Here is the example where I just removed every semicolon.

https://gist.github.com/atemerev/889806081ed8fcb77495666fac9...

For me, it looks infinitely better.

Re:Typing Nix by tonyarkles on Friday June 23, 2017 @10:34AM (#14619405)
> In fact, I can live with anything, except non-optional semicolons. Is there a possibility to infer them?

I'm genuinely curious... what makes that a dealbreaker?

Re:Typing Nix by atemerev on Friday June 23, 2017 @10:56AM (#14619618)
Re:Typing Nix by regnat on Friday June 23, 2017 @11:09AM (#14619699)
I see. But that means using a whitespace-sensitive syntax, which some people (including me ;) ) don't really like
Re:Typing Nix by matrix on Friday June 23, 2017 @12:56PM (#14620665)
Very strongly agreed. Syntactically significant whitespace is the source of so many preventable errors that I believe it's simply not worth the aesthetic improvements.
Re:Typing Nix by atemerev on Friday June 23, 2017 @01:30PM (#14620977)
There is no significant whitespace in what I am offering; just semicolon inference at newlines (like in modern Javascript).
Re:Typing Nix by tonyarkles on Friday June 23, 2017 @06:22PM (#14623221)
Keep in mind that I am being simultaneously irreverent while also expressing how I feel about these two debates (semicolons and significant whitespace).

I'm someone who has worked in a large variety of languages, including Python (significant whitespace) and Javascript (no significant whitespace).

First: semicolon inference in Javascript is an abomination :). If the language says that whitespace is not significant, then using newlines to infer where semicolons maybe should be... is inconsistent with the statement "whitespace is insignificant".

Second: when I learned Python, I was coming from a primarily Perl and C background. The significant whitespace wasn't a big deal at all because that's how I indent my code anyway. And I would argue (and do in code reviews) that any code that is not indented properly is incorrect because it is extraordinarily misleading to a reader.

So, yeah, for any given programming language, I couldn't care less if whitespace is significant or not, or whether there's semicolons at the end of lines, but god damnit don't go half way on either of those. Indent your code as if whitespace is significant (because it IS to whoever's trying to decipher it later), and stick semicolons at the end of your lines whether or not some stupid inference rule will stick them there for you if you forget.

And as a final rant, "modern Javascript" didn't introduce semicolon inference; it's been there for a long time and was put there to try to lower the barrier for newbies. It wasn't put there because it's a great design decision.

Re:Typing Nix by atemerev on Friday June 23, 2017 @08:07PM (#14623676)
I come from Scala, and there semicolon inference works flawlessly. Why do you consider it to be an abomination in Javascript? (Except this famous corner case with continued line, almost never encountered in practice).
Re:Typing Nix by tonyarkles on Saturday June 24, 2017 @11:13PM (#14628423)
Things like this[1] are why I dislike semicolon inference. I very much think in language grammars, and languages that do clever things on top of that tend to annoy me. And, yes, I realize significant whitespace is likely implemented as a an edge case outside of the grammar, but it's at least simple.

An interesting thing with Scala is that in the BNF, "semi" is defined as ';' or nl.[2] After doing some initial reading about Scala, I was pretty much wondering why Scala needed semicolons at all. What you call "semicolon inference" seems like it's more like "optional semicolons", in that the language doesn't really need them.

[1]https://stackoverflow.com/questions/29743009/in-scala-are-se... [2]https://github.com/jystic/language-scala/blob/master/doc/syn...

Re:Typing Nix by regnat on Saturday June 24, 2017 @09:08AM (#14625456)
Well... This is a sort of whitespace sensitivity, and I don't really like it, because that means that some tokens may or may not be meaningful depending on the context, which increases the complexity of the syntax -- and syntax is probably the first thing that I think should be dumb simple and predictable.
Re:Typing Nix by porker on Friday June 23, 2017 @10:26AM (#14619349)
Is that a definite no, and there's no chance of compiling whatever $newLanguage is written to the current nix code prior to execution?

If that was possible, and a few $000 was raised (looking at the comments here, I think people would chip in) then a new version of the Nixlang with the same semantics and full backwards compatibility but a cleaner syntax, would be a great project to fundraise for.

Re:Typing Nix by ykler on Friday June 23, 2017 @10:11AM (#14619255)
Can't it just accept two different syntaxes (if really necessary for disambiguation, perhaps requiring people to put some magic string at the beginning of the file to request the new syntax)?
Re:Typing Nix by regnat on Friday June 23, 2017 @10:25AM (#14619342)
My tool could, but (for now, at least) it is a separate project from the main Nix interpreter, and this one is notably slow to evolve
Re:Typing Nix by adultSwim on Friday June 23, 2017 @12:25PM (#14620351)
Aside: I would love it if ML caught on. Such a good balance between expressiveness and usability. Imagine if Caml had caught on in the 90s instead of Java...
Re:Typing Nix by mintplant on Friday June 23, 2017 @02:33PM (#14621523)
This is why I'm very much interested in Guix and GuixSD, which use Guile Scheme. Unfortunately I don't think they have an officially-supported story for running on the server, yet, or an equivalent to NixOps.
Re:Typing Nix by agumonkey on Friday June 23, 2017 @09:23AM (#14618952)
You tried guix ? I still have a fondness for sexps, but ML would be nice too.
Re:Typing Nix by atemerev on Friday June 23, 2017 @09:44AM (#14619073)
I need CUDA drivers for what I am working with, and I have found no way to install it in Guix. Otherwise, it looks interesting enough.

(Sexps are usually not my first choice, I think it is a "lazy option" for people who do not want to write parsers / design their own syntax. Even then, they are better than current Nix expressions).

Re:Typing Nix by zeveb on Friday June 23, 2017 @10:45AM (#14619521)
> Sexps are usually not my first choice, I think it is a "lazy option" for people who do not want to write parsers / design their own syntax.

There are some real advantages to having one universal syntax: witness the explosion in XML and, later, JSON (both of which are generally inferior to S-expressions[1]). It'd be pretty great for one person to write one parser, and then everyone forever after to be able to use it. We'd be able to focus on semantics and not on syntax.

[1] Although it is nice that JSON supports first-class associative arrays.

Re:Typing Nix by corysama on Friday June 23, 2017 @12:17PM (#14620269)
AFAICT, there are 2 major differences between Nix and Guix. Language choice is the obvious one. The other is that Guix takes a hard-line stance on the GNU philosophy and therefore refuses to distribute pre-compiled binaries. I don't think CUDA will ever be an option on Guix.
Re:Typing Nix by geokon on Friday June 23, 2017 @01:00PM (#14620701)
Pretty sure there is nothing language-wise stopping anyone from hosting a separate repository with pre-compiled binaries.

It's a volunteer-run service. It makes sense they don't want to host your proprietary binaries

Re:Typing Nix by gnufx on Saturday June 24, 2017 @03:37PM (#14627128)
Does something actually stop you packaging proprietary binaries, perhaps privately, for Guix? It's clearly better to say No, but CUDA is a case where that's difficult.

(I don't see what's wrong with adopting sexps to avoid dealing with custom syntax -- quite the opposite,)

Re:Typing Nix by wcummings on Sunday June 25, 2017 @11:52AM (#14630581)
The kernel it ships with won't load blobs.
Re:Typing Nix by gnufx on Sunday June 25, 2017 @03:56PM (#14631838)
OK, there's a distinction between the GuixSD free software distribution and Guix package management. I'm surprised you can't build and use a non-linux-libre kernel with GuixSD, though; that presumably excludes even free additions, like Lustre, unless someone has done the forward porting work. (One of the recent HPC-ish presentations on Guix mentioned nvidia stuff -- I don't remember which.)
Re:Typing Nix by agumonkey on Friday June 23, 2017 @09:58AM (#14619176)
Some academics say that sexp allow to focus on what's important: semantics. I kinda agree with that, so many time, effort is wasted on syntax that moves, and only make ideas further apart.

Anyway, thanks for the answer

Re:Typing Nix by atemerev on Friday June 23, 2017 @10:09AM (#14619238)
Well, right, but we are not talking about an academic paper here, we talk about practically convenient language. If syntax is unimportant, we could leave Nix files as is -- semantically, it is a good programming language. But judging from the comments, I am not the only one who thinks that syntax and overall esthetics are important.
Re:Typing Nix by thinkpad20 on Friday June 23, 2017 @12:12PM (#14620225)
Really? I write almost nix every day at work and I have no problem with the syntax. I think it's pretty elegant and well-suited to its use case. There are a few minor tweaks I would make but nothing big at the syntactic level.

EDIT: probably the only gripe I would make is to have comma-separated lists instead of having to use parentheses to separate non-atomic expressions.

Re:Typing Nix by kmicklas on Friday June 23, 2017 @02:16PM (#14621387)
> probably the only gripe I would make is to have comma-separated lists instead of having to use parentheses to separate non-atomic expressions.

Wait no separators are evil. This is the best thing about the syntax.

Re:Typing Nix by runeks on Saturday June 24, 2017 @06:06AM (#14625081)
> I cringe every time I have to edit a .nix file (and I have to do it a lot).

No need to cringe over syntax. Syntax is just syntax. If you are familiar with a better syntax to express Nix in then create a parser from that format to Nix' syntax. Then insert this parser as a pre-processor in the build process, and problem solved.

Re:Typing Nix by KitDuncan on Friday June 23, 2017 @09:32AM (#14619018)
Honestly that's the only thing that keeps me from jumping to NixOS. I don't want to learn a weird language, I'll never use for anything else, just to maintain my OS.
Re:Typing Nix by rnhmjoj on Friday June 23, 2017 @10:09AM (#14619237)
The language is so simple you can learn all of it in a day. Read through chapter 15 in the nix[1] manual and that's it.

To me it doesn't feel weird at all: I can't think of any feature that was new or surprising when I started using it and I am not the biggest expert of functional programming. You have to learn more about the standard environment and tools if you want to start contributing to nixpkgs and write your own packages but if you only care about configuring your system nix is as difficult to learn as say, JSON.

[1]: https://nixos.org/nix/manual/#ch-expression-language

Re:Typing Nix by atemerev on Friday June 23, 2017 @10:10AM (#14619250)
It is definitely not difficult to learn, just somewhat hard to read and visually unappealing :)
Re:Typing Nix by adrianmonk on Friday June 23, 2017 @11:47AM (#14619997)
Personally, I'm not against the idea in principle. There are some real DSL-haters out there, and I'm not one of them. For a different problem domain, a different language can be more efficient.

It's true that some DSLs are not only different, they're also badly-designed languages or gratuitously different. I guess this is an occupational hazard of DSLs, but it's not unavoidable. It's possible to make the leap to a DSL only when actually beneficial and then to design a DSL that doesn't suck.