yitzi has quit [Remote host closed the connection]
hashfunc has joined #commonlisp
augfab has quit [Remote host closed the connection]
kevingal has quit [Ping timeout: 248 seconds]
X-Scale has joined #commonlisp
NotThatRPG has joined #commonlisp
synchromesh has quit [Quit: WeeChat 4.0.5]
synchromesh has joined #commonlisp
random-nick has quit [Ping timeout: 255 seconds]
synchromesh has quit [Read error: Connection reset by peer]
synchromesh has joined #commonlisp
Akbar-Birbal has joined #commonlisp
rtypo has quit [Ping timeout: 252 seconds]
Lord_of_Life has quit [Ping timeout: 248 seconds]
Lord_of_Life has joined #commonlisp
<johnjaye>
maybe a weird question, but can common lisp implementations call c functions?
<beach>
Most of them can.
<johnjaye>
like for example locale functions, or std lib things like printf or toupper
<johnjaye>
like with some kind of FFI except for C?
<beach>
There is a library called CFFI that most implementations support.
<johnjaye>
presumably any strings or numbers would have to be coerced to fit with the c requirements
<johnjaye>
interesting. i was thinking about python and wondering, why don't high level languages just let you access the C api underneath them?
<johnjaye>
there's no reason not to
<beach>
"underneath"?
<johnjaye>
yeah. presuming the platform is written in C.
<beach>
That's just not true. SBCL is written in Common Lisp, for very good reasons.
<johnjaye>
ah i see. so cffi would expect you to provide some kind of libc i suppose
<beach>
That I don't know. I don't use foreign code myself. I am just telling you what I have heard.
<johnjaye>
ah ok. maybe i'm thinking more of those scheme implementations that transpile to C
<elderK>
johnjaye: CFFI provides a common interface for each implementation's own FFI layer.
<elderK>
Some implementations such as ECL are "easily bridged" with C, as they are implemented in C. So, some Lisp data types may be represented in such a way to make interchange simple.
<elderK>
SBCL, on the other hand, is a true CL system: It is written in CL. SBCL's FFI doesn't provide a C runtime, for instance.
<johnjaye>
i didn't realize ecl was in c. but that makes sense if it's intended to be embeddable
<elderK>
Instead, it respects the platform ABI and performs necessary conversions on entry and exit to a foreign function.
<elderK>
Naturally, for some things, this is cheap and for others, expensive. Lisp strings, for instance, are not C strings so SBCL has to convert.
<johnjaye>
beach: yes that's called "self-hosting" I believe. is there any good conceptual reason for that
<elderK>
A byte-vector in CL probably isn't directly passed by address to C, if only for garbage collection reasons but more probably because the actual layout is totally different.
<johnjaye>
or is it more a practicality thing
<elderK>
johnjaye: Clarity, modularity, testing.
<elderK>
It's convenient to write the implementation in CL, because that means you can use CL's features to build it. CL is much better than C in some things such as language implementation or symbolic computation.
<beach>
johnjaye: Yes, I made an entire series of videos explaining why it is very hard to implement Common Lisp in something else.
<elderK>
It also means you don't need to have a C toolchain available which is also nice.
<johnjaye>
meaning what, you debug yourself with your own features?
smlckz has quit [Quit: WeeChat 4.3.1]
<elderK>
johnjaye: Pretty much. I'd suggest reading beach's bootstrapping paper. There are a lot of interesting papers.
<ixelp>
CFFI - The Common Foreign Function Interface
<johnjaye>
thanks!
triffid has quit [Remote host closed the connection]
pranav has quit [Remote host closed the connection]
rainthree has joined #commonlisp
triffid has joined #commonlisp
X-Scale has quit [Quit: Client closed]
puke has quit [Ping timeout: 252 seconds]
pve has joined #commonlisp
puke has joined #commonlisp
<jackdaniel>
elderK: to be precise, ECL implements a Common Runtime Support in C, and that's what Common Lisp is built upon; while not entirely accurate today, the second section https://ecl.common-lisp.dev/static/files/papers/ecl-1995-attardi.pdf provides a high-level overview
<jackdaniel>
a more appropriate phrasing would be that ECL is bootstrapped from C, and its compiler targets C as an intermediate language; most sources are written in 100% Common Lisp (most notably the compiler)
<jackdaniel>
(to confuse things further, ecl has also alternative runtime based on a virtual machine, and the second compiler targets its bytecode:)
st_aldini has quit [Ping timeout: 252 seconds]
zxcvz has joined #commonlisp
st_aldini has joined #commonlisp
synchromesh has quit [Read error: Connection reset by peer]
synchromesh has joined #commonlisp
synchrom1 has joined #commonlisp
zxcvz has quit [Quit: zxcvz]
synchromesh has quit [Ping timeout: 252 seconds]
synchromesh has joined #commonlisp
synchrom1 has quit [Ping timeout: 252 seconds]
treflip has joined #commonlisp
hashfunc has quit [Remote host closed the connection]
amb007 has quit [Ping timeout: 272 seconds]
mishoo has joined #commonlisp
wacki has joined #commonlisp
Th30n has joined #commonlisp
amb007 has joined #commonlisp
Algernon69 has joined #commonlisp
Algernon69 has quit [Client Quit]
heisig has joined #commonlisp
rainthree has quit [Ping timeout: 245 seconds]
shka has joined #commonlisp
varjag has joined #commonlisp
danza has joined #commonlisp
rainthree has joined #commonlisp
amb007 has quit [Ping timeout: 248 seconds]
mishoo_ has joined #commonlisp
King_julian has joined #commonlisp
mishoo has quit [Ping timeout: 260 seconds]
amb007 has joined #commonlisp
psilord has quit [Ping timeout: 252 seconds]
danza has quit [Remote host closed the connection]
rainthree has quit [Read error: Connection reset by peer]
<Bubblegumdrop>
I'm also using Shinmera's deploy to build the binaries
Lord_of_Life has joined #commonlisp
<dnhester26>
Bubblegumdrop: thanks for replying. do you know why it was removed from quicklisp? it was removed from clack so that it wouldn't break when getting it from quicklisp
<Bubblegumdrop>
try (ql:system-apropos "cgi")
<Bubblegumdrop>
I don't know anything about cl-fastcgi
<Bubblegumdrop>
There's sb-fastcgi
<dnhester26>
ahhh just noticed you said fcgiwrap and not cl-fastcgi
<Bubblegumdrop>
I'm trying to get GNU clisp compiled with threading support
<dnhester26>
sb-fastcgi and cl-fastcgi are related
attila_lendvai has quit [Read error: Connection reset by peer]
bjorkintosh has quit [Ping timeout: 260 seconds]
<dnhester26>
Bubblegumdrop: thanks, do you notice it being faster using the fcgi wrap with HT instead of straight http proxy?
yitzi has quit [Ping timeout: 252 seconds]
yitzi has joined #commonlisp
King_julian has joined #commonlisp
danieli has quit [Read error: Connection reset by peer]
mgl has joined #commonlisp
danieli has joined #commonlisp
chkhd has quit [Quit: ZZZzzz…]
cdegroot_ has quit [Ping timeout: 252 seconds]
chkhd has joined #commonlisp
flounders has quit [Ping timeout: 252 seconds]
drewjose has quit [Quit: Ping timeout (120 seconds)]
drewjose has joined #commonlisp
mgl has quit [Ping timeout: 252 seconds]
yitzi has quit [Ping timeout: 260 seconds]
yitzi has joined #commonlisp
<Bubblegumdrop>
HT? Hunchentoot?
<Bubblegumdrop>
I don't notice any performance difference putting anything behind nginx
<dnhester26>
ok, so I should just make a helper function since the functionality will be the same on those cases? is that the sensible approach?
<dnhester26>
thanks for answering btw
<Shinmera>
sure
<dlowe>
make a parent class to both class1 and class2 and specialize on that
<Shinmera>
or create a mixin that combines the two and have clients inherit from that. I don't know your design
<Shinmera>
either approach can be sensible
* dlowe
chuckles.
zxcvz has quit [Quit: zxcvz]
<dnhester26>
ok, thanks
<dlowe>
You might want to consider if it should be a method at all, though
<dlowe>
if you don't want automatic dispatching it's kind of overkill
tedwing has joined #commonlisp
<dnhester26>
right, i just wanted to simplify some code. I have multiple arguments and depending on their type i have to do some processing to get them to be what I want, it's just that the processing is the same, so I just wanted to make it so that I didn't have to specialize each argument on each type and instead I made another defmethod for that processing...
augfab has quit [Remote host closed the connection]
<dlowe>
there's also typecase and etypecase if you don't want to fool with all that
skeemer has joined #commonlisp
decweb has quit [Remote host closed the connection]
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
yitzi has joined #commonlisp
Th30n has quit [Ping timeout: 252 seconds]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
gorignak has joined #commonlisp
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
meaty has joined #commonlisp
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
jonatack has quit [Ping timeout: 264 seconds]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
jonatack has joined #commonlisp
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
metsomedog has quit [Quit: ERC 5.5.0.29.1 (IRC client for GNU Emacs 29.4)]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Read error: Connection reset by peer]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
<phantomics>
How do I control formatting for printing numbers within a vector? I.e. (format t "~v,'0X~%" 2 #(10 20 30)) prints #(A 14 1E) when I want it to print #(0A 14 1E)
<yitzi>
~X is for printing integers. If FORMAT finds a non-integer it will just call WRITE
<yitzi>
You will probably need to bind *PRINT-BASE*
puke has quit [Ping timeout: 244 seconds]
<scymtym>
for the exact use-case, something like (format t "~@<#(~;~{~2,'0X~^ ~}~;)~@:>" (coerce #(10 20 30) 'list)) should work. for generally changing the way integers are printed, customizing the pprint dispatch table could work
<phantomics>
Ok, so it's defaulting in the case of encountering a vector, thanks
puke has joined #commonlisp
<yitzi>
If you don't care about the leading zeros. `(write #(10 20 30) :base 16)` or `(write #(10 20 30) :base 16 :radix t)`
yitzi has quit [Remote host closed the connection]
amb007 has quit [Ping timeout: 260 seconds]
amb007 has joined #commonlisp
mgl has joined #commonlisp
NotThatRPG has joined #commonlisp
dnhester26 has joined #commonlisp
shawnw has joined #commonlisp
Akbar-Birbal has left #commonlisp [Error from remote client]
dnhester26 has quit [Remote host closed the connection]
treflip has quit [Remote host closed the connection]
treflip has joined #commonlisp
Lord_of_Life has quit [Client Quit]
Lord_of_Life has joined #commonlisp
supercode has joined #commonlisp
gorignak has quit [Quit: quit]
gorignak has joined #commonlisp
zwr has joined #commonlisp
<elderK>
jackdaniel: Thanks for the info :) I stand corrected :)
gooba has joined #commonlisp
pranav has quit [Remote host closed the connection]
mwnaylor has joined #commonlisp
<zwr>
"If you studied Lisp in college and came away with the impression that it was only an academic language with no real-world application, chances are you learned Scheme."
<dlowe>
you were also probably forced into only using recursion
<dlowe>
and lists
<zwr>
anyway I decided to try learning a LISP again, I always had difficulty learning languages, but after learning Rust with ease today and hearing it's supposed to be hard, maybe this time I'll succeed with LISP
<zwr>
s/today/recently/
<dlowe>
good luck! it can be fun.
<boigahs>
There's some pretty practical implementations and applications of Scheme, though :)
wobbol has joined #commonlisp
heisig has quit [Quit: Leaving]
dino_tutter has quit [Quit: Leaving]
cage has quit [Remote host closed the connection]
elderK has quit [Quit: WeeChat 4.4.2]
treflip has quit [Ping timeout: 248 seconds]
supercode has quit [Quit: Client closed]
<dlowe>
yeah, I think of it the "college lisp" dialect because its reduce features give a terrible impression about what it's like to code in lisp normally
<dlowe>
*reduced
dnhester26 has quit [Remote host closed the connection]
<mwnaylor>
zwr: Not sure about #scheme or #guile, but a lot of the nicks from #emacs can be found on #lisp, #commonlisp, and #clojure. Lot of elisp hacking discussed in #eamcs. #fennel I a channel tied to the creator of that language; a lisp dialect that was writtten in Lua.
<aeth>
oh, #eamcs is the channel for elisp? ;-p
<aeth>
afaik, #lisp is a better Emacs Lisp help channel than #emacs because of the Common Lispers there, but I'm not in #emacs so I can only go off of second-hand accounts
<aeth>
I think one of the reasons to go with #commonlisp instead of #lisp in the IRC network move was so Emacs Lispers couldn't keep feigning ignorance to get elisp help from CL programmers
<aeth>
zwr: The problem isn't Scheme, it's academic Lisp, which only teaches people what is different in Lisps, which means people think that only linked lists are used because most languages don't have first-class singly-linked lists
<mwnaylor>
It's all things emacs, plus a good bit of side bar discussions. A lot of people there hack on elisp. Some of theme have pupblished packages.
<aeth>
(though, yes, academic Lisp is usually Scheme these days)
<mwnaylor>
SICP was written for Scheme, I guess things haven't changed a lot. Have to say that I would have been in hairpulling mode if I had to deal with a lisp-2 in university days.
gooba has quit [Remote host closed the connection]
dino_tutter has joined #commonlisp
jmiven has quit [Quit: reboot]
pve has quit [Quit: leaving]
dnhester26 has joined #commonlisp
jmiven has joined #commonlisp
jonatack has quit [Read error: Connection reset by peer]
synchromesh has joined #commonlisp
kevingal has joined #commonlisp
jonatack has joined #commonlisp
gorignak has quit [Quit: quit]
tedwing has quit [Ping timeout: 252 seconds]
gorignak has joined #commonlisp
synchrom1 has joined #commonlisp
synchrom2 has joined #commonlisp
synchromesh has quit [Ping timeout: 265 seconds]
synchrom1 has quit [Ping timeout: 260 seconds]
synchromesh has joined #commonlisp
synchrom2 has quit [Ping timeout: 260 seconds]
pranav has joined #commonlisp
amb007 has joined #commonlisp
tam has joined #commonlisp
amb007 has quit [Ping timeout: 244 seconds]
cdegroot has quit [Ping timeout: 260 seconds]
dra has joined #commonlisp
NotThatRPG has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tam has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
shka has quit [Quit: Konversation terminated!]
tam has joined #commonlisp
amb007 has joined #commonlisp
tam has quit [Client Quit]
tam has joined #commonlisp
tedwing has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
gorignak has quit [Quit: quit]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
amb007 has quit [Ping timeout: 248 seconds]
dnhester26 has joined #commonlisp
gorignak has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
gorignak has quit [Client Quit]
gorignak has joined #commonlisp
<Bubblegumdrop>
ayooo
<Bubblegumdrop>
Got CLISP built with thread support
<Bubblegumdrop>
@_@
mishoo has quit [Ping timeout: 252 seconds]
dnhester26 has joined #commonlisp
<tux0r>
why?
yitzi has quit [Remote host closed the connection]
varjag has quit [Quit: ERC 5.5.0.29.1 (IRC client for GNU Emacs 29.2)]
mgl has joined #commonlisp
dra has quit [Ping timeout: 272 seconds]
yitzi has joined #commonlisp
mgl has quit [Ping timeout: 260 seconds]
dino_tutter has quit [Ping timeout: 244 seconds]
amb007 has joined #commonlisp
Pixel_Outlaw has joined #commonlisp
donleo has quit [Ping timeout: 252 seconds]
dino_tutter has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
gorignak has quit [Quit: quit]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
gorignak has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
tedwing has quit [Quit: leaving]
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
dnhester26 has joined #commonlisp
dnhester26 has quit [Remote host closed the connection]
yitzi has quit [Remote host closed the connection]
<Bubblegumdrop>
Apparently the clisp package in debian doesn't ship with threads enabled, after messing around it looks like 2 of the ~500 tests dont pass. I just skipped the tests.
<Bubblegumdrop>
I wanted threads in my clisp so I could connect via swank
<Bubblegumdrop>
swank works best when you can start a dedicated thread so you don't bring down the whole image
kevingal has quit [Remote host closed the connection]