Hacker News new | ask | show | jobs
by beagle3 4029 days ago
> This "feature" makes it just as annoying as dealing with, eg, PHP, where the same codebase may feature NULL or null. It encourages inconsistency.

This is not a problem in practice, after two weeks. Seriously - Pascal has fallen out of favor, but there are large pascal codebases that demonstrate this point. NIL, NiL, nIl, nil are all accepted as the null pointer. It really isn't a problem in practice, not even remotely.

> Yes, because making grep (and search functions from code editors and IDEs) useless is a fantastic idea :(

No, grep is not useless, though it isn't quite as useful (just as much as #define makes grep less potent in C/C++). nimgrep fills some of the void.

> I feel that basing the design of a language based on the use-cases of non-programmers, for something they will likely not consider an issue after two weeks, at the expense of code maintainability is a mistake.

The Alice study was just an example BASIC and Pascal (and its predecessors) were designed in the late '60s and early '70s and feature case insensitivity. Nim follows Pascal, not Alica.

It looks like you are really upset with choices because of some theoretical objection. I have not really used Nim, but I have used both BASIC and Pascal very extensively. Case sensitivity and alternate spellings are NOT problems in practice, even though you try very hard to imagine that they are.

1 comments

> It looks like you are really upset with choices because of some theoretical objection. I have not really used Nim, but I have used both BASIC and Pascal very extensively. Case sensitivity and alternate spellings are NOT problems in practice, even though you try very hard to imagine that they are.

I'm not upset, I happen to think that these choices add complexity and promote inconsistency for little practical gain.

> This is not a problem in practice, after two weeks. Seriously - Pascal has fallen out of favor, but there are large pascal codebases that demonstrate this point. NIL, NiL, nIl, nil are all accepted as the null pointer. It really isn't a problem in practice, not even remotely.

If you want to enforce a consistent style, it's one more obstacle in your way. And considering how often projects end up with little technical lead and no enforcement of style whatsoever, I'd rather avoid that.

> No, grep is not useless, though it isn't quite as useful (just as much as #define makes grep less potent in C/C++).

It makes it useless to find an identifier, which means useless 90% of the time I want to use it on a codebase.

> nimgrep fills some of the void.

See? More complexity for no appreciable benefit. A much saner approach would be to implement a compiler warning for this kind of thing.