p_l changed the topic of #lisp to: Common Lisp, the #1=(programmable . #1#) programming language | <https://irclog.tymoon.eu/freenode/%23lisp> <https://irclog.whitequark.org/lisp> <http://ccl.clozure.com/irc-logs/lisp/> | ASDF 3.3.4
karlosz has joined #lisp
<Oladon> phoe: Did you ever get your bytea columns working in Postgres/CLSQL back in 2018?
<Oladon> I've got a bytea column that just returns 0 when I select from it, even though there's definitely a byte array in there.
ayuce has quit [Remote host closed the connection]
mixfix411 has left #lisp [#lisp]
pilne_ has joined #lisp
Zakkor has quit [Quit: Connection closed for inactivity]
shifty has joined #lisp
pilne has quit [Ping timeout: 260 seconds]
pilne_ has quit [Quit: I was standing in the park wondering why frisbees got bigger as they get closer. Then it hit me.]
pilne has joined #lisp
shifty has quit [Ping timeout: 260 seconds]
bleeeeeh has joined #lisp
Oladon has quit [Quit: Leaving.]
shifty has joined #lisp
jonatack has quit [Ping timeout: 264 seconds]
jonatack has joined #lisp
karlosz has quit [Remote host closed the connection]
lucasb has quit [Quit: Connection closed for inactivity]
iAmDecim is now known as cyberoctopi
bitmapper has quit [Ping timeout: 240 seconds]
Josh_2 has quit [Ping timeout: 256 seconds]
ardoc has quit [Ping timeout: 264 seconds]
orivej has quit [Ping timeout: 256 seconds]
Kundry_Wag has joined #lisp
CrazyEddy has quit [Remote host closed the connection]
phadthai has quit [Quit: bbl]
buffergn0me has joined #lisp
xlei has quit [Ping timeout: 256 seconds]
karlosz has joined #lisp
Oladon has joined #lisp
wxie has joined #lisp
CrazyPython has quit [Ping timeout: 240 seconds]
cyberoctopi has quit [Ping timeout: 265 seconds]
cyberoctopi has joined #lisp
igemnace has quit [Quit: WeeChat 2.8]
cyberoctopi has quit [Ping timeout: 256 seconds]
JetJej has quit [Read error: Connection reset by peer]
monok has joined #lisp
SGASAU has quit [Remote host closed the connection]
mono has quit [Ping timeout: 256 seconds]
SGASAU has joined #lisp
cyberoctopi has joined #lisp
SGASAU has quit [Remote host closed the connection]
SGASAU has joined #lisp
SGASAU has quit [Remote host closed the connection]
phadthai has joined #lisp
SGASAU has joined #lisp
xlei has joined #lisp
slyrus has joined #lisp
gko has joined #lisp
<beach> Good morning everyone!
turona has quit [Ping timeout: 272 seconds]
turona has joined #lisp
SGASAU has quit [Remote host closed the connection]
<Oladon> Morning beach!
SGASAU has joined #lisp
<Oladon> beach: What fun projects do you have going on these days?
decentsoup has joined #lisp
<beach> Only one active one right now: SICL. I think I finished code generation, so I am back to working on bootstrapping. I am trying to simplify it as much as I can before I turn my DAG into a cyclic graph of metaobjects.
<beach> Oladon: What about yourself?
<Oladon> Nice! Sounds like fun.
<Fare> beach, nice. How does that interact with the use of parts of SICL by clasp?
<Oladon> I'm working on a fairly "straightforward" web server thingy -- wrestling with trying to get clsql to process byte arrays properly at the moment. :)
<beach> Clasp uses Cleavir, which is a compiler framework. And Cleavir is a separate sub-project of SICL.
<Fare> beach, is there an overview of the passes of your compiler?
karlosz has quit [Quit: karlosz]
<no-defun-allowed> There are concrete syntax trees, abstract syntax trees, HIR (which I suppose explicates data and control flow), MIR (introducing memory), LIR (introducing registers) and Cluster assembler, from memory.
<beach> Fare: Globally speaking, it is CST-to-AST, AST-to-HIR, HIR-to-MIR, MIR-to-LIR, LIR-to-Cluster (assembler), and Cluster code generation. There are not many optimization passes yet. Also the thing can be customized, so Clasp probably does its own.
<beach> no-defun-allowed: Heh, thanks!
<no-defun-allowed> (:
decentsoup has quit [Quit: Quit]
<beach> Fare: Clasp stops at HIR and then does HIR-to-LLVM.
karlosz has joined #lisp
<beach> Fare: We have code for several optimization passes, but each client can choose which ones to apply and how. For example, type inference is done in HIR. Value numbering can be done in several passes, etc.
nmg has joined #lisp
buffergn0me has quit [Ping timeout: 240 seconds]
<Fare> CST is common-lisp syntax?
<beach> It is S-expressions wrapped in standard objects for things like source tracking.
<beach> The Eclector reader is able to read Common Lisp source code and return a CST.
<beach> Many of the early passes are now in separate libraries. CST is separate, Eclector is separate, Trucler manages lexical compile-time environments, and that's separate too. We are working on extracting first-class global environments to a separate library. After that, it will be AST and CST-to-AST.
ebzzry has joined #lisp
shifty has quit [Ping timeout: 240 seconds]
SGASAU has quit [Remote host closed the connection]
SGASAU has joined #lisp
<beach> Fare: Every pass is defined as a bunch of generic functions that take a CLIENT argument, so that client code can customize pretty much everything.
<beach> That's why it's a "compiler framework" rather than a "compiler".
pilne has quit [Quit: Call me a relic, call me what you will. Say I'm old fashioned, say I'm over the hill.]
Kundry_Wag has quit [Remote host closed the connection]
wxie has quit [Ping timeout: 240 seconds]
theosvoitha has joined #lisp
ebzzry has quit [Read error: Connection reset by peer]
wxie has joined #lisp
Kundry_Wag has joined #lisp
ayuce has joined #lisp
Kundry_Wag has quit [Ping timeout: 260 seconds]
lemoinem is now known as Guest84104
Guest84104 has quit [Killed (egan.freenode.net (Nickname regained by services))]
lemoinem has joined #lisp
Lycurgus has joined #lisp
wxie has quit [Remote host closed the connection]
wxie has joined #lisp
bleeeeeh has quit [Ping timeout: 240 seconds]
zulu-inuoe has quit [Read error: Connection reset by peer]
anlsh has quit [Ping timeout: 246 seconds]
ebzzry has joined #lisp
Jeanne-Kamikaze has quit [Remote host closed the connection]
aeth_ has joined #lisp
dddddd has quit [Ping timeout: 258 seconds]
aeth has quit [Ping timeout: 264 seconds]
cyberoctopi has quit [Ping timeout: 240 seconds]
aeth_ is now known as aeth
cyberoctopi has joined #lisp
Nilby` has joined #lisp
vlatkoB has joined #lisp
Bike has quit [Quit: Lost terminal]
gravicappa has joined #lisp
_whitelogger has joined #lisp
jprajzne has quit [Quit: jprajzne]
jprajzne has joined #lisp
wxie has quit [Ping timeout: 240 seconds]
jprajzne has quit [Client Quit]
jprajzne has joined #lisp
mason has left #lisp [#lisp]
EvW has joined #lisp
ebzzry has quit [Quit: WeeChat 2.3]
asarch has joined #lisp
Oladon has quit [Quit: Leaving.]
<asarch> One stupid question: how is better? (foo () (let ... (do-the-computation))) or (let ... (do-the-computation) (foo with-results))?
cyberoctopi has quit [Ping timeout: 260 seconds]
<beach> It depends on the context. There is no universal answer.
<asarch> Thank you!
<Fare> asarch, I favor whichever form gives the programmer more context faster when reading left to right
<asarch> Thank you very much :-)
<asarch> Ok
v88m has quit [Remote host closed the connection]
<Fare> Sometimes it's even ((lambda (x) (foo x)) (some-computation))
<asarch> I suspect the second form is better because it let you to know all the vars in a glitch
<Fare> What will best enlighten the reader?
* asarch takes notes...
<Fare> Is there a pattern followed throughout the file or codebase?
<asarch> No, there isn't. That's my code
emys has joined #lisp
<asarch> I just writing the do's and don'ts in the language
<beach> Fare: Did I answer your questions to your satisfaction?
<Fare> What will help the reader understand what's going on, with most context and least misdirection?
<aeth> CL doesn't have DONTs, only DOs...
<Fare> Imagine that an older stupider more forgetful drunk yourself has to fix a bug or add a feature under a tight deadline a few years later after having forgotten all about it... how would he like the code to look like?
<asarch> Good point
<Fare> Also, go explain the code to your colleagues, or write documentation for the internals... do you have to simplify things? To introduce some concepts? To gloss over others? Then you need to refactor your code accordingly
<aeth> asarch: When in doubt, break things up into as many functions as possible. But I'm not quite sure howt hat maps to your two styles.
<aeth> *how that
<beach> Fare: That is precisely how I try to write code these days. Because I am already older, more stupid, and more forgetful. Though I don't attempt to fix bugs when I am drunk, of course.
ayuce has quit [Remote host closed the connection]
<Fare> Matthias Felleisen likes to quote a saying (approx.) "Write your code as if it will be maintained by a psycopathic murderer who knows your address"
<beach> Heh.
<aeth> When I find myself commenting entire sections of code, I almost always notice that those sections break up pretty well into separate functions with names pretty close to the comments I made. I might have to have them return multiple values (via VALUES) and then MULTIPLE-VALUE-BIND the functions, though.
<asarch> (let (....) (bar) (baz) ... (spam) (foo with-the-result))
<asarch> Much clear, isn't it?
<Fare> beach: thanks for the answer. I'm trying to design my compiler, and though it has constraints very different from CL, there are commonalities too
<beach> Fare: I see. Good luck.
<asarch> Than: (foo (let (...) (bar) (baz) ... (spam))
corpix has quit [Remote host closed the connection]
corpix_ has joined #lisp
<aeth> asarch: let* might be the way to go
<aeth> (let* ((x (foo)) (y (bar x)) ...
<aeth> (I know, in your example your foo comes last, but I'm just too used to doing foo and then bar in my examples)
<aeth> asarch: on the other hand if you do (foo (...)) then you could always do (foo (quux ...)) where QUUX now has the LET etc
shangul has joined #lisp
<aeth> Of course, (foo (bar (baz (quux ...)))) isn't very readable, so you can't compose them all in the parent function like this
<asarch> I see
ArthurStrong has joined #lisp
cyberoctopi has joined #lisp
gltb has joined #lisp
cyberoctopi has quit [Ping timeout: 256 seconds]
nowhere_man has quit [Ping timeout: 272 seconds]
EvW has quit [Ping timeout: 240 seconds]
_paul0 has quit [Remote host closed the connection]
paul0 has joined #lisp
jprajzne has quit [Quit: jprajzne]
jprajzne has joined #lisp
Necktwi has joined #lisp
<Fare> clojure has popularized "threading macros". Maybe CLers should adopt them.
jprajzne has quit [Client Quit]
watkinsr has quit [Ping timeout: 240 seconds]
<Fare> (One of these macros corresponds to the macro "NEST" that I export in POIU)
jprajzne has joined #lisp
<no-defun-allowed> There is cl-arrows.
<no-defun-allowed> I probably have a right-way-around-arrows somewhere, because the "postfix" -> didn't feel right in prefix code.
Inline has joined #lisp
asarch has quit [Quit: Leaving]
<Fare> I love postfix. I miss the HP RPL.
<no-defun-allowed> Sure, but it still is the "other way around" in the context of Lisp.
jprajzne has quit [Quit: jprajzne]
hdasch has quit [Quit: ZNC 1.6.6+deb1ubuntu0.2 - http://znc.in]
jprajzne has joined #lisp
* Lycurgus thought that would turn out to be something category theory related or the like
<no-defun-allowed> The cool kids (OCaml, Javascript soon, etc) seem to do -> with the infix |> operator (eg x |> f = f x)
<Fare> F# started the trend, IIRC. Of course, | is taken in CL, for escaping symbols.
<markasoftware> When should I add an :after method to initialize-instance instead of making a constructor method that wraps make-instance?
jprajzne has quit [Client Quit]
jprajzne has joined #lisp
hdasch has joined #lisp
dale has quit [Ping timeout: 240 seconds]
<beach> markasoftware: Sonja Keene favors constructors, but I find that it can get pretty complicated when the class hierarchy is not simple. So I always do the :AFTER method on INITIALIZE-INSTANCE.
<markasoftware> beach: is this because, if you only add after to initialize-instance, initargs for a superclass still take effect?
gltb has left #lisp [#lisp]
<beach> markasoftware: I kind of follow the example of the CLIM specification, where the interface to a class is the :INITARGs and the generic functions that operate on its instances.
<markasoftware> i see
pve has joined #lisp
<markasoftware> What if you need a custom argument to initialize your class, but you don't want to store that argument permanently? This is the case for me.
<markasoftware> can you have an initarg that is not connected to a slot?
<beach> Sure.
<beach> Just capture them in your method on INITIALIZE-INSTANCE.
<markasoftware> beach: how do you mean, "capture"?
<beach> Define them as &key parameters.
<markasoftware> make-instance throws an error if i try to pass an initarg that is not declared on any slot
<markasoftware> oh huh that works
<markasoftware> i am confusion
<markasoftware> How does anyone know about the lambda-list to initialize-instance?
<beach> Hold on, let me look for the relevant Common Lisp HyperSpec page...
jprajzne has quit [Quit: jprajzne]
<beach> clhs 7.1.2
<specbot> Declaring the Validity of Initialization Arguments: http://www.lispworks.com/reference/HyperSpec/Body/07_ab.htm
jprajzne has joined #lisp
<beach> markasoftware: The first item in the list says that a keyword argument is valid for MAKE-INSTANCE if it is defined by INITIALIZE-INSTANCE.
<beach> markasoftware: Technically, MAKE-INSTANCE is quite a complex operation in that it has to check the validity of those keyword arguments for every call. But in practice, there are tricks that your Common Lisp implementation can play to cache this information and make things fast.
dale has joined #lisp
<markasoftware> how do you even access the lambda list for a function? is that implementation specific?
<beach> clhs function-lambda-expression
<beach> But yeah, mostly implementation specific. Not so for generic functions though.
jellopudding has joined #lisp
jprajzne has quit [Client Quit]
<beach> mop generic-function-lambda-list
jprajzne has joined #lisp
narimiran has joined #lisp
<beach> markasoftware: While it is not in the Common Lisp standard, it is in the MOP.
<markasoftware> very interesting
<beach> I agree.
<markasoftware> so the "main" method may have a different lambda list than the :after method...how does lisp combine them?
<markasoftware> does it find the &key for all of them, and take the union?
<beach> Something like that.
<beach> That's another Common Lisp HyperSpec page as I recall.
<beach> Let me see if I can find it...
v_m_v has joined #lisp
dale has quit [Ping timeout: 258 seconds]
<beach> clhs 7.6.4
<specbot> Congruent Lambda-lists for all Methods of a Generic Function: http://www.lispworks.com/reference/HyperSpec/Body/07_fd.htm
<markasoftware> does the default initialize-instance have &rest but not &key?
v_m_v has quit [Ping timeout: 258 seconds]
<markasoftware> the congruence page says that all keyword parameters specified on one method must be specified on all other methods, OR there must be &rest but not &key on other methods, OR there must be &allow-other-keys on other methods
<beach> clhs initialize-instance
<markasoftware> ok, so it has &allow-other-keys
<markasoftware> but 7.1.2 says " The presence of &allow-other-keys in the lambda list of an applicable method disables validity checking of initialization arguments."
<markasoftware> so why does validity checking work even though initialize-instance has &allow-other-keys?
<beach> Yes, but make-instance also explicitly checks the validity of the keyword arguments according to the page I showed you.
<beach> It has to take &allow-other-keys, because otherwise, it would signal an error before it has the opportunity to check the validity.
<beach> These are very good questions. Perfect for #lisp. :)
<markasoftware> (make-instance) does the checking, not (initialize-instance), right?
Bourne has quit [Read error: Connection reset by peer]
gko_ has joined #lisp
<beach> Right.
<beach> It doesn't say explicitly, but it says "Making an instance of a class..".
<markasoftware> the make-instance clhs page does make it explicit, thankfully
gko has quit [Ping timeout: 265 seconds]
<markasoftware> Thank you, this has made a lot of things clearer for me. I'm mainly used to Java's excuse for an OOP system :)
<beach> Heh. Glad I could help.
<phoe> does (make-excuse 'oop-system ...) also check keyword validity?
Lycurgus has quit [Quit: Exeunt]
Bourne has joined #lisp
gko has joined #lisp
<phoe> I mean ummmm
<phoe> good morning
<no-defun-allowed> Good morning phoe.
<beach> Hello phoe.
gko_ has quit [Read error: Connection reset by peer]
jprajzne has quit [Quit: jprajzne]
jellopudding has quit [Quit: Quit Client]
<phoe> hey hi you two
jprajzne has joined #lisp
Bourne has quit [Read error: Connection reset by peer]
gko has quit [Ping timeout: 258 seconds]
jprajzne has quit [Client Quit]
jprajzne has joined #lisp
<Inline> morning
<no-defun-allowed> Hello Inline
jprajzne has quit [Quit: jprajzne]
jprajzne has joined #lisp
jprajzne has quit [Client Quit]
dale has joined #lisp
jprajzne has joined #lisp
Bourne has joined #lisp
wxie has joined #lisp
dale has quit [Ping timeout: 256 seconds]
Fare has quit [Quit: Leaving]
v_m_v has joined #lisp
cyberoctopi has joined #lisp
cyberoctopi has quit [Ping timeout: 265 seconds]
orivej has joined #lisp
emys has quit [Ping timeout: 265 seconds]
dale has joined #lisp
jellopudding has joined #lisp
emys has joined #lisp
v_m_v has quit [Remote host closed the connection]
jellopudding has quit [Client Quit]
dale has quit [Ping timeout: 256 seconds]
emys has quit [Ping timeout: 240 seconds]
emys has joined #lisp
v_m_v has joined #lisp
v88m has joined #lisp
duncan_ has joined #lisp
v88m has quit [Ping timeout: 240 seconds]
xuxuru has joined #lisp
Inline has quit [Ping timeout: 265 seconds]
<pjb> aeth: I wouldn't be so confident about DONTs in CL… They're only a mere macro away! cf. http://groups.google.com/group/comp.lang.lisp/msg/c85442d46c643536 http://groups.google.com/group/comp.lang.lisp/msg/7490e28eec0c0ff5 for example…
xuxuru has quit [Client Quit]
wxie has quit [Read error: Connection reset by peer]
wxie has joined #lisp
asarch has joined #lisp
<asarch> What does 'The value "2" is not of type NUMBER when binding SB-KERNEL::X' mean?
<beach> It means it's a string.
<no-defun-allowed> Exactly that.
<asarch> Oh, then I simply cannot (let ((value (* 40 x))) ...), right?
<beach> You are probably passing a string to some operator doing arithmetic.
<no-defun-allowed> "2" denotes a string; you probably gave some numeric function a string instead of the appropriate number.
<no-defun-allowed> You can, but X has to be a NUMBER, not a STRING.
wxie1 has joined #lisp
<asarch> Thank you guy!
<asarch> *guys
wxie has quit [Ping timeout: 265 seconds]
wxie1 is now known as wxie
<asarch> Thank you very much! :-)
dale has joined #lisp
<asarch> Why (qsort ...) is not part of the STL?
<asarch> *"STL"
<no-defun-allowed> clhs sort
<no-defun-allowed> (format nil "~{~a~^ ~}" (sort '("is..." "But it") #'string<))
<asarch> Bingo!
Inline has joined #lisp
<no-defun-allowed> The sorting algorithm that it uses isn't specified, but it's probably not a slow one. (Does qsort mean quicksort? I think that's also unspecified.)
dale has quit [Ping timeout: 260 seconds]
<asarch> Yeah, QuickSort (like C's qsort)
<beach> asarch: Why do you care what sorting algorithm is used?
<no-defun-allowed> qsort(3) doesn't specify what algorithm is used; but for lists I believe merge-sort is more efficient.
<beach> That's correct.
<asarch> Actually, I was doing a program in Assembly for x86 with GAS in the Intel Syntax and I just wonder how fast was Common Lisp's qsort
<beach> asarch: Common Lisp doesn't have any function named QSORT.
<pjb> And sort doesn't necessarily use the quicksort algorithm. There are faster algorithms… in some circumstances.
<beach> asarch: Also, performance depends on the implementation, not on the language.
<asarch> I see
<asarch> I thought qsort was the fastest algorithm for sorting elements :-(
<phoe> not always
<phoe> the problem highly depends on what and how you want to sort
<beach> asarch: It is not. Especially not on a list, as no-defun-allowed pointed out.
<Grue`> does anybody know/use "popup buffers" in SLIME? trying to figure out how to make slime-media display an image in a separate buffer
<beach> asarch: Bucket-sort is the fastest if your element domain permits it.
<no-defun-allowed> I also recall that quicksort is also O(n^2) if your sequence is sorted the other way.
<beach> no-defun-allowed: That depends on how the pivot element is chosen.
<no-defun-allowed> Right.
<Grue`> if the implementation is known, it's possible for an attacker to construct a sequence that's O(n^2) to sort
<asarch> Wow! :-(
<Grue`> all I figured out so far is that (swank::send-to-emacs '(:popup-buffer "aaa" "test" nil)) will kill Swank dead
<asarch> Bingo! My Caveman2 web application has now pagination: http://localhost:5000/students?p=2
<jackdaniel> Grue`: implementation may pick the element randomly from the appropriate set
<asarch> Thank you guys!
<asarch> Thank you very much! :-)
<Grue`> that localhost link is not very helpful...
<asarch> Sorry, sorry :-P
zaquest has quit [Ping timeout: 265 seconds]
nika has joined #lisp
twelvemonkeys has quit [Ping timeout: 256 seconds]
<asarch> Take a look: http://paste.scsys.co.uk/588708
twelvemonkeys has joined #lisp
<Grue`> pjb: that requires setting special permissions in emacs, while sending an event does not
<asarch> From all the web frameworks I know, Caveman2 is the only one where you only need to edit just two files to up application
<Grue`> also now that I look at swank source, it doesn't seem like it can handle a :popup-buffer event at all
<no-defun-allowed> Well, I mean, you could put as many forms as you wanted into one Lisp source file...
<Shinmera> or you could not use any lisp source files at all.
<Shinmera> though some frameworks seem to require file system stuff.
dddddd has joined #lisp
emys has quit [Ping timeout: 260 seconds]
<asarch> Have a nice day :-)
asarch has quit [Quit: Leaving]
<aeth> pjb: I think a DONT would be more along the lines of (defmacro dont (&body body) (declare (ignore body)) nil)
<no-defun-allowed> (dont nil)
<aeth> no-defun-allowed: it doesn't nil, it just returns a different nil... you can use (values) instead in your DONT if you want, though
<no-defun-allowed> (dont (values))
emys has joined #lisp
<aeth> (if (eql body nil) (values) nil)
<no-defun-allowed> :c
<aeth> or, actually (and body (listp body) (endp (cadr body))
<aeth> s/cadr/cdr/
emys has quit [Ping timeout: 240 seconds]
<aeth> no-defun-allowed: (defmacro dont (&body body) (if (and (consp body) (endp (cdr body)) (null (car body))) `(values) nil))
wxie has quit [Ping timeout: 240 seconds]
<aeth> of course you can still (dont (progn nil)) etc. but that works as expected because it shouldn't attempt to evaluate it, it should just do nothing
random-nick has joined #lisp
<Shinmera> A much more interesting variant would be one that actually randomly constructs valid code and executes it.
<aeth> technically all it has to do is something that is not provided, yes
<pjb> Grue`: what is a popup-buffer event?
<pjb> Grue`: how do I set special permissions in emacs?
<aeth> and technically DONT is actually useful, as a way to essentially comment out entire s-expressions (assuming nothing fancy is going on, like with the reader).
gko has joined #lisp
<no-defun-allowed> #1=(dont #1#)
<aeth> (dont #.(print "Hello")) ; of course, it's technically functioning, because it's returning NIL instead of "Hello"
<Grue`> pjb: for eval-in-emacs to work, `slime-enable-evaluate-in-emacs' should be set to T on the Emacs side. It's a security feature, I think (though realistically running random CL code is as dangerous as running random Elisp code)
<pjb> indeed, since you can always do emacsclient -e …
dale has joined #lisp
<pjb> (uiop:run-program "emacs-client -e '(setq slime-enable-evaluate-in-emacs t)'") (eval-in-emacs '(switch-to-buffer "HELLO"))
karlosz has quit [Quit: karlosz]
v_m_v has quit [Remote host closed the connection]
dale has quit [Ping timeout: 265 seconds]
shifty has joined #lisp
v_m_v has joined #lisp
akoana has left #lisp ["Leaving"]
wxie has joined #lisp
Kundry_Wag has joined #lisp
dale has joined #lisp
frgo has quit [Read error: Connection reset by peer]
frgo has joined #lisp
Lycurgus has joined #lisp
Kundry_Wag has quit [Ping timeout: 256 seconds]
dale has quit [Ping timeout: 256 seconds]
Kundry_Wag has joined #lisp
RedMallet has joined #lisp
Kundry_Wag has quit [Ping timeout: 256 seconds]
Lycurgus has quit [Remote host closed the connection]
cosimone has joined #lisp
zaquest has joined #lisp
wxie has quit [Ping timeout: 240 seconds]
orivej has quit [Ping timeout: 260 seconds]
theosvoitha has quit [Quit: Connection closed for inactivity]
Lord_of_Life_ has joined #lisp
pragmaticdog has joined #lisp
Lord_of_Life has quit [Ping timeout: 256 seconds]
Lord_of_Life_ is now known as Lord_of_Life
cosimone has quit [Quit: Quit.]
pragmaticdog has quit [Quit: Leaving]
dale has joined #lisp
<Grue`> very important to set buffer-file-name and not-modified because Emacs image mode is dumb
Bike has joined #lisp
<phoe> Grue`: please turn that into a blogpost
<Grue`> I might do that
dale has quit [Ping timeout: 240 seconds]
dale has joined #lisp
dale has quit [Ping timeout: 260 seconds]
gareppa has joined #lisp
jonatack has quit [Ping timeout: 250 seconds]
jonatack has joined #lisp
<pjb> Grue`: instead of view-file-slime, you can use (defmethod view-image (image-designator stream)) and have methods for pathname image 2d-array etc, and character-stream, binary-stream, swank/gray::slime-output-stream etc.
<pjb> so (defmethod view-image (image-designator (stream swank/gray::slime-output-stream)) …) could call swank::eval-in-emacs.
<pjb> but (defmethod view-image (image-designator (stream clim:stream-or-whatever)) …) would call clim.
<pjb> etc.
shka_ has joined #lisp
shka_ has quit [Remote host closed the connection]
shka_ has joined #lisp
Lycurgus has joined #lisp
pfdietz has joined #lisp
scymtym has quit [Ping timeout: 260 seconds]
cosimone has joined #lisp
RedMallet has quit [Quit: WeeChat 2.8]
gareppa has quit [Quit: Leaving]
v_m_v has quit [Remote host closed the connection]
scymtym has joined #lisp
Kundry_Wag has joined #lisp
EvW has joined #lisp
bor0 has joined #lisp
Inline has quit [Ping timeout: 272 seconds]
Myk267 has joined #lisp
remexre has quit [Ping timeout: 260 seconds]
gareppa has joined #lisp
orivej has joined #lisp
krid has joined #lisp
Inline has joined #lisp
jonatack has quit [Ping timeout: 240 seconds]
Lycurgus has quit [Remote host closed the connection]
jonatack has joined #lisp
JohnMS_WORK has joined #lisp
gareppa has quit [Quit: Leaving]
msk has joined #lisp
JohnMS_WORK has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
Josh_2 has joined #lisp
EvW has quit [Ping timeout: 240 seconds]
Kundry_Wag has quit [Ping timeout: 256 seconds]
Kundry_Wag has joined #lisp
Kundry_Wag has quit [Read error: No route to host]
krid has quit [Ping timeout: 250 seconds]
msk has quit [Ping timeout: 240 seconds]
keep_learning has quit [Quit: This computer has gone to sleep]
EvW has joined #lisp
gko_ has joined #lisp
gareppa has joined #lisp
gko has quit [Ping timeout: 240 seconds]
gko has joined #lisp
gko_ has quit [Ping timeout: 240 seconds]
cmatei has quit [Remote host closed the connection]
EvW has quit [Ping timeout: 272 seconds]
gareppa has quit [Quit: Leaving]
cmatei has joined #lisp
gko_ has joined #lisp
gareppa has joined #lisp
gko has quit [Ping timeout: 240 seconds]
msk has joined #lisp
jason_m has quit [Remote host closed the connection]
jason_m has joined #lisp
gareppa has quit [Remote host closed the connection]
b0nn has quit [Remote host closed the connection]
dale has joined #lisp
stoneglass has joined #lisp
asarch has joined #lisp
null_ptr has quit [*.net *.split]
HDurer has quit [*.net *.split]
ult has quit [*.net *.split]
spacedbat has quit [*.net *.split]
trittweiler has quit [*.net *.split]
ck_ has quit [*.net *.split]
zagura has quit [*.net *.split]
zagura has joined #lisp
HDurer has joined #lisp
trittweiler has joined #lisp
ult has joined #lisp
spacedbat has joined #lisp
Myk267 has quit [Ping timeout: 240 seconds]
null_ptr has joined #lisp
Kundry_Wag has joined #lisp
hdasch has quit [Ping timeout: 264 seconds]
hdasch has joined #lisp
ck_ has joined #lisp
CEnnis91 has quit [*.net *.split]
shenghi has quit [*.net *.split]
otwieracz has quit [*.net *.split]
cwaydt has quit [*.net *.split]
justinmcp_ has quit [*.net *.split]
|3b| has quit [*.net *.split]
shenghi has joined #lisp
cwaydt has joined #lisp
otwieracz has joined #lisp
CEnnis91 has joined #lisp
justinmcp has joined #lisp
simplegauss has quit [Ping timeout: 264 seconds]
simplegauss has joined #lisp
keep_learning has joined #lisp
asarch has quit [Quit: Leaving]
theseb has joined #lisp
ebzzry has joined #lisp
<theseb> Is this right? I think I know why/when you'd want a DSL (domain specific language).....when you are solving a very complex problem!...In that case you can't tolerate *any* distractions from your language....even an easy readable language like Python isn't clean enough when you're pushing the envelope of complexity yes?
arbv has quit [Ping timeout: 264 seconds]
<beach> By "your language", do you mean the DSL? And what kind of "distraction" are you referring to?
sjl has quit [Ping timeout: 265 seconds]
<beach> theseb: There are different reasons for preferring a DSL over a general-purpose language. Once possible reason is that you don't want your language to be Turing complete, so that the compiler can do a complete analysis of the program. In that case, the programmer must be completely restricted to the DSL that is being available.
<beach> theseb: But another possible reason might be that it is just more expressive for the domain in question, i.e., you need less code for a particular task. Then, you can make a DSL as an embedded language, and program in a mixture of the host language and the DSL.
<beach> theseb: Common Lisp programmers use the second method all the time. Any complex macro can be thought of as a small DSL for a particular domain.
pfdietz has quit [*.net *.split]
dale has quit [Ping timeout: 260 seconds]
nmg has quit [Remote host closed the connection]
krid has joined #lisp
arbv has joined #lisp
Davd[m] has left #lisp [#lisp]
Davd[m] has joined #lisp
scymtym_ has joined #lisp
scymtym has quit [Ping timeout: 260 seconds]
ebzzry has quit [Read error: Connection reset by peer]
sjl has joined #lisp
<theseb> beach: right....
<theseb> beach: at first making a DSL sounded extreme....but if you are doing something "extreme" like some hardcore cutting edge machine language thingie...then it may be warranted!
<theseb> i think i'm starting to "get" lisp ;)
varjag has joined #lisp
<theseb> beach: thanks for your help
Lycurgus has joined #lisp
cmatei has quit [Remote host closed the connection]
<beach> Sure.
cmatei has joined #lisp
<varjag> could anyone point to an example of udp broadcast handling with usocket?
pfdietz has joined #lisp
CrazyPython has joined #lisp
<theseb> beach: can i ask you about what seems an very elegant feature of lisp parsing? I think lisp can parse strings like this "abc"def" without escaping? (e.g. "abc\"def")?.....Because of the way s-expressions work it seems there isn't the ambiguity in "abc"def" you'd find in other languages...Is that right?
<phoe> theseb: that's actually not how the reader works
<phoe> "abc" gets read as a string
<phoe> def gets read as a symbol DEF
<phoe> " starts reading the next string
<theseb> phoe: i just tested (print "hel"lo") and it bombed ;)
<theseb> you are right'
<phoe> yes
<theseb> phoe: oh i think i get it....the reader doesn't know when string ends if we allow that
<phoe> exactly
<MichaelRaskin> Also, "asd""def" is a legal way to represent two strings
<pjb> theseb: there's no point in asking the same question in different channels!
<pjb> theseb: if you didn't care about CL or scheme, you could have used ##lisp !
<pjb> theseb: With the syntax you propose, how do you distinguish (list "good" morning" !") from (list "good" morning" !" ? ie a list of 1 string vs. a list of a string, a symbol and a string?
<pjb> s/ ?/)?/
anewuser has joined #lisp
edgar-xyz has joined #lisp
edgar-rft has quit [Ping timeout: 260 seconds]
benjamin-l has quit [Ping timeout: 240 seconds]
benjamin-l has joined #lisp
<theseb> pjb: hmmm...yea ...your example was ambiguous because you had a space after a "....weird that MY example is fine if you do NOT put a space after the "
Kevslinger has joined #lisp
CrazyPython has quit [Read error: Connection reset by peer]
EvW1 has joined #lisp
anewuser has quit [Ping timeout: 244 seconds]
amazoniantoad has joined #lisp
<amazoniantoad> How do I reference the second element of a simple-array? I tried using elt but it throws an error. Also aref doesn't work.
<phoe> amazoniantoad: "doesn't work", what do you mean
<phoe> (aref array 1) should do the trick
<amazoniantoad> let me try real quick
<Bike> of course, that's assuming your array is one dimensional.
<amazoniantoad> Wrong number of subscripts, 1, for array of rank 2.
<amazoniantoad> Yeah, it isn't
<Bike> if it's not one dimensional than "second element" is a more ambiguous concept.
<phoe> ^
<amazoniantoad> It's an array of arrays
<phoe> no, it's a two-dimensional array
<Bike> No, it's a two dimensional array.
<amazoniantoad> Oh okay
<phoe> an array of arrays is a different thing
<phoe> try (aref array 0 0)
<phoe> use more than one subscript, as many subscripts as many dimensions your array has
<amazoniantoad> yeah that works
<amazoniantoad> oh I see
<phoe> you can't really refer to invidual "subarrays" in Lisp, mostly because they aren't individual
jackhill has quit [Ping timeout: 272 seconds]
<phoe> a 10x10 array is different than a 10-element array full of 10-element arrays
bitmapper has joined #lisp
gko_ has quit [Ping timeout: 256 seconds]
jackhill has joined #lisp
<amazoniantoad> I see
<phoe> the first is a vector of vectors
<phoe> the latter is a 2D array
<phoe> ...which, on SBCL, is nonetheless backed by a vector for storage - but that's an implementation detail
Kundry_Wag has quit [Remote host closed the connection]
<beach> phoe: Oh? I think the standard requires the elements to be stored in row-major order.
ayuce has joined #lisp
<Bike> technically they could be stored in some other way and row-major-aref and array-row-major-index could do translations
<Bike> don't think anyone actually does that, though
<Shinmera> you can access them in row-major order byr-m-a, but yeah, you could store it however.
<beach> I guess, so, sure.
<beach> Displaced arrays would be very hard to implement then.
jonatack has quit [Ping timeout: 250 seconds]
<phoe> beach: order, yes
dale has joined #lisp
jonatack has joined #lisp
<phoe> I meant what Shinmera said though
edgar-xyz has quit [Quit: Leaving]
dale has quit [Ping timeout: 260 seconds]
CrazyPython has joined #lisp
edgar-rft has joined #lisp
Lycurgus has quit [Remote host closed the connection]
<pjb> theseb: actually, your example is no less ambiguous than mine. Notably, in CL, (length '("ab""cd"foo)) #| --> 3 |#
<pjb> theseb: reader macros can be terminating or non-terminating: (mapcar 'identity '(foo"bar"#P"baz"quux#P"FOO")) #| --> (foo "bar" #P"baz" QUUX\#P "FOO") |#
anewuser has joined #lisp
anewuser has quit [Ping timeout: 260 seconds]
krid has quit [Ping timeout: 246 seconds]
dale has joined #lisp
jackhill has quit [Quit: leaving]
jackhill has joined #lisp
varjagg has joined #lisp
shangul has quit [Ping timeout: 260 seconds]
varjag has quit [Ping timeout: 265 seconds]
theseb has quit [Ping timeout: 244 seconds]
dale has quit [Ping timeout: 240 seconds]
<z0d> someone's writing a Diablo clone in SBCL
Kundry_Wag has joined #lisp
bor0 has quit [Quit: Leaving]
Kundry_Wag has quit [Ping timeout: 246 seconds]
renzhi has joined #lisp
ayuce has quit [Read error: Connection reset by peer]
jonatack has quit [Quit: jonatack]
<Grue`> z0d: hopefully it has Kitten of Death as a monster
Lord_of_Life has quit [Read error: Connection reset by peer]
dale has joined #lisp
Lord_of_Life has joined #lisp
dale has quit [Ping timeout: 260 seconds]
zaquest has quit [Ping timeout: 260 seconds]
jonatack has joined #lisp
anlsh has joined #lisp
renzhi has quit [Ping timeout: 240 seconds]
emys has joined #lisp
stoneglass has quit [Read error: Connection reset by peer]
varjagg has left #lisp [#lisp]
narimiran has quit [Quit: leaving]
v_m_v has joined #lisp
Intensity4 has joined #lisp
EvW1 has quit [Ping timeout: 244 seconds]
Intensity has quit [Ping timeout: 264 seconds]
Intensity4 is now known as Intensity
anewuser has joined #lisp
Kundry_Wag has joined #lisp
anewuser has quit [Ping timeout: 244 seconds]
Kundry_Wag has quit [Ping timeout: 240 seconds]
dale has joined #lisp
_jrjsmrtn has joined #lisp
__jrjsmrtn__ has quit [Ping timeout: 240 seconds]
dale has quit [Ping timeout: 246 seconds]
Necktwi_ has joined #lisp
nika has quit []
EvW has joined #lisp
Necktwi has quit [Ping timeout: 256 seconds]
Kundry_Wag has joined #lisp
ayuce has joined #lisp
renzhi has joined #lisp
cyberoctopi has joined #lisp
cyberoctopi has quit [Ping timeout: 244 seconds]
krid has joined #lisp
v_m_v has quit [Remote host closed the connection]
vlatkoB has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
efm has joined #lisp
v_m_v has joined #lisp
cyberoctopi has joined #lisp
|3b| has joined #lisp
<Grue`> !clhs 22.2.1.2
<Grue`> what would be format alternative to (pprint-fill nil (alexandria:iota 100)) ? Can't figure it out...
cyberoctopi has quit [Ping timeout: 244 seconds]
<|3b|> Grue`: "~@<~a~:@>" or something like that?
<|3b|> or "~:<~@{~a~^ ~}~:@>", depending on how much control you want over printing the list
<|3b|> (assuming you mean the behavior of pprint-fill when *print-pretty* is t. if you want it to depend on *print-pretty* use "~:/pprint-fill/" format string)
<Grue`> hmm I tried (format nil "~<~{~a ~}~:>" (list (alexandria:iota 100))) but it didn't work at all
<Grue`> but "~<~@{~a~^ ~}~:@>" does what I want
Jesin has quit [Quit: Leaving]
<|3b|> yeah, body of ~< ... ~:> sees corresponding argument as if it were expanded, ~@{~} puts it back into a list and iterates over it
<|3b|> so you could use ~{~a~^ ~} with (list (iota 100)) instead
<|3b|> @ in ~:@> adds conditional newline after every space, so it matches pprint-fill
<|3b|> and : in ~:< adds parens around it, if you want those
<pve> hello
<Grue`> well actually I have a list of pairs (key description) and I want to format each of them as "[~a] ~a". However if ~@{...~} is used, it gets (key description) on every iteration and can't be easily formatted. but if ~{... ~} is used then filling doesn't work
<pve> Do you guys think it be cleaner to use dynamic variables in a situation such as this? Or some other approach?
<pve> I.e. communicating certain things from the top-level down to the lower levels.
Jesin has joined #lisp
<|3b|> Grue`: like '((a b) (c d) (e f))?
<pjb> (format nil "~:{[~A] ~A ~}" '((k1 d1) (k2 d2) (k3 d3))) #| --> "[k1] d1 [k2] d2 [k3] d3 " |#
<phoe> pve: you already are using dynamic variables under the hood
<|3b|> "~<~@{~{~a=~a~}~^, ~}~:@>" prints that as A=B, C=D, E=F
<phoe> you seem to use the convenient feature of handlers where, if they don't transfer control, they execute in order from newest to oldest, just like hooks
<|3b|> or with ~{~a = ~a~}, can break before or after the =
sjl has quit [Ping timeout: 260 seconds]
<Grue`> oh yeah right, another level of iteration
Kundry_Wag has quit [Remote host closed the connection]
<Grue`> though I'd want the space between pairs to be unbreakable
<|3b|> if you want spaces inside an item without breaking an individual item, "~<~@{~<~a = ~a~:>~^, ~}~:@>"
<phoe> pve: I'd need more context about that issue; do you need to have multiple layers of communication and need it to be established in dynamic scope?
<pjb> (format nil "~:{[~A] ~A~:^; ~}" '((k1 d1) (k2 d2) (k3 d3))) #| --> "[k1] d1; [k2] d2; [k3] d3" |#
jackdaniel has quit [Remote host closed the connection]
<pjb> Note: you need to use ~:^ instead of ~^ in that case.
jackdaniel has joined #lisp
<pve> phoe: yes to dynamic scope, and the layers in question are pretty disconnected so I'd like the coupling to be loose
<Grue`> |3b|: oh now I'm starting to get it
<pve> and somehow I feel that the condition approach gives me looser coupling.. although that could be an illusion
<|3b|> pjb: does that do the pprint-fill style wrapping?
<phoe> pve: you can use the condition system for that, sure, or you can construct your own dynamic hook system
<pjb> |3b|: no, this is without the pretty-printer.
<phoe> the condition approach is basically (let ((*hooks* (cons new-hooks *hooks*))) ...)
<phoe> where new-hooks is the list of new hooks that you specify to fire for condition type ASK
<Grue`> I need pretty printing though for pretty UI :)
<phoe> or, if you don't need to cluster hooks together, (let ((*hooks* (append new-hooks *hooks*))) ...)
<pve> phoe: I see, thanks.. I'll pick one approach now and see if it sticks. It should be easy to change later in this case
<phoe> this is literally how the handler subsystem works under the hood, so you can either use it for your purpose or devise your own
heisig has joined #lisp
man213 has joined #lisp
Nilby` has quit [Ping timeout: 260 seconds]
karlosz has joined #lisp
dale has joined #lisp
dale has quit [Client Quit]
dale has joined #lisp
lucasb has joined #lisp
Kundry_Wag has joined #lisp
sjl has joined #lisp
CrazyPython has quit [Read error: Connection reset by peer]
Kundry_Wag has quit [Ping timeout: 260 seconds]
efm has quit [Ping timeout: 240 seconds]
heisig has quit [Quit: Leaving]
efm has joined #lisp
karlosz has quit [Quit: karlosz]
ArthurStrong has left #lisp [#lisp]
v_m_v has quit [Remote host closed the connection]
heisig has joined #lisp
<pfdietz> The place where I use hooks like that is the aptly named *macroexpand-hook*. Very handy for AOP-style things.
emys has quit [Ping timeout: 244 seconds]
emys has joined #lisp
ArthurStrong has joined #lisp
ArthurStrong has left #lisp [#lisp]
Kundry_Wag has joined #lisp
pilne has joined #lisp
X-Scale` has joined #lisp
X-Scale has quit [Ping timeout: 258 seconds]
X-Scale` is now known as X-Scale
Kundry_Wag has quit [Ping timeout: 260 seconds]
grumble is now known as rawr
Lycurgus has joined #lisp
Oladon has joined #lisp
Inline has quit [Ping timeout: 272 seconds]
karlosz has joined #lisp
zooey has quit [Remote host closed the connection]
shka_ has quit [Ping timeout: 260 seconds]
Lycurgus has quit [Remote host closed the connection]
_heisig has joined #lisp
heisig has quit [Ping timeout: 244 seconds]
zooey has joined #lisp
heisig has joined #lisp
_heisig has quit [Ping timeout: 240 seconds]
sjl has quit [Quit: WeeChat 2.2-dev]
heisig has quit [Ping timeout: 244 seconds]
Myk267 has joined #lisp
SGASAU has quit [Remote host closed the connection]
SGASAU has joined #lisp
<ralt> it's my first time writing a recursive macro
<ralt> it's fun
<ralt> well, rather, it's my first time writing a macro that recurses into forms to generate the code
<ralt> i.e. ((foo) (bar)) ends up as (foo (bar))
karlosz has quit [Read error: No route to host]
karlosz has joined #lisp
CrazyPython has joined #lisp
karlosz has quit [Read error: No route to host]
karlosz has joined #lisp
amazoniantoad has quit [Quit: Connection closed for inactivity]
ayuce has left #lisp ["ERC (IRC client for Emacs 28.0.50)"]
shifty has quit [Remote host closed the connection]
shifty has joined #lisp
shifty has quit [Ping timeout: 260 seconds]
v_m_v has joined #lisp
pve has quit [Quit: leaving]
duncan_ has quit [Ping timeout: 260 seconds]
SAL9000 has joined #lisp
<SAL9000> Hi everyone (long time no see...)! Does ELS 2020 have an IRC channel of its own, or will it be just Twitch chat?
<Shinmera> Just Twitch.
<Shinmera> Though you can chat on Twitch over IRC (they have a bridge for it)
rand_t has joined #lisp
man213 has quit [Ping timeout: 244 seconds]
sjl has joined #lisp
adam4567 has joined #lisp
add^_ has quit [Read error: Connection reset by peer]
emys has quit [Quit: Leaving]
Lycurgus has joined #lisp
<pfdietz> Can one log into twitch using gnome-twitch, or is that just for viewing?
<anlsh> How can I accomplish something like (apply #'and list-of-conditions)?
<|3b|> is list-of-conditions already evaluated?
<anlsh> Yes
<|3b|> (every 'identity list-of-conditions) maybe?
<|3b|> or (loop for i in list-of-conditions always i)
<anlsh> Thanks
v_m_v has quit [Remote host closed the connection]
<|3b|> or (not (member nil list-of-conditions))
gravicappa has quit [Ping timeout: 264 seconds]
frgo has quit [Remote host closed the connection]
frgo has joined #lisp
CrazyPython has quit [Remote host closed the connection]
<aeth> Heh, apparently loop has an always. I've never seen that one before.
* |3b| isn't sure if (notany 'null list-of-conditions) is more or less clear than (every 'identity ...)
<|3b|> more obvious test, but inverted sense of main function
<|3b|> shorter if nothing else :p
xlei has quit [Ping timeout: 240 seconds]
<|3b|> (notany 'not ...) is probably less clear :)
<|3b|> aeth: yeah, not one of the more common ones, but useful sometimes
tomaskral has joined #lisp
<|3b|> probably more common than INITIALLY or package symbol iteration at least
xlei has joined #lisp
<aeth> ":always foo" is a bit unusual/niche because it's just replacing ":unless foo :do (return nil) :finally (return t)" which, yeah, when written in IRC looks a lot longer, but it's not that much longer.
<aeth> looks like it produces the same disassemble in SBCL, too
rgherdt has joined #lisp
<|3b|> annoying that LOOP's always,never,thereis don't match every,notany,some :/
refusenick has joined #lisp
<|3b|> arguably COUNT foo just replaces SUM (if foo 1 0) too, but both are more clear, not just shorter
<aeth> LOOP's always seems useful for a short-circuiting reduce if you want to e.g. implement something like char<
<aeth> (char< is arbitrary-length)
<refusenick> I started using StumpWM on my 2nd laptop because I wanted to try Emacs' experimental ELisp compiler without causing more EXWM crashes and because EXWM has bugs opening some apps.
<aeth> I'm surprised people use Emacs for everything, e.g. IRC.
<refusenick> However, while those apps work in StumpWM, others (notably Zoom, which I have to use) crash it entirely
<refusenick> Is there a "mini Erlang" package for CL?
<aeth> The only issue I've seen on StumpWM is Steam big picture mode, which crashes, it doesn't crash StumpWM.
<refusenick> (open app in its own process, trust it won't modify everything else, monitor it for crashes and restart with attempted fixes)
cosimone has quit [Remote host closed the connection]
cosimone has joined #lisp
<refusenick> aeth: It sucks too much to not have Emacs keys everywhere else. That's my one regret about learning Emacs instead of Vim - no one writes Emacs key overlays for Firefox, etc
akoana has joined #lisp
Oladon has quit [Quit: Leaving.]
<aeth> I like Emacs keys everywhere (although you often get a readline-like subset of Emacs keys in a lot of places inside terminals, not just the shell itself)
<refusenick> aeth: I think Zoom is the only one which has outright crashed StumpWM itself, which is a shame because I'm supposed to use that
<anlsh> From my limited experience with emacs keybindings I have concluded they suck
<anlsh> I use spacemacs myself :|
tomaskral has left #lisp [#lisp]
<refusenick> anlsh: You can get pretty fast with them if you rebind Control to Caps Lock
<aeth> The basics like C-a, C-e, C-t, etc., are good and useful. Far easier than the typical alternatives (which are home and end for C-a and C-e... way harder to use and not accessible on all laptops)
<aeth> The ergonomics in actual Emacs of some actual Emacs things I do all of the time are a bit awkward, like C-u M-! (i.e. C-u M-shift-1) for e.g. timestamping a text document via C-u M-! date -Iminutes RET
<aeth> I guess I could configure that, but then it'll only work on a subset of my machines, not everywhere
<aeth> And the worst thing about trying to make frequent things more ergonomic (which I've done in stumpwm) is finding a convenient, unused combination! Most convenient combinations are taken, even if I never use them intentionally!
<refusenick> aeth: I've taken to rebinding certain keys (default query-replace is M-% - for me, it's C-c q q, and C-c q r for query-replace-regexp)
<aeth> In stumpwm, I launch firefox with t or C-t because those aren't taken because stumpwm foolishly uses C-t as its default start of its key sequence (which is incredibly bad, and needs to be rebound to avoid having to C-t C-t every time you want to use C-t)
<aeth> s/use C-t/use C-t in an app/
<aeth> But in general key combos are hard
<refusenick> aeth: The global namespace and lack of (key) modes is part of the appeal, though. It's like Logo - one chord = one function, so macros can become bona fide procedures if you want. I feel like a lot of the "Emacs keys vs Vim keys" arguments miss that.
<aeth> Emacs keys are a more powerful way of doing typical key bindings because the chording reduces the chance of collisions and gives you more available.
<aeth> vim is just another mode of thinking
<refusenick> Isn't it C-t t to send C-t? In any case, I rebound C-t to C-z. Not so many problems, except for that I still hit Emacs sequences (M-x, C-x, etc) in external apps thinking they'll pull up Emacs commands like in EXWM.
<aeth> stumpwm here isn't that good because it has one "namespace" of sorts (by default, C-t foo), but there isn't really a good answer here because you don't have the luxury of GNU Emacs where you can just use every key combination.
<verisimilitude> Well, there's the *TOP-MAP* and the *ROOT-MAP*.
<aeth> Although this could be avoided by using the super key, which is usually assumed to be reserved to the window manager, which then lets you e.g. have s-z s-x s-c, etc., all available. Of course, stumpwm doesn't work like that so you can only choose one and that's your new prefix
<aeth> refusenick: C-t t and C-t C-t are used to send C-t, but C-t is a terrible default (I rebound my stumpwm to use a combo involving the super key, for the reasons outlined above) so by removing that default, that means that I have C-t and t available for my personal use, i.e. Firefox
<aeth> That saves me from having to use ! firefox RET
<refusenick> verisimilitude: I like how stumpwm:define-remapped-keys lets you give a regex for which programs should have which top-level keys. If I could find how to bring up an Emacs posframe (child frame) without bringing a full visible frame behind it, I could issue M-x from whichever app in my background Emacs server.
<aeth> Now, not every keyboard has super and having the key is kind of mandatory, but if I were to write my own CL WM, I would use a dozen super-key prefixes (s-z, s-x, s-c, etc.) which gives me namespaces like Emacs and means the user can define things they want with lower risk of that already being taken
<refusenick> I tried using s-x for some time. Too clumsy for me (and it's on a laptop with a non-replaceable keyboard, so no custom LispM keys for me)
<aeth> s-x and not s-z?
<aeth> s-z is usually the most convenient
<refusenick> In retrospect, that's what I should have done. C-z works fine, though.
<aeth> On my laptop, super's right under z. On my desktop, the z is above both super and left alt (mostly, but not entirely, the left alt).
<aeth> Either way, s-z is the easiest super-based key
<refusenick> All the super-based keys are hard for me. I type like a moron. :)
<aeth> s-z s-z is more convenient than alt tab, which is fun, although technically alt-tab equivalent would be the much harder s-z n in stumpwm
<aeth> s-x would be a good M-x equivalent since it's harder
<aeth> s-c for user defined things could be OK
man213 has joined #lisp
<refusenick> I never even knew about alt-tab until after I learned Emacs, I think
Lycurgus has quit [Quit: Exeunt]
<refusenick> In any case, is there an "Erlang processes" library for CL? I know it can't provide real isolation, but I'd like to isolate app failure from StumpWM's core functionality.
<refusenick> When Zoom dies, I have to Ctrl+Alt+F2 and kill the X server from the TTY. It's a good thing I left one of the TTYs active.
<refusenick> That, or I'll need to find a more reliable WM.
Lord_of_Life_ has joined #lisp
Lord_of_Life has quit [Ping timeout: 240 seconds]
Lord_of_Life_ is now known as Lord_of_Life
<MichaelRaskin> refusenick: I think #stumpwm is a better place for discussion; I think you can try triggering StumpWM soft-restart from the TTY; and also, just open the Zoom link in Chromium and press «doesn't work» three times, then «join in browser» appears.
<refusenick> MichaelRaskin: Fair enough. That's what I've been doing, but I also haven't built ungoogled-chromium yet. I'd like it if I could run the app and just the app under as much virtualization and sandboxing as possible. Yuck.
<refusenick> (Also, I was looking for library suggestions for process isolation)
<refusenick> b
rgherdt has quit [Ping timeout: 265 seconds]