freenode/#lisp - IRC Chatlog
Search
14:47:10
xificurC
is iterate usable without `use-package`ing it? From a REPL session I can't get it to work. Something like `(iter:iter (for i from 1 to 10) (collect i))` spurts a number of undefined function/variable warnings
14:49:30
xificurC
this works and is very readable `(iter:iter (iter:for iter::i iter::from 1 iter::to 10) (iter:collect iter::i))`
14:59:41
_death
sbcl has iter::(iter (for i from 1 to 10) (collect i)) but it's unlikely that you want that
15:03:04
beach
xificurC: There should be no particular reason to put your own variables in the ITER package.
17:41:52
devon
Unhappy with M-x irc, mainly because not comint based & randomly trashes command history. Any suggestions?
17:46:38
markasoftware
can someone recommend a quicklisp library for finding the roots of a polynomial with the given coefficients?
18:45:27
frodef
slightly off-topic, but can anyone tell me when I am editing a file in emacs that is under git, how can I get a buffer with a previous revision of that file?
18:53:10
frodef
not even a diff, just the plain file version that I checked in some days ago.. seems to me the most basic of operations, but somehow it's not obvious how to do it.
18:56:13
frodef
or rather, I can do M-x vc-revision-other-window, but I don't know how to name an old revision. Probably I don't understand git.
18:58:01
ck_
"23rd" even -- how embarrassing! I'll now hide before someone "off-topic!"s me out of here
18:59:12
frodef
ck_: thanks! (I'm surprised/frustrated that I can't seem to find a menu over old revisions, though.)
19:01:04
frodef
ck_: ok. I just thought I could use vc pretty much like I used to do with CVS, but I guess not.
19:02:14
ck_
you probably can, I don't have experience with that though. Many things are probably just personal preference, but it's generally accepted that magit is very polished, and its menu system is (I think) easy to pick up
22:15:26
frodef
I fell silly for asking this, but what is the preferred idiom for taking the subset of a list by some predicate?
22:17:31
frodef
yes, but remove-if-not and the :test-not args are "deprecated", which makes me suspect there's supposed to be another way...
22:18:15
Bike
it was deprecated like twenty years ago because they thought COMPLEMENT would be more useful.
22:18:53
Bike
but there is no problem using remove-if-not and even if there was somehow a new standard revision, they probably wouldn't actually remove it.
22:29:20
mfiano
It's surprisingly actually smaller code size on SBCL, too (though code zie is not a good measure of performance).
22:54:36
frodef
Bike: right, thanks, COMPLEMENT was probably the piece of the puzzle I'd forgotten about.
22:57:04
frodef
...and even more so for (remove keep-value ... :test-not 'eql), which is not very readable at all.
23:00:57
frodef
-- "Several alternative names for REMOVE-IF-NOT were suggested: KEEP-IF, ABSTRACT, FILTER. We did not pursue these suggestions." Oh well.
0:07:53
aeth
a true IF-NOT in the language would have a second branch and just reverse the order of the IF
2:12:35
dbotton
if anyone over next day or so has time and can try out my tutorial 8 from CLOG running at http://office.botton.com:8080/ I made some critical changes from last test (thank you for using it those that did). The source is at https://github.com/rabbibotton/clog/blob/main/tutorial/08-tutorial.lisp
2:14:13
brandflake11
Hey all, I have a question for you all. I am writing a function in lisp, and need to create a list out of the function's arguments. Here is what I have for the function:
2:14:56
Bike
please use a pastebin service for multi-line pastes. anyway, so this function is supposed to randomly select and return one of its three arguments?
2:15:40
Bike
The only problem I see in this paste is that you meant to write (list note1 note2 note3).
2:17:07
Bike
you wrote (note1 note2 note3). this means it will call the function NOTE1 with two arguments. Since there's no function called NOTE1, you get an error.
2:17:45
Bike
your compiler might alert you to this. SBCL says "Undefined function: NOTE1" when you compile, and "The function NOTE1 is undefined" when you actually call it.
2:19:11
Bike
No, but if you all you want to do is pick one of the arguments randomly, you probably don't need to make a list.
2:19:13
brandflake11
I tried '(note1 note2 note3), but they gave me the literal variable names as members in the list
2:23:24
brandflake11
Does the &rest args stand for something? Like is it an abbreviation of a phrase in English?