freenode/#lisp - IRC Chatlog
Search
16:54:28
shka_
vms14: abstraction layer, this way you can TRACE access to the html-mode, you can define logging, you can do all sorts of stuff
16:57:06
Bike
that's how setf works. if it can't find an expander or anything, (setf (foo ...) bar) becomes (funcall #'(setf foo) bar ...)
16:59:26
Jachy
Maybe the answer vms14 is more simply, convention? You'll often see a get/set pair of (get-foo) and (setf (get-foo)) instead of (get-foo) and (set-foo).
17:01:29
katco
vms14: i think common-lisp.net is the canonical landing-page for common-lisp, but i agree you can't beat a curated walkthrough like you get from a book, and practical common lisp is a great first read.
17:03:15
katco
vms14: as an author who spent a lot of time away from my family and young daughter to write a book, it is distressing to hear you steal books.
17:03:47
Bike
seriously, if you say "more than you can afford" but don't mean money what are you even talking about
17:05:42
vms14
Bike: I never end a book, but nvm. I was asking for a website because I usually need to look for more info while reading a book
17:08:01
Bike
so you have the easy to understand introduction, and then the manual for the more complicated points
17:10:59
edgar-rft
vms14: you can read CLtL2 (Common Lisp the Language 2nd edition) if you want a something that covers all of Lisp, but it predates the official CL Standard by a few years, see https://www.cs.cmu.edu/Groups/AI/html/cltl/cltl2.html
17:14:22
vms14
https://www.cs.cmu.edu/afs/cs.cmu.edu/project/ai-repository/ai/lang/lisp/doc/cltl/cltl_ht.tgz
18:52:22
fe[nl]ix
phoe: can you send a pull request addressing the issues in https://github.com/sharplispers/split-sequence/issues/14 ?
20:17:41
TheWild
Lisp atoms are: NIL (an empty list), string, number and symbol. Non-empty list is not an atom. Are there other types that are built to the interpreter?
20:23:14
aeth
"number" oversimplifies things and might imply that you just have double float like some languages (which I won't name) do
20:23:25
aeth
There's actually a very elaborate numeric tower in Common Lisp and most other decent Lisps
20:23:37
asdf_asdf_asdf
http://www.lispworks.com/documentation/HyperSpec/Body/09_aa.htm http://www.lispworks.com/documentation/HyperSpec/Front/Contents.htm
20:24:48
TheWild
well, that's a lot of stuff. I forgot about functions, but I was suspecting Lisp bootstraps everything from conses or something else.
20:25:43
Bike
yeah, in really old lisps you could call conses if they were lambda expressions, stuff like that
20:26:12
phoe
but you need more stuff to bootstrap off if you want to actually be efficient; numbers and arrays are a must, and some sort of function objects to represent code.
20:26:33
phoe
with that and a little bit of trickery, you can implement hash-tables, structures and classes, and bootstrap a lot of stuff off that.
20:27:17
Bike
actually i vaguely remember reading some old lisp implementation implemented numbers as conses of digits
20:27:46
Bike
which sounds horrible, but i guess that's what a bignum is if you really think about it and are intoxicated.
20:29:03
aeth
Bike: This is the only way a Lisp should implement integers imo. https://gitlab.com/snippets/1761668
20:29:03
minion
davve: please look at pcl: pcl-book: "Practical Common Lisp", an introduction to Common Lisp by Peter Seibel, available at http://www.gigamonkeys.com/book/ and in dead-tree form from Apress (as of 11 April 2005).
20:30:08
TheWild
darn, I have to think about Lisp as a higher-level language than just three steps away from assembly. (C was one step, C++ were two ;))
20:33:28
asdf_asdf_asdf
Character "'" (quotation mark) prevent evalution value. '*my-var* it's not the same with *my-var*.
21:22:08
Younder
1994 is a long time ago. The standard became stale. No-one cared. The world moved on.
21:27:44
defunkydrummer
phoe: TAGBODY and GO like a Real Programmer would do. Because Real Programmers are able to talk in actual caps.
21:29:46
defunkydrummer
minion: memo to saravia: Portacle is a combination of Emacs with SBCL and SLIME, Emacs license you know, SBCL license is mostly Public Domain, SLIME license is Public Domain.
21:32:25
Younder
defunkydrummer, oh, just the use of got and the like in code. Of cource it is just used to use higher level constructs.
21:32:53
defunkydrummer
Younder: GOTO makes total sense for some kind of code like state machines or some parsers. It simplifies the code.
21:35:23
defunkydrummer
i've taken a look at the WuWei web framework, and it's built on Portable AllegroServe. It's a very nice framework and is actually used on a serious production system, so it has some credibility.
21:36:01
defunkydrummer
anamorphic: Wow, what a practical programming language!! I want it!! This must be the language of the XXI century!!
21:36:36
defunkydrummer
defunkydrummer: I think I'll try AllegroServer first. If I was to port it to something, I'd port it to Clack instead, and let Clack interface to Hunchentoot
21:38:22
defunkydrummer
anamorphic: Yeah, yesterday i took a look at weblocks, the problem is the authors state that the documentation isn't useful anymore since the rewrite(reblocks branch)changes the API
21:38:43
defunkydrummer
anamorphic: contrast this with Radiance, which probably has the biggest tutorial and documentation of any CL web framework
21:39:12
defunkydrummer
reblocks has the same docs of always, some of them have been updated like the tutorial, but the tutorial is very succint
21:40:31
defunkydrummer
i also took another look at Caveman2 (fukamachi), the way one defined handlers looks nice, but then... idocumentation is very scarce, and i'd get a bit scared if something doesn't work as expecte
21:50:08
vaartis
i get division by zero error although i didn't even pass anything, it's just an init function
22:01:43
aeth
Use https://github.com/Shinmera/float-features/blob/59ffb467413e25e95319b8324be2a6afc80f11c0/float-features.lisp
22:03:47
aeth
minion: memo for anamorphic: use the portable with-float-traps-masked in the library float-features https://github.com/Shinmera/float-features
22:06:50
defunkydrummer
PuercoPop: tiny simple lib with continuations and ajax. Examples' codebases look fine. Fits my purpose.
22:07:38
defunkydrummer
PuercoPop: yeah "ajax" sounds like so 2005, but good enough for some tasks, instead of going the "SPA" route
22:10:49
PuercoPop
defunkydrummer: I hate SPA's with passion, but the problem is 'continuations' and CL don't go well together afaik
22:13:42
defunkydrummer
PuercoPop: tell me more, tell me more, did it give you a fight? [Grease music]
22:24:08
aeth
PuercoPop: Oh, wow, I didn't know that all I needed to do was use IGNORE-ERRORS and then I wouldn't make any mistakes anymore.
22:30:39
PuercoPop
it is turned on precisely form *developer-mode* ^_^. But everyone has their own debugging flow
22:31:22
defunkydrummer
i'm having a pain in the ass trying to make wuwei work with the modern Portable AllegroServe which works over ZACL (AllegroCL compatibility layer)
22:31:48
defunkydrummer
because wuwei also has it's own AllegroCL compatibility layer... they clash and rock the casbah
22:37:19
defunkydrummer
well, since i don't have (yet) the money for my own AllegroCL Ultra Deluxe x64 Edition with Flux Capacitor, i think i'll pass...
22:58:07
vaartis
although i DO build it myself, the package manager just does something to it after that
23:35:45
pjb
minion: memo for vaartis: perhaps a mixup between float and double? https://pastebin.com/4Dd4BZ6u
23:55:51
liambrown[m]1
Is QuickLisp not intended for system-wide install? I just tried installing it system-wide, and it worked, but when I start SLIME as a non-root user I get an error about trying to access "system-index.txt" within the newly created installation tree.
23:57:59
no-defun-allowed
i don't think so, quicklisp touches a lot of files and will create more files when downloading systems
0:19:37
pjb
liambrown[m]1: quicklisp keeps mutating state. So, no, not a good idea to make it system-wide.
0:20:09
pjb
liambrown[m]1: what would be a good idea would be to make an immutable quicklisp, or a system-wide quicklisp service.
0:20:47
pjb
liambrown[m]1: also, consider that on a system, you may have systems depending on different versions of a same system, but quicklisp doesn't deal with versions.
0:22:35
grewal
Or you can throw caution to the wind, chmod -R 777 that directory and pray that nothing bad happens
0:23:07
liambrown[m]1
pjb: So it's not the precise analog of NPM or PIP? That makes sense. I wonder what it would take to tweak it so that there could be a single install for all users.
0:23:50
liambrown[m]1
Then again, on a shared system that may not even be wanted; I'm bringing my JS habits to Lisp, which could be limiting.
0:23:58
pjb
liambrown[m]1: you could download and compile all the systems in the distribution, for all the CL implementation available to the users, and make that read-only to all users.
0:40:42
aeth
I didn't think someone would make the same suggestion so I wrote that while reading the backlog, but grewal already said that, my bad
1:07:44
_ark_
Hello lispers. I have a question on SO about hunchentoot redirection. I'd appreciate if anyone could help. https://stackoverflow.com/questions/55960088/redirect-to-https-with-hunchentoot
1:43:20
mooch
hey, is anybody in here interested in developing emulators as well? i'm working on a project that i think you might be interested imn
3:04:30
mooch
beach, would you be interested in helping with an emulation project of mine? i basically want to write emulation cores for a bunch of different components and make emulators based around them, in common lisp of course
3:05:31
asarch
How exactly do you get an executable binary file? I mean, I would like a binary for the (gtk-demo:main) function from the cl-cffi-gtk-demo-demo package
3:06:29
asarch
So, I evaluate (ql:quickload :cl-cffi-gtk-demo-demo package) and then (gtk-demo:main) and finally (sb-ext:save-lisp-and-die "tigger" :executable t)?
3:06:57
beach
mooch: I am sorry, but I am way too busy with other stuff. Plus, you really put me off when you told us that you disagree with basic principles of software engineering. There is no way I could collaborate with someone who writes that kind of code.
3:07:03
asarch
If yes, however, why the binary doesn't have permissions?: ksh: ./tigger: Permission denied
3:07:31
asarch
In spite of it actually has them: -rwxr-xr-x 1 asarch 1000 76300824 May 2 22:04 tigger
3:22:42
aeth
beach: What are the basic principles of software engineering according to you? Do you have a blog or article somewhere?
3:24:50
aeth
mooch: Encapsulation is like CS 101 (or 102), that's going to be tricky to argue against.
3:27:32
mooch
and i honestly don't see the point. if someone could explain it to me, then maybe it'd make sense
3:28:32
aeth
Well... There are many approaches. Here's one. Excluding debugging, you have to (within reason) anticipate every change that can be made if you want robust software. The more you expose, the more checks you have to add in.
3:29:26
aeth
Privacy can be, to some degree, a convention, though. For instance, in CL, if you start messing with unexported symbols that's kind of on you if the software breaks.
3:29:30
mooch
aeth, i mean, i only write emulators, so in my cpu cores, for example, i don't need to make anything private because the cpu core should already handle all edge cases
3:32:11
aeth
mooch: sounds like your style probably has a few giant functions that does a bunch of de facto encapsulation
3:35:02
aeth
mooch: If you have a helper function for foo, bar doesn't need to know that it exists. Even if you're just doing things internally to one program.
3:37:48
PuercoPop
LdBeth: It is a cool concept. You define your models and the application figures out how to best store them
3:38:58
aeth
mooch: I'm more talking about, if you have a function that's 80 lines long with comments that serve as headings splitting it into 4 parts, why not turn those into four functions? And in CL it's pretty easy to split off functions because everything's an expression and almost everything returns a useful value
3:39:33
aeth
And once you have a dozen functions instead of one, it's pretty clear that you want a public interface, and most of the functions won't make the cut, at least not initially.
3:39:46
LdBeth
Let me bookmark the pages. Last time I thought I’ve seen a library introduces a meta class called cube which is for syncing database across languages
3:46:51
aeth
I mean, of course, there's the completely opposite approach, too. http://number-none.com/blow/blog/programming/2014/09/26/carmack-on-inlined-code.html
3:47:09
beach
aeth: One such principle is "information hiding" which is the one that mooch publicly disagreed with when saying that everything should be public.
3:48:27
aeth
mooch: Note that that contrarian article has the author's semi-retraction at the top, though.
3:52:50
beach
aeth: I can't quote a single source for those principles to you, because I learned them as a result of life-long reading of books on the subject, but I am pretty sure that this one principle is cited in almost all books with "software engineering" in the title, and also in many other books on programming.