freenode/lisp - IRC Chatlog
Search
9:42:23
beach
flip214: That's OK, I'll do it. But another pair of eyes might be appreciated. There are already a few chapters on planet.lisp.org and I think they are still possible to update.
9:43:35
flip214
beach: ack, will try to. so, basically http://lisp-univ-etc.blogspot.com/search/label/lisp, right?
13:29:12
jonatack
beach: good that you are doing it. Dyomkin's content is very good and interesting but the writing does need proofreading. hope he is using it.
13:40:42
Josh_2
what variables do I need to initialize in my top-level function when I save-lisp-and-die?
13:42:56
pjb
Also, variables that reference values that will be different when you ressucitate your lisp image.
13:43:50
pjb
Josh_2: this doesn't mean anything: there can be compilation-time configuration files, and run-time configuration files.
13:45:07
pjb
So the point is to initialize the variable at the time they need to be initialized, with the correct values for that time.
13:46:01
pjb
Josh_2: why do you keep giving irrelevant facts? Being the first file mentionned in a system definition file means nothing.
13:47:24
pjb
Also, it would be a good idea to keep the configuration in a single object or structure…
13:47:50
pjb
It's better to limit the number of global variables, the more so when they are special.
13:48:34
jmercouris
I disagree about limiting the number of global variables, I think that strongly depends on the application
13:49:41
pjb
jmercouris: also be sure to have several variable with the same symbol name in different packages…
13:52:04
p_l
pjb: global variables are common way to implement forms of pub/sub messaging in realtime systems
14:14:11
jmercouris
Xach: did you use any documentation to learn about them, or just look at the source or?
14:14:39
Xach
jmercouris: I had a fairly firm basis of understanding of the underlying Unix API, and the sbcl interface is a very thin layer.
14:15:51
Xach
jmercouris: I don't know how well that would work. section 7 of the unix manual for ip, tcp, and udp could help. as well as IPC chapters of unix books.
14:16:23
jackdaniel
if you want to get a basic communication working take a look at dependents.lisp file in clx
14:18:08
jmercouris
jackdaniel: I only see a dependent.cl file here in https://github.com/franzinc/clx
14:18:22
Xach
unix network programming by stevens helped me back in the day. things have changed a lot with regard to new ways to multiplex and stuff but the fundamentals still work.
14:20:06
jackdaniel
basically you want: (make-instance 'sb-bsd-sockets:local-socket :type :stream) (sb-bsd-sockets:socket-connect * "/foo/bar") (sb-bsd-sockets:socket-make-stream ** :element-type '(unsigned-byte 8) :input t :output t :buffering :none)
14:20:24
jackdaniel
where stars are limited to count of two to avoid being accused of being a three-star-programmer
14:28:51
Xach
I don't particularly like SBCL's socket API, but the good news is that it takes only a small amount of code to make a new API with sb-alien if you like.
14:37:30
Xach
jmercouris: the code of sb-bsd-sockets is relatively small and it uses ffi to do its work.
14:37:48
Xach
jmercouris: if you don't like what it presents, you can make something that you like better without much work.
14:39:37
Xach
In my experience, it was about as easy to add the FFI interface I liked as to build an interface I liked on top of one I didn't like.
15:01:52
mrcode_
I can second Xach . Sb-bsd-socket interface feels awkward enough to warrant making your own. It’s relatively simple and can be done in an afternoon. What I don’t like about sb-bsd-sockets is the random work it tends to do at the times you least expect it to. FFI interface of your own has a more DWIM feel to it
15:32:03
beach
shka_: As I said before today, I spend most of the morning proofreading the chapter on linked lists in Dyomkin's book.
15:55:46
shka_
beach: i am still on vacations, i will likely implement code generation i have been talking about, i am also feeling like going back to that in-place merge sort algorithm again
17:17:15
Josh_2
when loading up asdf-system it isn't auto grabbing the packages in :depends-on with quicklisp, how do I get it to do that, or did I mess something up? do I have to manually load them with quicklisp before hand?
17:41:30
Josh_2
I was gonna ask how you do it, but I had done it correct but I didn't delete the default config
17:42:01
Josh_2
also, if I get https working do I need the certificate on both nginx and hunchentoot?
17:45:14
Xach
but it was only this year i heard someone say "nginx" out loud and i had no idea what they were talking about, technology-wise
18:00:04
Oladon_work
Xach: I think some could make the case that "cdr" might have some unusual pronunciations
20:46:39
aeth
about yesterday... I'm really tempted to just call the library the ungooglable name "to"
20:48:01
aeth
Oladon_work: I need a name for markdown->html in a way that will inevitably accomodate the bloat to supporting other random things like reStructuredText->org-mode
20:59:44
aeth
My design goal is to go with an intermediate format which basically means that if someone wrote a different frontend or backend then it basically would just be a generic format converter. e.g. "**foo**" => (bold "foo") => (:strong "foo") => "<strong>foo</strong>"
21:00:20
aeth
Then an org frontend could use "*foo*" for (bold "foo") instead of markdown's **, and /foo/ for italics instead of markdown's *
21:01:47
aeth
Basically if I can do "**foo**" => (bold "foo") => (:strong "foo") => "<strong>foo</strong>" then I could do "**foo**" => (bold "foo") => "*foo*" and translate md to org, assuming a backend was written
21:02:29
aeth
A bit harder, though, because it wouldn't be using s-expression-styled HTML/XML, though
21:02:34
alexanderbarbosa
hey y'all, is worthy reading Paul's Ansi Common Book or On Lisp for advanced topics? tnx
21:03:33
alexanderbarbosa
Gentle Introduction Symbolic ends stating: "Writing really large programs requires a different set of skills than what this
21:04:44
jackdaniel
alexanderbarbosa: ANSI Common Lisp book is a very good introductory material and has quite stimulating excercises
21:05:24
jackdaniel
(clos seems to be a dominant programming paradigm among common lisp programmers)
21:07:21
alexanderbarbosa
jackdaniel: ive read practical before gentle and did not understood most of it. I am one of those dumb learners that you have to say lots of time "to get it"... practical aint for me :D
21:08:37
aeth
jackdaniel: I'm not sure what you mean by "a dominant programming paradigm". Most CL code I've seen does use standard-objects, yes, but they're mostly just used as containers, barely scratching the surface of CLOS. Maybe there needs to be a CLOS book...
21:09:58
PuercoPop
it is very good as a introduction to CLOS imho. It helped me understand the AMOP better
21:10:21
aeth
PuercoPop: I only know about The Art of the Metaobject Protocol, but Object-Oriented Programming in Common Lisp also has a Wikipedia article. https://en.wikipedia.org/wiki/Template:Common_Lisp
21:10:27
PuercoPop
https://www.amazon.com/Object-Oriented-Programming-COMMON-LISP-Programmers/dp/0201175894
21:13:44
aeth
jackdaniel: not scientific because there are lots of duplicates (different versions over time) and I don't have all of quicklisp, but in quicklisp/dists/quicklisp/software I get 338604 defun in wc -l and 182213 for defmethod. Of course, CLOS auto-generates a lot, and a lot of people wrap their defuns/defmethods in define-foo macros, so even if I had a snapshot of the current QL, that wouldn't quite work.
21:15:14
jackdaniel
another bit supporting my opinion is that pcl is usually recommended as an introductory material and it quickly moves to clos techniques
21:17:23
aeth
I wouldn't be surprised if it's about even in methods and functions, but only if you count the auto-generated accessors in defclass, since those are way more common than the auto-generated functions of defstruct. Probably still a little in favor of defun. (I get 45992 defclass and 7777 defstruct)
21:18:14
aeth
Although you'd need a better sample and a more sophisticated search that takes various defun/defmethod wrappers into account
21:19:25
jackdaniel
I'm not sure for what I'd need more sophisticated search? I'm not looking for validation. good night ,)
21:19:52
Oladon_work
jackdaniel: I think you're taking all this a bit too personally/seriously. That was a hypothetical "you" — aeth is engaging in a thought experiment. :P
21:21:07
jackdaniel
hm, I'm not taking it personally, just pointing out that all this counting doesn't make sense in light of clarificaion I gave that I speak about opinions, not metrics
21:21:36
Oladon_work
jackdaniel: it's a thought exercise — he's not actually arguing with your opinion.