jackdaniel changed the topic of #commonlisp to: Common Lisp, the #1=(programmable . #1#) programming language | Wiki: <https://www.cliki.net> | IRC Logs: <https://irclog.tymoon.eu/libera/%23commonlisp> | Cookbook: <https://lispcookbook.github.io/cl-cookbook> | Pastebin: <https://plaster.tymoon.eu/> | News: ELS'22 this Monday (2022-03-21), see https://european-lisp-symposium.org
rotateq has quit [Quit: ERC 5.4 (IRC client for GNU Emacs 28.1)]
mfiano has quit [Quit: WeeChat 3.5]
mfiano has joined #commonlisp
zacque has joined #commonlisp
mfiano has quit [Client Quit]
mfiano has joined #commonlisp
mfiano has quit [Client Quit]
triffid has quit [Remote host closed the connection]
triffid has joined #commonlisp
mfiano has joined #commonlisp
sabra has quit [Remote host closed the connection]
Bike has joined #commonlisp
ec has joined #commonlisp
pranavats has left #commonlisp [Error from remote client]
pranavats has joined #commonlisp
yauhsien has joined #commonlisp
yauhsien has quit [Ping timeout: 248 seconds]
tyson2 has quit [Remote host closed the connection]
tyson2 has joined #commonlisp
WBarends has quit [Ping timeout: 276 seconds]
pranavats has left #commonlisp [Disconnected: Replaced by new connection]
pranavats has joined #commonlisp
guest74 has joined #commonlisp
trannus_aran has joined #commonlisp
trannus_aran has quit [Client Quit]
waleee has quit [Ping timeout: 240 seconds]
Inline has joined #commonlisp
yauhsien has joined #commonlisp
<beach> Good morning everyone!
yauhsien_ has joined #commonlisp
yauhsien has quit [Ping timeout: 260 seconds]
pranavats has left #commonlisp [Error from remote client]
yewscion has quit [Ping timeout: 260 seconds]
Inline has quit [Quit: Leaving]
Sankalp has quit [Ping timeout: 246 seconds]
Sankalp has joined #commonlisp
semz_ has joined #commonlisp
semz has quit [Ping timeout: 260 seconds]
pranavats has joined #commonlisp
tyson2 has quit [Remote host closed the connection]
yauhsien_ has quit [Ping timeout: 256 seconds]
z4kz83 has joined #commonlisp
z4kz83 has quit [Client Quit]
pranavats has left #commonlisp [Error from remote client]
z4kz has quit [Quit: WeeChat 3.5]
zak1 has joined #commonlisp
zak1 is now known as z4kz
trannus_aran has joined #commonlisp
trannus_aran has quit [Remote host closed the connection]
zeroc00l0 has joined #commonlisp
zeroc00l0 has left #commonlisp [#commonlisp]
acebulf has quit [Ping timeout: 256 seconds]
Bike has quit [Quit: Connection closed]
slowButPresent has quit [Quit: leaving]
lisp123 has joined #commonlisp
pranavats has joined #commonlisp
dbotton has quit [*.net *.split]
dale has quit [*.net *.split]
gin has quit [*.net *.split]
neominimum has quit [*.net *.split]
pl has quit [*.net *.split]
contrapunctus has quit [*.net *.split]
selwyn has quit [*.net *.split]
energizer has quit [*.net *.split]
zephyr has quit [*.net *.split]
contrapunctus has joined #commonlisp
dale has joined #commonlisp
gin has joined #commonlisp
pl has joined #commonlisp
neominimum has joined #commonlisp
zephyr has joined #commonlisp
dbotton has joined #commonlisp
selwyn has joined #commonlisp
lisp123 has quit [Ping timeout: 260 seconds]
energizer has joined #commonlisp
agrosant has quit [*.net *.split]
Xach has quit [*.net *.split]
phadthai has quit [*.net *.split]
gjvc has quit [*.net *.split]
phadthai has joined #commonlisp
Xach has joined #commonlisp
gjvc has joined #commonlisp
agrosant has joined #commonlisp
agrosant has quit [Max SendQ exceeded]
frgo has quit [Ping timeout: 246 seconds]
aartaka has joined #commonlisp
agrosant has joined #commonlisp
pranavats has left #commonlisp [Error from remote client]
contrapunctus has left #commonlisp [#commonlisp]
Inline has joined #commonlisp
yauhsien has joined #commonlisp
lisp123 has joined #commonlisp
lisp123 has quit [Ping timeout: 246 seconds]
<patrix> morning beach :)
Cymew has joined #commonlisp
yauhsien has quit [Remote host closed the connection]
yauhsien has joined #commonlisp
frgo has joined #commonlisp
lisp123 has joined #commonlisp
lisp123 has quit [Ping timeout: 252 seconds]
shka has joined #commonlisp
amk has left #commonlisp [#commonlisp]
triffid has quit [Remote host closed the connection]
triffid has joined #commonlisp
Inline has quit [Quit: Leaving]
<beach> So it turns out that there is a better version of sb-texinfo (which is what Alexandria uses to parse documentation strings, and that generates the correct font for references to lambda-list parameters.
<beach> But apparently, nobody had noticed this problem before. Not sure what to make of that.
azimut has quit [Remote host closed the connection]
azimut has joined #commonlisp
tedwing has joined #commonlisp
mfiano has quit [Quit: WeeChat 3.5]
mfiano has joined #commonlisp
<Demosthenex> so i'm reading a FIFO using read-line. when i first open the file and read-line, it hangs until there is input (great!). after that i hit EOF and either i have to reopen the file so i can wait for the next data, or spin on read-line returning NIL but looping hard against the cpu. is there another way to get read-line back to the hang while waiting for new input?
poselyqualityles has quit [Quit: zzzzzz]
<Demosthenex> it just seems silly to reopen the fifo
<Alfr> Demosthenex, does the program writing into it close it after every line or so?
shka has quit [Ping timeout: 240 seconds]
random-nick has joined #commonlisp
shka has joined #commonlisp
<Demosthenex> Alfr: not sure, i replaced the output logfile of another application with this fifo
<Demosthenex> Alfr: i'm just seeing the behavior described. if i readline and the fifo is empty, i hang and wait on first read after open. next read is EOF, so i have to re-open, OR i tell readline to not error and return nil and spin on detecting nil
<Demosthenex> i just want to make every read-line wait.
ccregor has quit [Ping timeout: 250 seconds]
ttree has quit [Ping timeout: 256 seconds]
pve has joined #commonlisp
<Alfr> Demosthenex, hm ... not sure. With (with-open-file (s #p"test-fifo") (loop :while (read-line s nil nil) :counting t)) I can't reproduce it on sbcl, ccl and gcl, and abcl errors, because it fails to seek.
zacque has quit [Quit: Goodbye :D]
siabard_ has joined #commonlisp
Inline has joined #commonlisp
contrapunctus has joined #commonlisp
siabard has quit [Ping timeout: 256 seconds]
analogsalad has joined #commonlisp
analogsalad has quit [Client Quit]
azimut has quit [Ping timeout: 240 seconds]
leeb has joined #commonlisp
analogsalad has joined #commonlisp
shka has quit [Ping timeout: 252 seconds]
leeb has quit [Ping timeout: 252 seconds]
yagamisato has quit [Ping timeout: 260 seconds]
yagamisato has joined #commonlisp
yagamisato has joined #commonlisp
yagamisato has quit [Changing host]
leeb has joined #commonlisp
jeosol has quit [Quit: Ping timeout (120 seconds)]
<Demosthenex> hrm. it could be the other program i guess :P
lisp123 has joined #commonlisp
kevingal has joined #commonlisp
<lisp123> Guest74: Re Emacs, I think people want linters and other autocomplete like tools
<lisp123> Now the problem IMO is, since Lisp has a relatively clean syntax, it doesn't need all the editor hacks of other languages
<lisp123> But its easier to blame the IDE than to blame oneself
<contrapunctus> lisp123: is it possible for an expert Lisp programmer to derive any comfort at all from better tools?
<lisp123> I thought about that
<jackdaniel> I think that the step from "lisp syntax without support for reader macros" to "lisp syntax with support for reader macros" is somewhat ridiculously steep
<lisp123> Documentation is one area
<beach> jackdaniel: What makes you think that?
<lisp123> But like the bottom part of Emacs already gives hints on what arguments a function accepts and you can easily navigate to the source of a function with M-.
<beach> jackdaniel: Oh, you mean in Emacs? Sure.
<lisp123> Perhaps stuff like object browsers would be good (LW has something nice here, but not perfect), and also being more easy to watch variables & their values during runtime
<jackdaniel> beach: you need to read the program with a conforming reader to do things correctly. "just use eclector" is of course some sort of an answer, but it is non-trivial piece of software, so the argument that "linting common lisp code is easy because the syntax is clear" doesn't really apply
<lisp123> contrapunctus: So there's a few things, but I don't think other systems do this that well either. I use Jetbrains more these days so I _am_ speaking from the other side too
kevingal has quit [Ping timeout: 260 seconds]
kevingal_ has joined #commonlisp
<beach> jackdaniel: I see. But we already know how to do that.
<jackdaniel> well, I don't mean emacs in particular, I mean /external tool that does not reimplement common lisp reader/
<beach> jackdaniel: OK, then I can agree.
<beach> But that's an unnecessary restriction since we do have Eclector.
<beach> I should just spend a few days on the indentation problem of Second Climacs so that we can then build on what we have already.
siabard__ has joined #commonlisp
<jackdaniel> I'm addressing lisp123 remark, I don't have strong opinions about how closely the editor should be tied with the editing language. better integration surely yields better results (and many contemporary IDE's have something akin to a compiler of the edited language)
siabard_ has quit [Ping timeout: 252 seconds]
Inline has quit [Quit: Leaving]
<jackdaniel> s/editing/edited/
lisp123mobile has joined #commonlisp
<lisp123mobile> jackdaniel: Oh I meant linting isn’t as much required for CL vs it being easier to implement
<jackdaniel> I see (I don't have a strong opinion on that topic neither ;)
<beach> lisp123mobile: What makes you say lining is less required in Common Lisp?
<beach> Er, linting.
<beach> I guess it depends on what you consider "linting".
<lisp123mobile> Cleaner syntax. Yes I guess it depends on the definition, but it’s relative terms - there is so much noise in other languages that linting really helps in spotting typos, reminding of the correct syntax etc
<beach> As Paul Wilson put it, Lisp has syntax in two levels. The surface syntax is simple, sure, but then we have the syntax of all the special forms.
lisp123 has quit [Remote host closed the connection]
<lisp123mobile> Yes but they are still easier than the mess in other languages
<beach> Maybe so.
ccregor has joined #commonlisp
<contrapunctus> I'd very much like things like indenting binding forms in LET, and extracting all instances of a selected form in an expression to local bindings. Lispy does some of that, but it's buggy as hell.
lisp123mobile has quit [Remote host closed the connection]
molson_ has joined #commonlisp
lisp123 has joined #commonlisp
<contrapunctus> Oh, and templates for class definitions where typing the slot name also inserts the accessor name and the initarg. I've made a template like that using Tempel, but it only works for one slot :\
<lisp123> contrapunctus: you can write a macro for the latter
molson has quit [Ping timeout: 240 seconds]
<lisp123> what do you mean by the former?
<beach> I am guessing (... (car y) ... (car y)) -> (let ((<mumble> (car y))) ... <mumble> ... <mumble>)
<lisp123> beach: Thanks. That's interesting
john-a-carroll has joined #commonlisp
<john-a-carroll> Demosthenex: you could try calling listen and/or sleep in your loop
ccregor has quit [Ping timeout: 246 seconds]
<lisp123> contrapunctus: Nice idea, I might implementing it sometime. "Raise Form to Binding" --> Cut out the form at point from the the list, replace it with <mumble> and then enclose the entire form within a (let (A) ...)
<lisp123> Guest74: "I propose a more immediate and useful tool that would solve a major problem in implementing the other two. a multiuser brainstorming app that can save/edit files easily viewed over the web at some place like cliki." --> good idea
<contrapunctus> lisp123: by "indenting binding forms in LET" I mean getting the beginning of LET's value expressions to line up. https://paste.rs/JU4
<lisp123> Oh, I never had that issue before
<lisp123> in which case - beach - nice idea!
<lisp123> contrapunctus: maybe its a lispy issue? if you use paredit, I think you would have to go out of your way to have extra spaces in a form
<contrapunctus> beach 's example is what I meant by "extracting all instances of a selected form in an expression to local bindings"
<lisp123> that is a great idea
lisp123mobile has joined #commonlisp
lisp123mobile has quit [Remote host closed the connection]
jmdaemon has quit [Ping timeout: 248 seconds]
<Demosthenex> john-a-carroll: yeah, i considered adding a sleep, but then it adds an awkward delay. i just hoped to keep the original hang until data available behavior. maybe i'll try piping to stdin instead.
<beach> I think lining up the initialization expressions has a tendency to waste a lot of horizontal space.
<beach> If one binding has a long variable and a short expression and another one the other way around, there is going to be a lot of waste, and they may not fit snuggly on a line.
<contrapunctus> yeah, it's not always what I want...
<beach> But if you are going to do it, it has to be automatic.
xaotuk has joined #commonlisp
john-a-carroll has quit [Ping timeout: 250 seconds]
lisp123 has quit [Remote host closed the connection]
Lord_of_Life has quit [Ping timeout: 260 seconds]
Lord_of_Life has joined #commonlisp
ccregor has joined #commonlisp
analogsalad has quit [Quit: bye]
yauhsien has quit [Remote host closed the connection]
ccregor has quit [Ping timeout: 246 seconds]
tyson2 has joined #commonlisp
lisp123 has joined #commonlisp
yauhsien has joined #commonlisp
akoana has quit [Quit: leaving]
frgo has quit [Ping timeout: 252 seconds]
yauhsien has quit [Ping timeout: 246 seconds]
<jackdaniel> "I literally only know how to debug with printf, but other developers may not approve." in https://flak.tedunangst.com/post/compiling-an-openbsd-kernel-50-faster made me chuckle :)
<lisp123> who is this guy/girl?
<jackdaniel> I don't know
<jackdaniel> but the post was a fun read
<lisp123> thought it might be someone famous
acebulf has joined #commonlisp
<mfiano> Hi all. Today's thought: temporal code is aneurysm-inducing.
attila_lendvai has joined #commonlisp
<mfiano> Working on a graphical debugger in CL (for algorithms, not debugger in the sense of CL, but not too far off either), and I have to manage time in all sorts of way to be able to support things like rewind/advancing time and restoring state step-wise, or seeking, or interpolating states...fun times. I know that wasn't a very good explanation. That is a side effect of the problem. I can't imagine
<mfiano> even attempting to try this without such language dynamism, and the condition system concepts.
ccregor has joined #commonlisp
<lisp123> how did you use the condition system?
<lisp123> to unwind and replay the stack?
<lisp123> s/replay/restart being a more precise term
treflip has joined #commonlisp
acebulf has quit [Ping timeout: 240 seconds]
<mfiano> I didn't yet. Still in napkin phase.
<lisp123> continuations may be useful too
<lisp123> If you do use the condition system, I'd be curious to learn how --> I never found a use for them outside of error handling but I can imagine quite a bit can be achieved with them (I'm just not smart enough to figure that out)
yauhsien has joined #commonlisp
<mfiano> I use the condition system for all sorts of things outside of error handling.
<lisp123> Do you have an illustrative example?
<mfiano> For example, I establish a debugger hook around each iteration of the main loop, that tracks the amount of time spent in the debugger, so I don't get large jumps into the future when I continue with my custom "skip frame" restart after fixing an error.
leeb has quit [Ping timeout: 240 seconds]
<mfiano> When the debugger exits, I subtract the amount of time spent in the debugger from the accumulated wall time counter.
<lisp123> Nice
<mfiano> That is also a useful thing for game development, otherwise you may get stuck inside of walls with your physics/collision detection system upon resuming
yauhsien has quit [Ping timeout: 256 seconds]
<mfiano> Another thing I used it for recently was pretty minor, but I implemented a multi-receiver event bus system in this project, where any number of handlers can respond to a particular event type, and in a predefined order per event type. For client code to override internal handlers, I use throw/catch so that a higher precedence handler of some event can "consume" the event with whatever user
<mfiano> logic to decide on that.
<mfiano> I mean, I don't use the condition system that much, but when I do, it is just a perfect fit.
<mfiano> That is, if you consider throw/catch part of the condition system.
<lisp123> These are all too advanced for me :)
<mfiano> The condition system is one area I'm pretty rusty at too. I only started using it a bit in the last year or two, apart from defining custom condition types to signal for users.
<mfiano> I have been slowly learning how to work it into my problems, and slowly reading CLCS (though didn't get very far as I don't find the flow very interesting to stay focused for very long)
<lisp123> I need to spend more time on it. I was thinking of using it for AI search strategies (restart when a condition is thrown), need to try and recall why I didn't go down that route
<mfiano> Are you interested in traditional AI, or more modern stuff like NN/ML?
<lisp123> I'm doing traditional stuff, but taking a break now to first build some tooling (as one does..)
<mfiano> I can highly recommend a not-so-well-known CL book to you on the topic.
<lisp123> which one?
<mfiano> It assumes knowledge of CL and uses it for all of its complete AI algorithms and examples.
<lisp123> Thanks alot, I will read through it
<lisp123> Great
<lisp123> I'll try and get through that & PAIP when I have time
<mfiano> I haven't finished it yet, only like 10% into it, but from what I heard, the authors know their stuff, and have solved AI problems in the industry, presented for the first time in this book (though the book is fairly dated)
yauhsien has joined #commonlisp
scymtym has joined #commonlisp
<mfiano> It seems to be great so far, and one of the better not-teaching-CL CL books on my bookshelf.
<lisp123> Great
<lisp123> Are the exercises good?
leeb has joined #commonlisp
<mfiano> I only really just finished the theory chapters so far, but it mentions the exercises are scaled from 1-5, with 1 being incredibly easy, and 5 being open-ended industry problems that you might want to write a paper about if you solve :)
tedwing has quit [Ping timeout: 252 seconds]
<lisp123> Nice :)
aartaka has quit [Ping timeout: 248 seconds]
aartaka has joined #commonlisp
lisp123 has quit [Quit: Leaving...]
Bike has joined #commonlisp
treflip has quit [Quit: Quit]
aartaka has quit [Ping timeout: 252 seconds]
treflip has joined #commonlisp
aartaka has joined #commonlisp
slowButPresent has joined #commonlisp
livoreno has quit [Ping timeout: 250 seconds]
leeb has quit [Ping timeout: 252 seconds]
pranavats has joined #commonlisp
Inline has joined #commonlisp
frgo has joined #commonlisp
tedwing has joined #commonlisp
pranavats has left #commonlisp [Error from remote client]
aartaka has quit [Ping timeout: 246 seconds]
semz_ is now known as semz
Cymew has quit [Ping timeout: 252 seconds]
frgo has quit [Ping timeout: 260 seconds]
aartaka has joined #commonlisp
dec0d3r has quit [Quit: Leaving]
Lycurgus has joined #commonlisp
xaotuk has quit [Ping timeout: 240 seconds]
tyson2 has quit [Remote host closed the connection]
acebulf has joined #commonlisp
<Lycurgus> it's 30 years old and you can't see the TOC - sour grapes igess
<Lycurgus> also the source listing volume is prolly impossible to find
waleee has joined #commonlisp
<Lycurgus> there's a disk
pfd has quit [Quit: Client closed]
<Lycurgus> now i don't need to see the TOC
<Lycurgus> the other author doesn't even refer to it though he's still teaching
guest74 has quit [Quit: Connection closed]
guest74 has joined #commonlisp
xaotuk has joined #commonlisp
xaotuk has quit [Ping timeout: 248 seconds]
xaotuk has joined #commonlisp
les has joined #commonlisp
les has quit [Changing host]
Brucio-61 has quit [Ping timeout: 260 seconds]
scymtym has quit [Ping timeout: 250 seconds]
<guest74> The thing I was wondering most about people wanting a CL emacs is what parts exactly.  Do they want compatability with elisp and all their packages? Do they like the idea of modes or they want those specific modes? Do they want all the hooks?  Do they want the same function names for editing functions? Or are they just concerned about being able
<guest74> to perform the same action with a keybinding of their choice?
<White_Flame> I would assume it's mostly hypothetical. _if_ they want to customize their environment, they'd want to do it in the same language as their other software, given that it's such a related language already
<guest74> I've been wondering about this because I think I've reached a point where I need to emulate a terminal and trying to think of how I should abstract interaction with this virtual terminals screen.
shka has joined #commonlisp
<semz> It's also the aspect that Elisp is pretty terrible compared to CL.
Lycurgus has quit [Quit: Exeunt]
<lagash> mfiano: got any more obscure CL books?
<mfiano> Hmm, not off the top of my head.
<beach> Guest74: I can tell you what I want. I want a truly superior Common Lisp "mode" where the editor "knows" much more about the code.
<semz> I'd also like to note that what many people want isn't exactly "an Emacs", it's just that Emacs is currently the best thing you can get with a sane amount of effort.
<guest74> it almost looks like nobody cares about how emacs does it's editing, but it's more about tools.
<beach> Guest74: I would personally configure a Common Lisp editor so that it has roughly the same key bindings as Emacs, but that's just because I am used to that. But I would certainly make a Common Lisp editor possible to configure differently.
<guest74> handling the keybinding is the easy stuff,...is what I said before writing a keybinder.
<beach> Indeed. The hard part is the Common Lisp parser. But we have that one solved.
<guest74> at this point i'm interested if there's anything people like about how emacs abstracts editing and screen/buffer addressing/movement.  Since I'm going to write something to abstract  interaction with a terminal.
<mfiano> I don't like the concept of file-associated buffers.
<Nilby> Guest74: it turns out one thing i want from a CL emacs, is not an emacs, but a substrate of editing that integrates through my whole environment. so I have not "an editor" but a tree editor, a table editor, a graph editor, a text form widget, a line editor, etc. which all do the same thing and have the same commands and customizations
<mfiano> I would prefer something more in tune to a package/system/image layout
<mfiano> Something similar but not exactly like how Lisp Machine OS's did it.
<beach> Guest74: I can tell you a thing that surprised me about Emacs a while ago. It is that the font size is associated with the buffer and not with the window the buffer is presented in. So you can't have two windows showing the same buffer, but with different font sizes.
<guest74> mfiano: I'm with you on that, I don't know how lispos did it, but I want single function editing even.
<mfiano> beach: That is not true. Both are possible.
<beach> Oh? If I do C-x + (I think that's it), it affects all windows.
<guest74> I've noticed that with repls
Brucio-61 has joined #commonlisp
scymtym has joined #commonlisp
<Nilby> mfiano is correct. there are fonts tied to pieces of the buffer, what what fonts ultimately get displayed are altered by many other things, including the frame structure, so it's totally malleable
<beach> OK. Thanks for letting me know.
<guest74> so how do we actually make them different?
<guest74> hrm, unfortunately this termcap library is bitrotted or implementation dependent.
* Nilby used to be an emacs internals hacker
<guest74> So you probably know what shouldn't be done?
<Nilby> it would be advisable to study other editors such as hemlock, climacs, lem, and if you can zmacs and multic emacs
<Nilby> studying the original gosing emacs which gnu emacs is based on, is very interesting too
<mfiano> I buddy of mine also wrote an editor in CL you could study.
<guest74> omg, why is crap like this even on the cliki!!!
<guest74> I don't want to write an editor.  I do have to write something to provide a terminal interface.  Preferably with support for ansi extended graphics.  Should make writing telnet games easier.
<mfiano> He has that I believe in his repositories that he depends on in vico
<guest74> If I had to write an editor I'd probably cheat and simply copy that book on writing editors.  No thought involved would make it fast work.
xaotuk has quit [Ping timeout: 276 seconds]
<pjb> beach: using a lisp reader is not enough in an editor. It only can go so far. Two problems are 1- any processing may occur at read-time, 2- multiple or different read-time environments may have to be dealt with if you want to run the reader macro functions.
<beach> I am aware of that, yes. So some version of first-class global environments is also necessary.
<pjb> Assume for example, a reader macro { <pascal-program-syntax> } that parses a pascal program, and compiles it into lisp code.
waleee has quit [Ping timeout: 248 seconds]
<beach> Yes, and?
<pjb> The question is do we want (and then how do we support) emacs doing pascal code editing (fontification, symbol tagging, etc) on this section?
<pjb> and recursively, we could have some reader macro for html sections, for SQL code, etc.
<beach> You are raising the level of ambition even more. I am saying a necessary, but perhaps not sufficient, step is to use a Lisp reader.
<guest74> mfiano: that looks interesting.  It'd be half the solution. Like everything seems to be.
<beach> pjb: How do you plan to do what you want without one?
<pjb> I would propose some way to describe the added syntax to emacs that wouldn't require executing CL code.
<beach> Good luck.
yauhsien has quit [Remote host closed the connection]
<beach> It already can't handle Common Lisp code.
<pjb> Indeed, in general, it's not anymore possible than interpreting the reader macros…
<beach> Why is it not possible to consider reader macros?
<pjb> Because we need to be able to load and executing the program being edited.
<guest74> I'm more of the mind of not needing my editor to think for me and more needing my editor to not interfere with my thinking.
<Nilby> as you may know, for editing code one needs something that isn't exactly a lisp reader but can do at least everything a lisp reader/parser can, but in a quite different way
<pjb> Which can be difficult, eg. if the program contains implementation dependent code for a different implementation than the editor.
<beach> pjb: Sure, there are limitations, but they are fewer with a Lisp reader than without one.
<pjb> We must be careful not to raise expectations too much. This can cause problems.
<beach> Nilby: Congratulations to your very brief description of Eclector.
<beach> pjb: And the way to do that is to keep our inferior tools?
yauhsien has joined #commonlisp
<pjb> Let's say that if we can have an indicator to tell whether the heuristic is failing or not could be a satisfying solution.
<Nilby> unfortunately Eclector doesn't suffice for my purposes
<beach> I am sorry to hear that.
yauhsien has quit [Ping timeout: 246 seconds]
acebulf has quit [Ping timeout: 252 seconds]
<Nilby> it's great that it exists, but i'm not sure a standard lisp reader and a code editing parser have similar enough goals. but perhaps it's useful as a starting point. it's also just useful as a standard lisp reader.
<yitzi> Nilby: I use it to do symbol completion, inspection, etc. In common-lisp-jupyter. Seems more then enough there. What do you think it is missing?
peterseibel has joined #commonlisp
azimut has joined #commonlisp
yauhsien has joined #commonlisp
<Nilby> yitzi: i guess i should try common-lisp-jupyter. one trouble is graceful handling of incorrect code
Fade has quit [Quit: exeunt]
<beach> Nilby: You want the reader to determine whether the code is correct?
<beach> That doesn't seem reasonable.
<Nilby> beach: not exactly. i'd like it to gracefully handle code with syntax errors.
<beach> I suggest you take a closer look at Elector then. But don't feel you have to. I am not going to argue with you with respect to the functionality you want.
tyson2 has joined #commonlisp
<Nilby> no need to argue. i appreciate it for what it is, and i'm already using it
frgo has joined #commonlisp
Colleen has quit [Ping timeout: 240 seconds]
Fade has joined #commonlisp
frgo has quit [Ping timeout: 246 seconds]
Fade is now known as Fade
Inline has quit [Remote host closed the connection]
Colleen has joined #commonlisp
Inline has joined #commonlisp
acebulf has joined #commonlisp
rotateq has joined #commonlisp
Catie has joined #commonlisp
yauhsien has quit [Remote host closed the connection]
acebulf has quit [Ping timeout: 240 seconds]
kevingal_ has quit [Remote host closed the connection]
orestarod has joined #commonlisp
tyson2 has quit [Remote host closed the connection]
waleee has joined #commonlisp
peterseibel has quit [Ping timeout: 240 seconds]
acebulf has joined #commonlisp
yauhsien has joined #commonlisp
morganw has joined #commonlisp
<jackdaniel> oh, so much backlog
yauhsien has quit [Ping timeout: 240 seconds]
<ehammarstrom> White_Flame: For C
<White_Flame> hmm, ok
<White_Flame> I wrote a new lexer/parser for some of my stuff
<White_Flame> the lexing is based on breaking tokens by whitespace, punctuation (which can be multi-character), and remaining tokens
acebulf has quit [Ping timeout: 240 seconds]
tychoish has quit [Ping timeout: 240 seconds]
<White_Flame> not sure if it's up to all of C yet though
frgo has joined #commonlisp
cage has joined #commonlisp
acebulf has joined #commonlisp
guest74 has quit [Quit: Connection closed]
acebulf has quit [Ping timeout: 246 seconds]
Dynom has joined #commonlisp
kevingal has joined #commonlisp
kpoeck has joined #commonlisp
cross has quit [Quit: leaving]
matt` has joined #commonlisp
burton_ has joined #commonlisp
ttree has joined #commonlisp
cross has joined #commonlisp
tyson2 has joined #commonlisp
cross has quit [Client Quit]
cross has joined #commonlisp
cross has quit [Client Quit]
cross has joined #commonlisp
acebulf has joined #commonlisp
aartaka has quit [Ping timeout: 276 seconds]
aartaka has joined #commonlisp
kpoeck has quit [Quit: Client closed]
aartaka has quit [Ping timeout: 252 seconds]
aartaka has joined #commonlisp
acebulf has quit [Ping timeout: 252 seconds]
kevingal has quit [Read error: Connection reset by peer]
aartaka has quit [Ping timeout: 252 seconds]
tyson2 has quit [Remote host closed the connection]
acebulf has joined #commonlisp
ec has quit [Quit: ec]
<ehammarstrom> I'm reading Let over Lambda and Doug is making claims such as "No other language has the potential for secure software that lisp does and this will only become more apparent over time." w.r.t read macros & user input. Are these just radical claims of some guy, or does lispers resonate with this?
kpoeck has joined #commonlisp
<White_Flame> well, I guess it depends on how far you take "potential"
n1to has joined #commonlisp
<White_Flame> lisp could analyze its own code much easier than other languages
<White_Flame> and it doesn't have the memory fault errors of C by default
<White_Flame> but many languages can claim the latter now
acebulf has quit [Ping timeout: 248 seconds]
jamesmartinez has left #commonlisp [WeeChat 2.8]
imjim has quit [Quit: reconfiguring network topology]
akoana has joined #commonlisp
imjim has joined #commonlisp
wildlander has joined #commonlisp
yewscion has joined #commonlisp
King_julian has joined #commonlisp
cage has quit [Quit: rcirc on GNU Emacs 27.1]
acebulf has joined #commonlisp
<Catie> There's classes of bugs that exist in C that don't exist in Common Lisp, but it's still plenty possible to do insecure things by programmer error. You won't smash the stack by overrunning an array (although it might be possible with (optimize (safety 0))) but you could still write sensitive data to to disk or something
<Shinmera> you can also still do rowhammer no problem if you find a vector to write to memory repeatedly.
<Shinmera> Lisp isn't inherently more secure than any language that has reference semantics.
<Shinmera> that is to say, no dma.
<Shinmera> And then, certain *implementations* are certainly much less secure than other languages' implementations, simply because they let the programmer write very unsafe code that can be exploited :)
analogsalad has joined #commonlisp
acebulf has quit [Ping timeout: 256 seconds]
tedwing has quit [Quit: leaving]
treflip has quit [Quit: Quit]
<dlowe> that's anything with an FFI
<dlowe> except for removing pointer arithmetic I don't think CL has much to offer in terms of security.
<dlowe> that may change if we see first-class environments in CL :D
<ehammarstrom> What are first-class environments and where can I read more about them?
<dlowe> a first-class environment is an encapsulation of global state. It would be like passing all of the global state to the evaluator
<ehammarstrom> I see.
<dlowe> so, for instance, you could create an environment with no access to files or network, and evaluate your user input parsing code there
tyson2 has joined #commonlisp
<dlowe> I think beach was doing a lot of academic research in this area
<dlowe> not just for security purposes, but conceptually
King_julian has quit [Ping timeout: 276 seconds]
King_julian has joined #commonlisp
jmdaemon has joined #commonlisp
analogsalad has quit [Quit: bye]
hashfunc77a has joined #commonlisp
<hashfunc77a> ok i'm having a brain fart. what is the best way to get a nested list from a list based off of a certain keyword's value within the nested list?
<hashfunc77a> for example:
acebulf has joined #commonlisp
<pjb> hashfunc77a: this is a bad specification! Can't you do better?
<hashfunc77a> if i have the list: '((:WEEK 1 :DAY MONDAY :DATA ((BEEP) (BOOP))) (:WEEK 1 :DAY THURSDAY :DATA ((BOOP) (BEEP)))) and i want to get the :DATA of nested list '(:WEEK 1 :DAY THURSDAY... how can i do so?
<pjb> So you have plists. And you want to find one plists on a multiple criteria.
<hashfunc77a> yes, my goal is to just extract the list '((BOOP) (BEEP))
<Catie> If you know which position the list is at you can use NTH. Otherwise you'd have to search the outer list based on some criterion
<pjb> (defun select (indicator value plists) (remove-if-not (lambda (plist) (equal value (getf plist indicator))) plists)) (select :day 'thursday (select :week 1 '((:WEEK 1 :DAY MONDAY :DATA ((BEEP) (BOOP))) (:WEEK 1 :DAY THURSDAY :DATA ((BOOP) (BEEP)))))) #| --> ((:week 1 :day thursday :data ((boop) (beep)))) |#
<pjb> (getf (first (select :day 'thursday (select :week 1 '((:WEEK 1 :DAY MONDAY :DATA ((BEEP) (BOOP))) (:WEEK 1 :DAY THURSDAY :DATA ((BOOP) (BEEP))))))) :data) #| --> ((boop) (beep)) |#
<hashfunc77a> ah ok, so it wasn't as trivial as i thought it'd be
<hashfunc77a> thanks for the suggestions, i'll give them a go
<pjb> you may also write: (getf (first (remove-if-not (lambda (plist) (and (equal 1 (getf plist :week)) (equal 'thursday (getf plist :day)))) '((:WEEK 1 :DAY MONDAY :DATA ((BEEP) (BOOP))) (:WEEK 1 :DAY THURSDAY :DATA ((BOOP) (BEEP)))))) :data) #| --> ((boop) (beep)) |#
Dynom has quit [Quit: WeeChat 3.5]
<hashfunc77a> earlier i came up with: (GETF (FIND NIL '((:WEEK 1 :DAY MONDAY :DATA ((BEEP) (BOOP))) (:WEEK 1 :DAY THURSDAY :DATA ((BOOP) (BEEP)))) :KEY (LAMBDA (X) (CONS (GETF X :WEEK) (GETF X :DAY))) :TEST (LAMBDA (X Y) (DECLARE (IGNORE X)) (AND (EQ (CAR Y) DAY) (EQ (CDR Y) WEEK)))) :DATA) , but it doesn't work when put into a function
<pjb> with find, you could do this: (find '(1 thursday) data :key (lambda (entry) (list (getf entry :week) (getf entry :day))) :test (function equal))
<pjb> (getf (find '(1 thursday) *data* :key (lambda (entry) (list (getf entry :week) (getf entry :day))) :test (function equal)) :data) #| --> ((boop) (beep)) |#
acebulf has quit [Ping timeout: 240 seconds]
<hashfunc77a> ^ that last one works like a charm
<hashfunc77a> pjb: thanks
yauhsien has joined #commonlisp
Brucio-61 has quit [Ping timeout: 250 seconds]
yauhsien has quit [Ping timeout: 252 seconds]
scymtym has quit [Ping timeout: 252 seconds]
karlosz has joined #commonlisp
King_julian has quit [Remote host closed the connection]
King_julian has joined #commonlisp
Devon has joined #commonlisp
acebulf has joined #commonlisp
aartaka has joined #commonlisp
yauhsien has joined #commonlisp
Brucio-61 has joined #commonlisp
aartaka has quit [Ping timeout: 246 seconds]
Brucio-61 has quit [Read error: Connection reset by peer]
King_julian has quit [Quit: Quit]
King_julian has joined #commonlisp
hashfunc77a has quit [Remote host closed the connection]
yauhsien has quit [Remote host closed the connection]
yauhsien has joined #commonlisp
shka has quit [Ping timeout: 252 seconds]
yauhsien has quit [Ping timeout: 240 seconds]
kpoeck has quit [Quit: Client closed]
tychoish has joined #commonlisp
matt` has quit [Remote host closed the connection]
aartaka has joined #commonlisp
guest74 has joined #commonlisp
King_julian has quit [Read error: Connection reset by peer]
King_julian has joined #commonlisp
dra has joined #commonlisp
yauhsien has joined #commonlisp
aartaka has quit [Ping timeout: 256 seconds]
morganw has quit [Remote host closed the connection]
yauhsien has quit [Remote host closed the connection]
akoana has quit [Quit: leaving]
yauhsien has joined #commonlisp
karlosz has quit [Quit: Client closed]
matt` has joined #commonlisp
yauhsien has quit [Ping timeout: 250 seconds]
n1to has quit [Quit: Leaving]
wmblathers has quit [Quit: Leaving...]
wmblathers has joined #commonlisp
King_julian has quit [Ping timeout: 240 seconds]
attila_lendvai has quit [Ping timeout: 248 seconds]
gin has quit [Ping timeout: 248 seconds]
jmd_ has joined #commonlisp
susam_ has joined #commonlisp
jmdaemon has quit [Ping timeout: 240 seconds]
susam has quit [Ping timeout: 250 seconds]
gin has joined #commonlisp
ec has joined #commonlisp
wildlander has quit [Quit: Saliendo]
orestarod has quit [Ping timeout: 248 seconds]
pillton has joined #commonlisp
Brucio-61 has joined #commonlisp
<guest74> I'm surprised they provide the pdf of that AI book for free.
yauhsien has joined #commonlisp
igemnace has joined #commonlisp
yauhsien has quit [Ping timeout: 256 seconds]
pve has quit [Quit: leaving]
tyson2 has quit [Remote host closed the connection]
mister_m has quit [Ping timeout: 240 seconds]
karlosz has joined #commonlisp
acebulf has quit [Ping timeout: 248 seconds]
perrierjouet has quit [Quit: WeeChat 3.5]
perrierjouet has joined #commonlisp
jmdaemon has joined #commonlisp
jmd_ has quit [Ping timeout: 246 seconds]
imjim has quit [Read error: Connection reset by peer]
imjim has joined #commonlisp
tyson2 has joined #commonlisp
jmes has joined #commonlisp
<jmes> I would like to use the repl to interact with a running process but when I start said process it blocks the repl. How can I change the process so as not to block the repl?
random-nick has quit [Ping timeout: 252 seconds]
psf has quit [Ping timeout: 256 seconds]
psf has joined #commonlisp
<jmes> basic example, I set a value (defparameter *value* 'hi) then run (loop do (sleep 2) (print *value*)), now as the loop is running I'd like to set *value* to something else
<jmes> also I'm using sly
<pjb> (bt:make-thread (lambda () (process)))
Xach has quit [Quit: leaving]
<pjb> jmes: alternatively: (loop do (print *value*) (princ "> ") (finish-output) (print (eval (read)))) ; then you can enter (setf *value* 'boo) inside the loop.
<jmes> pjb: thanks, for some reason I was thinking there would be some repl-specific way to do it but I wasn't thinking :P
dra_ has joined #commonlisp