
I want a macro or something (may need to be a reader [is that what it’s called?] over the initial text ?) for ’(a, b, c) to become ’(“a, b, c”) , but it becomes ’(a ,b ,c) which then something like (symbol->string input) errors, seems likez I’m still learning more of the basics for more immediately helpful stuff; thanks so much for this more complicated stuff. Is there a way to make this work?

Thanks so much for all your help; studying more Racket and Lisp has been very helpful and joy producing.

@jerome.martin.dev has joined the channel

(displayln "Hello there :D")

(pretty-print "welcome :)")

Poll regarding https://github.com/racket/racket/pull/1803: ??
and ?@
or ~?
and ~@
?

@me1 Are you using these commas as list delimiters? Your example input reads as '(a ,b ,c)
, which is the quoted form of (list 'a (quasi-unquote b) (quasi-unquote c))
, which makes no sense unless you’re trying to do something unusual with quasiquotes.

??
and ?@

If those commas really are list delimiters, just drop them — Racket lists use whitespace to delimit list elements, and commas to escape from a quote. Then, your original problem is to produce '("a b c")
from '(a b c)
.

which is one string-join
away :wink:

> (list (string-join (map ~a '(a b c))))
'("a b c")
(you can replace ~a
with symbol->string
for the same result)

I’ve always wondered if ~seq
and ~optional
(or ?seq
and ?optional
) would be better names than the symbol soup, since they’d correspond more closely to their matching counterparts, but that might be too likely to break programs.

@kylewsherman has joined the channel

The commas aren’t being used as list delimiters. The language I’m/(my company is) developing was using simply (e.g.,) (define x ’(a, b, c)) to mean x is defined to be the string of “a, b, c”. Overall though I am thinking doing explict string quotes (e.g.,) (define x (“a, b, c”)) whenever there is punctuation like that ("," ";", etc.), and allowing for symbol->string for if there’s no conflicting punctuation, if really a more robust system, fundamentally.

Thanks though. :blush:

Oh, I get it.

How do you differentiate between normal Racket and things to parse differently?

:+1: for less symbol soup

Related to the discussion of van Tonder’s system on the mailing list, the system has some really interesting properties. For example, this program: (define x 'module)
(define-syntax (mac stx)
(syntax-case stx ()
[(_)
#`(let ([x 'local])
(list x #,#'x))]))
(mac)
produces '(local module)
, which I think is just fascinating.

@abmclin I’ve just accidentally stumbled upon this page detailing racket logos history - near the bottom there is the one with a star: http://www.eecs.northwestern.edu/~robby/logos/

Fascinating history! Thanks for the link. I do miss the logo version used for RAcket v 4.3 – 6.7. The history behind the stepper foot is amusing. Neato.

@dedbox yeah, we’re moving away from that system because it has issues. Always evolving!

:smiley:

To the Scribble wizards, I’m having a couple of problems with scribble/examples
.

Issue 1: an opaque struct inside an eval:error
is being printed as if it was transparent. You can see it here (http://docs.racket-lang.org/neuron/Control_Your_Resources.html#%28part._.Concurrency%29) in the first example. The raised value is a transparent struct that contains the opaque one.

Issue 2: I made a macro that quasiquotes a supplied term, but scribble complains that valid quasi-unquoted terms are not inside a quasiquote.

Are either of these expected behavior in certain cases, for instance if my evaluator sandbox is too strict? I’ve tried twiddling parameters to no avail.

¯_(ツ)_/¯

I really ought to read about this macro system too because it makes a disturbing amount of sense