freenode/#lisp - IRC Chatlog
Search
0:55:13
asarch
If I have: (defparameter *values* '('(lisp rocks) '(clos rocks even better) '(mcclim is also awesome))) and then I do: (loop for lists in *values* do (loop for element in lists do (format t "Parsing element: ~a~%" element))), how could I get each element?
0:58:08
aeth
You can think of ' as like multiplication. 2*(4+3)=2*4+2*3. '((foo) (bar)) = (list '(foo) '(bar))
1:02:52
White_Flame
asarch: if you (setf *print-pretty* nil), then you'll see the full lists with QUOTE symbols in them when you show *VALUES* at the repl, and you can see how they're in the way
1:04:06
pjb
'('(lisp rocks)) = '((cl:quote (lisp rocks))) and ask yourself why 1- you put (lisp rocks) in a sublist, 2- you put the symbol CL:QUOTE as first element of that sublist.
1:05:02
smokeink
(ql:quickload :com.informatimago) ; System "com.informatimago" not found. Not on quicklisp any more?
1:05:14
aeth
To use the distributive property analogy: '('(foo)) is (list ''(foo)) which of course is just (list (quote (quote (list foo))))
1:05:47
aeth
If you have to work with quote in quote, be aware of that extra quote, but it's rarely what you want
1:06:42
pjb
smokeink: indeed. cd ~/quicklisp/local-projects ; git clone https://github.com/informatimago/lisp informatimago
1:09:15
Xach
smokeink: the author posted many vile racist and neo-nazi things on twitter and i do not wish to work with them in quicklisp or anything else.
1:10:54
pjb
Note how he benefits from free-speech protection by his constitution, but he acts in a completely totalitarian way against others…
1:11:48
smokeink
yeah but if it was nazi stuff and he doesn't want to associate in any way, it's his freedom too
1:18:27
no-defun-allowed
There is also a...was it draw-cons-tree system on Quicklisp which achieves roughly the same thing.
1:20:34
smokeink
pjb: I have neo-nazi friends, I respect their vision , which in part is insightful, but as far as I'm concerned, it's only in part
1:24:23
holycow
Xach: if you are monitoring peoples personal postings online you are no longer worty of support
1:26:19
Xach
holycow: I don't generally seek out things like that, but if I am aware of them and do nothing, I find it intolerable.
1:28:33
holycow
i will make a donation for the work you have done thus far, i find it helpful, but i will no longer be using ql on principle
1:29:11
holycow
* i have not donated to you and should out of principle for the work you have done thus far
1:29:40
no-defun-allowed
holycow: The paradox of tolerance is an odd one; but not really a topic for #lisp. #lispcafe is usually at its greatest throughput when arguing such philosophical things.
1:29:50
holycow
* i admit that my position is hypocritical because my line in the sand is somewhere along the lines of sexual abuse and i would make a similar call then
1:35:21
LdBeth
Does the terminal emulator in CLiki’s suggested projects require to be a VT100 compatible one?
1:36:18
karlosz
i think with suggested projects you should take them in whatever direction you see fit
1:36:40
pjb
LdBeth: you can define your own control codes, but write down a termcap/terminfo entry for your terminal!
5:05:28
beach
HiRE: If you take a job in the right place, or work for the right customer, your employer or customer might not care whether you use Common Lisp or something else.
5:06:13
HiRE
beach: thats true. Similar to the one artcle...cant remember its name where a guy sells common lisp to JPL
5:08:47
beach
Also, consider getting a job at a place that does NOT use Common Lisp, but that has no good reason not to use it. Then you can show them that you can do better with Common Lisp than with what they are currently using.
5:09:22
beach
That's even better than to work for a company that is already convinced about the virtues of Common Lisp.
5:10:34
copec
I do systems admin and devops and my job is 100% remote, I've managed to slip in quite a bit of CL scripting
5:10:42
beach
The only thing I have found to work is to show that you can create a lot of high-quality stuff in a short period of time.
5:14:33
copec
You seem totally qualified for a lot of arbitrary listings I have seen, here in the states
5:16:31
beach
A degree, while not strictly necessary to get the job done, is a kind of international unemployment insurance.
5:17:08
no-defun-allowed
On the contrary, I am trying to find a part-time job so I can pay for university, but I could still wait since it'll just come out of my taxes after university.
5:19:12
HiRE
I'm currently in a PhD program. I just couldn't get enough of paying absurd university prices ;D
5:20:25
HiRE
doing it part time and working full time definitely makes it tolerable despite it taking ages to finish
5:31:22
no-defun-allowed
Anyways, this is probably the reverse of what is usually asked here, but has anyone attempted to implement something like the JVM in Common Lisp?
5:38:09
beach
I strongly recommend you move to a country where the university enrollment fees are low.
5:38:53
Xach
no-defun-allowed: not just "something like" but the real thing, able to load and run java code.
5:58:18
no-defun-allowed
It's bitrotted to the point I can't compile it sadly, but most of the code is there.
9:03:35
no-defun-allowed
I think it's supposed to be usable when the user doesn't have a Common Lisp implementation already.
9:13:27
jackdaniel
beach: it is a package manager which automates downloading the CL implementation of your choice and apparently to set up quiklisp etc
9:13:56
jackdaniel
i.e I couldn't set up my self-build CL implementation for it, managing "active" implementation was quirky etc
9:19:21
pjb
beach: so instead of having the problem of installing a CL implementation, now the newbies have the problem of installing roswell.
9:19:52
beach
Sure. And I would have a problem too, because I don't have a C compiler installed by default.
9:49:38
easye
roswell ain't too bad from a casual user perspective, but I was not very happy when I needed to modify it to install LispWorks last year for Emotiq.
9:52:10
beach
I recently learned that I can't map page 0 because there might be bugs in the OS that dereference NULL and the C compiler does not protect against that by (say) inserting a test.
9:59:28
p_l
and it's less OS bugs and more tricks with application bugs to get them to jump to known address
9:59:43
beach
Yes, so if I distribute SICL, I have to ask every Linux user to reconfigure their systems, thereby making them vulnerable to OS bugs.
10:00:47
beach
So we keep adding kludges on top of hacks to avoid solving the fundamental problems, thereby making life harder for both developers and users.
10:02:11
beach
If I represent NIL as a the machine number 5 and store NIL at address 0, they can't use my system unless they reconfigure.
10:05:30
beach
So now I am in a situation where I must use a 32-bit immediate for NIL, because it can't be stored in the first few pages, and if i want to be able to run the implementation on a system with ASLR, then I also can't have pre-defined data structures in the executable.
10:05:56
no-defun-allowed
https://utcc.utoronto.ca/~cks/space/blog/linux/KernelPageZeroProblem describes it slightly better; the kernel is mapped into the process's address space, and so kernel code could dereference NULL and act weirdly.
10:06:18
beach
So I am basically forced to either have the system behave like a C++ application with ctors, or I am forced to do a full GC at the beginning of the execution, or possibly use relative pointers everywhere. Everything has a cost.
10:31:51
beach
LdBeth: I suspect not. I looked at how Emacs dumped memory to an executable a long time ago, but I think they changed it since. Why do you ask?
10:32:32
no-defun-allowed
"[kdeinit] executes KDE programs and kdeinit loadable modules (KLMs) starting them more efficiently." That's more terrible than I felt while waiting for at least two minutes for KDE4 to load on my old computer.
10:38:30
LdBeth
beach: https://dancol.org/pdumperpres.pdf Indeed, their new solution works on ASLR system
10:39:23
no-defun-allowed
Can you dump an image from a cross-compilation where one implementation compiles another using that method?
10:41:06
LdBeth
Emacs now does not directly mapping data into memory, at the cost of a little overhead
10:43:17
pjb
Let's note that C NULL pointers don't have to be represented by a #b0 bit pattern. At the level of the C source, casting it into a intptr_t should give you 0, and (void*)0 should give you a NULL pointer, but the binary representation of (void*)0 and (intptr_t)0 can be different.
10:43:23
no-defun-allowed
It's certainly useful, but in the "general" case dumping an image doesn't sound easy.
10:44:26
no-defun-allowed
Hm, I think Zeta C/Symbolics C had an odd representation for NULL (which was NIL?) as pointers were arrays of some kind.
10:44:55
no-defun-allowed
pjb: https://stackoverflow.com/questions/2597142/when-was-the-null-macro-not-0
10:45:21
beach
LdBeth: Thanks for the information. That is a terrible kludge that should not have been necessary in the first place.
10:45:50
pjb
beach: there are other reasons why you might not be able to use page 0 (or others pages with small addresses). Sometimes interruption vectors are stored there. Sometimes these addresses are used for fast addressing so the pages are used as temporary registers. And of course, the kernel can memory map them out of the user process reach anyways.
10:46:54
p_l
no-defun-allowed: all "plain" memoy in Symbolics C was a big array that was multiply mapped as different types
10:48:31
beach
So I guess if you take ASLR into account, there is no chance that NIL could be a fixed constant, let alone an 8-bit machine value.
10:54:54
beach
p_l: The problem is not the architecture. The problem is that we insist on programming as if we have access to the raw computer, just as we did in 60 years ago.
10:59:14
LdBeth
There’re lot of tools I can name written using specifically designed languages so they can translated to different architecture and assembled with macro
11:14:20
p_l
beach: making it explicit that you don't have access to raw machine requires either a special machine, or disregard for security. And we no longer can do the latter, niot really