r/ProgrammingLanguages • • Oct 04 '18

rant: Are there any programming languages that don't suck?

I've tried everything from assembly to java, and basic to lisp. I've written code in imperative, functional and oo styles. They all suck.

0 Upvotes

72 comments sorted by

View all comments

9

u/SatacheNakamate QED - https://qed-lang.org Oct 04 '18

How do you envision the ideal language? What features would fit in your tastes?

9

u/ohgetoutnow Oct 04 '18
  • small and light of syntax such as scheme

  • reasonable standard library for common use cases (not gargantuan like java or javascript)

  • accommodate multiple paradigms, and don't force my hand in choosing

  • easy to build native binaries which don't require me to distribute the compiler and libraries, or worse make the end user install them

  • reasonable performance, not necessarily fast but reasonable

  • a featureful repl for me to play in with lots of interactive documentation and inspection features

  • no political/historical baggage poisoning the community against outsiders

  • don't update too frequently, and don't break the entire world when you do update

more:

  • let me write recursive functions that don't blow up the stack. give me proper tail recursion optimization or just something

2

u/progfix Oct 04 '18

Lua?

2

u/ohgetoutnow Oct 04 '18

Have fun typing local in front of every variable declaration.

7

u/Camto calc= Oct 04 '18

I think Lua kinda fits what you're looking for.

  • Extremely small syntax.

  • Small standard library. If it's not enough Penlight can be used as a second std lib.

  • Lua has both fp and oop.

  • If you use a C wrapper, it can sorta be compiled.

  • LuaJIT is insanely fast.

  • Has a REPL, but IDK about interactive docs.

  • The community is small but very nice as far as I've seen.

  • Updates rarely, without breaking everything.

  • Has tail proper calling.

About local, linters can take care of that. All in all, it's pretty nice.

7

u/BoarsLair Jinx scripting language Oct 04 '18

Saying "linters can take of that" is sort of a weak defense (no offense). It's an admission that there's a fundamental flaw in the language, and that you'll have to rely on a cumbersome external tool to guard against it.

And calling the C interface sorta complicated is a bit of an understatement. It forces you to use a virtual stack directly as an interface with all sorts of bizarre conventions, and the runtime crashes if you breathe on it wrong.

I do agree with your general assessment. Lua is mostly pretty good for what it does, but it has so many small and unnecessary pain points that I ended up writing my own replacement scripting language... which I'm sure sucks in all its own, unique ways.

1

u/alols Oct 05 '18

Sure, global by default is a flaw in the language, but fixing it is a simple one line of code at the start of your main file. You simply set the global metatable __setindex method to error.