freenode/#lisp - IRC Chatlog
Search
2:09:17
madpengu
(defparameter *a* (list 1 2 3)) (defparameter *b* (list 4 5 6)) (defparameter *c* (append *a* *b*)) (setf (first *a*) 55)
2:15:22
madpengu
Okay, figured, append is only allowed to reuse the last structure, not just any one of them
2:20:08
pjb
madpengu: append is not destructive, but the result shares the last argument, so if you mutate the result, it could be destructive!
2:20:56
pjb
(let ((a (list 1 2 3)) (b (list 4 5 6)) (c (list 7 8 9))) (tailp c (append a b c))) #| --> t |#
2:21:00
madpengu
I was just confusing about what is reused, it seems only the last structure, no the first one.
2:21:52
pjb
Notice that this is what lets you use append to build a dotted list: (append '(1 2 3) 4) #| --> (1 2 3 . 4) |#
2:23:15
dmiles
(otherwise indeed it may have been nice to have had it resue the first structure to save space)
2:23:44
pjb
(let ((a (list 1 2 3)) (b (list 4 5 6)) (c (list 7 8 9))) (tailp a (nconc a b c))) #| --> t |#
2:29:00
pjb
madpengu: you can also use (com.informatimago.common-lisp.picture.cons-to-ascii:draw-list (cons '(1 2 3) 4))
3:57:59
drmeister
I realize that nil is not a character - but I have some code (not my own) that is invoking unread with nil.
4:09:27
jasom
ebrasca: every object in lisp is either a cons or an atom. The type atom is literally the same as the type (not atom)
4:10:30
jasom
ebrasca: it's a bit silly that vectors and hash-tables are atoms, but the atom/cons distinction predates lisps having those
4:41:27
jmercouris
anyone know a cl lib that provides functionality similar to: https://www.passwordstore.org or perhaps a wrapper for it?
4:50:51
madpengu
jmercouris: That is a stupid simple wrapper around gpg. You could probably write in cl in 2 lines of code ;)
5:14:02
jmercouris
I'm hesitant to recreate it in CL because I think there are some users of pass already, and I'd like to integrate with their workflow rather than break it
5:43:56
madpengu
jmercouris: I use pass all day erry day. And considering that it is just a bash script, I am not sure how you can find a cl library.
5:48:48
beach
jmercouris: I consider it progress whenever some existing software can be rewritten in pure Common Lisp, or at least as pure as possible, depending on the task at hand. It makes the software safer and easier to maintain for us.
5:51:50
jmercouris
Ironclad also looks like a nice library: https://github.com/sharplispers/ironclad
5:59:41
beach
jmercouris: There have been some issues with Ironclad. I suggest you ask Bike and drmeister.
6:27:18
beach
I have almost all the customization code in place. I think only what backquote returns need to be customized.
6:28:39
beach
Extracting it would be the good opportunity to make sure it is truly implementation independent, and also the opportunity to document it properly.
7:32:03
beach
The fact that Common Lisp has several implementations can be confusing to "modern" programmers who are used to single-implementation languages, where the language and the implementation evolve together.
7:32:09
beach
But having a fixed standard like Common Lisp does, and having several possible implementations of that standard to choose from is actually a good thing.
7:32:10
beach
A commercial software project that chooses a single-implementation language is actually taking a great risk.
7:36:57
dmiles
zhoujingrui: paste an entire function to pastebin, RET is used in a certain dialect of lisp that i am very familiar with
7:38:09
dmiles
hah i see now, i thought the refernce to the keyboard was a joke.. but now i see this is instructions
8:04:21
beach
ebrasca: I am fine thank you. I am working on one the ELS submissions for this year. What about yourself?
8:09:49
beach
Quite nice. There are usually almost 100 participants, and many of the same people come back every year, so it is good to see them again, and discuss what they are doing. Many people here on #lisp are regular participants.
8:10:57
hajovonta
today morning I have this error message when starting SLIME: fatal error encountered in SBCL pid XXXX: can't find core file at ~/sbcl/lib/sbcl/sbcl.core
8:11:18
beach
ebrasca: The thing to know about academic conferences is that the presentations are nice, but secondary. The primary interest is to meet the other participants and discuss with them face to face.
8:14:46
hajovonta
it was more than a year when I installed sbcl, but as I remember, I couldn't write to that directory
8:16:19
beach
OK, very preliminary version of one of the submissions: http://metamodular.com/partial-inlining.pdf
8:17:21
hajovonta
beach: I had discussed it briefly with my wife last week, and it seems she's excited to go there for a few days.
8:17:23
beach
ebrasca: Take a flight to Malaga, then a bus to Marbella. Use AirBnB to get a place to stay.
8:18:39
|3b|
hajovonta: have you reinstalled sbcl since then, or made any major changes to OS install?
8:21:24
hajovonta
|3b|: I don't think so. but the problem is only present when I start via M-x slime. If I open a terminal then I can start SBCL. I have a script that I use to set up an load certain lisp files into the image at start (with sbcl --load) and then load SLIME's swank-loader and connect to it in a separate step
8:23:05
beach
ebrasca: The fee is very small, so your cost is going to be dominated by transportation.
8:23:36
ebrasca
beach: https://www.google.com/flights/#search;f=OSR;t=AGP,YJM;d=2018-01-28;r=2018-02-01
8:30:32
|3b|
hajovonta: and if you specify a path to sbcl in .emacs, try specifying that path in shell
8:33:53
|3b|
yeah, that might give you different environment variables depending on where you set them, so make sure you are running same sbcl in both
8:36:30
|3b|
and if you get a version # in the error message from starting it in emacs, compare that to what you get from shell
8:37:34
hajovonta
maybe quicklisp gets in the way? I have that two lines that ql:add-to-init-file generated
8:39:01
hajovonta
(progn (load "/home/_/quicklisp/dists/quicklisp/software/slime-v2.19/swank-loader.lisp" :verbose t) (funcall (read-from-string "swank-loader:init")) (funcall (read-from-string "swank:start-server") "/tmp/slime.8992"))
8:46:18
hajovonta
~/sbcl/bin/sbcl: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), for GNU/Linux 2.6.18, dynamically linked (uses shared libs), not stripped
8:47:42
phoe
hajovonta: try replacing ~ with an expanded path to your homedir, in the inferior-lisp-program elisp variable.
8:56:59
hajovonta
my brother who once worked in tech support, said that 40% of the problems was due to some power failure (not plugged in, not switched on, etc)
8:57:36
|3b|
and probably 40% of the rest were not plugged in but the person just didn't tell them after figuring that out :)
9:28:40
beach
Slightly updated version of one ELS submission here: http://metamodular.com/partial-inlining.pdf
9:30:19
otwieracz
How to perform $ curl -F data=@my-file -X POST http://localhost:8080/restore with drakma?
9:31:09
otwieracz
I believed something like: `(drakma:http-request (build-url "restore") :method :post :parameters `(("data" . ,(pathname file))))`, but it keeps running indefinitely with numerous weird TCP Window Something messags in wireshark.
9:49:11
|3b|
otwieracz: maybe :parameters `(("data" . (,(pathname file) :content-type ".../..." :filename "..."))) ?
9:50:09
scymtym
beach: in the first paragraph of section 3, inlining of globally defined functions is discussed. i have two suggestions: 1) state explicitly (if it actually is the case) that the remainder of the paper will not be concerned with this kind of inlining 2) if possible, avoid "we simply incorporate the abstract syntax tree of F" since that sounds like the descriptions in other sources cited and criticized earlier
9:53:42
scymtym
beach: i have no idea either. that's why i didn't try to suggest an alternate formulation
9:55:02
flip214
minion: memo for sjl: thanks a lot for the vlime update.... (but) I'm currently looking at spacemacs.... let's see.
10:00:26
beach
scymtym: I added a phrase that I hope clarifies the purpose of incorporating the AST.
10:16:24
|3b|
beach: in 3rd bullet list in 3.2 "...about ownership lexical variables.", missing "of"?
10:22:42
beach
I am asking because other people here also use "what" instead of "which" or "that", so I am wondering what languages might do that.
10:24:52
otwieracz
beach: Polish, unfortunately. Sorry, my native language, forigve me for this advertisement. :)
10:26:38
tazjin
I'd love to learn Russian, but it's very difficult to learn a language like that without living in the country
10:47:19
|3b|
beach: could be a bit more clear about how the 4 steps in 3.2 correspond to worklist items, in particular "the mapping" and similar in step 4 are for each of 2 output worklist items
10:51:31
pjb
tazjin: use youtube for you linguistic bath: https://www.youtube.com/channel/UCuSx-lf2ft7hPceGVNHybOw https://www.youtube.com/user/starmedia https://www.youtube.com/watch?v=K59KKnIbIaM https://www.youtube.com/channel/UC2D0dmLHKbIe9aACnlcTLPg
10:52:36
tazjin
pjb: language learning is an interactive process for me, but maybe I could find myself a community of Russian expats ;-)
11:11:50
beach
It used to be current practice to "publish" both in SIGPLAN notices (no peer review) and in a conference (with peer review).
11:13:38
beach
It's OK to include both references in case of SIGPLAN+conference. They may be slightly different, and one could be easier to get hold of.
11:16:19
Lithp
Good day Lispers.. So is it possible to have an object (B) be the slot-value of another object (A) and then modify the print-slot-value of (A) to print the values of (B) under the (A) slot when calling print-object on (A)?
11:16:50
Lithp
Maybe the meta-question is should i be putting object instances in another instances slots?
11:17:17
p_l
Lithp: there's nothing saying you shouldn't. They are just objects, like any other value
11:18:18
|3b|
ACTION isn't sure what you are asking though. do you want to modify the printing of As to show B? or somehow cause the printing to change due to containing a B without explicitly modifying the printing of As?
11:19:55
phoe
this is pretty commonly done, actually, when you want to print-unreadable-object with some details about this object
11:21:04
Lithp
Thats where my problem is arising.. print-unreadable to afile needs to be able to print the nested object
11:22:57
|3b|
just print the contents of the slot, and the print-object method for whatever is there will be used :)
11:28:28
|3b|
ebzzry: what are you trying to load? the message seems to be saying that whatever it is you are loading has a bad .asd :)
12:17:19
solene
hello, I'm stuck at something that seems simple.. I'm trying to loop over a list of values and call a macro with each value, like this example : https://zerobin.net/?ed147d5ef76b1dda#sFl8qUYx6UOztDsm6871VWCEa5pp1jFdWe8+tzkcEvc=
12:22:30
|3b|
solene: macros are expanded before it starts evaluating the loop (for example during compilation), so it can't see the value of variables inside the loop when it is expanded