libera/commonlisp - IRC Chatlog
Search
0:06:09
etimmons
Shinmera: trivial gray streams has file-position, and I'm pretty sure it works on most implementations
2:49:32
Guest74
is there a way to add/view documentation for a specific method of a generic function?
3:00:32
dbotton
if there a popular library for doing text templates? I am looking to generate "scaffolding" for projects, ie. an asdf file, some basic lisp files, etc. much of which a simple replace of some symbol would do.
3:01:48
White_Flame
it would be nice if backquoted forms could be passed around, but they can't. You could use a macro for an active template
3:03:52
dbotton
The idea is to have a set of files and just replace some text in each and write them out to some directory
3:04:11
Guest74
I don't see how typing out exactly what the page says is any help when I said I don't understand what is on the page.
3:04:47
mfiano
Common Lisp is a class-based language. If you don't know the function for getting a method instance, it is find-method
3:05:07
mfiano
I'm sorry, but I can't write code for you right now. Those are the signatures you need.
3:05:18
EdLangley[m]
I’m not at my laptop at the moment, and the details here are implementation-dependent
3:05:31
White_Flame
dbotton: here's a functional, short, but janky way of using backquotes: https://plaster.tymoon.eu/view/2898#2898
3:07:35
White_Flame
there's really no difference in having that sort of literal backquoted form, and a macro body I guess
3:08:48
EdLangley[m]
But, if you’re generating lisp source it’d be better to take advantage of lisp’s builtin templating mechanisms.
3:10:51
EdLangley[m]
(let ((*print-case* :downcase)) (pprint `(asdf:defsystem ,name . . .) *file-stream*))
3:23:49
mfiano
I was about to direct them to #clschool. I can't remember all the guests that come here.
3:55:18
dbotton
Is there a simple tutorial on presentations in CLIM/McCLIM around? Something very practical?
3:57:58
beach
dbotton: But most participants are probably still asleep, and jackdaniel is not quite well yet, perhaps.
3:59:21
mfiano
beach: Do you think it is worth reading for an experienced Common Lisper? I am getting the vibe that it was Symbolics marketing for what OOP should be, and I'm unsure if I would learn anything from it.,
4:00:41
beach
If you already use CLOS, then probably no. And I didn't much like the book, mainly because the (in my opinion) badly chosen examples.
4:03:43
beach
mfiano: I read the Keene book and didn't understand much of how to use CLOS. Then I read the CLIM II specification, and I understood a lot more.
4:07:32
mfiano
I see. I have not much interest in graphical interfaces, or graphical environments for that matter, so I am unsure if I could stomach it. I prefer working at a terminal.
4:10:39
beach
Josh_2: Sure, it is not completely worthless. It does contain the basics of CLOS. But I suspect mfiano already knows that much.
4:11:22
mfiano
I do know quite a bit of CLOS and the MOP already, but I think there needs to be more books on practical applications of them.
4:11:54
beach
I totally agree. I have some partially finished books, but every book project is stalled now.
4:12:08
mfiano
I think AMOP was a terrible techical book (like most of them). It could have used a couple dozen more copy editors and maybe a typesetter or 3.
4:13:53
mfiano
AMOP was pretty painful to read because of my attention to detail. I had to ask a lot of questions when the book was plain wrong or contradicted itself in various places.
4:13:59
beach
My book projects depend on having a coauthor to take care of the copy editing, precise organization, LaTeX details, etc. But my favorite coauthor essentially abandoned me. Then phoe was going to help me with one of my books, but then got very busy with lots of other stuff.
4:14:55
beach
mfiano: I started it twice without finishing. It was only on my third attempt that I managed to read to the end. And that was after learning a lot more of CLOS from the CLIM specification.
4:15:18
beach
dre: Please don't post links without an explanation of what we can expect if we follow them.
4:15:31
mfiano
Who is your favorite coauthor? I take it that is an abbreviation to auto-complete, but it is slightly annoying we never know who that is :)
4:16:23
beach
mfiano: Oh, "everybody" knows. Her name is Irène Durand, and sometimes comes here as idurand.
4:16:44
beach
mfiano: She is the only coauthor on my papers and books. So it is not hard to be the favorite one. :)
4:18:37
beach
mfiano: And I can already tell that he is essentially never going to be available, so I gave up on him.
4:19:27
mfiano
I think that is accurate. phoe is doing amazing work for the community, but he moves around a lot.
4:21:43
beach
My favorite coauthor was perfect. She knows her domain very well. She is meticulous and hard working. And she lives not too far from me, so we can easily meet. But she has changed her priorities of how she likes to spend her time.
4:22:48
moon-child
mfiano: waitaminit, if you don't like graphical environments, why are you writing a colour library?
4:24:24
mfiano
moon-child: That is a good question. I don't like using a graphical interface. Most computing tasks can be done perfectly fine with a command line interface. However, just because I like algorithmic art and generating imagery, doesn't mean I have to use the mouse or interact with GUI widgets.
4:25:31
moon-child
I think there are myriad opportunities to take advantage of graphical organization for better presentation of information
4:29:49
mfiano
Not just ergonomic disasters, but everytime I have to take my fingers off the keyboard to reach for the mouse, usually means I'm switching to some other context, which is a huge productivity disaster, and even a few milliseconds can disrupt "flow".
4:30:30
mfiano
My workflow is entirely keyboard oriented, except for very few tasks that are unavoidable.
4:32:23
moon-child
to me, the problem is not switching. The problem is that mice are generally used to choose from among discrete objects and perform discrete actions, a task to which (as analogue instruments) they are not well suited
4:33:14
mfiano
I also tend to try to keep a similar working environment across all my hardware, some virtual/remote even.
7:05:45
jeosol
mfiano: I can attest to keep similar environment across machines - i run the same linux distro on my two working machines (one for dev and other for testing) - tend to upgrade OS similarly and compiler updates like SBCL. it makes for less surprises and issues
7:09:23
jeosol
beach: changed her prorities of how she likes to spend her time .... meaning she change areas of focus and interest?
7:11:34
jeosol
is there a lot of money in publishing these days? I don't know and asking genuinely. I guess it depends on the area of focus
7:12:09
jeosol
I believe a lot of people can benefit from using CL but they get bugged down with emacs and parentheses issues
7:12:50
beach
jeosol: I have a book "Introduction to Computer Science" self published through Amazon, and I make around 2€ per month.
7:12:51
jeosol
beach: very nice, I eventually worked through the algorithms and DS refreshers I was taking a while back. Finally the graphs and doing some dynamic programming.
7:13:36
beach
I see. About half of the books on algorithms and data structures are so bad that the authors should be spanked.
7:14:51
jeosol
binary search with the issue of computing the mid, remember seeing issues with that overflow or when high and low are very large
7:16:13
jeosol
beach: i take it you are aware of the CL book on algorithms, forgot the guys name, from Ukraine I think? vsevelod? or something like that
7:16:13
beach
Well, that one is fairly easy to fix. The main problem is that half the books start by testing for equality, thereby making the overall algorithm half the speed as it should be.
7:17:16
jeosol
Interesting point, I was looking at that lately, I see yesterday, don't recall it was wiki, or somewhere, the equality was put at the end
7:23:28
jeosol
Makes a lot of sense. One branch test for going left or right , and when R=L, break out of the loop andd check if A[L] == Target, and return T or nil
7:25:02
beach
Tanenbaum and Bos claim that it is impossible to write an operating system in a language with automatic memory management, just to take one example.
7:25:47
beach
That's why I feel compelled to write better books. But then, like I said, the projects are stalled.
7:28:45
beach
Thanks. I can come up with the general contents, but I don't have the time or the energy with all the details, hence the need for a meticulous coauthor.
7:30:39
beach
Oh, right, we have one about architecture published in French. That one also gives a few € per year.
7:32:03
beach
The book entitled "Concrete and abstract data types" hides Common Lisp in that it translates it to an algorithmic language. But I consider just using Common Lisp, because the additional work to check the code required my favorite coauthor.
7:35:24
beach
The book on operating systems mainly corrects the incorrect history of other books, and laments the fact that we still use derivatives of UNIX, even though the UNIX execution model exists because of the limitations on very small and very simple hardware.
7:37:12
jeosol
My adviser in school used the word pendantic, when I first turned in some plots and not analysing all the behavior, since then I remember that word and always double check and triple check things ...
9:05:23
pjb
Note that in CL, (truncate (+ low high) 2) is as good as (+ low (truncate (- high low) 2)). The only case where it may make a difference is if you go out-of-memory upon the bignum sum, (but then you'd probably go out-of-memory on the difference as well).
9:06:00
pjb
The problem is indeed, that most people don't program in their programming language, but instead program in an imagined language that ressemble their programming language.
9:07:16
pjb
Look at how beach strive to give more meaning to operators, so that (if a b) => (when a b) ; (return (when a b)) => (return (if a b nil)) etc… It doesn't matter if you write in CL, but it matters if you try to write in a imaginary language ressembling CL. And the problem is that you need to be able to read CL anyway, or else…
9:08:06
moon-child
eh, I would expect the difference code to be slightly faster. And, given high>low (presumably...), less likely to cons. It would never cons in the common case when high and low are array indices and fixnums
9:09:46
moon-child
and the difference code is clearer in some respects, imo. 'Start at low, and go halfway towards high.' Vector basically
11:10:18
phoe
minion: memo for Bike: I think this sort of snippet can work as some basic FBIND test, https://plaster.tymoon.eu/view/2899#2899 - Serapeum's FBIND obviously fails the identity comparison because it makes an intermediate function
11:10:44
phoe
minion: memo for Bike: I'll try to make an implementation that fulfills that test in a spare while