terpri has quit [Ping timeout: 256 seconds]
<pjb> jasom: I don't know it that's bugs. It may be a regretable misfeature, but the specification doesn't presuppose you can manipulate all native paths.
<jasom> pjb: it's a testament to how bad submodules are that a POS like repo is better
<pjb> yes.
<jasom> pjb: there are bugs other than non-conformance to the specification
<jasom> e.g. if the sbcl sockets library broke in some way, that would still be a bug.
<jasom> rpg: I sped git-svn up by a factor of 1000 before writing my own tool
smurfrobot has quit [Remote host closed the connection]
<jasom> git-svn shells out to a command that does a lot of work just to see if a branch exists. In an inner-loop.
ikki has quit [Ping timeout: 256 seconds]
<jasom> it also uses an O(N*M) algorithm where N is the number of commits and M is the number of branches. We have ~100k branches in our repository
<rpg> jasom: maybe I'll try it again some time. It does seem like there ought to be some way to drag less of the history if all one wants to do is to hack on an airplane. I know that it's more than that, and maybe what I need is just automated support for the cheap trick of taking your working copy and jamming it into a temporary git repo.
pilfink has quit [Quit: ERC (IRC client for Emacs 25.3.1)]
<pjb> On an airplane, don't hack; watch Airplane or Zero Hour.
<pjb> If you're a frequent flyer, I've got a playlist…
<jasom> rpg: I don't know if the change ever made it upstream. I sent a "I'm not using this tool anymore, so can't really work on a patch, but here's my change that sped it up by a huge amount" to the list and never checked to see what became of it.
<jasom> pjb: my dad says that movie doesn't work hard on defense and never really tries, except during the playoffs.
FreeBirdLjj has joined #lisp
smurfrobot has joined #lisp
terpri has joined #lisp
Devon has quit [Ping timeout: 256 seconds]
smurfrobot has quit [Remote host closed the connection]
Kaisyu has joined #lisp
<p_l> pjb: I'm tempted to watch Mayday. Or bring manuals/emergency checklists for the plane I'm flying
sjl has quit [Ping timeout: 256 seconds]
ikki has joined #lisp
FreeBirdLjj has quit [Ping timeout: 256 seconds]
fikka has quit [Ping timeout: 248 seconds]
FreeBirdLjj has joined #lisp
Tobbi has quit [Quit: Leaving]
_whitelogger has joined #lisp
FreeBirdLjj has joined #lisp
Oladon has joined #lisp
dieggsy has quit [Quit: ERC (IRC client for Emacs 27.0.50)]
JonSmith has quit [Remote host closed the connection]
FreeBirdLjj has quit [Ping timeout: 260 seconds]
sjl has joined #lisp
orivej has quit [Ping timeout: 276 seconds]
JonSmith has joined #lisp
zooey has quit [Ping timeout: 272 seconds]
pjb has quit [Ping timeout: 256 seconds]
fikka has quit [Ping timeout: 255 seconds]
JonSmith has quit [Ping timeout: 248 seconds]
zooey has joined #lisp
FreeBirdLjj has joined #lisp
pragmaticmonkey has joined #lisp
<pragmaticmonkey> So now that I have learned lisp, how do I find a lisp job?
<Xach> pragmaticmonkey: make cool stuff for many years and the job offers will just roll in
<pragmaticmonkey> Any shortcuts?
<Xach> There is no royal road to awesomeness
fikka has joined #lisp
FreeBirdLjj has quit [Ping timeout: 248 seconds]
<pragmaticmonkey> Xach: I have bills to pay.
<aeth> pragmaticmonkey: Lisp is good for many things, but finding a job is not one of those things.
<aeth> Unless you want to make your own job
<aeth> If you can find a Lisp job, though, you'll probably get paid more.
FreeBirdLjj has joined #lisp
<pragmaticmonkey> I want to find a lisp job to get a lisp job, you get it?
FreeBirdLjj has quit [Remote host closed the connection]
FreeBirdLjj has joined #lisp
<malice> Is there a way to invoke a method without going through the generic function?
<malice> And is this behavior defined?
<Xach> malice: no.
<Xach> malice: what prompts the question?
vertigo has quit [Remote host closed the connection]
<malice> Xach: I am explaining methods in CL and when reading Keene I noticed that she mentions that you have to invoke method through the generic function.
<malice> I was curious whether it was always the case, or if you could, by some other mechanisms, retrieve a method object and then invoke it on some arguments, bypassing the generic function, though perhaps doing the same work as it would.
EvW1 has quit [Ping timeout: 255 seconds]
<Bike> in an implementation with mop you can get the method function. but calling methods like that is not normal or anything, and pretty hairy to do.
<sjl> is there a less awful way of handling the if-exists argument here? http://paste.stevelosh.com/5a5ea5a9e5abd80008d72afb
<jasom> malice: if you know you are going to do it ahead of time, you can implement the method with a vanilla function and then inline the function into the method
<sjl> I want to pass along the if-exists to the with-open-file, but passing nil and not passing it are two different things
<sjl> and I can't hack around it with (apply ... (if if-exists-given `(:if-exists ,if-exists) nil) because w-o-f is a macro
<Bike> i don't think so, sjl
osune has quit [Remote host closed the connection]
<sjl> Bike: that's what I was afraid of... I mean, this *works*, it's just super ugly.
<Bike> yeah, i've done similar things. i wish i had a better solution
* sjl considers writing a macro for it
<sjl> probably not worth it
smasta has joined #lisp
<jasom> you could open-code the wtih-open-file using unwind-protect, or you could manually calculate the default value
<sjl> jasom: w-o-f is a bit more than just an open and unwind-protect, I think.
pjb` has joined #lisp
<sjl> If you're writing a new file and get an error, it tries to clean up the partially-written file for you
dddddd has quit [Remote host closed the connection]
<sjl> I mean, I can reimplement that too... but I think I can live with the ugly if that's the solution
<jasom> manually calculating the default-value isn't too hard though
nirved has quit [Quit: Leaving]
<jasom> you can even do it in the lambda-list
<jasom> since the init-form is evaluated with all of the parameters to the left already bound
earl-ducaine has quit [Remote host closed the connection]
<jasom> something like (defun write-foo-to-file path data &key (if-exists (if (eql (pathname-version (pathname path)) :newest) :new-version :error)
<jasom> though perhaps factoring out that to a function would be good
khisanth_ has quit [Ping timeout: 256 seconds]
damke_ has joined #lisp
damke has quit [Ping timeout: 264 seconds]
Tobbi has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
warweasle has joined #lisp
smurfrobot has joined #lisp
smurfrobot has quit [Remote host closed the connection]
Xal has quit [Ping timeout: 260 seconds]
fikka has quit [Ping timeout: 248 seconds]
holycow has joined #lisp
Xal has joined #lisp
mood has quit [Ping timeout: 256 seconds]
mood has joined #lisp
<sjl> I feel dirty for writing this.
shrdlu68 has joined #lisp
khisanth_ has joined #lisp
<Xach> Because of the IF indentation?
<Xach> I guess people can indent how they like?
fikka has joined #lisp
<sjl> that last if is a macroexpansion that didn't get prettyindented
JonSmith has joined #lisp
<Xach> I tease. I really do think you can indent how you like. The last IF is the only style I like.
<sjl> indenting if like a function (args all aligned)?
<Xach> Yes.
<sjl> I feel like I rarely see that style.
jonh has joined #lisp
<Xach> sjl: Really? I have never seen your style before. The only similar variant I've seen is the dedented ELSE clause, but that seems to be from people with lisps that have an implicit progn in else.
FreeBirdLjj has quit [Remote host closed the connection]
FreeBirdLjj has joined #lisp
fittestbits has joined #lisp
JonSmith has quit [Ping timeout: 255 seconds]
<Xach> I would guess every pretty-printer does it the "right" way.
<Xach> implementation pretty-printer, that is. not every possible pretty printer.
FreeBirdLjj has quit [Ping timeout: 248 seconds]
<Xach> sjl: Now I'm really curious - where have you seen the two-space style in the wild?
pjb` has quit [Ping timeout: 256 seconds]
* Xach guesses clojure?
ebzzry has joined #lisp
<rme> I do it because that's the style CCL's code uses.
<Xach> rme: two-space IF indentation?
<rme> yes
<sjl> Clojure definitely does it
<Xach> rme: but the ccl pretty-printer default is different, eh?
<sjl> Most of my books apparently do the extra spaces too, which I never noticed.
<sjl> Except Let Over Lambda, which does body-spacing
<rme> Xach: that could be
<rme> I've had (put 'if 'common-lisp-indent-function 1) in my .emacs for a long time
<Xach> Interesting
eschatologist has quit [Ping timeout: 276 seconds]
z3t0 has joined #lisp
eschatologist has joined #lisp
papachan has quit [Ping timeout: 255 seconds]
erikc has quit []
pjb` has joined #lisp
z3t0 has quit [Remote host closed the connection]
z3t0 has joined #lisp
z3t0 has quit [Remote host closed the connection]
z3t0 has joined #lisp
jsn` has joined #lisp
zooey has quit [Ping timeout: 272 seconds]
warweasle has quit [Quit: rcirc on GNU Emacs 24.4.1]
dieggsy has joined #lisp
z3t0 has quit [Ping timeout: 256 seconds]
zooey has joined #lisp
<stylewarning> wait, what's the proposed alternative?
<stylewarning> IF with the args aligned sounds right (:
d4ryus1 has joined #lisp
fikka has quit [Ping timeout: 256 seconds]
Oladon has quit [Quit: Leaving.]
d4ryus has quit [Ping timeout: 256 seconds]
fikka has joined #lisp
<loke> The pasted code by sjl looks horrible, IMHO...
<loke> I have also never seen it before (except for Clojure)
z3t0 has joined #lisp
<stylewarning> oh yeah his `(if ...) code is no bueno
<stylewarning> I simply cannot believe sjl doesn't follow the same style as I do!
<loke> I'm just happy that most people follow the style I use.
rpg has quit [Quit: Textual IRC Client: www.textualapp.com]
damke has joined #lisp
pjb` has quit [Ping timeout: 256 seconds]
damke_ has quit [Ping timeout: 264 seconds]
dieggsy has quit [Ping timeout: 265 seconds]
epony has quit [Quit: QUIT]
pragmaticmonkey has quit [Quit: Page closed]
shifty has quit [Ping timeout: 256 seconds]
smasta has quit [Ping timeout: 276 seconds]
ckonstanski has joined #lisp
holycow has quit [Quit: Lost terminal]
<beach> Good morning everyone!
<loke> Hello beach!
vydd has quit [Ping timeout: 240 seconds]
jmercouris has joined #lisp
sz0 has quit [Quit: Connection closed for inactivity]
pjb` has joined #lisp
smurfrobot has joined #lisp
z3t0 has quit [Remote host closed the connection]
mhd has joined #lisp
z3t0 has joined #lisp
thijso has quit [Ping timeout: 256 seconds]
<jmercouris> So within next, there is a concept of *active-buffer*, what it is, is just like a defparameter that points to the object of type buffer that is the currently active buffer
guaqua has quit [Ping timeout: 240 seconds]
<jmercouris> the active buffer can be activated by opening the minibuffer, switching the buffer in focus etc
smurfrobot has quit [Ping timeout: 255 seconds]
<jmercouris> I was thinking, this is a problem, because if we are to oen day support multiple panes, there will be multiple buffers on screen, and the user may click on a different buffer, and not just switch buffers via the keyboard
Oladon has joined #lisp
<jmercouris> so the issue is, now we have a *active-buffer* that is pointing to something ONLY settable by keyboard, whereas the user may click on a different buffer, therefore making the *active-buffer* incorrect
<jmercouris> I was therefore thinking any functions that wish to operate upon the active-buffer should actually invoke some function get-active-buffer, which will query the UI to determine which is actually the currently selected buffer
<jmercouris> is there something I am not seeing here? or does my reasoning make sense
z3t0 has quit [Ping timeout: 265 seconds]
<beach> Usually, user gestures are relative to a [let's call it a] window. The window contains a buffer, and that buffer is the one that is meant for gestures emitted to that window.
<beach> While I am at it, some terminology: There is no such thing as "a defparameter". There is such a thing as "a defparameter FORM", resulting in the creation of a "special variable".
guaqua has joined #lisp
<jmercouris> okay, yeah, definitely, but a window may contain several buffers
<jmercouris> okay, let's just use standard emacs terminology for a second
<jmercouris> a frame contains several windows
<jmercouris> and I need to know which window is selected, so I should query the interface before some operation
<jmercouris> does that make sense?
<jmercouris> ignore my first "okay, yeah, definitely, but a window may contain several buffers"
<jmercouris> as a window can only contain one visible buffer
<beach> Sure, if you have to have such a thing as a "selected window".
<jmercouris> I don't see how it could be avoided
<jmercouris> unless all actions specify a window each time
<jmercouris> like "scroll-down" and then the user must select a window
<beach> Fair enough.
<jmercouris> which may not be a bad idea actually
<jmercouris> and then the currently selected window is just the last selected window
<jmercouris> unless they type in a prefix command or something
<beach> I personally "select" my windows by moving the mouse into one. But I guess that is a kind of selection.
<jmercouris> heres another thing
<jmercouris> what if the user performs some action right, some long running action or they open the minibuffer and then do something else
<jmercouris> what if they change the buffer within the window originally operated on
<beach> I don't know how your GUI layer works, but usually, the selection is an OS-wide thing, and gestures get delivered with an explicit window attached.
<jmercouris> should the function affect the new buffer, or the old one
<jmercouris> in normal OS terminology, yes, I will get the window as part of my signal
<jmercouris> for both GTK and Cocoa
<sjl> stylewarning: you merged my commit to cl-charms that has that indent style, must not be THAT horrible https://github.com/HiTECNOLOGYs/cl-charms/commit/e41103ac6b47c2464209f03141cc3d54426dc3a8
<stylewarning> sjl: wow im terrible
smasta has joined #lisp
<stylewarning> sjl: I should have done more diligence on your unmatching IF-style!
ckonstanski has quit [Remote host closed the connection]
<sjl> I'm pretty sure I took it from Clojure. The extra spaces look so wasteful now.
<sjl> I don't think I've looked at the CCL codebase much at all so I can't have gotten it from there
nika has joined #lisp
JonSmith has joined #lisp
smasta has quit [Ping timeout: 256 seconds]
Arcaelyx has joined #lisp
cess11_ has quit [Remote host closed the connection]
fikka has quit [Ping timeout: 276 seconds]
JonSmith has quit [Ping timeout: 260 seconds]
pjb` has quit [Ping timeout: 256 seconds]
hvxgr has quit [Remote host closed the connection]
fikka has joined #lisp
<beach> sjl: I think your indent style for IF is more consistent with others.
<beach> There is no particular reason to indent the `then' and `else' forms of and IF more than two spaces.
<sjl> It's more consistent with [ec](type)?case -- the value you're checking comes on the first line, then all the possible branches come indented 2 spaces each below.
<beach> By "more consistent with others", I mean with other special forms and macros.
borei has quit [Ping timeout: 264 seconds]
<beach> Exactly.
<beach> I am thinking of making "your" style the default for Second Climacs.
guaqua has quit [Ping timeout: 268 seconds]
guaqua has joined #lisp
<sjl> Yeah, indenting the branches at the same level as the test makes it look less like a control structure and more like an ordinary function to me.
<beach> I totally agree.
<aeth> At least in my Emacs configuration, indentation of 2 spaces implies it's a &body afaik
ckonstanski has joined #lisp
<sjl> &body implies two spaces, but not the other way around, e.g. CASE and friends.
<sjl> well, I suppose CASE can be defined with &body in the lambda list if you want
<stylewarning> I want the indentation that (DEFMACRO IF (P X Y) ...) provides
<sjl> so a non-conforming IF? ;)
<sjl> (defmacro if (p x &optional y) ...)
<beach> Heh.
jsn` has left #lisp ["ERC (IRC client for Emacs 25.2.1)"]
mitc0185 has joined #lisp
sonologico has quit [Ping timeout: 255 seconds]
pjb` has joined #lisp
mitc0185 has quit [Ping timeout: 260 seconds]
jarwin has joined #lisp
jarwin is now known as Jarwin
smasta has joined #lisp
pjb` has quit [Remote host closed the connection]
pjb` has joined #lisp
fikka has quit [Ping timeout: 276 seconds]
<fiddlerwoaroof_> Is fare still around?
<fiddlerwoaroof_> I'm trying to figure out what the "right" way to mark an ASDF operation as done is, if you're skipping it
ikki has quit [Ping timeout: 248 seconds]
fikka has joined #lisp
malice has quit [Remote host closed the connection]
EvW has joined #lisp
<fiddlerwoaroof_> I have a suspicion that ASDF::MARK-OPERATION-DONE should be exported
<stylewarning> sjl I guess I’ve programmed into my brain that the code is wrong if IF doesn’t have two branches
<sjl> I feel like they should have either gone all the way and let it have 0 branches, or force it to have 2.
<sjl> allowing 1 is just weird
dtornabene has joined #lisp
<stylewarning> I think it should just be 2
<stylewarning> COND fills the other niche uses
oleo has quit [Ping timeout: 276 seconds]
<fiddlerwoaroof_> sjl: I think emacs forces your if-style by default
<fiddlerwoaroof_> At least, I use it because that's how emacs formats my code
sonologico has joined #lisp
<fiddlerwoaroof_> Hmm, I figured out my mark-operation-done issue
<fiddlerwoaroof_> And, Xach, I have a fix that makes LINEDIT compile again, does Nikodemus Sivola still maintain his libraries?
quazimodo has quit [Ping timeout: 256 seconds]
schoppenhauer has quit [Ping timeout: 264 seconds]
schoppenhauer has joined #lisp
|3b| has quit [Remote host closed the connection]
oleo has joined #lisp
sjl__ has joined #lisp
z3t0 has joined #lisp
<beach> fiddlerwoaroof_: Emacs indents the `then' part by 4 positions, and the `else' part (which can have more than one form in it) by 2 positions.
<beach> fiddlerwoaroof_: And that is different from what sjl suggests.
sjl__ has quit [Ping timeout: 255 seconds]
z3t0 has quit [Ping timeout: 240 seconds]
<fiddlerwoaroof_> It does that in emacs-lisp mode, but not (for me) when slime is loaded and it's in common-lisp mode
Bike has quit [Quit: Lost terminal]
<beach> Then you are not using slime-indentation.
<beach> ... which is a must in order to get LOOP clauses indented correctly.
<beach> If you are using slime-indentation, then both the `then' and the `else' parts are indented 4 positions.
<jmercouris> How to get slime to word wrap macro expansions?
<fiddlerwoaroof_> beach: yeah, I have 4-space indents for both branches when editing .lisp files
<beach> fiddlerwoaroof_: And that is not what sjl suggests.
<shaftoe> fiddlerwoaroof_: looking at linedit pull requests, seems like some have been around for a while
<fiddlerwoaroof_> Yeah, I just realized I was looking at the printed output, not the source
<fiddlerwoaroof_> Hmm, the bug is in madeira-port, actually
<fiddlerwoaroof_> (e.g. the problem that's causing it to fail quicklisp in the latest sbcl)
<fiddlerwoaroof_> Maybe I can takeover that project? Fare has a fix that I'm planning to merge with my fix
fikka has quit [Ping timeout: 255 seconds]
EvW has quit [Ping timeout: 255 seconds]
oleo has quit [Quit: Leaving]
<shaftoe> do you have a fork of it?
<fiddlerwoaroof_> I'm about to
z3t0 has joined #lisp
mhd has quit [Quit: Textual IRC Client: www.textualapp.com]
fikka has joined #lisp
z3t0 has quit [Ping timeout: 260 seconds]
asarch has quit [Quit: Leaving]
smasta has quit [Ping timeout: 256 seconds]
wigust has joined #lisp
pjb` has quit [Remote host closed the connection]
z3t0 has joined #lisp
smasta has joined #lisp
Jarwin has quit [Ping timeout: 276 seconds]
z3t0 has quit [Ping timeout: 256 seconds]
Oladon has quit [Quit: Leaving.]
smasta has quit [Ping timeout: 255 seconds]
z3t0 has joined #lisp
<jmercouris> I would like to make a defcommand macro, the only ideas I have to go off of are ones suggested to me from stumpwm, and the other which I can see in lispkit: https://github.com/AeroNotix/lispkit/blob/master/commands.lisp#L29
pjb` has joined #lisp
pjb` has quit [Remote host closed the connection]
<jmercouris> I was further thinking of prefixing all commands with some sort of namespace like next-command, so that I can provide some sort of m-x completion by being able to query the symbols in a package
<jmercouris> or should I stike with the make-instance objects as shown in the example
<jmercouris> make-instance command object
<jmercouris> man, this is such an elegant design actually
z3t0 has quit [Ping timeout: 255 seconds]
<jmercouris> at least parts of it
<jmercouris> the keymap could use some work
<jmercouris> prefix keys have to be manually set
dtornabene has quit [Remote host closed the connection]
dtornabene has joined #lisp
chenbin has joined #lisp
<beach> With this technique, the types of the arguments are kept with the function, so that arguments can be acquired according to the types when the command is invoked interactively.
damke_ has joined #lisp
smurfrobot has joined #lisp
z3t0 has joined #lisp
<jmercouris> beach: I don't really understand your code
damke has quit [Ping timeout: 264 seconds]
<jmercouris> can you explainw hat you mean by the types of the argumenst are kept?
<jmercouris> if one has an argument, doesn't one always know its type?
<beach> It has to do with invoking the command like this M-x my-command<RET>.
<beach> Then you have to prompt for the arguments.
<jmercouris> Oh I see
<jmercouris> my commands themselves prompt for the arguments
<beach> The loop that prompts for the arguments takes a "type" for each argument.
<beach> jmercouris: Then you will have a huge amount of duplicated code.
<jmercouris> within the body of my commands I have something like (with-result*)
<beach> jmercouris: Plus, then you can't easily just call the command as a function.
<jmercouris> I didn't explain it really well
<jmercouris> let me show an example one sec
smurfrobot has quit [Ping timeout: 276 seconds]
z3t0 has quit [Ping timeout: 256 seconds]
<jmercouris> so as you can see, bookmark-url can be called with arguments as it doesn't need to accept args
<jmercouris> those are handled by the with-result
<jmercouris> that's where you can specify all sorts of things like, completion function to call, any setup etc
<beach> Good for you.
mishoo_ has joined #lisp
<jmercouris> do you really think this approach is bad?
shifty has joined #lisp
<beach> Hard to say. I am inspired by the presentation-type system of CLIM II, which I think is excellent in terms of the modularity that it provides.
<beach> You should do what you want. I just gave you another source of inspiration.
<jmercouris> That's exactly the problem, there are no hard/fast rules in good design
<jmercouris> something I may do now, I may regret a year from now for completely unforseen circumstances
<beach> Oh, and it is a bad idea to use #'bookmark-url in define-key. It is much better to use 'bookmark-url in case you want to redefine the function later.
<jmercouris> I guess there is no way to prevent large scale refactoring, no matter how clever I might try to be
<beach> Oh, there is, but you have rejected that solution before.
<jmercouris> yeah I should get rid of those hashes indeed
<jmercouris> what do you mean?
<aeth> definitely get rid of them
<beach> jmercouris: I recommended you use CLIM, because a lot of the things you are doing already exist in better versions of CLIM. But you rejected that solution.
<jmercouris> Ah, well, it is not possible for me to use it
<chenbin> https://pastebin.com/raw/3gAPvJQr ,please help sbcl on windows . I make sure the SBCL_HOME environment variable isn't set.
<jmercouris> believe me, I would rather not be writing code for several platforms and reinventing GUI paradigms
<beach> jmercouris: If, instead of re-inventing the wheel, you would work on a backend for McCLIM that would work for you, then everyone would benefit, and it would be less work for you in the end.
borei has joined #lisp
<chenbin> or what's the best and convinent cl on windows
<beach> jmercouris: But, I am not going to insist. We have been through this.
<jmercouris> Even so, I don't see how it would be possible to take an existing webkit port and use it in a different context
<jmercouris> I would also literally have to make my own webkit port
<jmercouris> which isn't exactly a trivial task...
<beach> I said I would drop it.
<beach> I am just sad that you are re-inventing the flat tire, as we say.
<jmercouris> Fair enough, I just want to make it clear, it is not because I don't want to, nor do I not see the advantages
<jmercouris> it's just simply not feasible for me, I am just a single developer
pierpa has quit [Quit: Page closed]
<fiddlerwoaroof_> jmercouris/beach: I'd really like to finish a usable Mac McClim backend
<beach> That would be great!
<fiddlerwoaroof_> Especially, if I can bridge Lisp/ObjC in a portable way using CFFI
<jmercouris> fiddlerwoaroof_: I have a feeling that project may be more complicated than you imagine
<jmercouris> the CFFI one at least, the xc-runtime is not trivial from what I gather
<beach> jmercouris: I think you are wrong about that. You are not alone. There are plenty of people here and in #clim to help you. And if everyone has your attitude, then nothing will ever be shared.
<fiddlerwoaroof_> Possibly
<fiddlerwoaroof_> I have a demo app that loads a nib using only lisp code + a tiny bit of objc
<jmercouris> beach: I wasn't talking about the port of mcclim, that wouldn't be too bad, I mean the objc-cffi project he is working on
pjb` has joined #lisp
<jmercouris> fiddlerwoaroof_: I saw that, quite impressive
<beach> jmercouris: I was talking to you when you said that you are just a single developer.
<jmercouris> I mean, I didn't run the application or anything, but I just saw
<fiddlerwoaroof_> But, my goal is to implement just what I need to put mcclim on top of it
<jmercouris> why do you need to implement any cffi at all? are there not c bindings for the carbon framework?
<jmercouris> or only objective c?
<fiddlerwoaroof_> carbon is deprecated
<beach> jmercouris: I see this very often here. People work on their own little thing, because they want it done as fast as possible. By doing that, they re-invent things that exist, and the invent things that could have been shared if done right, thereby cutting down the global development effort.
<fiddlerwoaroof_> cocoa is objective-c only
<fiddlerwoaroof_> (and Swift, I guess, these days)
<jmercouris> fiddlerwoaroof_: I thought there were still carbon compatibility layers in place
<fiddlerwoaroof_> Yeah, but I don't think those support 64bit apps
<aeth> So when is Apple going to rewrite everything but with Swift?
<jmercouris> beach: Well, I think my project is a little unique :D I have also contributed a little bit to other projects, particularly to eql
<fiddlerwoaroof_> Swift is built on the objective-c runtime
<jmercouris> aeth: They are reusing the runtime
LocaMocha has joined #lisp
<beach> jmercouris: Yes, of course.
<jmercouris> so I dont think they'll just up and drop objective-c support
<fiddlerwoaroof_> Anyways, objective-c's runtime is a closer fit to lisp than swift is
<fiddlerwoaroof_> s/swift/carbon/
<fiddlerwoaroof_> ... if only Apple had embraced Dylan
<jmercouris> fiddlerwoaroof_: Have you spoken with rme?
<jmercouris> he has quite a bit of expertise on this exact topic
<jmercouris> maybe he'd be willing to give you some advice that could save you hundreds of hours
<jackdaniel> I feel the urge to chip in in this discussion, but I have nothing interesting to say ;-)
chenbin has quit [Ping timeout: 256 seconds]
<jackdaniel> good morning o/
<beach> Hello jackdaniel.
<jmercouris> fiddlerwoaroof_: why exactly do you need objective-c anyway?
<jmercouris> fiddlerwoaroof_: what obj-c APIs do you wish to call?
dtornabene has quit [Quit: Leaving]
pjb` has quit [Ping timeout: 256 seconds]
<fiddlerwoaroof_> Wrapping obj-c lets you use all the apple apis as a first-class citizen
<jmercouris> fiddlerwoaroof_: here's a different question, why don't you just want to use CCL?
<fiddlerwoaroof_> Because why do something in an implementation-dependent way if it can be done portably?
<jmercouris> it may not be able to be done portably without great compromise or complexity
<fiddlerwoaroof_> Maybe, but my code works in both LispWorks and CCL
<fiddlerwoaroof_> I'm interested, at least, in seeing how far I can get before abandoning this path.
z3t0 has joined #lisp
<jmercouris> I believe you'll get it to work
<jmercouris> I just don't think it'll be easy
<jmercouris> why is the backend for MacOS named beagle?
<fiddlerwoaroof_> Darwin's ship, I believe
<fiddlerwoaroof_> darwin == the osx kernel
<jackdaniel> avoiding an effort because "things won't be easy" isn't a very sound argument
<jmercouris> jackdaniel: I'll offer a different argument then
<jmercouris> "Another way may be easier, and less error prone"
<jackdaniel> you forgot to add, that this another way doesn't met original requirement (of portability)
marusich has joined #lisp
<jmercouris> I'm not sure why this is a requirement at all
<jmercouris> if all CL implementations meet the spec, why choose one over CCL?
<jmercouris> are the SBCL extensions really so unbelievably powerful to merit this effort?
<jackdaniel> it simply is (as far as I understand fiddlerwoaroof_), fact that you don't care about portability is fine by me, but doesn't make a compelling argument to discourage others
<beach> jmercouris: Because this is freenode, and it is about free software that is preferable to share as much as possible.
<jmercouris> let's not muddy the waters, you haven't actually provided an argument for portability other than "You don't care about portability, but others do"
<jmercouris> beach: Freedom of choice is an argument I can understand
<jackdaniel> jmercouris: actually I didn't want to judge requirements which others put in front of themself. I've just pointed out, that your "easy" solution doesn't meet them
pjb` has joined #lisp
z3t0 has quit [Ping timeout: 240 seconds]
<jackdaniel> and missing goals you put before yourself because something *may not* be easy is not very sound approach to solve problems
<jmercouris> jackdaniel: thats true, I misunderstood you, sorry for that
<jackdaniel> programming is hard, so I will be a gardener
<jmercouris> jackdaniel: I often dream about that actually
<jmercouris> just cutting trees or something
<jmercouris> but I feel like I would be so mind numbingly bored so quickly
<jmercouris> maybe I could last a week
<jackdaniel> good for you, still that misses the point. some people do hard stuff because they find it interesting (to them), not because they underestimate the effort involved
<jmercouris> I don't remember saying "people do things that are hard because they underestimate the effort involved"
<jackdaniel> fwiw gardening is hard too if you think about it (given non-trivial gardens)
<jackdaniel> well, you said: drop the effort because it *may be* not easy ;-)
<jackdaniel> and here it is, I've chipped in ;-)
<beach> jackdaniel: Well put.
Karl_Dscc has joined #lisp
<jmercouris> jackdaniel: It was a suggestion
<jmercouris> I did not say nor imply that people do things because they underestimate
<jmercouris> at any rate, whether x or y, doesn't matter, we have different opinions on the value of portability and the "WHY" but, as long as we are doing our own thing, is okay
<beach> People are free to do what they want of course, but I find it sad to see that so many people do their "own thing" instead of trying to collaborate to decrease the global effort.
<aeth> jmercouris: At the moment, it's best to try to get something to run on at least SBCL, CCL, and ECL. Why? Well, one reason is that all of the people who wrote code that only works on CLISP 10 years ago are in a bad position in 2018 even if CLISP was a reasonable choice in 2008. You never know which implementation(s) you want to use in 10 years.
<jmercouris> this is a tragedy of the open source world, things like quicklisp help, but still
<beach> jmercouris: And you think Quicklisp came about because Xach was doing his "own thing"?
<jmercouris> I mean, kind of yeah
<jmercouris> he is most definitely a quicklisp dictator
<jmercouris> benevolent, but still a dictator
makomo has quit [Ping timeout: 240 seconds]
<jackdaniel> actually not
<beach> jmercouris: I am afraid you missed my point entirely. Not that it matters.
<jackdaniel> infrastructure is build to make other repositories working
<jackdaniel> for instance (in closed project) we use a separate quicklisp distribution
<jmercouris> jackdaniel: Do you have access to the quicklisp servers?
quazimodo has joined #lisp
<jackdaniel> I have means to provide my own servers
<jmercouris> are you able to approve projects and submit them to the official servers?
<jackdaniel> and code is written the way which make it easy
<jmercouris> do you know of anyone other than Xach that can do this?
<jackdaniel> as I said, Xach servers are Xach thing, but Quicklisp works with any servers
<jmercouris> yes, it is a great project for this reason
<aeth> jmercouris: Quicklisp will scale when Quicklisp needs to scale
<jmercouris> but for 99% of users, they are ql:quickload some project and hitting the quicklisp servers
<aeth> Xach is smart. Don't try to scale until you need to scale.
<jmercouris> Does that make him a non-dictator?
<jackdaniel> fact that people trust quicklisp servers is a matter of authority not dictatorship
<aeth> Quicklisp avoids about 90% of the problems that the JS world faces because it goes through Xach
<aeth> Human oversight is great
<jmercouris> I'm not seeing the line between authority and dictatorship
<aeth> Try to avoid human oversight and you get messes, like YouTube and Facebook
<jmercouris> if it was a community effort, you'd still have oversight, but something closer to an oligarchy perhaps
<loke> And twitter...
<jackdaniel> of course it makes him a non-dictator :-) if beach suggests, that some code doesn't follow well-estabilished practice I'll think twice before I stick to this code passage
<jmercouris> beach: Do you mean because he collaborated with Fare?
<jackdaniel> if this suggestion comes from random person, I put less thought in it
<jackdaniel> that is what authority is
<jmercouris> That is what respect and credibility is
borei has quit [Ping timeout: 276 seconds]
<jackdaniel> dictatorship is when your manager tells you to change the code
<jmercouris> that is not what authority is
<fouric> (quick minor question, not to distract from ongoing conversation: any suggestions as to where i can find information on hotpatching running CL programs? specifically, I know how to do it in Emacs+SLIME (because that's trivial), i'm more interested in learning how to do things like have the patched program "know" that a function was updated and then run code that updates the associated data structures, too...)
<beach> jmercouris: I wasn't talking about access to servers at all. You completely missed the point. I'll drop it now. It's a futile discussion.
smurfrobot has joined #lisp
<jmercouris> beach: Maybe another day
<beach> Not likely.
<fouric> (where would i go about learning about that? i found *two* stack overflow posts, neither of which either have the information i'm looking for nor have links that point to the same)
<jmercouris> beach: Let's stay optimistic :D
<aeth> jmercouris: Quicklisp would be a dictatorship if it came bundled with all implementations and was the only way to do things in that implementation imo. If Quicklisp was bad, people would use some other thing.
<jackdaniel> hm, apparently word "authoritiy" is a false friend in English. In polish "autorytet" means "respect and credibility" (among other things)
<jmercouris> aeth: I am not saying quicklisp is bad, nor that xach is a bad dictator, but it is a dictator project
<jackdaniel> my point stands though, and I agree that discussion is futile
<jmercouris> jackdaniel: It happens :P
<jmercouris> you gusy are so quick to be pessimistic
z3t0 has joined #lisp
<jmercouris> at any rate, we can solve the worlds problems tomorrow, perhaps we can settle tabs vs spaces as well :D
<jmercouris> goodnight everyone
<jackdaniel> actually it's not a sign of pessimism but a sign of the fact that people value their time and don't want to spend it on something futile
igemnace has joined #lisp
smurfrobot has quit [Ping timeout: 248 seconds]
z3t0 has quit [Ping timeout: 255 seconds]
jmercouris has quit [Ping timeout: 256 seconds]
<jackdaniel> after reading into it word "authority" has three estabilished meanings where two of them match polish word
flamebeard has joined #lisp
<jackdaniel> and none matches "dictatorship"
<aeth> jackdaniel: jmercouris might have been referencing Python's BFDL. https://en.wikipedia.org/wiki/Benevolent_dictator_for_life
<jackdaniel> I know, but it doesn't match well with Quicklisp architecture and the context of discussion
jmercouris has joined #lisp
hexfive has quit [Quit: WeeChat 1.9.1]
fikka has quit [Ping timeout: 260 seconds]
z3t0 has joined #lisp
chenbin has joined #lisp
milanj has quit [Quit: This computer has gone to sleep]
jmercouris has quit [Ping timeout: 256 seconds]
borei has joined #lisp
<chenbin> hi , how to avoid refresh the name list of channel on Emacs ERC? thank
z3t0 has quit [Ping timeout: 260 seconds]
pjb` has quit [Ping timeout: 256 seconds]
<fiddlerwoaroof_> chenbin: that's probably a question for #emacs
fikka has joined #lisp
<aeth> As far as what's best for the Lisp community, I think what drives people to languages are popular applications, engines, frameworks, libraries, etc. But you cannot control what becomes popular. So I don't think divided efforts are necessarily wasted efforts. Just make lots of very different things that are programmable in Lisp imo.
Karl_Dscc has quit [Remote host closed the connection]
igemnace has quit [Ping timeout: 256 seconds]
DeadTrickster has joined #lisp
pjb` has joined #lisp
z3t0 has joined #lisp
alexmlw has joined #lisp
vydd has joined #lisp
z3t0 has quit [Ping timeout: 264 seconds]
smasta has joined #lisp
pjb` has quit [Ping timeout: 256 seconds]
pjb` has joined #lisp
smasta has quit [Ping timeout: 276 seconds]
dec0n has joined #lisp
eivarv has joined #lisp
JenElizabeth has joined #lisp
mishoo_ has quit [Ping timeout: 248 seconds]
pjb` has quit [Ping timeout: 256 seconds]
vlatkoB has joined #lisp
Lord_Nightmare has quit [Ping timeout: 256 seconds]
vydd has quit [Ping timeout: 256 seconds]
Lord_Nightmare has joined #lisp
pjb` has joined #lisp
smurfrobot has joined #lisp
eivarv has quit [Quit: Sleep]
safe has quit [Read error: Connection reset by peer]
pjb` has quit [Remote host closed the connection]
pjb` has joined #lisp
smurfrobot has quit [Ping timeout: 255 seconds]
sonologico has quit [Quit: WeeChat 1.9.1]
pjb` has quit [Remote host closed the connection]
pjb` has joined #lisp
pjb` has quit [Remote host closed the connection]
mishoo has joined #lisp
pjb` has joined #lisp
m00natic has joined #lisp
varjag has joined #lisp
pjb` has quit [Ping timeout: 256 seconds]
smurfrobot has joined #lisp
pjb` has joined #lisp
smurfrobot has quit [Ping timeout: 240 seconds]
Cymew has joined #lisp
fikka has quit [Ping timeout: 256 seconds]
smasta has joined #lisp
pjb` has quit [Ping timeout: 255 seconds]
smasta has quit [Ping timeout: 255 seconds]
fikka has joined #lisp
schweers has joined #lisp
chenbin has quit [Read error: No route to host]
lnostdal has quit [Ping timeout: 256 seconds]
pjb` has joined #lisp
pjb` has quit [Remote host closed the connection]
sjl__ has joined #lisp
sjl__ has quit [Ping timeout: 240 seconds]
loke has quit [Ping timeout: 256 seconds]
pjb` has joined #lisp
MetaYan has quit [Remote host closed the connection]
MetaYan has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
shka has joined #lisp
damke_ has joined #lisp
pjb`` has joined #lisp
pjb` has quit [Remote host closed the connection]
orivej has joined #lisp
vydd has joined #lisp
vydd has joined #lisp
vydd has quit [Changing host]
pjb`` has quit [Ping timeout: 256 seconds]
damke has joined #lisp
igemnace has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
<sigjuice> fiddlerwoaroof_ looks like madeira-port can be made unnecessary for linedit quite easily. https://github.com/LispLima/linedit/commit/c07816b8f29f6a54a13616d6bc71b46715618c42
hhdave has joined #lisp
randomstrangerb has quit [Ping timeout: 260 seconds]
hhdave_ has joined #lisp
randomstrangerb has joined #lisp
damke_ has joined #lisp
igemnace has quit [Ping timeout: 276 seconds]
dilated_dinosaur has quit [Ping timeout: 240 seconds]
pjb`` has joined #lisp
hhdave has quit [Ping timeout: 276 seconds]
hhdave_ is now known as hhdave
damke has quit [Ping timeout: 264 seconds]
<beach> Question about error reporting in the compiler: A Cleavir-based compiler is meant to be used in several situations, to implement COMPILE, EVAL, and COMPILE-FILE, of course, but also for things like processing top-level forms in an editor so as to give more information to the user.
<beach> Now, it seems to me that each such use of the compiler requires a different way of reporting errors. The file compiler might just give a warning, whereas EVAL might signal an error for the same situation. An editor much handle the signal and turn it into some kind of highlight of the buffer.
<beach> So, it seems that the core of the compiler should not attempt to determine what the application is. As a result, I am thinking that the core of the compiler should always signal an error and propose one or more restarts. Each individual application can selectively convert the error to a warning and/or invoke a restart.
<beach> Does this thinking seem reasonable, or am I completely off here?
<jdz> Sounds like exactly what condition system is there for (to me at least).
<beach> It can certainly deal with those situations, yes.
<Shinmera> Sounds reasonable to me.
<beach> Thanks to both of you. If anything else comes to mind, let me know.
<Shinmera> The only question I have is about the condition types
<Shinmera> Since, depending on context, each one could be an error, warning, or note.
<beach> I am suggesting using errors everywhere.
<beach> ... in the core compiler.
<beach> Then each "application" can convert to something else.
<Shinmera> Hrm.
<Shinmera> I'm wondering whether it would be useful to automatically create subclasses for each variant of error, and then allow the context to change-class the condition to the appropriate subclass. (Yes I know this forces conditions to be classes)
<beach> Cleavir is also meant to be implementation customizable, so the core can't even make a decision between error, warning, style warning, etc. in all cases, because different implementations might want something different.
<beach> I definitely want a different subclass for each situation.
<beach> But the typical use case is to handle and re-signal a different condition type.
<Shinmera> Right, but that involves recreating the condition and transfering all data over
<beach> I do need different types for each situation so that client code can selectively handle.
<Shinmera> And losing identity.
<beach> It does.
<Shinmera> If you could just change-class to the appropriate variant, that would preserve identity and circumvent having to transfer the data
dilated_dinosaur has joined #lisp
<beach> It would. But it would only be moderately useful. Conditions are signaled in exceptional situations, so there is no performance problem with the transfer. Perhaps you see the use for preserving the identity, but I don't immediately see it.
<Shinmera> The data transfer bit makes me iffy because it means a change in cleavir's condition definition means you need to update everywhere you transfer this data.
<Shinmera> You would also have to replicate the data slots in your own code, etc.
<beach> Yes, I see.
epony has joined #lisp
epony has quit [Max SendQ exceeded]
epony has joined #lisp
JenElizabeth has quit [Remote host closed the connection]
pjb`` has quit [Remote host closed the connection]
pjb`` has joined #lisp
pjb`` has quit [Ping timeout: 256 seconds]
z3t0 has joined #lisp
<TMA> if the conditions are part of the interface (API) then a change to the conditions is a change to the API that the client has to deal with as it is the case with other API changes
<Shinmera> You can always make an excuse to force the user to update their code.
<Shinmera> The point is to minimise the cases where that has to happen.
<TMA> that boils down to 'do not change the API' in this case
<Shinmera> If you implement it the way I illustrated, the amount of changes that need to be made is far less than if you forced transfering.
z3t0 has quit [Ping timeout: 268 seconds]
<Shinmera> In many cases I expect there won't be any changes that need to be made
<Shinmera> Whereas with transfering there's a guaranteed minimum amount of changes.
<TMA> which can be easily done with one more level of indirection -- the changeable part would be in some other object that would be held in a nonspecific DATA slot -- with the transfer you can transfer the whole data object unchanged
<Shinmera> Why add indirection when you can solve it without
<phoe> How can I declare variable types in LOOP?
pjb`` has joined #lisp
<phoe> (loop for x (unsigned-byte 8) = ...) doesn't work.
<Shinmera> phoe: (loop with foo of-type bar for bla of-type thing = ..)
<phoe> Shinmera: thanks.
JonSmith has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
JonSmith has quit [Ping timeout: 264 seconds]
pjb`` has quit [Ping timeout: 256 seconds]
z3t0 has joined #lisp
igemnace has joined #lisp
pjb`` has joined #lisp
pjb`` has quit [Remote host closed the connection]
pjb`` has joined #lisp
z3t0 has quit [Ping timeout: 260 seconds]
angavrilov has joined #lisp
pjb`` has quit [Remote host closed the connection]
milanj has joined #lisp
damke_ has joined #lisp
z3t0 has joined #lisp
pjb`` has joined #lisp
Arcaelyx has quit [Ping timeout: 276 seconds]
smurfrobot has joined #lisp
Arcaelyx has joined #lisp
z3t0 has quit [Ping timeout: 240 seconds]
smurfrobot has quit [Ping timeout: 256 seconds]
damke has joined #lisp
pjb`` has quit [Ping timeout: 256 seconds]
lnostdal has joined #lisp
mingus has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
blacknc has joined #lisp
pjb``` has joined #lisp
redeemed has joined #lisp
lnostdal has quit [Ping timeout: 265 seconds]
z3t0 has joined #lisp
pjb``` has quit [Remote host closed the connection]
z3t0 has quit [Ping timeout: 276 seconds]
randomstrangerb has quit [Ping timeout: 256 seconds]
pjb``` has joined #lisp
randomstrangerb has joined #lisp
pjb``` has quit [Remote host closed the connection]
pjb``` has joined #lisp
heurist has quit [Ping timeout: 256 seconds]
heurist has joined #lisp
nika has quit []
z3t0 has joined #lisp
makomo has joined #lisp
lnostdal has joined #lisp
pjb``` has quit [Ping timeout: 276 seconds]
damke_ has joined #lisp
z3t0 has quit [Ping timeout: 256 seconds]
mingus has quit [Ping timeout: 268 seconds]
damke has quit [Ping timeout: 264 seconds]
<phoe> Is there some variant of SUBSEQ that does not copy the data but creates displaced arrays instead?
pjb``` has joined #lisp
z3t0 has joined #lisp
<varjag> make-array? :)
<phoe> varjag: I think so, yes, but I'm looking for a shortcut.
<phoe> something like (dsubseq array 10 20)
<phoe> like, something that shares interface with CL:SUBSEQ.
nirved has joined #lisp
papachan has joined #lisp
<phoe> ...guess like I'll need to write my own, then.
z3t0 has quit [Ping timeout: 256 seconds]
pjb``` has quit [Remote host closed the connection]
d4ryus1 is now known as d4ryus
damke has joined #lisp
wxie has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
igemnace has quit [Ping timeout: 240 seconds]
pjb``` has joined #lisp
z3t0 has joined #lisp
z3t0 has quit [Ping timeout: 260 seconds]
pjb``` has quit [Ping timeout: 256 seconds]
gabot has quit [Ping timeout: 256 seconds]
gabot has joined #lisp
pjb``` has joined #lisp
pjb``` has quit [Remote host closed the connection]
<shka> hello
<shka> is there slime extension for quicklisp?
<shka> quickloading project with emacs shorcut and so one
pjb``` has joined #lisp
schweers has quit [Read error: Connection reset by peer]
schweers has joined #lisp
pjb``` is now known as pjb
m00natic has quit [Remote host closed the connection]
z3t0 has joined #lisp
m00natic has joined #lisp
groovy2shoes has quit [Ping timeout: 276 seconds]
<Xach> shka: not that i know of
z3t0 has quit [Ping timeout: 256 seconds]
<schweers> Is there an easy, portable way to find out the values of C “constants” like O_TMPFILE?
<schweers> apart from going all the way and using a groveller or similar
<Shinmera> Scrape the header files.
<schweers> for instance with cffi-grovel?
<shka> Shinmera: hello!
<shka> i have a question regarding landing-page
<shka> i should set it in the session, like this? (setf (session:field 'landing-page) (uri-to-url "dzienniczek/entry" :representation :external))
<shka> that's for auth, btw
<Shinmera> schweers: In general unless you're writing a C compiler entirely there is no way other than just running the C compiler on a sample program.
<Shinmera> So the "portable" way is to emit a C program that prints the constant, call a C compiler, and run the resulting executable.
<schweers> That would have been my guess, I wanted to know if there is an easier way.
<Shinmera> Which I believe is what the groveller does, but I don't know. Never used it.
<Shinmera> shka: Sure, that works.
<schweers> Neither have I
<shka> schweers: thanks for info
<schweers> shka: huh?
<shka> that was obviously tab-fail
z3t0 has joined #lisp
sjl__ has joined #lisp
z3t0 has quit [Ping timeout: 240 seconds]
mingus has joined #lisp
sjl__ has quit [Ping timeout: 240 seconds]
thijso has joined #lisp
<_death> schweers: using cffi-grovel is easy
<schweers> I’m trying my hands at it, but I just realized that my problem is not cffi-grovel, but is on the C side
<schweers> I want to expose O_TMPFILE to lisp in order to open(2) temporary files. Yet I can’t get a C program to see the file, so my problem is not with cffi ;)
plertrood has joined #lisp
<_death> what do you mean by "see the file"?
Tobbi has joined #lisp
<schweers> oops. see the constant
<_death> "The O_DIRECT, O_NOATIME, O_PATH, and O_TMPFILE flags are Linux-specific. One must define _GNU_SOURCE to obtain their definitions."
<schweers> oh. thanks!
<schweers>
<schweers> I should have seen that :/
EvW1 has joined #lisp
<pjb> schweers: I have already implemented a C pre-processor in CL, so you could use it to parse C headers and find the values of such C macros.
<schweers> now it works with cffi-grovel \o/
<pjb> (eventually, I'll complete a C to CL compiler).
esthlos has joined #lisp
<pjb> The C program solution is as risky as your own parsing of the header: you need to pass the right options and have the right definitions established in the C program just as in your CPP process (this _GNU_SOURCE macro, and others).
<pjb> It's also the same problem when you use different C compilers on the same system. They may not all interpret the headers the same way…
<pjb> (you can have a compiler generating 32-bit code, and another generating 64-bit code, or a cross-compiler, etc).
<pjb> Also, there's one thing that is not handled: #pragma; notably structures in headers using #pragma pack won't be generated correctly by swig (and I wonder about cffi-grovel, I never had much success with it).
|3b| has joined #lisp
ikki has joined #lisp
<murii> Hi
<murii> would a 2D game framework be something people using Lisp be interested in?
<murii> btw, are the any 2D game frameworks for lisp?
<phoe> murii: #lispgames
<phoe> that's where the game-writing people are hanging out at
<phoe> they'll be able to answer your questions much better.
<murii> ok
wxie has quit [Remote host closed the connection]
wxie has joined #lisp
smurfrobot has joined #lisp
smurfrobot has quit [Ping timeout: 240 seconds]
EvW1 has quit [Ping timeout: 276 seconds]
ikki has quit [Ping timeout: 248 seconds]
wxie has quit [Remote host closed the connection]
wxie has joined #lisp
marusich has quit [Ping timeout: 276 seconds]
marusich has joined #lisp
damke_ has joined #lisp
Jesin has quit [Quit: Leaving]
fikka has quit [Ping timeout: 256 seconds]
damke has quit [Ping timeout: 264 seconds]
mishoo has quit [Ping timeout: 248 seconds]
arbv has quit [Ping timeout: 248 seconds]
arbv has joined #lisp
nipav has joined #lisp
nipav has left #lisp [#lisp]
asarch has joined #lisp
randomstrangerb has quit [Ping timeout: 260 seconds]
fikka has joined #lisp
randomstrangerb has joined #lisp
epony has quit [Read error: Connection reset by peer]
shifty has quit [Ping timeout: 256 seconds]
igemnace has joined #lisp
mnoonan has quit [Remote host closed the connection]
<Xach> Hmm, I haven't used sb-sprof in a while, I wonder if it's always shown things like "foreign function __lxstat" in the reports.
<Xach> That is very handy.
wxie has quit [Remote host closed the connection]
<Xach> lxstat is soaking up 29% of my runtime for a thing
fikka has quit [Ping timeout: 240 seconds]
arbv has quit [Ping timeout: 255 seconds]
orivej has quit [Ping timeout: 255 seconds]
z3t0 has joined #lisp
quazimodo has quit [Ping timeout: 265 seconds]
arbv has joined #lisp
fikka has joined #lisp
z3t0 has quit [Ping timeout: 265 seconds]
flamebeard has quit [Quit: Leaving]
rippa has joined #lisp
dyelar has joined #lisp
rumbler31 has joined #lisp
Bike has joined #lisp
dyelar has quit [Quit: Leaving.]
dyelar has joined #lisp
orivej has joined #lisp
murii has joined #lisp
loli has quit [Quit: WeeChat 2.0]
dddddd has joined #lisp
loli has joined #lisp
mishoo has joined #lisp
plertrood has quit [Remote host closed the connection]
sjl has quit [Quit: WeeChat 1.9.1]
murii has quit [Ping timeout: 268 seconds]
fikka has quit [Ping timeout: 255 seconds]
FreeBirdLjj has joined #lisp
fikka has joined #lisp
randomstrangerb has quit [Ping timeout: 276 seconds]
Tristam has joined #lisp
varjag has quit [Quit: ERC (IRC client for Emacs 24.5.1)]
randomstrangerb has joined #lisp
m00natic has quit [Remote host closed the connection]
Tristam has quit [Ping timeout: 256 seconds]
Cymew has quit [Remote host closed the connection]
Cymew has joined #lisp
oleo has joined #lisp
murii has joined #lisp
vydd has quit [Ping timeout: 256 seconds]
sjl has joined #lisp
lnostdal has quit [Quit: https://quanto.ga/]
Cymew has quit [Ping timeout: 265 seconds]
damke has joined #lisp
Cymew has joined #lisp
damke has quit [Read error: Connection reset by peer]
damke has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
<sjl> is https://github.com/nixeagle/cl-irc/blob/master/trunk/utility.lisp#L127-L130 a portable way to implement read-byte-no-hang?
JonSmith has joined #lisp
<sjl> It seems like (listen some-binary-input-stream) is probably not guaranteed to work
<sjl> clhs listen
<pjb> yes.
Cymew has quit [Ping timeout: 240 seconds]
<pjb> Which is not to say that it will work as you want. But this is how you can implement it conformingly.
<sjl> > Returns true if there is a *character* immediately available from input-stream;
<pjb> if it works, it works, but it may not work.
scymtym has quit [Ping timeout: 256 seconds]
<Xach> yep
nika has joined #lisp
<pjb> Notably, the description of LISTEN talks of characters, while input-stream is specified as a stream, not a character stream.
turkja has quit [Ping timeout: 276 seconds]
<Xach> there isn't a portable standard read-byte-no-hang
<pjb> This is an inconsistency, or at least, an underspecification: it says nothing about bytes for binary streams.
eudoxia has joined #lisp
<sjl> right, it doesn't say the stream has to be a character stream, but it implies it
nowhereman_ has quit [Remote host closed the connection]
<Shinmera> With usocket you can check if there's something available to be read
<Shinmera> so based on that you can implement read-byte-no-hang
<pjb> It also talks of interactive streams. So it may be good for binary socket streams, but perhaps it always returns T for file streams.
milanj has quit [Ping timeout: 248 seconds]
<sjl> Shinmera: what function in usocket are you thinking of?
<sjl> Not that I really want to drag in all of usocket for one stream function...
<Shinmera> sjl: Since you linked cl-irc, I thought you had a sockets background in mind
<sjl> Is there an SBCL-specific one? I could live with that, but I can't seem to find one in the manual.
<sjl> Shinmera: ah, no, that's just a result of googling for "read-byte-no-hang"
<Xach> when i needed it, i wound up using sb-alien to drag in epoll.
Cymew has joined #lisp
<Xach> probably overkill? maybe something built-in now?
<sjl> Yeah, I could FFI I guess.
<Xach> i was really concerned about stuff timing out
LiamH has joined #lisp
<sjl> huh, clisp has a read-byte-no-hang
<sjl> Hmm, it makes a decent argument there that (listen binary-stream) should always return nil.
<sjl> To be conforming.
Jesin has joined #lisp
<Xach> clisp also disallows probe-file on directories and a number of other things.
Cymew has quit [Ping timeout: 256 seconds]
<sjl> Yeah, I know it's got other quirks.
pagnol has joined #lisp
Cymew has joined #lisp
milanj has joined #lisp
anti_smap has joined #lisp
anti_smap is now known as antismap_
fikka has quit [Ping timeout: 256 seconds]
Cymew has quit [Ping timeout: 256 seconds]
moei has joined #lisp
fikka has joined #lisp
Cymew has joined #lisp
warweasle has joined #lisp
damke_ has joined #lisp
Cymew has quit [Ping timeout: 256 seconds]
damke has quit [Ping timeout: 264 seconds]
Cymew has joined #lisp
marioxcc has joined #lisp
Cymew has quit [Ping timeout: 276 seconds]
<marioxcc> Hello. Is there some Common Lisp implementation that is suitable to call *from* C code?
<jackdaniel> marioxcc: yes, ECL
<marioxcc> SBCL does not seem to be (it can call C code, but apparently not be called from C code).
<jackdaniel> it shares runtime with C
<marioxcc> jackdaniel: Ok. I will take a look into it
<jackdaniel> and its fasls are in fact shared objects
Cymew has joined #lisp
<marioxcc> jackdaniel: Thanks.
<jackdaniel> "E" stands for embeddable, because it is easy to embed in C/C++ applications
nullniverse has quit [Ping timeout: 264 seconds]
<marioxcc> Ok. I thought that referred to very small computers like microcontrollers.
<jackdaniel> in fact you may define callbacks in SBCL to as far as I remember (so they may be passed to C world)
<jackdaniel> but I don't know the details
<jackdaniel> no, ECL implementation main part is libecl.so (ecl binary is just a client)
<Xach> marioxcc: i'm curious - what prompts the question?
<phoe> jackdaniel: that is correct
FreeBirdLjj has quit [Remote host closed the connection]
<phoe> callbacks are a part of CFFI
<marioxcc> Xach: I am considering contributing to gtk-gnutella. I think it would benefit from rewriting a part in Common Lisp (or another high level language).
<phoe> so anything that is covered by CFFI should be able to implement C callbacks.
<marioxcc> But callbacks still need the implementation to be the owner of the OS process.
<jackdaniel> phoe: CFFI is "just" a portability layer, if implementation can't "do" callbacks neither cffi will be able to
<shka> Shinmera: you there by any chance?
<Shinmera> Yes
<phoe> jackdaniel: correct, that's why I said, "anything covered by CFFI".
<phoe> so you can look up the list of capable implementations by scanning over CFFI docs.
<shka> Shinmera: how should i approach data bases?
<Shinmera> What do you mean?
<phoe> shka: for the love of god, don't use ORMs
<phoe> and then use postmodern
<jackdaniel> phoe: that is not correct either - implementation may be supported by cffi in various degree, so if you call defcallback from cffi it will simply error out
Cymew has quit [Ping timeout: 260 seconds]
<phoe> jackdaniel: I stand corrected
<jackdaniel> I'm sure SBCL has it implemented in CFFI, but it doesn't make that statement true in principle
<shka> I need to perform join or two, i was wondering if i can somehow neatly express that using Radiance data-model module.
<Shinmera> You cannot.
<Shinmera> The database interface is very minimal, and doesn't do joins because some DBs don't do joins.
Cymew has joined #lisp
<shka> ok
osune_ has quit [Read error: Connection reset by peer]
<Shinmera> If you need more capabilities, you're better off accessing a specific database like postgres directly.
<Shinmera> Naturally you can also do joins and stuff in your application if you need to. There's tradeoffs for everything.
knobo has quit [Ping timeout: 256 seconds]
<shka> perhaps it is not that bad as it seem
<shka> ok, so let's restate this slightly differently
<marioxcc> I want to rewrite a part of a C program in Common Lisp to make it more easily manipulatable. Is ECL my best option?
<Shinmera> You can write C programs with just CFFI.
<jackdaniel> I can't say if its your best, but it is a good option. you may even embed CL in your application to connect to it at runtime
<shka> Shinmera: let's say that i only need one-to-one relationships, does this makes things slightly easier?
<jackdaniel> what is the best option for you depends on various factors (and its not that all are technical - taste is an example of non-technical factor)
<marioxcc> Shinmera: If I know correctly, CFFI serves to call C from a Common Lisp implementation, but not to call a Common Lisp implementation from C.
<Shinmera> Colleen: tell shka look up radiance database:query
<Colleen> shka: Macro database:query https://shirakumo.github.io/radiance#MACRO%20DATABASE%3AQUERY
<marioxcc> jackdaniel: Ok. What are the other options?
<marioxcc> I am glancing at the ECL manual. Previously I had used only SBCL.
Cymew has quit [Ping timeout: 256 seconds]
<Shinmera> marioxcc: It can create callbacks, which you can stuff into C variables and then call from C out.
<jackdaniel> marioxcc: I don't know, just asserting its the best option wouldn't be smart on my side
dec0n has quit [Ping timeout: 276 seconds]
<attila_lendvai> cffi has some callback support
<marioxcc> Shinmera, jackdaniel: Ok. Thanks you.
<jackdaniel> I'm ECL developer fwiw, so my point of view may be a little narrowed
<shka> Shinmera: thanks
<jackdaniel> if you have any questions regarding ecl drop them on #ecl channel (less traffic)
<marioxcc> jackdaniel: Thanks. I will, if I do. ☺
<Shinmera> shka: Joins are a pain point, I know. I've been thinking about adding a mechanism to it, but it would increase complexity of an implementation for the interface quite a bit.
pagnol has quit [Ping timeout: 256 seconds]
marioxcc has quit [Quit: Leaving.]
<shka> Shinmera: i think that i will relay on postmodern for the time being
<shka> perhaps some abstract RDB interface implementation can be engineered in the future
fikka has quit [Ping timeout: 240 seconds]
pagnol has joined #lisp
<Shinmera> Yeah, that's a good idea. An extension to the db interface for rdbms.
<shka> right
<Shinmera> I'll think on it
fikka has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
vydd has joined #lisp
redeemed has quit [Quit: q]
<shka> Shinmera: uh, i know that tutorial explains deploy stuff
<shka> but how can i switch to postgress in development phase?
FreeBirdLjj has joined #lisp
dyelar has quit [Quit: Leaving.]
<Shinmera> The configuration variables for i-postmodern are here: https://github.com/Shirakumo/radiance-contribs/tree/master/i-postmodern
<shka> oh, thanks
igemnace has quit [Quit: WeeChat 2.0.1]
FreeBirdLjj has quit [Ping timeout: 240 seconds]
<Shinmera> The documentation about the available modules/implementations are a bit scarce, and I apologise for that
<Shinmera> I ran out of steam writing documentation and haven't been able to get back to it.
<shka> don't worry, i understand that pain all to well
Kaisyu has quit [Quit: Connection closed for inactivity]
ahungry has joined #lisp
ikki has joined #lisp
murii has quit [Ping timeout: 265 seconds]
<ahungry> When using Emacs+slime, is there a standard mechanism to redirect the REPL output to a different buffer? Ideally I would like to have a slime prompt for running interactive lisp, and a separate output buffer to display the results of what is run
scymtym has joined #lisp
<pjb> A standard, normalized by what body? ANSI? ISO? AF? DN?
Tristam has joined #lisp
marusich has quit [Quit: Leaving]
<rumbler31> you can redirect trace-output for many functions that print to the repl
<phoe> pjb: stop
<rumbler31> and then run emacs auto-revert-tail-mode on that file and keep it open in another buffer
PuercoPope has joined #lisp
<rumbler31> I suspect also simply redirecting standard-output as well
<ahungry> Thanks rumbler31, so it seems doable, but not as simple as just setting a variable in Emacs to control it
<ahungry> Maybe approaching in the opposite direction would be easier (make a brand new prompt window that on RET sends the current input line to the active slime session for evaluation)
<rumbler31> although,
<rumbler31> you might miss out on being able to use presentations
<rumbler31> although that is kinda black magic to me anyways, maybe it will just work
<ahungry> hm, a very quick test shows something like slime-eval-buffer would work reasonably well for this (overall i'm hoping to get lispy working well with the slime repl, and the output from the repl breaks it's paren matching counts)
schweers has quit [Ping timeout: 265 seconds]
<PuercoPope> Xach: Do the quicklisp failure reports bail on the first error? I've submitted a couple of fixes to the projects listed but I want to know if having a different issue appearing after the first one was fixed is a possiblity
<Xach> PuercoPope: yes, they do bail out - if there's an error, there's no easy way to continue to find more until the first is fixed.
<Xach> PuercoPope: do you have an example in mind?
pagnol has quit [Ping timeout: 276 seconds]
<PuercoPope> Well, the one I'm worried about is linedit
<PuercoPope> Removing madeira port is easy
<Xach> PuercoPope: was your fix committed?
fikka has quit [Ping timeout: 240 seconds]
smasta has joined #lisp
<PuercoPope> but linedit also uses asdf to call gcc when loading the system and I don't know if that will work or not
squaanchi has quit [Remote host closed the connection]
<Xach> Can discuss a bit more later - afk for now
<PuercoPope> Xach: haven't check yet, submitted it today. (Currently at $work). But the solution worked for the other system of nikodemus that depended on madeira port
<PuercoPope> *checked
<Xach> PuercoPope: I suggest grabbing sbcl 1.4.3 and using (ql:quickload ... :verbose t) to see everything that has to be fixed
<pjb> ahungry: I was just asking, because I have a solution, but it's not standardized. I just invented it myself.
<Xach> that will reproduce my environment to some degree
<PuercoPope> Xach: ok, will do. Basically no warnings right?
drewc_ has joined #lisp
drewc has quit [Ping timeout: 265 seconds]
drewc_ is now known as drewc
ckonstanski has quit [Remote host closed the connection]
JuanitoJons has joined #lisp
damke_ has joined #lisp
cess11 has quit [Ping timeout: 240 seconds]
hexfive has joined #lisp
d4ryus has quit [Quit: WeeChat 2.0.1]
Karl_Dscc has joined #lisp
fikka has joined #lisp
brendyn has quit [Ping timeout: 240 seconds]
bigos_ has joined #lisp
d4ryus has joined #lisp
cess11 has joined #lisp
kami has joined #lisp
<kami> Hello #lisp
fikka has quit [Ping timeout: 240 seconds]
khrbt has joined #lisp
fikka has joined #lisp
<khrbt> PuercoPope: Xach: I did this thing a while ago that removes gcc and .c files from linedit. https://github.com/nikodemus/linedit/pull/10
<Xach> linedit is coming from gitlab.common-lisp.net right now
<khrbt> ok. let me see what happens with that version.
ikki has quit [Ping timeout: 256 seconds]
eivarv has joined #lisp
fikka has quit [Ping timeout: 240 seconds]
antismap_ has quit [Quit: antismap_]
ahungry has quit [Remote host closed the connection]
fikka has joined #lisp
hhdave has quit [Ping timeout: 256 seconds]
<PuercoPope> khrbt: I think remembering trying that branch a couple of years ago. linedit is almost there as a portable decent REPL experience from the CLI
<shka> Shinmera: where are the docs on setf enviorement?
<shka> Ubiquitous?
<shka> i am at loophole
<shka> to set config i need loaded module, to load module i need started radiance, to update config i need to restart it which i don't know how to do
<shrdlu68> kami: Hi
vydd has quit [Ping timeout: 264 seconds]
<shka> oh, whatever i just modified default
<shka> and then my module won't load because something something lambdalite?
<khrbt> PuercoPope: yes. my copy of linedit is based on your branches and I can even load/compile it on ecl and cmucl. I haven't yet looked into what is involved in actually installing a repl.
<Shinmera> shka: Just use the recompile hook provided by ASDF
<shka> in what way
<Shinmera> Err, recompile restart
<shka> i have no clue what you are suggesting
<shka> use for what, use how?
<Shinmera> Your module won't load, so during loading use the recompile restart from ASDF?
_main_ has joined #lisp
_main_ has quit [Read error: Connection reset by peer]
<shka> Shinmera: it… works?
<shka> but how
__main__ has quit [Ping timeout: 248 seconds]
<Shinmera> When you previously loaded it, it was using macros from the lambdalite db implementation. Those expansions ended up in the FASL. When you switched implementations, the lambdalite package isn't there anymore, but ASDF isn't smart enough to pick up that you switched implementations
<Shinmera> So it doesn't recompile automatically.
<shka> very confusing
<shka> but makes sense i guess
__main__ has joined #lisp
<shka> what are those macros are for anyway?
<Shinmera> Well you most likely used the db:query macro, which compiles the query language to something else to make things not slow as hell.
<shka> ok
nika has quit [Quit: Leaving...]
dyelar has joined #lisp
drot has quit [Quit: Quit.]
<shka> Shinmera: well, everything works i guess, tables has been created for user and profile
drot has joined #lisp
milanj has quit [Ping timeout: 240 seconds]
fikka has quit [Ping timeout: 276 seconds]
varjag has joined #lisp
JuanitoJons has quit [Ping timeout: 240 seconds]
<Shinmera> I'd hope so :)
_mjl has joined #lisp
dlowe has quit [Quit: ZNC - http://znc.sourceforge.net]
<shka> phoe: btw, I will use ORM that comes with postmodern because i hate myself and you ;-)
<p_l> ... you haven't yet used hu.dwim.perec
fikka has joined #lisp
* p_l might have somewhere a bit of code to implement custom datatype PESEL using it
<shka> what's wrong with that one?
JuanitoJons has joined #lisp
<p_l> it's not so much wrong, but it's a big thing
toon` has joined #lisp
<khrbt> Xach: What would be the best way to improve the linedit situation? The GitHub version, especially PuercoPope's "fork" branch is in the best shape it seems.
<shka> Shinmera: btw, how one should approach to extending information in users? I would simply add my own tables, use foreign key and call it awesome, but perhaps there is a better way to do so
<Shinmera> shka: If all you need is to store a string on a user object, you can use user:field
<shka> i see
<Shinmera> Colleen: tell shka look up radiance user:user
<Colleen> shka: Class user:user https://shirakumo.github.io/radiance#CLASS%20USER%3AUSER
<shka> yes, actually i seen this class
<shka> but i would rather not do it this way…
<Shinmera> Right, then use the username to identify the user.
<shka> sounds fine
PuercoPope has quit [Ping timeout: 264 seconds]
knobo has joined #lisp
bigos_ has quit [Remote host closed the connection]
fikka has quit [Ping timeout: 255 seconds]
<ebzzry> How does NREVERSE behave in SBCL? Does it modify the argument?
<pjb> type M-. on nreverse and read the sources.
<oleo> yes
<oleo> it does
<ebzzry> thanks!
dlowe has joined #lisp
smasta has quit [Ping timeout: 256 seconds]
Ven`` has joined #lisp
pagnol has joined #lisp
<shka> using postmodern
<shka> DAO classes seems to lack features like setting foreign-key
<shka> am I right?
smasta has joined #lisp
fikka has joined #lisp
<phoe> shka: postmodern bundles its own ORM?
<shka> sort of
<shka> but it is half arsed
<phoe> ORM like https://github.com/eudoxia0/crane is the ORM I mean
<phoe> the simple kind of stuff like postmodern provides isn't insane yet
__main__ has quit [Read error: Connection reset by peer]
<shka> could use few extra features
__main__ has joined #lisp
<shka> damn, even option to provide YOUR OWN initialization code for table would be nice
<shka> but whatever
megalography has quit [Ping timeout: 255 seconds]
<jasom> most ORMs tend to be buggy ill-specified implementations of half of a real object store; 99% of the time SQL actually maps better to the problems I have
<shka> well, hard to argue with that…
<jasom> though I wouldn't mind a sexp sugar on top of SQL, since that's more aesthetically pleasing to me than wrapping a DSL with ""
<phoe> jasom: postmodern has that I think
<phoe> is called S-SQL
<p_l> perec has quite good approach to ORM (i.e. it doesn't do Active Record pattern)
<rumbler31> ORM is what?
PuercoPope has joined #lisp
toon` has quit [Remote host closed the connection]
toon` has joined #lisp
megalography has joined #lisp
<phoe> object-relational mapping, google it.
dilated_dinosaur has quit [Quit: Leaving]
Ven`` has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
LocaMocha has quit [Ping timeout: 248 seconds]
<jasom> rumbler31: a tool to let programmers stay in their OO bubble and pretend that SQL doesn't actually exist ;)
<phoe> ^
nullman has quit [Ping timeout: 256 seconds]
nullman has joined #lisp
<dim> avoid ORM
<dim> the problem space of application code objects in memory and of the relational model are not compatible, specialize each of them, the mapping is bound to fail
<dim> the only interesting ORM style would be to map query results to app objects, as each SQL query defines a new relation
<dim> I've seen that to some extend in POMM (PHP) and I think JOOQ (Java) has something to that approach
<sukaeto> jasom: re: sexp sugar on top of SQL, I've been relatively happy with https://github.com/fukamachi/sxql
<rumbler31> I always thought that was what object databases were
<dim> in general ORM try to map the database model with the application in-memory state, and that can't help anybody
<dim> object database would be a kind of hierarchical model rather than relational, I think
<sukaeto> it doesn't do some of the more complicated dialect specific stuff (namely Postgres' ON CONFLICT and common table expressions), but it's extensible so you could always add those things if you need them
<dim> CTE is part of SQL'92 I think, it's basic foundamental SQL
<dim> (fundamental, oops)
<sukaeto> ah, well then
<dim> disclaimer: I wrote a book on SQL this summer to teach that to app developers, available at https://masteringpostgresql.com ; I am quite opinionated on the topic...
<sukaeto> it doesn't support all of the SQL standard, then
<sukaeto> (it's still pretty nice, and again, you can add those things)
<jasom> dim: does it include basics of RDB? I was unable to take the DB course at university because there was no room in the class, so I've mostly just learned by doing...
<jasom> oh, the webpage answered that... buying a copy now...
<dim> jasom: I think it does, but that depends on the specifics of the curriculum you missed ; you can get a sample with the full ToC for free (in exchange of your email) on the website
<dim> jasom: awesome, thanks! have a good read ;-)
<jasom> I limped by using key-value stores for like a decade before actually learning any SQL
<sukaeto> anyway, to add my (potentially uneducated) opinion on ORMs to the discussion: I agree that trying to automatically map "sets of facts about the world" into "sets of objects in memory" is a fundamentally flawed errand.
smasta has quit [Read error: Connection reset by peer]
epony has joined #lisp
smasta has joined #lisp
epony has quit [Max SendQ exceeded]
epony has joined #lisp
shrdlu68 has quit [Ping timeout: 256 seconds]
ebzzry has quit [Ping timeout: 256 seconds]
damke has joined #lisp
<p_l> the problem with ORM is that it's associated with ActiveRecord pattern, which is popular but not the only way that falls under "ORM"
damke_ has quit [Ping timeout: 264 seconds]
vydd has joined #lisp
wigust_ has joined #lisp
Ven`` has joined #lisp
wigust has quit [Ping timeout: 276 seconds]
<sukaeto> I mean, I've used ORMs as just a way to query the database in the language the ORM was written in vs. embedding strings of SQL - that is, each ORM object is just a record representing some relation in the database, and the business logic objects consume/query the ORM objects. That works out just fine.
<sukaeto> I still think things like SxQL are nicer for "querying the database in your language". Just one benefit of Lisp over most everything else. :-)
<p_l> some ORMs provide explicit access to relational aspect instead of trying to shoehorn shit into objects
<p_l> the "one class one table" thing is called "Active Record"
<p_l> which is not just a ruby library
murii has joined #lisp
smasta has quit [Ping timeout: 264 seconds]
smasta has joined #lisp
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
PuercoPope has quit [Ping timeout: 248 seconds]
milanj has joined #lisp
openthesky has joined #lisp
_mjl has quit [Ping timeout: 248 seconds]
eudoxia has quit [Quit: Leaving]
Cymew has joined #lisp
Cymew has quit [Ping timeout: 240 seconds]
<shka> how to prevent postmodern from converting table name FOO/BAR into foo_bar in query?
khrbt has quit [Quit: Page closed]
ikki has joined #lisp
wigust_ has quit [Quit: ZNC 1.6.5 - http://znc.in]
<shka> to_sql_name does it
<shka> grrrr
hvxgr has joined #lisp
pjb has quit [Remote host closed the connection]
PuercoPope has joined #lisp
PuercoPope has quit [Ping timeout: 265 seconds]
<shka> (or (eq ch #\*) (alphanumericp ch)) :(
<shka> i am so sad right now
<Bike> should be eql
<phoe> ^
angavrilov has quit [Remote host closed the connection]
<shka> Bike: not my code but yeah
lnostdal has joined #lisp
<shka> actually it can be char=
<shka> but that's beside the point
<shka> i can't use S-SQL :/
<shka> gross
smasta has quit [Ping timeout: 256 seconds]
<shka> i can create view, i guess
hexfive has quit [Read error: Connection reset by peer]
<fouric> anyone have any resources on function hotpatching in CL? i've found a few pages on stack overflow that just tell me the bare minimum (how to hotpatch a single function using Emacs+SLIME), but i'm interested in knowing more, such as "how does this work?" and "how can i make my code \"aware\" of said hotpatching (e.g. add hooks that fire off when a function is replaced so i can run code that updates state)?"
vlatkoB has quit [Remote host closed the connection]
hexfive has joined #lisp
<fouric> stack overflow gives me like 2 pages that tell me what i already know, and google gives me those same pages before beginning to omit either "lisp" or "hotpatch" from my query
<phoe> >add hooks that fire off when a function is replaced
<Bike> you mean you want to redefine functions in the middle of operation?
scymtym has quit [Remote host closed the connection]
scymtym has joined #lisp
<phoe> in general: you generally don't, unless you care enough to write your own DEFUN.
<fouric> redefine functions in a given program while it's still running
<Bike> right.
<phoe> And your own DEFUN can contain code to fire any callbacks you want and call CL:DEFUN as a part of its operation.
<Bike> as phoe says, there are no hooks.
<phoe> but nobody prevents you from installing them
<fouric> i was hoping that there would be something built-in, but i'm willing to write my own variant of DEFUN if need-be
<fouric> in general, though, how would i find answers to other questions like this?
<phoe> fouric: other questions like this - what do you mean?
smasta has joined #lisp
<Bike> for how it works, it's a somewhat obscure point of compilation semantics. If a function defined in one compilation unit refers to another function defined in the same unit, e.g. by a call or #', redefining the other function is undefined behavior.
<fouric> questions about how code hotswapping works in common lisp
<fouric> has someone written an article somewhere?
<phoe> you also need to use something like ASDF's WITH-UPGRADABILITY for the functions that you want to be able to always replace.
<Bike> But you can explicitly force a lookup by using fdefinition, either explicitly or by e.g. (funcall 'foo ...)
<fouric> is there a section in a book?
<Bike> I don't know of any articles or anything.
<phoe> fouric: I don't think so. Just ask questions here.
<fouric> ...or is almost all of this stuff just passed from person to person?
<fouric> ah
<Bike> it's a pretty short explanation.
<fouric> for that question, yes
<fouric> i'm anticipating having more
<phoe> as long as your functions are *not* inlined by the compiler, setting a new fdefinition instantly causes the whole image to pick up the new function.
<Bike> More about redefining functions, specifically?
<fouric> mutating bits of an image on the fly, in general
<phoe> like, when the function is newly called, it'll use the new definition. old calls won't magically start executing the new function if the old function is in the middle of being executed.
<fouric> i'm vaguely aware of the fact that you can update classes in-place
<Bike> Mm, that might be tricky. It's kind of... the whole language?
<Bike> All the defining forms just do side effects.
<jasom> fouric: under the hood, functions are typically called via indirection, so there is a pointer to the code for a function. When you redefine it, you create new code then just update the pointer
<jasom> fouric if you know assembly at all, just look at this output from sbcl: (disassemble (lambda () (declare (optimize (speed 3) (safety 0))) (quux)))
ikki has quit [Ping timeout: 256 seconds]
* fouric does, and disassembles
<jasom> then all of the call stacks &c. are roots for the GC, so no old function definition will get garbage collected until it is no longer on anybody's call stack
ikki has joined #lisp
mishoo has quit [Ping timeout: 248 seconds]
<fouric> that's clever
<fouric> jasom: how did you learn this?
<fouric> Bike: if there isn't some single document on the internet, that's fine, i'll gladly come here for help
<fouric> ...i was just trying to see if there was something that i could go to instead of re-asking questions that have already been put here multiple times
<fouric> (possibly)
<Bike> I guess the overall way to think of it is, the image is the image. it has some bindings, like of functions and classes. you can alter the bindings at your whim. these are basic language semantics. With functions, the compiler is allowed to integrate definitions and skip bindings sometimes, so you have to be aware of those times to do redefinition
fikka has quit [Ping timeout: 240 seconds]
<Bike> But everything else is fairly safe. except there's also threading and who knows what's going on there.
<Bike> this channel gets a lot of repeat questions. it's no big deal, i don't think
<Bike> i guess we could put together a faq or whatever, like the cool channels
<fouric> is that how function redefinition happens? your code is running in one thread, and the SLIME client in another, and said client updates the definition of FOO or whatever, which the "main" thread picks up on the next time FOO is called?
<rumbler31> I imagine that question has implementation specific answers
<Bike> well, that's basically it though.
<fouric> Bike: i'm just trying to learn stuff while enroaching of the time of more skilled (and therefore productive) people in here as little as possible
<Bike> the semantics are actually defined in a single threaded environment, and implementations do try to be nice
<fouric> if that explains anything
<Bike> yeah i getcha
<Bike> thanks for the concern i guess. but in this case i think it's question city
<fouric> aight
<fouric> well, i'm very happy with the answers i got
<fouric> ty Bike and phoe and jasom
<rumbler31> also, I personally appreciate the dive into more complicated topics that I might not yet even know how to ask about
<fouric> o good!
* fouric is useful
<rumbler31> and I speak up to have my assumptions tested
oleo has quit [Quit: Leaving]
PuercoPope has joined #lisp
oleo has joined #lisp
fikka has joined #lisp
<jasom> also the specification lists when functions can be redefined; if they are either declared notinline at all call points, or not referenced anywhere in the file in which they are defined then it's safe.
zaquest has quit [Ping timeout: 276 seconds]
<jasom> basically permission to inline is logically the same as permission to assume the function will never change
cgay has quit [Remote host closed the connection]
<rumbler31> jasom: what do you man about "not referenced anywhere in the file in which they are defined"
Baggers has joined #lisp
<jasom> rumbler31: logically speeking there are 3 states for inlining a function; lets call them: inline, notinline and default. The default is "may be inlined anywhere in the same file as the function definition"
ccl-logbot has quit [Remote host closed the connection]
ccl-logbot has joined #lisp
<jasom> so a file with (defun foo () ) (defun bar () (foo)) the call to foo in bar may be inlined, absent any other declarations
<sjl> related: is there any way to set a function's inline status back to the default?
<jasom> sjl: no portable way that I've ever been able to find
<sjl> (declaim (inline foo)) (defun foo ...) (declaim (notinline foo)) makes foo inlineable but prevents any compiler macros
<rumbler31> so without explicitly specifying notinline on foo when loading the file, given the default inline state, a conforming implementation will warn/error when foo is redefined?
<jasom> rumbler31: it will not
jack_rabbit has quit [Quit: Leaving]
<rumbler31> then.. I guess I still don't know what you meant to say with your second sentence
<jasom> rumbler31: the assumption is that you know what you are doing if you redefine functions unless something very obviously is wrong (it was declared inline, you have two definitions of the same function in the same file)
<jasom> rumbler31: a conforming implementation is allowed to assume that a function defined in file X has a fixed definition for the entire body of file X.
<rumbler31> what does fixed definition mean? s.t. re-invocations of defun are unspecified behavior?
<jasom> rumbler31: correct
<rumbler31> oh..
<jasom> rumbler31: in practice it usually just means that the redefinition won't take effect, but I suppose it could have safety implications if the type of the function were inferred (not sure if sbcl does this).
<jasom> For the purposes of incremental development using C-c C-k will usually mean that all functions not declared inline will work right (since you recompile the entire file).
<jasom> obviously macros (and compiler macros) have a different set of rules
<rumbler31> can you go into the last sentence briefly?
<jasom> regarding macros?
<rumbler31> yes
<jasom> macros definitions are invoked when the macro is expanded. When compiling this is the same as compile time.
<jasom> so if you change a macro, there is no magic that finds all places in which it was expanded and recompiles them.
<jasom> you should use asdf if you want this to work (it tracks dependencies on a file-level basis)
<rumbler31> so the part about macros not being re-evaluated I understand. I will ponder how that affects function redefinition
<jasom> My point is everything I said up to that sentence refers only to redefining functions. If you redefine macros, then you need to think differently
hexfive has quit [Remote host closed the connection]
<rumbler31> oh I see what you mean now
hexfive has joined #lisp
cgay has joined #lisp
eivarv has quit [Quit: Sleep]
<aeth> jasom: Return type information isn't inferred unless the function is inline afaik, i.e. (defun foo () (the single-float 1f0)) (defun bar () (+ 1f0 (foo))) (disassemble #'bar)
fikka has quit [Ping timeout: 248 seconds]
<aeth> You could probably wrap a the around the function call, which would get rid of the generic-+, but still do type checking because it still won't trust you not to redefine #'foo. You'd probably need sb-ext:truly-the in SBCL, and you'd need to *really* make sure your wrapper will never fail.
<jasom> aeth: I do *not* see the same behavior when I tried it.
zaquest has joined #lisp
<aeth> ah, they need to be in the same file
<aeth> And then it produces the same effect as the, but not truly-the
nullniverse has joined #lisp
<aeth> Actually, almost but not
smasta has quit [Ping timeout: 256 seconds]
<aeth> It will type-check that it's 1.0f0, not just single-float
<jasom> right it type-checks and then returns 2.0f0 without doing an add
<jasom> I assume changing foo to be (random 1.0) or some such will have a similar effect. but use a single-float specialized add
quazimodo has joined #lisp
PuercoPope has quit [Ping timeout: 256 seconds]
<aeth> jasom: I think that it's not a type thing but a constant thing, though. I've had the same thing happen with macros that generate functions that return constant strings. If I changed those macros in SBCL, I would then get a runtime type error on the user of that generated function if the length of the generated string changed (because length is part of the type in Pascal-style strings)
<jasom> yup. So sbcl does assume that function-types for functions that are not declared inline are fixed
<jasom> aeth: it's typechecking for a float in the range [1.0, 1.0]
<aeth> s/those macros/those calls to the macro/
<aeth> jasom: yeah, but I think it's specifically an optimization for functions that are returning constants
<jasom> aeth: it is not
PuercoPope has joined #lisp
<jasom> because I get a FPU add instead of generic+ when I change it to return a random single-float
<jasom> ADDSS
fikka has joined #lisp
<jasom> fortunately it works like THE so it does not violate safety constraints
<aeth> You are correct, I just tested that with (random 2f0) and I get ADDSS and it tests for '(single-float 0.0)
<jasom> oh, and it does warn on redefinition in this case too
<jasom> but only if I redefine on the REPL
<aeth> I don't get a warn when recompiling foo to return "hi" (rather than the file), I just get a runtime type error when calling bar
<aeth> It must have been added in a new version
<aeth> Probably because someone else faced these sorts of issues
<aeth> Possibly with a string-generating macro like I used
nullniverse has quit [Ping timeout: 256 seconds]
<aeth> It wouldn't warn when recompiling the file because it can update bar, too
Ven`` has quit [Ping timeout: 260 seconds]
<aeth> (well, it would warn about the return type of foo not being compatible with +, so my example isn't perfect)
<jasom> changing it to return 1.0d0 is maybe a better example
<aeth> This is interesting, though. It means that fewer, larger files aren't just a stylistic choice. It will potentially make the code more efficient, but at the cost of possibly causing issues with recompiling just an individual function rather than the file.
<stylewarning> aeth this is well known about compiling things within the same compilation unit
<stylewarning> CMUCL has block compilation to ameliorate some of the concerns, I think
<jasom> asdf has with-upgradability at least partly because the entire thing gets put into a single .lisp file
murii has quit [Quit: WeeChat 1.4]
Ven`` has joined #lisp
<Bike> with-compilation-unit should be usable to make more things optimize together, at least in theory. hell if i know whether sbcl does
markong has joined #lisp
smasta has joined #lisp
Ven`` has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
milanj has quit [Quit: This computer has gone to sleep]
smurfrobot has joined #lisp
pjb has joined #lisp
alexmlw has quit [Quit: alexmlw]
alexmlw has joined #lisp
alexmlw has quit [Client Quit]
<aeth> with-compilation-unit would only be necessary to get file-like optimizations in the REPL, though, right?
<pjb> aeth: that, and if you want to remove the file boundary in a project.
<aeth> pjb: Is removing the file boundary possible in a way that's compatible with ASDF? It might be useful as part of a build step for distributing a final executable.
<pjb> You would need asdf support for with-compilation-unit. I don't remember if it's available or not.
knobo has quit [Ping timeout: 256 seconds]
fikka has quit [Ping timeout: 256 seconds]
<pjb> Also, you raise a interesting question: can we always concatenate all the files of a project for distribution, without changing semantics, vs. a separate compilation.
<pjb> Obviously, it's not possible in general: you would have to add eval-when to be able to compile the concatenated file.
<aeth> yeah
<pjb> Perhaps that's what asdf does?
<aeth> Multiple packages would complicate things, too
<aeth> Or at least could complicate things
milanj has joined #lisp
smasta has quit [Ping timeout: 256 seconds]
orivej has quit [Ping timeout: 268 seconds]
toon` has quit [Ping timeout: 272 seconds]
fikka has joined #lisp
shifty has joined #lisp
toon` has joined #lisp
quazimodo has quit [Ping timeout: 276 seconds]
smasta has joined #lisp
ikki has quit [Ping timeout: 240 seconds]
Karl_Dscc has quit [Remote host closed the connection]
nirved has quit [Quit: Leaving]
randomstrangerb has quit [Ping timeout: 248 seconds]
randomstrangerb has joined #lisp
PuercoWork has joined #lisp
PuercoPope has quit [Ping timeout: 256 seconds]
smurfrobot has quit [Remote host closed the connection]
smasta has quit [Ping timeout: 256 seconds]
Bike has quit [Ping timeout: 260 seconds]
LiamH has quit [Quit: Leaving.]
raynold has quit [Quit: Connection closed for inactivity]
PuercoWork has quit [Ping timeout: 256 seconds]
smurfrobot has joined #lisp
moei has quit [Quit: Leaving...]
_main_ has joined #lisp
damke_ has joined #lisp
PuercoWork has joined #lisp
smurfrobot has quit [Ping timeout: 240 seconds]
__main__ has quit [Ping timeout: 256 seconds]
_main_ is now known as __main__
damke has quit [Ping timeout: 264 seconds]
shka has quit [Ping timeout: 240 seconds]
sjl has quit [Ping timeout: 260 seconds]
fikka has quit [Ping timeout: 240 seconds]
fikka has joined #lisp
smasta has joined #lisp
pagnol has quit [Ping timeout: 256 seconds]
varjag has quit [Quit: ERC (IRC client for Emacs 25.2.1)]
openthesky has quit [Quit: Page closed]
dilated_dinosaur has joined #lisp
PuercoWork has quit [Ping timeout: 240 seconds]
_main_ has joined #lisp
__main__ has quit [Ping timeout: 276 seconds]
kami has quit [Ping timeout: 256 seconds]
_main_ is now known as __main__
<drmeister> That’s what I assumed with-compilation-unit was for when I first encountered it. Optimize whole compilation units together
rumbler31 has quit [Ping timeout: 248 seconds]
randomstrangerb has quit [Ping timeout: 260 seconds]
__main__ has quit [Read error: Connection reset by peer]
_main_ has joined #lisp
randomstrangerb has joined #lisp
_main_ is now known as __main__
Baggers has quit [Remote host closed the connection]
Bike has joined #lisp
PuercoWork has joined #lisp
Jesin has quit [Quit: Leaving]
fikka has quit [Ping timeout: 264 seconds]
zmt00 has quit [Read error: Connection reset by peer]
zmt00 has joined #lisp
smasta has quit [Ping timeout: 256 seconds]
smasta has joined #lisp
fikka has joined #lisp
smurfrobot has joined #lisp
smasta has quit [Ping timeout: 240 seconds]
dddddd has quit [Read error: Connection reset by peer]