5 ms·
Lisp is a family of languages, not any single one. There's (thankfully, lisps needs innovation like everything else) room for different types. In the C family
by monsieurbanana 3y ago
Lisp is a family of languages, not any single one. There's (thankfully, lisps needs innovation like everything else) room for different types.
In the C family for example, you have both C and Javascript.
> It would also be nice to port programs from one dialect to another without major editing
If the languages are the same, they wouldn't be different dialects, they would be the same language, so porting them doesn't make much sense. I think the closest thing to what you're describing is Clojure, where you can swap the targeted environment (JVM if you're working on a server, babashka if you're making a script, javascript if it's a web app, dart/flutter if you're making mobile apps, etc...)
- dragonwriter 3y ago> In the C family for example, you have both C and Javascript. There is no reasonable sense in which JavaScript is in the “C family”. It's not really even in the broader Algol family that C is in, being most closely related to Self and Scheme (the latter being in the Lisp family.)
- monsieurbanana 3y agoI just took a random example from the wikipedia page of C languages: https://en.wikipedia.org/wiki/List_of_C-family_programming_languages https://en.wikipedia.org/wiki/List_of_C-family_programming_l... I don't think that takes away from my point, in each family of programming languages you can find very different ones and lisp is not a language but a family of languages. Besides using S-expressions, I don't know what else you would need to be considered a Lisp.
- DonaldFisk 3y agoIf you know C, you don't need to learn a new syntax if you learn C++, Java, C#, or Javascript, except where their semantics is different from C. In those languages, this was a good design choice, which encouraged people to adopt those languages.
- lispm 3y agoA language syntax is quite a bit more than { }.
- hencoappel 3y agoC family here refers to syntax style. In this case the general use of curly braces to denote blocks and often semicolons to denote end of statements. Another example of such a family would be the ML language family with languages like Haskell and F Sharp.
- akkad33 3y agoIs Haskell in ML family? I know Fsharp and Ocaml are but Haskell seems to be very different from them synctically with the only similarity being that it is functional
- DonaldFisk 3y agoC and Javascript are very different languages with similar syntax. Common Lisp and Picolisp are very similar languages/dialects with different syntax/function names. Common Lisp based its syntax on Maclisp so that Maclisp code could run without much alteration on common Lisp systems.
- mrighele 3y ago> C and Javascript are very different languages with similar syntax I don't know specifically about Picolisp, but many lisps are as different between themselves as C and Javascript are. For example, Scheme is a functional language, while Common Lisp is multi-paradigm One has only lexically scoped variables, the other has also dynamically scoped variables. They have two completely different macro systems (hygienic vs non-hygienic). One has continuations, the other doesn't. These are just the few that come to my mind right now. Those are not trivial difference, they completely change the way you reason about you program, and what you can do with it.
- soegaard 3y agoScheme is not functional per se. Scheme the language supports multiple programming paradigms. The culture pushes people towards functional programs, but having mutation available has always been part of Scheme. Most Scheme implementations also offer some sort of object oriented solution.
- actionfromafar 3y agoI first read “suffer from some sort of object oriented solution”.
- lispm 3y agoScheme exists in various forms and standards. There are small educational definitions and implementations which provide most SRFIs and thus have all features of CL and more. https://srfi.schemers.org https://srfi.schemers.org At its core Scheme is procedural, imperation and functional. Common Lisp is also "object-oriented" in its core.
- Chris2048 3y ago"port programs from one dialect to another without major editing" isn't the same as "the languages are the same", so why did you parse it that way?