News for hackers. Stuff that matters.
Re:Little is a statically typed, C-like scripting language by derefr on Saturday February 20, 2021 @11:37AM (#26205419)
I've always been surprised that nobody has tried to take a "The Good Parts" subset of a big language (C++, Perl, etc.), codified/formalized it as its own language, and then attempted to popularize the new reduced language as a distinct effort/project/community to that of the original language.

One could release this "language" as a distribution of the inner language's compiler together with a wrapper (like C++ originally was to C), that, rather than adding features and compiling down, just analyzes the source file and errors out on use of forbidden syntax; or, if no forbidden syntax is used, just passes your code straight through to the inner compiler. A bit like a pre-commit-hook style checker, but a pre-compile-hook style checker.

Re:Little is a statically typed, C-like scripting language by TimWillebrands on Saturday February 20, 2021 @02:15PM (#26206915)
For c++ there is orthodox c++ which is a subset of the larger language. Although as far as I know there is no linter/compiler. https://gist.github.com/bkaradzic/2e39896bc7d8c34e042b
Re:Little is a statically typed, C-like scripting language by luckydude on Saturday February 20, 2021 @11:47AM (#26205520)
I just liked what is in Little, it's enough like C that it is trivial for me to jump into it (tcl always took a half a day, I really dislike the tcl syntax), it's got enough of the shortcuts from perl that it is pretty terse, and credit where credit is due, syntax aside, tcl has a bunch of useful stuff, check out Little's switch(), that's tcl's switch.
Re:Little is a statically typed, C-like scripting language by forgotmypw17 on Saturday February 20, 2021 @08:32PM (#26209980)
I have not tried to codify it yet, I think mainly because I'm still figuring it out, but I've been doing this with Perl and PHP, writing in a lowest-common-denominator style which is almost identical between the two...
Re:Little is a statically typed, C-like scripting language by prirun on Saturday February 20, 2021 @08:17PM (#26209894)
Someone should do this with Nim.