jackdaniel changed the topic of #commonlisp to: Common Lisp, the #1=(programmable . #1#) programming language | Wiki: <https://www.cliki.net> | IRC Logs: <https://irclog.tymoon.eu/libera/%23commonlisp> | Cookbook: <https://lispcookbook.github.io/cl-cookbook> | Pastebin: <https://plaster.tymoon.eu/>
akonai has quit [Ping timeout: 260 seconds]
azimut has quit [Ping timeout: 255 seconds]
lisp123 has joined #commonlisp
lisp123 has quit [Ping timeout: 268 seconds]
akonai has joined #commonlisp
akonai has quit [Ping timeout: 252 seconds]
nij- has joined #commonlisp
<nij-> Is concatenating two vectors of length M and N taking constant time in CL? Or is it impl dependent? (In that case, how about SBCL?)
<nij-> And just to make sure, concatenating two lists of length M and N takes O(M) time.. right? Or does most implementations cleverly makes it less than O(M)?
akonai has joined #commonlisp
<hayley> Concatenation of vectors is probably O(M+N).
<nij-> Any "sequence" type that takes only constant or log?
random-jellyfish has quit [Quit: Client closed]
<hayley> Not built-in to Common Lisp, but you can create a tree. I think in Erlang it's called an "iolist".
morganw has quit [Remote host closed the connection]
inward has quit [Quit: leaving]
akonai has quit [Ping timeout: 268 seconds]
lisp123 has joined #commonlisp
pve has quit [Quit: leaving]
akonai has joined #commonlisp
lisp123 has quit [Remote host closed the connection]
lisp123 has joined #commonlisp
lisp123 has quit [Remote host closed the connection]
akonai has quit [Ping timeout: 268 seconds]
akonai has joined #commonlisp
akonai has quit [Ping timeout: 272 seconds]
akonai has joined #commonlisp
akonai has quit [Ping timeout: 272 seconds]
akonai has joined #commonlisp
random-nick has quit [Ping timeout: 265 seconds]
akonai has quit [Ping timeout: 260 seconds]
akonai has joined #commonlisp
akonai has quit [Ping timeout: 265 seconds]
lisp123 has joined #commonlisp
lisp123 has quit [Ping timeout: 256 seconds]
lisp123 has joined #commonlisp
lisp123 has quit [Ping timeout: 252 seconds]
akonai has joined #commonlisp
akonai has quit [Ping timeout: 260 seconds]
akonai has joined #commonlisp
akonai has quit [Ping timeout: 246 seconds]
terrorjack has quit [Quit: The Lounge - https://thelounge.chat]
terrorjack has joined #commonlisp
akonai has joined #commonlisp
tyson2 has quit [Remote host closed the connection]
akonai has quit [Ping timeout: 260 seconds]
akonai has joined #commonlisp
lambdart has quit [Remote host closed the connection]
terrorjack has quit [Quit: The Lounge - https://thelounge.chat]
terrorjack has joined #commonlisp
akonai has quit [Ping timeout: 246 seconds]
azimut has joined #commonlisp
pjb has quit [Ping timeout: 265 seconds]
akonai has joined #commonlisp
waleee has quit [Ping timeout: 246 seconds]
lisp123 has joined #commonlisp
lisp123 has quit [Ping timeout: 272 seconds]
akonai has quit [Ping timeout: 246 seconds]
akonai has joined #commonlisp
ec_ has quit [Ping timeout: 255 seconds]
ec_ has joined #commonlisp
azimut has quit [Remote host closed the connection]
azimut has joined #commonlisp
vassenn has joined #commonlisp
akonai has quit [Ping timeout: 260 seconds]
gateway2000 has joined #commonlisp
akonai has joined #commonlisp
aartaka has joined #commonlisp
vassenn has quit [Quit: Leaving]
gateway2000 has quit [Remote host closed the connection]
gateway2000 has joined #commonlisp
aartaka has quit [Ping timeout: 272 seconds]
aartaka has joined #commonlisp
pjb has joined #commonlisp
aartaka has quit [Ping timeout: 264 seconds]
aartaka has joined #commonlisp
<Spawns_Carpeting> is anyone interested in sly supporting unix sockets instead of binding to a real tcp socket on localhost?
<Spawns_Carpeting> (unix sockets can be protected with file system perms and are not able to be accessed from the outside network)
<Spawns_Carpeting> i am tinkering around with patching it to support this and so far it seems to actually work fine
<jackdaniel> you may desyructively concatenate two lists if you have a pointer to the last cons
shka has joined #commonlisp
<jackdaniel> nij-: ^
<jackdaniel> (defun concat (furst-list-last-cons next-list) (setf (cdr first-list-last-cons) next-list))
jolby has quit [Quit: Client closed]
Inline has joined #commonlisp
jolby has joined #commonlisp
azimut has quit [Ping timeout: 255 seconds]
azimut has joined #commonlisp
aartaka has quit [Ping timeout: 260 seconds]
aartaka has joined #commonlisp
aartaka has quit [Ping timeout: 252 seconds]
aartaka has joined #commonlisp
johnjaye has quit [Ping timeout: 268 seconds]
johnjaye has joined #commonlisp
aartaka has quit [Ping timeout: 252 seconds]
aartaka has joined #commonlisp
aartaka has quit [Ping timeout: 256 seconds]
aartaka has joined #commonlisp
azimut has quit [Ping timeout: 255 seconds]
azimut_ has joined #commonlisp
jmdaemon has quit [Ping timeout: 246 seconds]
Lord_of_Life_ has joined #commonlisp
Lord_of_Life has quit [Ping timeout: 272 seconds]
Lord_of_Life_ is now known as Lord_of_Life
azimut_ has quit [Remote host closed the connection]
azimut has joined #commonlisp
morganw has joined #commonlisp
danisanti has joined #commonlisp
<danisanti> hi all!
<danisanti> does anyone know if quicklisp packages are compatible with a free software license?
<danisanti> if not, how do I know a package license?
<beach> Each individual system (not "package") has its own license. But I don't know whether Xach requires the systems in Quicklisp to have any particular license requirements.
lisp123 has joined #commonlisp
<danisanti> beach: how do I know the license of a specific package?
<beach> You look in the LICENSE file or in the ASDF system definition.
rgherdt has joined #commonlisp
<danisanti> so, I need to download the system first?
<danisanti> it seems so
<beach> I know of no other way, other than figuring out where Quicklisp takes the source from and look there.
<danisanti> I would like to know a system license before downloading it
<danisanti> ok
<beach> Usually, you will find the systems on GitHub or similar.
lisp123 has quit [Ping timeout: 246 seconds]
<beach> There shouldn't be any harm in downloading a system, though.
pve has joined #commonlisp
<danisanti> ok
Shareni has joined #commonlisp
danisanti has left #commonlisp [ERC 5.4 (IRC client for GNU Emacs 28.2)]
aartaka has quit [Ping timeout: 272 seconds]
aartaka has joined #commonlisp
<Spawns_Carpeting> I wonder if malicious JavaScript on a website could send a payload to slime or sly running on the same system as the browser
<Spawns_Carpeting> I'm not sure if modern browsers isolate JavaScript from the "real" networking stack via namespaces or not, but this seems a little bit scary to me
aartaka has quit [Ping timeout: 268 seconds]
cosimone has joined #commonlisp
aartaka has joined #commonlisp
Sauvin has quit [Remote host closed the connection]
Sauvin has joined #commonlisp
Sauvin has quit [Remote host closed the connection]
holycow has joined #commonlisp
Sauvin has joined #commonlisp
Sauvin has quit [Remote host closed the connection]
<pve> Hi! It occurred to me that don't think I've ever come across a library that only defines protocols. Do such things exist? Say, a protocol for database access, or even something like an "alexandria" of reasonably general protocols.
Sauvin has joined #commonlisp
Sauvin has quit [Remote host closed the connection]
epony has quit [Remote host closed the connection]
Sauvin has joined #commonlisp
Sauvin has quit [Remote host closed the connection]
Sauvin has joined #commonlisp
Sauvin has quit [Remote host closed the connection]
Sauvin has joined #commonlisp
Sauvin has quit [Remote host closed the connection]
Sauvin has joined #commonlisp
aartaka has quit [Ping timeout: 255 seconds]
aartaka has joined #commonlisp
scymtym_ has joined #commonlisp
scymtym has quit [Remote host closed the connection]
scymtym_ has quit [Remote host closed the connection]
random-nick has joined #commonlisp
<jackdaniel> pve: usually there is no need for such a thing because libraries usually implement home-baked protocol
<jackdaniel> and even if there was a semi-standard protocol (like clim), putting in a library "only" the protocol would be insufficient - you'd need some differentiation mechanism for implementations
<jackdaniel> consider the function clim:find-port - how does it know where to look for ports?
<pve> jackdaniel: "Differentiation mechanism"?
<jackdaniel> one way to do it is to agree on some registry where ports are registered by name by different implementations of the protocol
<jackdaniel> another way to do this is to have such a function as a generic function with a specializable argument client
<jackdaniel> (then say franz-clim and mcclim would specialize it on a token of their own)
<jackdaniel> so potentially there is some use for "protocol-only" libs, but the number of libraries that could (potentially) benefit from it is small, because there is a small number of agreed on protocols
<pve> jackdaniel: I understand. Something like the *client* in eclector?
<jackdaniel> another example is uffi, there is an uffi library and cffi-uffi-compat, both implement the same thing but by different means
<jackdaniel> yes
<jackdaniel> in practice the implementation usually bundles the protocol with the library, because why not - less dependencies and practical benefits are little if not none
<pve> In my database example, suppose I make a library that does some kind of analysis on database tables (like draw a pretty picture of the tables). I'm thinking that if I had a widely used protocol to target, anyone using a db library that also implements the protocol could hypothetically benefit from my library with minimal plumbing.
<jackdaniel> pve: there are two scenarios: either you target existing protocol (say cl-sql) - someone may add a new backend to it. or you define your own protocol with a default implementation targetting (say) cl-sql, then someone may contribute implementation also for postmodern
<pjb> pve: defining a useful protocol is difficult and perhaps in most cases, impossible, or inefficient.
<pjb> pve: Here is for example, a protocol for "dictionaries" https://gitlab.com/com-informatimago/com-informatimago/-/blob/master/common-lisp/cesarum/dictionary.lisp you might notice the overhead that this represents.
<ixelp> common-lisp/cesarum/dictionary.lisp · master · com-informatimago / com.informatimago · GitLab
<jackdaniel> having an independent protocol for "all databases and more" is n-to-m problem - the library protocol would need to cover both possible backends needs and possible frontends needs, so there is probably a lot of code in-between, so it will be come more a library than a "pure" protocol (the plumbing will involve coding)
<jackdaniel> also, as noted earlier, cl-sql is potentially such protocol for sql libraries, but it is bundled with backends (because why not?)
<jackdaniel> adding another "protocol library" that targets both cl-sql and postmodern would be just 1+ layer of indirection
<jackdaniel> (most probably reducing the scope to the lewest common denominator
<jackdaniel> )
<jackdaniel> s/lewdest/lowest/
<pve> jackdaniel: Ok, I see what you mean now. I meant that the protocol has somehow become so widely used that the authors of db libraries choose to implement it because all db tools also target it, therefore enabling goodness for all.
<pve> pjb: yes, I see
<jackdaniel> sure, I'm not saying that it does not make sense - I'm saying that it rarely is beneficial in practice. On the other side of the coin we have portability layers which could be said to be such "protocols" that are added ad-hoc
<jackdaniel> i.e cffi maps into ecl's ffi, sbcl's sb-alien etc packages
<jackdaniel> happy new year!, /me goes offline
<pve> happy new year!
nij- has quit [Ping timeout: 246 seconds]
scymtym has joined #commonlisp
<hayley> Almost there.
<hayley> Happy new year!
pranavats has left #commonlisp [Error from remote client]
cage has joined #commonlisp
nij- has joined #commonlisp
jolby has quit [Quit: Client closed]
<nij-> Spawns_Carpeting have you checked https://github.com/slime/slime/issues/286 ? "SLIME is insecure and easily allows local attackers to execute arbitrary code #286"
<ixelp> SLIME is insecure and easily allows local attackers to execute arbitrary code · Issue #286 · slime/slime · GitHub
<nij-> jackdaniel thanks
* beach just got more motivated to work harder on Second Climacs.
nij- has quit [Ping timeout: 246 seconds]
pranavats has joined #commonlisp
tyson2 has joined #commonlisp
aartaka has quit [Ping timeout: 252 seconds]
aartaka has joined #commonlisp
pranavats has left #commonlisp [Error from remote client]
nij- has joined #commonlisp
<nij-> beach why so (on second climacs)?
aartaka has quit [Ping timeout: 260 seconds]
aartaka has joined #commonlisp
cage has quit [Quit: rcirc on GNU Emacs 28.2]
<jackdaniel> I think that the underlying premise is that it will be a more secure ide than slime
<jackdaniel> (behind the motivation boost)
<beach> nij-: What jackdaniel said.
rgherdt has quit [Remote host closed the connection]
<beach> That was not a major design goal though. I just learned about the problem of SLIME.
son0p has quit [Remote host closed the connection]
azimut has quit [Remote host closed the connection]
azimut has joined #commonlisp
<nij-> Hmm I think it's not hard to add support of unix socket domain.
<nij-> The thing is that it won't be compatible with say windows.
<nij-> The same problem would be so for Climacs v2 too I guess.
<beach> No.
<beach> It runs in the same image that it is also communicating with, so there is no wire protocol.
<nij-> Does it support connecting to multiple lisps?
<beach> Since it doesn't "connect" to any Lisp, that's no.
cosimone has quit [Read error: Connection reset by peer]
nij- has quit [Ping timeout: 272 seconds]
<morganw> I think a Windows equivalent would be a Named Pipe: https://learn.microsoft.com/en-us/windows/win32/ipc/named-pipes
<ixelp> Named Pipes - Win32 apps | Microsoft Learn
<pjb> pve: that said, as module interfaces, protocols can be interesting, in terms of software architecture. So I guess, for database accesses, it may be the right granularity.
<Bike> the linked issue describes a way to do it in windows.
son0p has joined #commonlisp
attila_lendvai has quit [Ping timeout: 252 seconds]
Shareni has quit [Ping timeout: 268 seconds]
Lycurgus has joined #commonlisp
aartaka has quit [Ping timeout: 260 seconds]
masinter has quit [Ping timeout: 268 seconds]
aartaka has joined #commonlisp
Lycurgus has quit [Quit: Exeunt: personae.ai-integration.biz]
rainthree has joined #commonlisp
<rainthree> does anyone have an example how to use https://www.cliki.net/stassats-storage ?
<ixelp> CLiki: stassats-storage
epony has joined #commonlisp
pranavats has joined #commonlisp
peterhil has quit [Ping timeout: 246 seconds]
igemnace has joined #commonlisp
jeosol has quit [Ping timeout: 260 seconds]
<rainthree> https://pastebin.com/DGNNnE8r when is the initialize-instance :after method called for a metaclass? https://github.com/stassats/storage/blob/master/mop.lisp#L248 https://pastebin.com/DGNNnE8r
<ixelp> stassats-storage attempt - Pastebin.com
cage has joined #commonlisp
aartaka has quit [Ping timeout: 260 seconds]
igemnace has quit [Remote host closed the connection]
<Bike> the method will be called when the class is made, in this case when the defclass is evaluated, after the normal initialization of slots
<Bike> so changing class-storage after the fact won't help
<Bike> is this how you're supposed to use the system? if class-storage isn't exported you're probably not meant to mess with it
<rainthree> I am trying to find out how I am supposed to use the system
<rainthree> through experimentation ...
aartaka has joined #commonlisp
<Bike> if i had to guess, you're supposed to specify the storage in the class definition, somehow
<rainthree> hmm (:storage *storage*) after (:metaclass db:storable-class) inside (defclass ... ) seems to work
<rainthree> *almost work
<rainthree> "defclass does not evaluate the class option's arguments. " https://stevelosh.com/blog/2022/08/depending-in-common-lisp/
<ixelp> Depending in Common Lisp / Steve Losh
pranavats has left #commonlisp [Error from remote client]
<semz> Is there some technical (asdf-related?) reason why projects tend to define the package in its own file? Or is it just because every other file will depend on the package?
<semz> i.e. is there anything speaking against putting the defpackage form and a bunch of common definitions together into one common.lisp
son0p has quit [Ping timeout: 256 seconds]
aartaka has quit [Ping timeout: 272 seconds]
<phoe> the issue is that the ASD file tells ASDF how to load the system
<phoe> in theory you can bundle everything in one file, package definitions and asdf definitions and what not, it'll just be a big ole modularity problem
aartaka has joined #commonlisp
rgherdt has joined #commonlisp
pranavats has joined #commonlisp
<Bike> semz: generally just a dependency/organization thing, yeah. there's no technical reason you can't put other code in the package definition.
pranavats has left #commonlisp [Error from remote client]
<semz> I see.
waleee has joined #commonlisp
pranavats has joined #commonlisp
rainthree3 has joined #commonlisp
rainthree33 has joined #commonlisp
rainthree has quit [Ping timeout: 268 seconds]
<rainthree33> bike: thanks for the help. working example https://gist.github.com/rainthree/87d0271a98bf1539a728f830f35cae1c . Now what has remained is to figure out how to use indexes, relations , if anyone manages to figure out please do share with me thank you
<ixelp> stassats-storage simple working example https://github.com/stassats/storage · GitHub
rainthree3 has quit [Ping timeout: 246 seconds]
nij- has joined #commonlisp
<nij-> beach In that case, can you have a single Climacs v2 connecting to multiple different lisp images at the same time?
rainthree33 has quit [Quit: Leaving]
danieli has quit [Quit: Alpine Linux, the security-oriented, lightweight Linux distribution]
danieli has joined #commonlisp
joast has quit [Quit: Leaving.]
aartaka has quit [Ping timeout: 272 seconds]
aartaka has joined #commonlisp
Inline has quit [Quit: Leaving]
nij- has quit [Ping timeout: 252 seconds]
son0p has joined #commonlisp
Inline has joined #commonlisp
akoana has joined #commonlisp
jmdaemon has joined #commonlisp
cage has quit [Quit: rcirc on GNU Emacs 28.2]
morganw has quit [Remote host closed the connection]
axvr has left #commonlisp [#commonlisp]
Noisytoot has quit [Excess Flood]
Noisytoot has joined #commonlisp
aartaka has quit [Ping timeout: 272 seconds]
akoana has quit [Quit: leaving]
aartaka has joined #commonlisp
paul0 has joined #commonlisp
aartaka has quit [Ping timeout: 252 seconds]
aartaka has joined #commonlisp
<holycow> happy new years everyone
<pjb> semz: since the packages must be defined to read the source code using symbols from those packages, it's easier to define them in a separate file. Sometimes, you may have circular depedencies between modules, but this is ok, if the circle is virtual, with no circular dependencies between the packages themselves, and implementation A depending on the defpackage B and implementation B depending on the defpackage A.
<pjb> semz: If you store the defpackage forms each in the implementation file, that'd be a circular dependency between the two files. If you put the defpackages in a separate file, then the circular dependency doesn't occur.
<pjb> holycow: Happy New Year!
jolby has joined #commonlisp
anticomputer has quit [Ping timeout: 255 seconds]
anticomputer_ has joined #commonlisp
<holycow> :)
asarch has joined #commonlisp
gateway2000 has quit [Remote host closed the connection]
<Inline> happ new year
gateway2000 has joined #commonlisp
tibfulv has quit [Remote host closed the connection]
tibfulv has joined #commonlisp
jeosol has joined #commonlisp
gateway2000 has quit [Remote host closed the connection]
Everything has joined #commonlisp
shka has quit [Ping timeout: 260 seconds]
asarch has quit [Quit: Leaving]
an_origamian has joined #commonlisp
azimut has quit [Ping timeout: 255 seconds]
aartaka has quit [Ping timeout: 260 seconds]
gateway2000 has joined #commonlisp
anticomputer_ has quit [Ping timeout: 255 seconds]
aartaka has joined #commonlisp
anticomputer has joined #commonlisp