Live data from Hacker News

A Friendly Introduction to Racket

geometridae.bearblog.dev

181–190 of 195 posts

Re: A Friendly Introduction to Racket

#181
post #113
post #109

Earlier quoted context omitted.

I quite intentionally said "within the language" to preempt nonsense like "Of course, you can. C is perfectly capable of writing C interpreters and compilers."

What does 'within the language' mean? Is the standard library part of the language? Would a variant of C that came with an interpreter in the standard library (but no other changes) count as homoiconic?

I want to point out that "Homo-iconic" does not appear in SICP.

But the concept is employed in the Meta-Circular Evaluator.

Perhaps see:

4.1.5 Data as Programs

https://sarabander.github.io/sicp/html/4_002e1.xhtml#g_t4_00...

Another striking aspect of the evaluator is that it acts as a bridge between the data objects that are manipulated by our programming language and the programming language itself. Imagine that the evaluator program (implemented in Lisp) is running, and that a user is typing expressions to the evaluator and observing the results. From the perspective of the user, an input expression such as (* x x) is an expression in the programming language, which the evaluator should execute. From the perspective of the evaluator, however, the expression is simply a list (in this case, a list of three symbols: *, x, and x) that is to be manipulated according to a well-defined set of rules.

That the user’s programs are the evaluator’s data need not be a source of confusion. In fact, it is sometimes convenient to ignore this distinction, and to give the user the ability to explicitly evaluate a data object as a Lisp expression, by making eval available for use in programs. Many Lisp dialects provide a primitive eval procedure that takes as arguments an expression and an environment and evaluates the expression relative to the environment.

The difference is this is built in to many Lisps without the need to create a separate interpreter. And thus much more direct. It's definitional.

Re: A Friendly Introduction to Racket

#182
post #8

I've never seen the appeal in schemes other than hot reloadability...

Homoiconicity.

A spotlight on the subject:

https://www.expressionsofchange.org/dont-say-homoiconic/

A humorous footnote:

In fact, the original article excludes Lisp as an example of homoiconicity, but only because Lisp had not settled on a single representation in terms of s-expressions at the time of writing: “Finally, LISP is troubled with a dual language problem: an M-language, which is easy to read, and is used externally, and an S-language, with which the LISP processor operates, and which is usable externally only by the hardened initiates. It should be noted here that were the S-language the only LISP language, LISP would be close to being homo-iconic (excluding the machine-language functions).”

  Don't Say “Homoiconic” (2018) (expressionsofchange.org)
 88 points by dmux on Aug 11, 2019 | hide | past | favorite | 69 comments
https://news.ycombinator.com/item?id=20657798

Re: A Friendly Introduction to Racket

#183
post #101

Earlier quoted context omitted.

You can write some library functions to get you more sophisticated indexing, if that's what you want.

The fact that you can write a C parser in C does not make C homoiconic. Not needing to have a user level parser is like, the whole thing that makes homoiconicity interesting.

You can produce a variant of C, call it C', that has the parser in the standard library.

Re: A Friendly Introduction to Racket

#184
post #113

Earlier quoted context omitted.

What does 'within the language' mean? Is the standard library part of the language? Would a variant of C that came with an interpreter in the standard library (but no other changes) count as homoiconic?

I want to point out that "Homo-iconic" does not appear in SICP. But the concept is employed in the Meta-Circular Evaluator. Perhaps see: 4.1.5 Data as Programs https://sarabander.github.io/sicp/html/4_002e1.xhtml#g_t4_00... Another striking aspect of the evaluator is that it acts as a bridge between the data objects that are manipulated by our programming language and the programming language itself. Imagine that the…

That part of SICP applies equally well to Haskell, which is not generally considered homoiconic.

Re: A Friendly Introduction to Racket

#185
post #37

Earlier quoted context omitted.

You can ask Claude to write you some.

Are you suggesting, possibly, that a team of 10x Lisp hackers with 10x agent force multipliers could catch up with the depth and bread of Python's CheeseShop and proceed to right the world?

No, what makes you think so?

I'm saying that you can produce some interesting apps to explore.

Re: A Friendly Introduction to Racket

#186

Earlier quoted context omitted.

Curious, how would look that in Python?

Would need some imports: import cmath from fractions import Fraction And then have to write numbers as strings to input them. From their examples: >>> Fraction('1.414213 \t\n') Fraction(1414213, 1000000) >>> cmath.sqrt(-2-0j) -1.4142135623730951j Not really great, but workable. I don't like having to import things for basic math stuff like exact numbers, but having a lot of special syntax is maybe also not that great…

[dead]

Re: A Friendly Introduction to Racket

#187
post #185

Earlier quoted context omitted.

Are you suggesting, possibly, that a team of 10x Lisp hackers with 10x agent force multipliers could catch up with the depth and bread of Python's CheeseShop and proceed to right the world?

No, what makes you think so? I'm saying that you can produce some interesting apps to explore.

[deleted]

Re: A Friendly Introduction to Racket

#188
post #185

Earlier quoted context omitted.

Are you suggesting, possibly, that a team of 10x Lisp hackers with 10x agent force multipliers could catch up with the depth and bread of Python's CheeseShop and proceed to right the world?

No, what makes you think so? I'm saying that you can produce some interesting apps to explore.

"Wishful thinking".

Re: A Friendly Introduction to Racket

#189
post #183

Earlier quoted context omitted.

The fact that you can write a C parser in C does not make C homoiconic. Not needing to have a user level parser is like, the whole thing that makes homoiconicity interesting.

You can produce a variant of C, call it C', that has the parser in the standard library.

And then everyone would have a user level parser instead of a homoiconic variant of C.

Re: A Friendly Introduction to Racket

#190
post #156

Earlier quoted context omitted.

First time dealing with developers I see. I’m sorry.

Nonsensical non sequitur ad hominem. (FWIW I've been a software developer for 60 years and have dealt with many of them.) I won't respond further.

Apologies sir, it was uncalled for. The plebeian in me couldn’t resist.

I am deeply jaded by my experience, but as you seem to imply your experience is different I am glad for you.

Post reply on HN