>His programming language cannot generate code
His programming language cannot generate code
Other urls found in this thread:
nyx.net
esolangs.org
archive.fo
archive.is
github.com
common-lisp.net
youtube.com
groups.google.com
docs.racket-lang.org
github.com
twitter.com
Shut the fuck up
brainlet here, what does it means to generate code? write programm without programmer?
(defmacro get-out (&rest shitposters)
`(progn
,@(loop for fag in shitposters
collect `(shitposter-cry ,fag))))
Can't think of one right now, excluding of course those really autistic "languages" that are created only to be funny and half the time aren't even Turing complete. All the usual stuff qualifies: nyx.net
And even a lot of the autistic stuff does: esolangs.org
And since you aren't talking about quines but just about generating code, any language that may not even be turing complete but has the capability to print arbitrary output could easily just print out a string of valid C or something.
You can write programs that generate programs.
This should also be something that is practical and not just possible. I.e your programs can be represented in a simple format such as a list which can be easily manipulated by another program
In Lisp code is data (from the name List Processor), which means that you can use macro to generate lists and evaluate them at run time. This means that you could write a program that generates for instance (+ 1 1) which sums two numbers. This is a stupid example but metaprogramming can be used to do much more complex stuff in a very concise way.
In C, while you could write code to a file and compile it, you wouldn't be able to do that dynamically without exploiting the memory area of the program. In lisp it is so simple that you can do that from list, at read time, at load time, at compile time, or even at runtime.
Cool, explain why that wouldn't count as "generating code"
You can compile a shared object and then dynamically link it. I've seen this trick exploited for a C REPL, but it's more novel than practical.