libera/commonlisp - IRC Chatlog
Search
18:40:33
EdLangley[m]
And my experience is that other languages have a huge problem of getting people used to the idea of not updating
18:41:17
EdLangley[m]
If you're always upgrading all the time, the work is significantly more manageable.
18:41:39
lisp123
EdLangley[m]: Actually it doesn't affect me much. But something does sit off with me on not being able to specify a path to a particular dependency. Like, reading (load "/new-sass-idea/make-money.lisp") is a natural way of thinking about loading files, but with ASDF, I have to learn about how the process works
18:42:31
etimmons
lisp123: But what if your "main" system uses a system that thinks _it_ is the "main" system and defines paths as well?
18:42:53
EdLangley[m]
For example, there's nothing preventing someone from writing an ASDF component that loads code from an SQLite database
18:43:24
etimmons
IMO there should be no distinction between a "main" system and non-main system. And that's why it's important configuration is decoupled from the system definition
18:44:15
lisp123
EdLangley[m]: Yes, but that's getting too abstract :P Lisp is just an implementation detail of my thoughts ;) Like most people *DO* think in terms of files
18:45:45
etimmons
the short story is that you should really only care about the exact versions of your dependencies when you're delivering something like an application. In that case, you deliver an ASDF config that finds the exact systems you want
18:46:59
etimmons
Also makes it easier for a dev to hack on one of your deps without needing to modify your .asd file to point it to a different place on their filesystem, etc.
18:47:05
lisp123
etimmons: I didn't think of "main" systems at all, perhaps I missed it, but is it an issue if a system definition called by another system definition defines its own paths?
18:49:23
etimmons
And you _can_ mix and match between different versions of the QL dist if you know what you're doing
18:49:27
lisp123
etimmons: I don't deny the 'automatic' approach of ASDF makes using systems much more convenient. But I disagree that you should only care about dependencies if you are delivering an application, some of us will want control from the first step in the process
18:50:30
lisp123
I guess the crux is the though of whether files are an implementation detail or not
18:50:59
etimmons
lisp123: I understand, but the reality is that current CL implementations make that basically impossible.
18:51:25
etimmons
because as soon as your and one of your deps disagree on where a shared dep is loaded from you've got problems
18:54:10
Demosthenex
hrm, i'm trying to figure out how to make trivia:match use my object accessor when it encounters a keyword (ie: compare the keyword to the obj)
18:54:10
etimmons
But that doesn't leak to users of my library and is kept up to date on a semi-regular basis by automated CI jobs
18:58:59
lisp123
I do think the lack of filepaths adds to quite a bit of that initial complexity. But I guess you may not want to enable practices that could cause some issues when systems have many dependencies (as just discussed)
18:59:45
White_Flame
foxfromabyss: if you don't want to use OS threads (which I personally don't see as problematic for your use case), you could also use timers, if your implementation supports them. They can interrupt your code every 15 seconds and do something
20:38:12
pjb
foxfromabyss: just put it in some directory, and have asdf:*central-registry* or quicklisp:*local-project-directories* point to it.
20:38:39
pjb
Changing the name of the system would be in order if you wanted to be able to load both the old and the new library at the same time.
20:41:25
pjb
asdf:*central-registry* let you shadow a library locally for all asdf commands. quicklisp:*local-project-directories* or storing in ~/quicklisp/local-projects/ let you shadow a library locally for all quicklisp and asdf commands.
22:47:29
_73
is there a library that provides reader macros on top of cl-ppcre that enables you to use syntax similar to perl?
22:48:38
Demosthenex
_73: i saw one that did #R for regexps, but its not going to improve the function calls
22:50:01
_73
Demosthenex: do you happen to remember what is was called? I was thinking of making my own but don't want to reinvent the wheel.
22:53:24
_73
Bike: this library goes beyond string interpolation? I was thinking syntax similar to perl's m// s/// etc.
22:55:23
Bike
it has stuff intended to allow you to write regexes exactly as you would in perl. i don't know anything beyond that.
23:07:09
tom
Hey! Any sly&sbcl users here? :) I'm trying to trace a method with sly, but it doesn't pass `:methods t` so sbcl doesn't trace the method
0:16:33
yottabyte
should I use fset:equal? instead of equalp for fset:set equality? both appear to work
6:02:52
beach
remexre: Sets are tricky things. There is really no abstract data type called a "set" because it is impossible to have all set operations be efficient simultaneously. That is why every abstract data type that contains other objects is defined by the operations that are supported. If you give us the operations you like, perhaps we can help.
6:03:22
beach
remexre: But in general, such a representation would not allow for many operations to be efficient.
6:05:14
moon-child
sorted vector gives you binary search if you care for it, but no in-place intersection or union
6:05:41
beach
remexre: For intersection, convert to lists, do the intersection, convert to a vector, sort.
6:07:11
beach
That sounds like premature micro-optimization without any measure to determine whether it is necessary.
6:07:51
beach
remexre: You are comparing cache effects and asymptotic complexity. They are not the same order of magnitude.
6:08:29
beach
remexre: My guess is that you are going to spend all the time comparing characters in strings anyway.
6:09:05
moon-child
beach: 'For intersection, convert to lists, do the intersection, convert to a vector, sort' hmm? If you were using such a representation--and you cared for performance--you could do it in O(m+n) by iterating over both vectors and VECTOR-PUSH-EXTENDing a result
6:09:18
moon-child
(and if you don't care for performance, just use a list and don't bother with anything else)
6:09:43
remexre
the point with the asymptotics was that they're not terrible; not ruining the cache by using vectors was more of the point
6:10:55
moon-child
sure. I think the problem is insufficiently motivated/contextualized. If it's desirable for some reason to use a vector in the first reason, that same reason may also make it undesirable to use an intermediate list (which was your suggestion)
6:11:55
moon-child
given two sorted vectors, you can produce a sorted intersection vector in linear time, without consing an intermediate list and calling SORT on it
6:12:33
moon-child
yes. And if it doesn't matter then you can just use lists. We are going in circles :P
6:13:46
moon-child
remexre: can you motivate your problem? Do you have set-processing code which is slow?
6:14:09
remexre
no, I'm planning on writing code that I don't want to go back and change the set representation for
6:14:46
moon-child
if your interface is properly abstracted, it should not be prohibitively difficult to change your representation
6:16:04
remexre
right, but i know the representation I want, and I would be surprised if I needed to change *from* that later