freenode/lisp - IRC Chatlog
Search
5:22:15
ck_
in your essay on perfection vs. performance orientations, you say "I myself recently discovered a marvellous feature in a programming language that I had purposely avoided for the past 10 years"
5:33:35
beach
Interesting. If I type (to Google) the name of the Scheme object system that was worked on by my colleague at the time and that made me not look at CLOS, there are no answers. But if I type my own name, there are pages and pages of results. :)
5:34:48
ck_
ooh. So it wasn't just that "object systems are bad" it was that /their/ object system is bad
5:37:01
beach
It is turned out to be true, there was a lot of stuff that I could ignore, and save a lot of work.
9:10:05
no-defun-allowed
I want to do an experiment to see how often "duplicate" objects appear in (a reasonable fraction of) my Lisp image (with varying definitions of "duplicate"), so I wrote a short program to traverse objects and count the times they are referenced: https://pastebin.com/Dv0tGv8D
9:11:11
no-defun-allowed
Someone suggested it wasn't correct, then backed out, but I wonder if there's something wrong with my method or if EQUAL objects do appear in my image about 5.4 times.
9:28:21
jmercouris
anyone know how to add indents in multiline strings without them appearing in the resulting string?
9:37:00
loke
jmercouris: No special String syntax. But the FORMAT will be executed at READ time, so it's as standard as anything
9:37:12
jmercouris
"have to IF want to indent multiline strings without indents appearing in resulting string"
9:37:29
loke
You could also write your own reader, I guess. I'd be trivial but the benefit compared to #.(FORMAT...) is questionable.
9:38:21
loke
I'd say that an untrained eye would likely be more confused seeing your custom reader syntax, as that wouldn't be anythign previously known :-)
9:40:05
jmercouris
loke: a good point, it would take me a few seconds to realize what is going on but yes
9:40:38
specbot
Tilde Newline: Ignored Newline: http://www.lispworks.com/reference/HyperSpec/Body/22_cic.htm
9:44:53
loke
~newline ignores newline and indentation. ~@newline ignores the indentation but keeps the newline
10:42:58
loke
Reader macros are really cool and all, but I have to admit I've never used them for effect.
11:55:09
pjb
minion: memo for jmercouris: I would say that it depends on how many such strings you have in your sources. If only one or two #.(format …) will be ok. Otherwise the specific reader macro is indicated. You can use another character than #\", eg. #\« … #\» or #\[ #\]