summaryrefslogtreecommitdiffstats
path: root/2021/talks/form.md
diff options
context:
space:
mode:
authorSacha Chua <sacha@sachachua.com>2021-12-02 01:23:52 -0500
committerSacha Chua <sacha@sachachua.com>2021-12-02 01:23:52 -0500
commit3b6a2c161825236f442727107b02d30a4b4c0c70 (patch)
treed604edeb2cfca73cd654abde2745a51f831a2540 /2021/talks/form.md
parent532bc5cda6dc0f094e9adcfdadfdc7bf435779f0 (diff)
downloademacsconf-wiki-3b6a2c161825236f442727107b02d30a4b4c0c70.tar.xz
emacsconf-wiki-3b6a2c161825236f442727107b02d30a4b4c0c70.zip
IRC notes from day 2
Diffstat (limited to '2021/talks/form.md')
-rw-r--r--2021/talks/form.md22
1 files changed, 21 insertions, 1 deletions
diff --git a/2021/talks/form.md b/2021/talks/form.md
index 73fef6ee..093887ed 100644
--- a/2021/talks/form.md
+++ b/2021/talks/form.md
@@ -24,7 +24,27 @@ comes with a powerful system for object-oriented programming? Join me
for a discussion of EIEIO, and learn how it can help you write more
modular, flexible Emacs Lisp.
-
+# Discussion
+
+IRC nick: ieure
+
+- I didn't know that custom.el works with EIEIO that way, very nice
+- Dang Ian. What a talk, great demos.
+- Wow, that's a great talk.
+- Great talk. So with that Emacs is on pair with Smalltalk development environments now
+- For reference, transient.el, which we all know and love as the engine that drives the magit interface, is written via EIEIO afaik.
+- I reckon I should look more into it, I've always avoided it because I was afraid it wouldn't be /quite as nice/ as CLOS or GOOPS.
+ - ieure: It's missing a few things (most documented in the manual: https://www.gnu.org/software/emacs/manual/html_mono/eieio.html#CLOS-compatibility), but it's solid and worth using.
+ - Yeah when transient.el first came out I was impressed by how naturally it worked as part of that abstraction.
+- ieure: EIEIO all the things! I had to cut it, but you can use dynamic dispatch based on major-mode, like: (cl-defmethod whatever ((mode (derived-mode python-mode)))) and then (whatever major-mode).
+
+- Also really nice for things like 'window-system. I really like when callsites are clean and not cluttered with conditionals.
+- Can eieio do regexp dispatch?
+ - ieure: Not currently, but it's possible to add.
+ - okay, so I don't need to feel too bad about coding up my own vtable for those then
+ - ieure: This is the thing that implements (thing (eql :whatever)) specialization, should be a good starting point if you want (thing (string-match-p "^foo")): <https://git.savannah.gnu.org/cgit/emacs.git/tree/lisp/emacs-lisp/cl-generic.el#n1164>
+ - thanks for the pointer, but I think I have some more pressing cl-defgeneric reimplementations to make before I touch that
+ - ieure: Extremely fair. One thing I didn't get to touch on is that you can extend generic functions from anywhere. So you don't have to patch up cl-generic.el, you can define a new method for a generic function defined anywhere, in any file. Which rules.
# Outline