freenode/#lisp - IRC Chatlog
Search
21:54:46
cgay_
Go has that but I have to say I haven't seen it used much. I think in a local scope it's not that useful, though it provides a little more indication of intention.
21:56:12
Ukari
i wanna use lexical defconstant or a lexical let which can't assign twice, because it might make code more clear when a variable couldn't be changed
22:01:02
pfdietz
(let-const ((x e)) . body) ==> (let ((#:G0001 e)) (symbol-macrolet ((x (identity #:G0001))) . body))
22:02:30
cgay_
bike-shedding: would be nice to be able to indicate const-ness for a particular variable in a LET, rather than introducing a new level of indentation.
23:23:36
pillton
You could also use the position return value of read-from-string and its start argument.
3:58:46
aeth
What do people use for Lisp testing? I've seen two. Roswell. And now this lisp-devel Docker. https://lispcookbook.github.io/cl-cookbook/testing.html#gitlab-ci https://hub.docker.com/r/daewok/lisp-devel/
4:09:40
edgar-rft
aeth: there's an ANSI test suite for testing Lisp, but I assume that you're not looking what you're asking for.
5:03:34
low_brain_cache
I haven't registered a nick but I've been on here as beginner_supreme, cl0s, Common_Lisp (I think), etc.
5:06:37
low_brain_cache
I figure that since nicks are temporary assuming low activity, and registering a nick doesn't necessarily disallow others from using it, there's no reason to register
5:13:32
LdBeth
I believe freenode also allow to register several different nick under one mail address for bot or something
5:14:47
low_brain_cache
Is there a freenode manual of commands? /help lists a table but /help <command> doesn't do anything. <- Sorry for the non-lisp question but since we're on the topic of IRC... ;)
5:19:47
LdBeth
low_brain_cache: many commands are IRC client specific, so you should find your own manual
7:40:07
kuribas
Hi, I've set inferior-lisp-program with customize to sbcl, however everytime I restart emacs, it gets reset to lisp. Any idea why?
7:42:59
hajovonta
kuribas: I think this is an #emacs question, but I think you should set the state to "Save for future sessions"
8:23:33
jdz
I have no idea. Defining questions in terms of what Haskell does in #lisp seems... wrong.
8:30:34
jdz
Lisp is not Haskell, so this most likely is not the best way to solve whatever problem it is you're solving.
8:38:09
loke
No one will every convince me that reverse drop reverse is simple or beautiful. With a magic compiler is may be efficient. Maybe.
8:39:50
lieven
the standard prelude has some awkward stuff in it. for real work, you should use Text for strings
8:43:43
kuribas
I was reading this, and I found the lisp code quite ugly: https://markkarpov.com/post/lisp-and-haskell.html
8:47:38
kuribas
in haskell: addPadding str pad newline = intercalate ('\n' : replicate pad ' ') $ lines $ if newline then "\n" ++ str else str
8:49:08
hajovonta
Common Lisp is not a functional language, but it supports functional style programming.
8:50:52
jdz
I wonder why people who have no real experience with a programming language immediately have an urge to write articles titled "Why XXX is not my favourite programming language and why you should use YYY."?
8:53:42
hajovonta
loke I think (judging by the name) it takes a string and extends it with dummy characters or something like that
8:53:46
loke
shrdlu68: Did you see the add-text-padding fuction? Wtf... w-o-t-s with a map 'string inside followed by a return that is never used?
8:54:41
loke
Oh wait. he maps over the characters. And he seems to believe that 'string refers to the type of the thing he's mapping over
9:01:35
jdz
Never mind that the original code has parameter named STR that is shadowed by LET binding.
9:03:09
jdz
OK, that's intended. Making a copy of input for no apparent reason. I wonder if the guy has tested his code?
9:03:11
loke
I like his argument that QL doesn't use tests. But tests are required. Therefore QL is broken.
9:03:27
loke
Instead of: QL doesn't need tests, and still works. Perhaps I'm wrong and tests are not the end-all-be-all?
9:03:54
jdz
This function seems so convoluted it triggers all the possible wrong signals in my brain.
9:04:19
loke
jdz: It probably _has_ tests, and therefore it's perfect. No matter hopw convoluted. The tests pass!
9:04:55
kuribas
ok, so I have this, with the cl-string library: (join ((concat (string #\Newline) (repeat padding " "))) (lines str))
9:12:40
jdz
I have real trouble wrapping my head around what it's supposed to do and in what circumstances one would use such a function.
9:20:11
jdz
Elegance is subjective. I personally find my version straight-forward and directly matching the problem statement, and also not particularly inefficient.
9:25:37
varjag
kuribas: idiomatic lisp solution is to use an existing library, implementing this efficiently