phoe 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/>
<Alfr> VincentV`, assuming these are the upgraded-array-element-types: (array (signed-byte 8)) are the arrays which can only store (signed-byte 8)s, and every array of type (array signed-byte) must be able to store signed-bytes.
lispy has quit [Quit: Leaving]
jeosol has joined #commonlisp
kevingal has quit [Remote host closed the connection]
pilipilihoho has quit [Quit: See ya!]
nature has quit [Ping timeout: 240 seconds]
igemnace has joined #commonlisp
zacque has joined #commonlisp
Oladon has quit [Quit: Leaving.]
<VincentV`> Alfr: That sort of makes sense, OK. This begs a question: is there a vector type Y such that '(simple-array (signed-byte n)) would be a subtype of Y for any n? The reason I am asking: I just want to define a type that is a vector of two reals. Turns out (vector real 2) is not enough. There's also (simple-bit-vector 2) and now, apparently, simple-array of signed-bytes, which I don't want to hardcode to 8.
lispy has joined #commonlisp
<Alfr> VincentV`, there's a satisfies type specifier.
<VincentV`> Alfr: i guess that will have to do, thanks
lisp123 has joined #commonlisp
notzmv has joined #commonlisp
karlosz has joined #commonlisp
lisp123 has quit [Ping timeout: 256 seconds]
VincentV` has quit [Ping timeout: 240 seconds]
Guest74 has joined #commonlisp
s-liao has quit [Quit: Client closed]
s-liao has joined #commonlisp
Oladon has joined #commonlisp
ggoes has left #commonlisp [ERC 5.4.1 (IRC client for GNU Emacs 29.0.50)]
Bike has joined #commonlisp
vats has joined #commonlisp
s-liao has quit [Quit: Client closed]
Inline__ has joined #commonlisp
karlosz has quit [Quit: karlosz]
s-liao has joined #commonlisp
Inline has quit [Ping timeout: 245 seconds]
orestarod has quit [Ping timeout: 252 seconds]
<White_Flame> victor: simple-vector mandates the element type of T, so for any numeric work it tends to be advantageous to use simple-array specialized to a numeric type
<White_Flame> but once you specialize, then as you see you no longer have any sort of type compatibility unless the specialization is the same
s-liao has quit [Client Quit]
<White_Flame> the worst is when binary-oriented libaries use simple-vectors of bytes :-P
<White_Flame> (oops, didn't notice that the tab completion hit someone else)
s-liao has joined #commonlisp
s-liao has quit [Client Quit]
Oladon has quit [Quit: Leaving.]
Oladon has joined #commonlisp
waleee has quit [Ping timeout: 245 seconds]
tyson2 has quit [Remote host closed the connection]
<beach> Good morning everyone!
Bike has quit [Quit: Connection closed]
Common-Lisp is now known as Guest8728
lispy has quit [Ping timeout: 272 seconds]
semz_ has joined #commonlisp
azimut has quit [Remote host closed the connection]
s-liao has joined #commonlisp
azimut has joined #commonlisp
semz has quit [Ping timeout: 250 seconds]
aartaka has joined #commonlisp
Oladon has quit [Quit: Leaving.]
sbodin has quit [Quit: Leaving]
sbodin has joined #commonlisp
sbodin has quit [Client Quit]
aartaka has quit [Ping timeout: 240 seconds]
aartaka has joined #commonlisp
karlosz has joined #commonlisp
dirtcastle has joined #commonlisp
azimut has quit [Remote host closed the connection]
azimut has joined #commonlisp
Inline__ is now known as Inline
aartaka has quit [Ping timeout: 256 seconds]
aartaka has joined #commonlisp
aartaka has quit [Ping timeout: 256 seconds]
aartaka has joined #commonlisp
Guest74 has quit [Quit: Connection closed]
Guest74 has joined #commonlisp
hashfunc803 has joined #commonlisp
s-liao has quit [Ping timeout: 256 seconds]
spiaggia has joined #commonlisp
cjb has quit [Quit: rcirc on GNU Emacs 29.0.50]
attila_lendvai has quit [Ping timeout: 268 seconds]
attila_lendvai has joined #commonlisp
semz_ is now known as semz
Cymew has joined #commonlisp
zacque has quit [Quit: Goodbye :D]
<hashfunc803> is there a way to change the name of a symbol?
Josh_2 has joined #commonlisp
<Josh_2> Good morning
<spiaggia> hashfunc803: I don't think so, no.
<hashfunc803> meaning, in pseudo-code: ... (defvar myvar 55) (get-symbol myvar) => MYVAR ... (change-symbol myvar YO) YO => 55
<pjb> hashfunc803: nope.
<pjb> no way.
<spiaggia> hashfunc803: It would be very confusing for the package, where the name is used as a key in a hash table (typically)
<hashfunc803> dang ok
<pjb> (let ((yo myvar)) yo) --> 55
<hashfunc803> ok, maybe i'm not doing something right. since i'm interating over a list of symbols and trying to transform each of the symbol names
<hashfunc803> e.g., '(sym0 sym1 sym2) => '(SYM000 SYM001 SYM002)
<pillton> Hmm.. A reader could, in theory, be told that the symbol characters YO should be interned as the symbol MYVAR.
<pjb> (mapcar (lambda (symbol) (intern (format nil "SYM~3,'0D" (parse-integer (string symbol) :start 3)))) '(sym0 sym1 sym2)) #| --> (sym000 sym001 sym002) |#
<pjb> hashfunc803: ^
<pjb> pillton: indeed, this could be done with a reader macro.
<pjb> or you can use a symbol-macro: (define-symbol-macro yo myvar) yo -> 55 ; (setf yo 33) ; myvar --> 33
<pjb> hashfunc803: ^
azimut has quit [Remote host closed the connection]
azimut has joined #commonlisp
<pillton> I had completely forgotten about symbol macros in the global environment. My apologies.
zacque has joined #commonlisp
<hashfunc803> pjb: i'm trying to attempt something like this: (mapcar (lambda (s) (setf s esrever)) '(reverse reverse reverse)) --> '(esrever esrever esrever)
<hashfunc803> but that clearly doesn't work
<spiaggia> hashfunc803: Why are you using symbols rather than strings?
<hashfunc803> spiaggia: that's just what I'm trying to do
<spiaggia> hashfunc803: That's the kind of stuff you want to do to strings, but not to symbols
<hashfunc803> spiaggia: i'm trying to do it with symbols
<spiaggia> hashfunc803: But then, there is no need to change the name of any symbol.
<hashfunc803> spiaggia: what?
<spiaggia> hashfunc803: What is the point of working with symbols if you want to reverse the names?
<hashfunc803> spiaggia: that's just what i'm trying to do dude
<spiaggia> hashfunc803: What characteristic of symbols made you want to do it with symbols?
<spiaggia> And please don't call me "dude".
<hashfunc803> my fault. i'm trying to work on symbols specifically in my case. there really is no simpler way to put it
s-liao has joined #commonlisp
<spiaggia> Fine
<pjb> hashfunc803: (mapcar (constantly 'esrever) '(reverse reverse reverse)) #| --> (esrever esrever esrever) |#
<pjb> hashfunc803: use STRING and INTERN as demonstrated in my first example!
<hashfunc803> pjb: alirght i'll give it a go.
<hashfunc803> pjb: spiaggia: thanks
<hashfunc803> spiaggia: also, sorry for calling you dude earlier
<spiaggia> Don't worry about it.
vats has quit [Ping timeout: 240 seconds]
dirtcastle has quit [Ping timeout: 240 seconds]
dirtcastle has joined #commonlisp
dirtcastle has quit [Client Quit]
rotateq has joined #commonlisp
spiaggia has quit [Quit: ERC (IRC client for Emacs 26.3)]
minion has quit [Remote host closed the connection]
specbot has quit [Remote host closed the connection]
specbot has joined #commonlisp
minion has joined #commonlisp
amb007 has quit [Ping timeout: 256 seconds]
amb007 has joined #commonlisp
Cymew has quit [Ping timeout: 272 seconds]
MajorBiscuit has joined #commonlisp
hashfunc803 has quit [Remote host closed the connection]
mgl has joined #commonlisp
s-liao has quit [Ping timeout: 256 seconds]
Cymew has joined #commonlisp
shka has joined #commonlisp
attila_lendvai has quit [Ping timeout: 272 seconds]
random-nick has joined #commonlisp
aartaka has quit [Ping timeout: 256 seconds]
aartaka has joined #commonlisp
aartaka has quit [Ping timeout: 256 seconds]
aartaka has joined #commonlisp
epony has quit [Read error: Connection reset by peer]
karlosz_ has joined #commonlisp
karlosz has quit [Ping timeout: 256 seconds]
karlosz_ is now known as karlosz
s-liao has joined #commonlisp
s-liao has quit [Client Quit]
aartaka has quit [Ping timeout: 256 seconds]
aartaka has joined #commonlisp
treflip has joined #commonlisp
mogan90 has joined #commonlisp
treflip has left #commonlisp [ERC (IRC client for Emacs 27.2)]
karlosz_ has joined #commonlisp
karlosz has quit [Ping timeout: 272 seconds]
karlosz_ is now known as karlosz
MajorBiscuit has quit [Ping timeout: 240 seconds]
MajorBiscuit has joined #commonlisp
aartaka has quit [Ping timeout: 272 seconds]
amk has quit [Ping timeout: 256 seconds]
aartaka has joined #commonlisp
VincentVega has joined #commonlisp
karlosz has quit [Quit: karlosz]
<VincentVega> White_Flame: just saw the message, gotcha, thanks for the info!
aartaka has quit [Ping timeout: 272 seconds]
amk has joined #commonlisp
aartaka has joined #commonlisp
pillton has quit [Quit: ERC (IRC client for Emacs 27.2)]
rogersm has joined #commonlisp
azimut has quit [Remote host closed the connection]
azimut has joined #commonlisp
dirtcastle has joined #commonlisp
amk has quit [Ping timeout: 240 seconds]
MajorBiscuit has quit [Ping timeout: 256 seconds]
nature has joined #commonlisp
amk has joined #commonlisp
jeosol has quit [Quit: Client closed]
zacque has quit [Quit: Goodbye :D]
nature has quit [Quit: Lost terminal]
v88m has quit [Ping timeout: 240 seconds]
nature has joined #commonlisp
cosimone has joined #commonlisp
kevingal has joined #commonlisp
tyson2 has joined #commonlisp
aartaka has quit [Ping timeout: 272 seconds]
aartaka has joined #commonlisp
v88m has joined #commonlisp
aartaka has quit [Ping timeout: 272 seconds]
kevingal has quit [Remote host closed the connection]
aartaka has joined #commonlisp
orestarod has joined #commonlisp
terrorjack has quit [Quit: Ping timeout (120 seconds)]
terrorjack has joined #commonlisp
aartaka has quit [Ping timeout: 240 seconds]
aartaka has joined #commonlisp
Colleen has quit [Read error: Connection reset by peer]
Colleen has joined #commonlisp
pranavats has left #commonlisp [Error from remote client]
cosimone has quit [Remote host closed the connection]
robin has quit [Quit: Leaving]
robin has joined #commonlisp
s-liao has joined #commonlisp
pranavats has joined #commonlisp
hirez has quit [Quit: Later]
servytor has joined #commonlisp
cosimone has joined #commonlisp
VincentV` has joined #commonlisp
aartaka has quit [Ping timeout: 256 seconds]
VincentVega has quit [Ping timeout: 272 seconds]
Bike has joined #commonlisp
hirez has joined #commonlisp
dirtcastle has quit [Ping timeout: 240 seconds]
dirtcastle has joined #commonlisp
<gjvc> (in-package #:gate-fix)
<gjvc> oops
<gjvc> which is preferable between (defpackage "my-fancy-package-name") and (defpackage #:my-fancy-package-name) ?
<beach> One gives you a name in lower-case letters and one in upper-case.
<gjvc> hah, wow! of course!
<gjvc> thank you :-)
<beach> Sure.
<gjvc> what does the #: prefix signify? "symbol name coming up" ?
<beach> Symbol without a home package.
<gjvc> right, which is probably what one wants for a package name symbol
rgherdt_ is now known as rgherdt
<beach> It sends a signal to the person reading your code that the only thing you are using about the symbol is its name, and not its package.
<gjvc> i see.
s-liao has quit [Ping timeout: 256 seconds]
<beach> ... so it's a case of the rule that one should use the most specific construct that will do the trick.
<gjvc> thanks again. i've read that before, but i didn't have enough on the page to join the dots
<gjvc> makes sense now.
<beach> Great!
v88m has quit [Read error: Connection reset by peer]
<rotateq> I have got into the habit of prefixing DEFPACKAGE and IN-PACKAGE in the top of files now always with CL: so I don't have to rely on that being in a package like #:CL or #:CL-USER.
<gjvc> rotateq: i have adopted that trick this week
<rotateq> nice :)
aartaka has joined #commonlisp
<gjvc> and lo, i now understand why (in-package #:common-lisp) works, but (in-package "common-lisp") doesn't ...
yewscion has joined #commonlisp
<ns12> Osicat is more capable than I initially believed. I guess I was misled by its manual https://osicat.common-lisp.dev/manual/osicat.html which was last updated in June 2009. The real list of supported functions is here https://github.com/osicat/osicat/blob/a45eb3b5826e9175f7c94ba97a00d6b4932f3163/posix/packages.lisp#L37-L447
<random-nick> the thing is that package names are strings instead of symbols (it wouldn't make much sense if packages were named using symbols) so #:common-lisp or :common-lisp is a designator for a string like "COMMON-LISP" while "common-lisp" designates itself
<random-nick> :\common-lisp would designate "cOMMON-LISP"
waleee has joined #commonlisp
cosimone has quit [Remote host closed the connection]
NotThatRPG has quit [Read error: Connection reset by peer]
NotThatRPG has joined #commonlisp
rotateq has quit [Remote host closed the connection]
orestarod has quit [Ping timeout: 252 seconds]
<dbotton> Why does #:cl entered in the REPL return a variable unbound if it indicates a symbol with no package?
<dbotton> beach is that #: something particular to IN-PACKAGE?
<jackdaniel> #:xxx means uninterned symbol
<beach> dbotton: It doesn't have a value as a variable.
<beach> dbotton: The same thing happens if you enter any new symbol, like lskjflskdjf
<beach> dbotton: IN-PACKAGE is not a function and it doesn't evaluate its argument.
<dbotton> thanks!
<beach> Sure.
lispy has joined #commonlisp
Josh_2 has quit [Ping timeout: 256 seconds]
waleee has quit [Ping timeout: 252 seconds]
dirtcastle has quit [Ping timeout: 245 seconds]
notzmv has quit [Ping timeout: 252 seconds]
<pjb> gjvc: lowercase or mixedcase package names can be nice. You can escape them, or use a readtable-case set to :preserve. (defpackage "MyPackage") |MyPackage|::foo
aartaka has quit [Ping timeout: 272 seconds]
aartaka has joined #commonlisp
jeosol has joined #commonlisp
mgl has quit [Quit: Client closed]
jeosol has quit [Quit: Client closed]
<random-nick> and uninterned symbols aren't self-evaluating because then they couldn't be used properly in macro expansions
mgl has joined #commonlisp
v88m has joined #commonlisp
jeosol has joined #commonlisp
aartaka has quit [Ping timeout: 272 seconds]
aartaka has joined #commonlisp
<Guest74> I see osicat doesn't muff their  ioctl constants.
Oladon has joined #commonlisp
rogersm has quit [Quit: Leaving...]
MajorBiscuit has joined #commonlisp
Guest74 has quit [Quit: Connection closed]
X-Scale` has joined #commonlisp
X-Scale has quit [Ping timeout: 272 seconds]
X-Scale` is now known as X-Scale
dirtcastle has joined #commonlisp
cosimone has joined #commonlisp
mjoerg has joined #commonlisp
cage has joined #commonlisp
mjoerg has quit [Remote host closed the connection]
lispy has quit [Quit: Leaving]
orestarod has joined #commonlisp
aartaka has quit [Ping timeout: 260 seconds]
aartaka has joined #commonlisp
yewscion has quit [Ping timeout: 272 seconds]
attila_lendvai has joined #commonlisp
Oladon has quit [Quit: Leaving.]
amb007 has quit [Ping timeout: 245 seconds]
mogan90 has quit [Ping timeout: 256 seconds]
MajorBiscuit has quit [Ping timeout: 256 seconds]
Catie has joined #commonlisp
amb007 has joined #commonlisp
karlosz has joined #commonlisp
mogan90 has joined #commonlisp
rgherdt has quit [Ping timeout: 240 seconds]
notzmv has joined #commonlisp
igemnace has quit [Ping timeout: 256 seconds]
Dynom has joined #commonlisp
dirtcastle has quit [Ping timeout: 240 seconds]
mksybr has quit [Quit: WeeChat 3.4]
aartaka has quit [Ping timeout: 240 seconds]
aartaka has joined #commonlisp
waleee has joined #commonlisp
mgl has quit [Quit: Client closed]
NotThatRPG is now known as NotThatRPG_away
karlosz has quit [Quit: karlosz]
splatt990 has quit [Quit: Gateway shutdown]
[smlckz] has quit [Quit: Gateway shutdown]
Oladon has joined #commonlisp
eddof13 has joined #commonlisp
attila_lendvai has quit [Ping timeout: 252 seconds]
eddof13 has quit [Client Quit]
VincentV` has quit [Ping timeout: 256 seconds]
notzmv has quit [Ping timeout: 252 seconds]
karlosz has joined #commonlisp
jeosol has quit [Quit: Client closed]
simendsjo has joined #commonlisp
stack2 has quit [Quit: WeeChat 3.0.1]
NotThatRPG_away is now known as NotThatRPG
Cymew has quit [Ping timeout: 240 seconds]
simendsjo has quit [Ping timeout: 240 seconds]
cage has quit [Quit: rcirc on GNU Emacs 27.1]
tyson2 has quit [Ping timeout: 256 seconds]
orestarod has quit [Ping timeout: 268 seconds]
Lord_of_Life_ has joined #commonlisp
Lord_of_Life has quit [Ping timeout: 240 seconds]
Lord_of_Life_ is now known as Lord_of_Life
orestarod has joined #commonlisp
aartaka has quit [Ping timeout: 272 seconds]
aartaka has joined #commonlisp
recordgroovy has quit [Remote host closed the connection]
aartaka has quit [Ping timeout: 256 seconds]
notzmv has joined #commonlisp
igemnace has joined #commonlisp
tane has joined #commonlisp
tane has quit [Changing host]
tane has joined #commonlisp
attila_lendvai has joined #commonlisp
azimut_ has joined #commonlisp
azimut has quit [Ping timeout: 240 seconds]
cjb has joined #commonlisp
kpoeck has joined #commonlisp
IPmonger has joined #commonlisp
IPmonger has quit [Remote host closed the connection]
jmes has joined #commonlisp
tyson2 has joined #commonlisp
kevingal has joined #commonlisp
<jmes> Just for fun I want to define a package using the name of the containing file. I'd like to be able to write (defpackage (make-symbol (string-upcase (current-filename))) ...) how would `current-filename' find the enclosing file name?
<jackdaniel> maybe #.*load-truename* ?
kevingal has quit [Client Quit]
<jackdaniel> mind that I'm resolving the variable value at the read time (so it doesn't change for when you load a fasl file or whatever)
<jmes> jackdaniel: thanks, this should be what I'm looking for
rgherdt has joined #commonlisp
kevingal has joined #commonlisp
rogersm has joined #commonlisp
Oladon has quit [Quit: Leaving.]
epony has joined #commonlisp
Dynom has quit [Quit: WeeChat 3.4]
cosimone has quit [Quit: ERC (IRC client for Emacs 27.1)]
Oladon has joined #commonlisp
<_73> I am totally stumped on debugging why I cant get my local-project system to load with quicklisp. I am getting an UNDEFINED-FUNCTION error for using functions that should be defined. I have not been able to reproduce the problem so I just info dumped my actual situation. http://dpaste.com/HWSA6LDBD
wyrd has quit [Ping timeout: 240 seconds]
wyrd has joined #commonlisp
tane has quit [Quit: Leaving]
nature has quit [Ping timeout: 240 seconds]
<pjb> jmes: the function is make-package
rogersm has quit [Quit: Leaving...]
<pjb> jmes: *load-truename* is bound to NIL while compiling the file! https://termbin.com/zxmy
<pjb> jackdaniel: ^
<Xach> _73: no in-package
<Xach> _73: put it after the defpackage in maxpc-extensions.lisp
<Xach> _73: check (apropos "=EQ") also
<_73> Xach: err of course it was something silly! Thanks.
kpoeck has quit [Quit: Client closed]
shka has quit [Ping timeout: 260 seconds]
<jmes> pjb: Okay thanks, I'm going back to explicit package names. I was just curious :P
attila_lendvai has quit [Ping timeout: 268 seconds]
mgl has joined #commonlisp
<pjb> jmes: Something like: (eval-when (:compile-toplevel :load-toplevel :execute) (let ((p (make-package (pathname-name (or *compile-file-truename* *load-truename*)) :use '("CL")) )) (dolist (n '("FOO" "BAR")) (export (intern n p) p)) (setf *package* p)))
Oladon has quit [Quit: Leaving.]
eddof13 has joined #commonlisp
hashfuncadb has joined #commonlisp
daemonises has joined #commonlisp
eddof13 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
pillton has joined #commonlisp
<hashfuncadb> so quicklisp appears to need three core file: <myproject>.lisp <myproject>.asd package.lisp
<hashfuncadb> is there a way to specify that all of that logic is contained in <myproject>.lisp?
pranavats has left #commonlisp [Error from remote client]
<hashfuncadb> by, "appears to need", i mean, that this is what (QL:QUICKLOAD) needs to get the project up-and-running in the repl
pranavats has joined #commonlisp
<hashfuncadb> ^correction: it appears to just need two core files: <myproject>.lisp and <myproject>.asd
<pillton> hashfuncadb: Quicklisp uses ASDF to manage loading of systems.
<random-nick> you have to have an .asd file for ASDF to find your system
<hashfuncadb> pillton: so the <myproject>.asd code can't be put in the <myproject>.lisp file?
<pillton> hashfuncadb: Not that I know of.
<random-nick> yes, because ASDF looks for .asd files
<hashfuncadb> random-nick: ok, so trying to work around that, i'm assuming, would probably be hacky
<pillton> hashfuncadb: Why? Nobody does that.
kevingal has quit [Ping timeout: 240 seconds]
<hashfuncadb> pillton: i would like everything contained in one file; yes i know that's contrary to the status quo
kevingal has joined #commonlisp
<pillton> You aren't answering the question.
<pillton> I already know you want everything in one file.
<hashfuncadb> pillton: it's for the system i'm developing
<Xach> hashfuncadb: you can put it all in one file if you want, but there's no simple (i.e. one-liner or whatever) way
<Xach> hashfuncadb: if i was doing it, i'd think about writing a custom asdf system search function that synthesized a system on the fly pointing to my source file.
<Xach> i don't know if that would work or be easy.
<Xach> but, that's where i'd start
<hashfuncadb> Xach: ok, thanks
<hashfuncadb> pillton: random-nick: thanks for the help
amb007 has quit [Remote host closed the connection]
amb007 has joined #commonlisp
<pillton> Best of luck. Not sure how successful you are going to be.
<pillton> ASDF still doesn't really support the type of problems you are going to encounter with your approach.
<pillton> I am referring to the :defsystem-depends-on system definition option in ASDF.
mgl has quit [Ping timeout: 256 seconds]