freenode/#lisp - IRC Chatlog
Search
14:20:38
beach
The standard says that, but then it also says it they are allowed to be one and the same, and that's what all implementations do.
14:23:29
beach
"The compilation environment inherits from the evaluation environment, and the compilation environment and evaluation environment might be identical. The evaluation environment inherits from the startup environment, and the startup environment and evaluation environment might be identical."
14:23:55
beach
ebrasca: But that's not the point here. The point here is that more than one run-time environment is needed for modularity.
14:26:46
CL-ASHOK
What's the best way to write Lisp documentation? I am thinking detailed documentation on exported functions within a package, with some basic notes how internal functions work?
14:27:37
jackdaniel
CL-ASHOK: I'm usually linking this post written by sjl: https://stevelosh.com/blog/2013/09/teach-dont-tell/
14:27:55
no-defun-allowed
CL-ASHOK: You likely want to make separate documentation for the protocol users should use, and for internals.
14:28:19
beach
CL-ASHOK: You mean what software to use? There are so many choices that any one choice would only get a tiny fraction of approval.
14:28:23
jackdaniel
it provides a very good intuition about different types of documentation and how they supplement each other
14:29:13
CL-ASHOK
no-defun-allowed: That's true, will do that. For now, its just documentation for myself, but I'll then split it into two and the exported functions will go to the user documentation
14:29:42
CL-ASHOK
beach: I'm just using GitHub Wiki Pages for Now, want to keep overhead as low as possible
14:37:00
no-defun-allowed
It can, but one should wonder if it should. At least nice documentation needs more formatting and introductory text than what you can get from scraping documentation strings.
14:39:22
CL-ASHOK
I never had the chance to use it. I see QuickRef from time to time, but I'm not the biggest fan
14:43:08
no-defun-allowed
My best documentation is probably in <https://theemacsshibe.gitlab.io/documentation/> which is still incomplete, but has almost everything I think is right for a reference.
14:44:31
no-defun-allowed
Sometimes it also mentions why a design decision was made, which also wouldn't fit in a documentation string or internal comment.
14:47:39
CL-ASHOK
Thats a very detailed example. The decision of the pages (left hand menu, prev / next on the top) is really good
14:48:42
CL-ASHOK
Yes, I think documenting the why behind design decisions is very important. Basically the exported definitions should be clearly explained so that a newcomer can read them, then the internal definitions should be lightly explained, with a focus on the why and how vs. detailed notes on each function
14:49:06
CL-ASHOK
IMO many functions are self explanatory, and we get lazy anyway when it comes to writing docs.
14:50:17
no-defun-allowed
My "aggressively move code into separate functions" strategy also lets me seemingly avoid comments by picking nice function names.
14:51:50
ptdevnull
I'm trying to set up a Doom Emacs environment with sly, but I keep running into issues with sly-contrib. Currently it's throwing an error trying to load sly-macrostep and complaining of an attempt to load an empty FASL file. Does anyone have a working configuration?
14:51:52
no-defun-allowed
(Of course, one picks good function names instead of writing good comments.)
14:53:22
CL-ASHOK
I do the same, although I still haven't mastered what I think is a good naming convention for functions. I do really like functions & variables having separate namespaces
14:54:21
CL-ASHOK
e.g. (let ((word-list (word-list word-string))... is preferred style, the repetition of the variable / function name imo makes it easier to digest
15:07:27
CL-ASHOK
ptdevnull: sorry don't know the answer of your query. Although I recommend Vanilla Emacs if you want to modify things a bit, after some time, the customised solutions like Doom / Portacle become a pain to modify to your desired setup
15:37:38
lukego
splittist, fiddlerwoaroof: hey I just pushed a small-but-big change to CLIME on the emacs side. Now it basically works fine to kill/yank CLIME images into other buffers. (Before if you moved the point onto an image then the keyboard stopped working because all the keymap events were buggered up, and yanked images didn't work with ACCEPT.) "Simple" fix that took a full day w/ help from #emacs to work out :)
15:39:12
lukego
Have to think about performance soon... I currently have about 60,000 presentations alive in both Emacs (as area definitions on image objects) and in Lisp (as strong references in clim-emacs::*presentations* registry.) It takes noticable time for Emacs to update all the presentations when switching input context e.g. a couple of seconds now.
15:46:58
jmercouris
no-defun-allowed: comments are not intended to explain what, but how, the function name should /always/ suffice for what
15:47:14
jmercouris
they are not arbitrary symbols, they are a piece of text that is supposed to convey meaning for programmers
15:47:24
jmercouris
otherwise each function could be completely anonymous or named by memory address... etc
15:48:19
phoe
I'd be more like, names explain the "what", documentation and docstrings explain the "how", comments explain the "why"
15:55:33
jnewton
jmercouris: should I have to change the name if I don't change what a function does, but I change how it does it?
15:56:22
jnewton
I would say that normally a function name is independent of its implementation. There are exceptions of course such as. FooFast and FooSlow
17:36:18
pjb
phoe: yes, but only superstars need to apply to join Ravenpack's team of superstars… ;-)
17:41:48
loli
beach: is that the case because of qualification and updating qualification upon module changes would be too expensive?
17:44:13
loli
beach: also do you have any more references for first class environments, I've read your SiCL paper about the subject
18:33:41
rpg
I could use some iterate advice if anyone has it. I have an iter loop using with-vector, and when I declare the type of the iteration variable I get this warning: Iterate, in clause (FOR CHILD IN-VECTOR (CHOICE-CHILDREN CHOICE-ENTRY) WITH-INDEX INDEX): Cannot supply an initial value for type (OR NULL CHOICE); using NIL. I have no idea how to make it go away.
18:38:55
rpg
The problem only arises when I put in a type declaration for this variable (so, yes, I know -- don't do that then!).
18:54:19
Bike
the function that's coming from looks dicey but i don't understand what it does well enough to diagnose anything
18:54:36
Bike
seems like they could just do (subtypep null declared-type) and if true, heyo, initialize to nil
19:42:33
nij
Is there a typo in Alexandria's manual, as in "Function: mappend function &rest lists" ;; https://common-lisp.net/project/alexandria/draft/alexandria.html
20:19:26
jackdaniel
I wrote a small tutorial about CLIM: http://turtleware.eu/posts/You-dont-need-a-backend-to-use-CLIM.html for those interested :)
21:07:11
nij
How much mouse should I use with CLIM? Is it possible to customize it to be keyboard-centric?
21:23:53
jackdaniel
nij: thanks. that depends on the application, but in principle commands may have keyboard accelerators
21:24:48
jackdaniel
as of selecting presentations on the screen, at some point of time I saw that someone hacked something so small numbers appeared beside acceptable presentations so it was possible to type the number instead of using a pointer
23:11:27
copec
What sort of CI/CD do you use with CL? Do you create a fresh image if you fix something and commit it to a repository? Have you setup a way to update the remote image? What sort of interaction do you do between a local copy of your source, and local running emacs with a remote swank?
23:24:40
pjb
copec: yes, if you want to validate or build a library or application, it's better to start from a fresh image.
23:28:31
pjb
and more: https://www.google.com/search?client=safari&rls=en&q=CI/CD+Common+Lisp&ie=UTF-8&oe=UTF-8
23:29:21
pjb
copec: of course, it's related to the question of delivery: it will depend on how you will deliver your code, and how you test it.
23:29:59
pjb
copec: but assuming you build (save) executable images, here is a typical example of how I proceed: https://github.com/informatimago/hw
23:31:24
pjb
copec: note, ecl is a special case, since it doesn't save executable images, but instead it will produce normal elf objects and binaries (or whatever native format on the target platform, since it goes thru gcc to compile and link).
23:32:00
copec
The code I'm using is just for me to administrate a bunch of things, we use SaltStack and gitlab internally, so I made some states that build roswell, and then I use that to build my image (against sbcl specifically)
23:33:27
copec
It all seemed so what everybody does for non-lisp stuff, I just wondered if I'm doing it wrong
23:35:03
fiddlerwoaroof
The build is failing now :( but, here's a CircleCI configuration for one of my projects: https://github.com/fiddlerwoaroof/daydreamer/blob/master/.circleci/config.yml
23:35:19
fiddlerwoaroof
I also just like to have a simple shell script or makefile instead of using Roswell
23:38:37
fiddlerwoaroof
Here's an example of that: https://github.com/fiddlerwoaroof/cl-git/blob/master/.github/workflows/test.yaml
23:43:10
etimmons
copec: and here's a concrete example with Gitlab CI https://gitlab.common-lisp.net/asdf/asdf/-/blob/master/gitlab-ci.yml
23:58:18
pjb
Definitely. Once you've written whatever you use to build or run tests, you should have a Makefile to do it easily from he shell.
0:56:47
no-defun-allowed
This dictionary says an apocalypse is "something viewed as a prophetic revelation". Since people know that shells are pretty janky, I would say you are in a post-apocalyptic scenario already.
1:37:05
Xach
etimmons: adopt-subcommands got me to add support for looking up release info from gitlab
1:37:46
Xach
it turned out to be pretty easy - i can mostly pretend it's github, the protocol of GFs meant I only had to implement a single method in a key place...
1:40:43
copec
nij bash is actually a bit faster than python in many cases, and it's directly interpreting the text stream, I've thought it would be funny to have a lisp on top of bash