damke_ has joined #lisp
z3t0 has quit [Remote host closed the connection]
z3t0 has joined #lisp
damke has quit [Ping timeout: 264 seconds]
z3t0 has quit [Remote host closed the connection]
voidlily has joined #lisp
aindilis has joined #lisp
z3t0 has joined #lisp
Ukari has quit [Remote host closed the connection]
z3t0 has quit [Remote host closed the connection]
ckonstanski has quit [Remote host closed the connection]
Ukari has joined #lisp
fikka has quit [Ping timeout: 256 seconds]
LiamH has quit [Quit: Leaving.]
voidlily has quit [Ping timeout: 256 seconds]
heurist__ has joined #lisp
voidlily has joined #lisp
heurist`_` has quit [Ping timeout: 240 seconds]
al-damiri has quit [Quit: Connection closed for inactivity]
fikka has joined #lisp
heurist has joined #lisp
nowhere_man has quit [Read error: Connection reset by peer]
heurist__ has quit [Ping timeout: 248 seconds]
damke has joined #lisp
nowhere_man has joined #lisp
rumbler31 has joined #lisp
EvW has quit [Ping timeout: 240 seconds]
damke_ has quit [Ping timeout: 264 seconds]
pagnol has quit [Ping timeout: 256 seconds]
pagnol has joined #lisp
pierpa has joined #lisp
markong has quit [Ping timeout: 260 seconds]
python476 has joined #lisp
aindilis has quit [Ping timeout: 268 seconds]
pagnol has quit [Ping timeout: 240 seconds]
dendisuhubdy has joined #lisp
wmannis has joined #lisp
fikka has quit [Ping timeout: 248 seconds]
vtomole has quit [Ping timeout: 260 seconds]
Tobbi has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
wmannis has quit [Quit: wmannis]
<thodg> it's just a let sugar right ?
<thodg> &aux
fikka has joined #lisp
smurfrobot has joined #lisp
dendisuhubdy has quit []
Ukari has quit [Remote host closed the connection]
smurfrobot has quit [Remote host closed the connection]
jdz has quit [Ping timeout: 256 seconds]
fikka has quit [Ping timeout: 248 seconds]
jdz has joined #lisp
JuanDaugherty has quit [Ping timeout: 240 seconds]
shifty has joined #lisp
fikka has joined #lisp
quazimodo has quit [Ping timeout: 256 seconds]
<iqubic> What is PAIP?
<Bike> minion: paip
<minion> paip: Paradigms of Artificial Intelligence Programming
<Bike> no link...
<Bike> well, it's that. it's a book.
<Bike> uses lisp to go through historical AI ideas.
<iqubic> s there a link anywhere?
<Bike> no, it's a print book.
<iqubic> darn.
<iqubic> is there a ebook version?
<pierpa> Amazon sells a kindle version
<rme> get the paper book
<rme> code from the book is https://github.com/norvig/paip-lisp
Guest14820 has quit [Ping timeout: 260 seconds]
<iqubic> I don't have enough money to get the print version.
<Bike> it doesn't have anything about perceptrons, anyway
<iqubic> Really? What form of AI does it talk about?
<Bike> symbolic stuff, basically
<Bike> that's why i said "historical"
<sjl> if you're an ACM member you can get a PDF of it https://dl.acm.org/citation.cfm?id=530559
<iqubic> What is symbolic stuff?
<Bike> uhhhh read the book and find out i guess
<Bike> nothing anybody really does any more, as far as i know
<Bike> it's all about statistics and general machines like ANNs
<iqubic> I don't think I want to read the book, because I don't have a good way to access the book.
<iqubic> And ancient AI stuff is not what I want to do.
<Bike> yes
<pierpa> Tha ancient AI stuff is used to teach good programming practices.
<Bike> yes, it's a good book in that respect, but you aint gonna learn about ML
jameser has joined #lisp
aindilis has joined #lisp
whoman has quit [Read error: Connection reset by peer]
impulse has joined #lisp
fikka has quit [Ping timeout: 240 seconds]
vtomole has joined #lisp
<iqubic> What would be a good beginner project for me to work on?
fikka has joined #lisp
aindilis has quit [Excess Flood]
d4ryus1 has joined #lisp
quazimodo has joined #lisp
<pierpa> something about something you like
d4ryus has quit [Ping timeout: 256 seconds]
aindilis has joined #lisp
sfa has joined #lisp
beach has quit [Ping timeout: 256 seconds]
sfa has quit [Client Quit]
aindilis has quit [Ping timeout: 268 seconds]
sfa has joined #lisp
porky11 has quit [Remote host closed the connection]
asarch has joined #lisp
beach has joined #lisp
dieggsy has joined #lisp
<iqubic> Can you modify the value of a parameter in a function?
<Bike> sure.
<Bike> (defun foo (x) (setf x 7)) like that? yes.
Cymew has joined #lisp
<Bike> (defun foo (x) (setf (car x) 7)) also fine.
<iqubic> Yes. But is a function in its own closure? IE does that modify the value passed in?
<Bike> (defun foo (x) (setf x 7)) (let ((x 19)) (foo x) x) => 19
<iqubic> Alright.
<iqubic> So, no pointers?
<Bike> (defun foo (x) (setf (car x) 7)) (let ((x (cons 0 0))) (foo x) x) => (7 . 0)
<iqubic> How is that different?
<Bike> (setf x 7) is modifying the binding of x, and that binding is created when the function is called
<Bike> (setf (car x) 7) is modifying the actual cons object that was passed in
<iqubic> Is see. Is there a way to make the first example actually change the value of x outside the function?
<Bike> Not really. You can write a macro to do things sometimes though.
<Bike> What do you have in mind?
<iqubic> Just playing around.
<iqubic> Are there any CL libraries that implement matrixes and matrix operations?
<iqubic> This I actually have a use for.
<pfdietz> Yes, I believe so.
<Bike> there's a few, like lisplab... i couldn't tell you which are good, though.
Cymew has quit [Ping timeout: 248 seconds]
aindilis has joined #lisp
Ukari has joined #lisp
smurfrobot has joined #lisp
<iqubic> Wow, are all of those good?
<iqubic> I only need 2D matrixes at this time though.
JuanDaugherty has joined #lisp
damke_ has joined #lisp
fikka has quit [Ping timeout: 268 seconds]
fikka has joined #lisp
aindilis has quit [Read error: Connection reset by peer]
nika has joined #lisp
damke has quit [Ping timeout: 264 seconds]
fikka has quit [Ping timeout: 256 seconds]
ahungry has joined #lisp
python476 has quit [Ping timeout: 264 seconds]
smurfrobot has quit [Remote host closed the connection]
Ukari has quit [Remote host closed the connection]
fikka has joined #lisp
<iqubic> Which library from that list will give me a good optimal 2D matrix implementation?
zooey has quit [Ping timeout: 255 seconds]
shka has joined #lisp
ikki has quit [Quit: Leaving]
<Bike> "optimality" is a nontrivial question, you know
<Bike> what operations are you doing? how sparse are the matrices? do you have guarantees on your form? what's the precision? how big are they? bla bla bla
<Bike> i imagine they're all at pleast pretty good, though
zooey has joined #lisp
<beach> Good morning everyone!
deng_cn has quit [Read error: Connection reset by peer]
deng_cn has joined #lisp
smasta has joined #lisp
<pfdietz> Good... morning.
beach has quit [Ping timeout: 256 seconds]
z3t0 has joined #lisp
zooey has quit [Ping timeout: 255 seconds]
milanj has quit [Quit: This computer has gone to sleep]
zooey has joined #lisp
Ukari has joined #lisp
fikka has quit [Ping timeout: 248 seconds]
vtomole has quit [Ping timeout: 260 seconds]
beach has joined #lisp
<iqubic> It is morning for you, night for me, but I'm not sure it can be considered good. I have been battling sickness all day.
<iqubic> beach: I know what that is.
<iqubic> I'm just too sick to remember to use stuff properly
<jack_rabbit> lol
smurfrobot has joined #lisp
<iqubic> Can I overload simple functions like + to work differently if I pass in a CLOS object of my own creation?
<iqubic> s/simple/pre-existing/
<Zhivago> You can supply methods for generic-functions.
fikka has joined #lisp
<iqubic> Are + and * generic functions?
<Zhivago> They are not required to be, so you cannot expect that they are in portable code.
<Zhivago> Ah, I missed + in your original question.
<iqubic> Oh, I see.
<Zhivago> You can always make your own version of + which is, but then you need to convince other code to use it.
<Zhivago> CL is not very generic at its core.
<iqubic> So most matrix libraries provide their own version of the addition function, instead of piggybacking on the existing symbol function name?
<Zhivago> You're not portably permitted to modify things in the common-lisp package.
<iqubic> Thank you. That answers my question.
<Zhivago> It makes more sense if you consider CL to be a compatibility layer like posix.
schoppenhauer has quit [Ping timeout: 248 seconds]
<Zhivago> It was originally intended to allow code from lisp-system A to run on lisp-system B.
JuanDaugherty has left #lisp ["Exeunt"]
<Zhivago> So they tried to avoid doing anything that would require hard work on the underlying implementation.
<pierpa> hmmm
smurfrobot has quit [Remote host closed the connection]
<Zhivago> Of course, now that everything has converged to CL or died ...
<Zhivago> Anyhow, it all made a lot more sense in the late 80s and early 90s.
schoppenhauer has joined #lisp
<iqubic> yeah. I somehow assumed that CL's (+) function was a generic function that was specialized to numbers.
<beach> iqubic: If you had bothered to look at the Common Lisp HyperSpec page for +, you would have seen that it is NOT a generic function.
<beach> clhs +
<beach> Notice the "Function", rather than "Generic Function".
<iqubic> beach: I keep forgetting that CLHS is a thing.
<iqubic> I need to bookmark that thing.
<beach> You keep forgetting location of the document defining the language you are using? Wow.
ahungry has quit [Remote host closed the connection]
<pierpa> you can also download it and then use your local copy. One thing less to remember :)
<Zhivago> Well, technically the CLHS isn't the spec, but close enough. :)
Kaisyu has joined #lisp
<iqubic> beach: I'm sorry. It's just that I use the emacs lisp documentation way more often than I use CLHS.
fonzie has joined #lisp
Arcaelyx has joined #lisp
<didi> An Info CLHS would be interesting.
<iqubic> I'd like that.
fonzie has quit [Remote host closed the connection]
<Bike> huh? isn't there one?
<didi> I'm not familiar with one.
<didi> Bike: Ah, nice. Thank you.
<stylewarning> iqubic: there’s CL-GENERIC-ARITHMETIC and LOOM, the former making arithmetic generic, the latter making almost all of CL generic
sfa has quit [Remote host closed the connection]
<iqubic> What's the difference between ' and #'?
Bike has quit [Quit: Lost terminal]
<stylewarning> iqubic: this is answered in most books
<stylewarning> #' looks up the function associated with a name
<stylewarning> ' just quotes data (returns it unevaluated)
sfa has joined #lisp
<iqubic> When would you use one over the other?
<stylewarning> the first one is when you want to refer to functions
<stylewarning> The second one has nothing to do with functions
<iqubic> Oh. I see.
ozzloy has joined #lisp
ozzloy has joined #lisp
smurfrobot has joined #lisp
<emaczen`> didi: If you download GCL it comes with the hyperspec in texinfo format
<emaczen`> at least it does if you download the docs via your linux distro
sjl__ has joined #lisp
<didi> emaczen`: Thank you.
sjl__ has quit [Ping timeout: 255 seconds]
<Zhivago> 'x is (quote x) #'x is (function x).
drewc has quit [Ping timeout: 248 seconds]
ozzloy has quit [Remote host closed the connection]
sjl has quit [Ping timeout: 256 seconds]
lnostdal has quit [Ping timeout: 255 seconds]
<pjb> assuming the standard readtable macros.
<pjb> and assuming by quote you mean COMMON-LISP:QUOTE and by function you mean COMMON-LISP:FUNCTION
fikka has quit [Ping timeout: 260 seconds]
<iqubic> I do mean that.
z3t0 has quit [Remote host closed the connection]
z3t0 has joined #lisp
<didi> Zhivago: I liked your connection between CL and posix.
z3t0 has quit [Remote host closed the connection]
z3t0 has joined #lisp
dieggsy has quit [Ping timeout: 255 seconds]
Chream_ has quit [Ping timeout: 260 seconds]
drewc has joined #lisp
<pjb> iqubic: first it should be noted that APPLY and FUNCALL take function designators, so if the symbol and the function designate the same function, quote and function will be equivalent in the sense that the same function will be called.
<pjb> iqubic: and in the case of functions from the CL package, they will always designate the same function!
<pjb> iqubic: however, for other symbols, (not from CL), they may deisgnate different functions!
fikka has joined #lisp
<pjb> iqubic: a symbol will always designate the global function binding, ie. the function obtained by (symbol-function symbol).
<pjb> iqubic: however, the function special operator is the (only) closure creator operator, and it may create closures of locally bound functions.
<pjb> iqubic: therefore: (defun foo () 'global) (mapcar 'funcall (flet ((foo () 'local)) (list (quote foo) (function foo)))) #| --> (global local) |#
<pjb> and also: (flet ((foo () 'local)) (mapcar 'funcall (list (quote foo) (function foo)))) #| --> (global local) |#
<pjb> In such cases, you would have to choose between quote and function depending on WHAT YOU MEAN!
nowhereman_ has joined #lisp
<pjb> iqubic: other characteristic properties of symbols and functions, is that since symbols, as function designators, are resolved only when used, when the function needs to be called, if the function is redefined (at run-time), then the symbol will designate the new version. While function returns the actual closure object, if the fbinding is redefined, the function object will still be the old one.
<pjb> (let ((funs (list (quote foo) (function foo)))) (list (mapcar 'funcall funs) (setf (symbol-function 'foo) (lambda () 'redefined)) (mapcar 'funcall funs) )) #| --> ((global global) #<Anonymous Function #x30200499B92F> (redefined global)) |#
<pjb> So again, choose between the symbol and the function, depending on the meaning you mean!
dddddd has quit [Remote host closed the connection]
nowhere_man has quit [Ping timeout: 256 seconds]
wigust has joined #lisp
asarch has quit [Quit: Leaving]
compro has joined #lisp
lnostdal has joined #lisp
oleo has quit [Quit: Leaving]
z3t0 has quit [Remote host closed the connection]
z3t0 has joined #lisp
pierpa has quit [Quit: Page closed]
z3t0 has quit [Ping timeout: 268 seconds]
ak5 has joined #lisp
damke has joined #lisp
<iqubic> Isn't there a difference between the literal value of a symbol, and the function-value?
damke_ has quit [Ping timeout: 264 seconds]
fikka has quit [Ping timeout: 256 seconds]
<beach> iqubic: Try it out at the REPL. I don't know what you mean by "literal value", so I can't try it out for you, but you must know what you mean yourself, so just type the form (EQ ? ?) and see the result.
<beach> .. where the first ? is the "literal value" and the second ? is the function value.
<emaczen`> (sb-ext:run-program "prog-name" (list "name" "--dynamic-space-size" "4096")) -- is this the correct way to pass command line arguments?
fikka has joined #lisp
wxie has joined #lisp
<jackdaniel> emaczen`: yes
<jackdaniel> if prog-name is not absolute path you may want to add also :search t
<emaczen`> I'm printing out the dynamic-space-size from the external program and it is the default 1 GB...
Ukari has quit [Quit: bye bye]
<iqubic> beach: I was confusing symbol-function with symbol-value.
<emaczen`> any idea why the dynamic-space-size argument is not getting picked up?
<iqubic> Which are rather different I assume.
wxie has quit [Ping timeout: 265 seconds]
z3t0 has joined #lisp
<jackdaniel> emaczen`: sbcl options come *after* custom ones
<jackdaniel> what is the "name" parameter?
<emaczen`> Isn't that after?
<emaczen`> Or do you mean before?
<emaczen`> the "name" parameter is needed for my external program
<jackdaniel> emaczen`: compare `sbcl --dynamic-space-size 4096 --eval "(print (sb-ext:dynamic-space-size))"` in the repl with `sbcl foo --dynamic-space-size 4096 --eval "(print (sb-ext:dynamic-space-size))"` (likewise)
<jackdaniel> `sbcl --dynamic-space-size 4096 --eval "(print (sb-ext:dynamic-space-size))" program-name ` should work though
<iqubic> What is the difference between set and setf?
<jackdaniel> iqubic: ↑
<jackdaniel> iqubic: generally a good resource to look up things is l1sp.org
<jackdaniel> it searches in many sources (pcl, clhs, clim spec, clx etc)
<emaczen`> jackdaniel: I see... that is kinda lame, I would have never figured that out myself
<emaczen`> the looked in the SBCL docs for run-program too
<jackdaniel> heh
<emaczen`> isn't set for property-lists of a symbol?
<jackdaniel> quoting from the spec: (set symbol value) == (setf (symbol-value symbol) value)
<jackdaniel> so i *foo* has a value *bar*, then (set *foo* 3) will be (setf *bar* 3)
<iqubic> can you do (setf (symbol-value symbol) value)?
<iqubic> or does that make no sense?
<loke> iqubic: Yes. ANd it makes sense.
<jackdaniel> iqubic: if it is qouted in the linked example, then why not? I highly recommend reading both linked pages and if you still have questions *after that* asking them here :)
<iqubic> What is the difference between (symbol-value symbol) and ('symbol) ?
<beach> iqubic: clhs symbol-value
<beach> clhs symbol-value
<beach> iqubic: See that page ↑
<beach> iqubic: See how it says "Accessor"?
<beach> iqubic: That means that you can use it with SETF.
<beach> iqubic: Do you still not have a REPL?
<iqubic> I have a repl. I just don't know how to use it to answer these questions.
<beach> iqubic: Do you know what the quote character means? If not, you definitely need to take a break and go read a book.
<iqubic> I know what the quote character means.
<beach> iqubic: Tell me, please.
<iqubic> ('symbol) is the syntax. ' is a reader macro that expands to the function (quote symbol) which returns the symbol exactly as it is, with out evaluation
<beach> So what does the reader return when it sees ('symbol)?
<iqubic> It returns symbol, exactly as it is. No evaluation is done at all. ('symbol) => symbol.
<beach> THE READER, not the evaluator.
<beach> What does THE READER return.
dec0n has joined #lisp
<emaczen`> I'm running (sb-ext:run-program ...) but when the external sbcl program's heap becomes exhausted I am dropped into ldb. I just want to exit from this and for my main program to continue.
smasta has quit [Ping timeout: 260 seconds]
<beach> iqubic: If the reader return (quote <something>) when it sees '<something>, then what does it return when it sees ('<something>)?
<iqubic> according to my repl the reader returns ('symbol)
<emaczen`> I want this to be done programmtically of course
sz0 has joined #lisp
shka has quit [Ping timeout: 248 seconds]
<beach> iqubic: Answer my question please.
Karl_Dscc has joined #lisp
<iqubic> Or wait, I was reading the input as if it were the output. When the reader sees ('symbol) it returns ((quote symbol))
<beach> Right.
fikka has quit [Ping timeout: 256 seconds]
red-dot has joined #lisp
<beach> So, in your opinion, what case applies if you look at 3.1.2.1?
<beach> clhs 3.1.2.1
<beach> iqubic: 3.1.2.1.1, 3.1.2.1.2, or 3.1.2.1.3?
<jackdaniel> emaczen`: non-trivial - when sbcl drops into ldb process doesn't exit whatsoever
<iqubic> I think the answer is 3.1.2.1.1 but I'm not too sure.
<jackdaniel> maybe wrapping your program in handler-case and catchin heap exhausted (and exitting application) would do what you want
<beach> iqubic: So you don't know that (<something>) is a CONS?
<beach> iqubic: Then you have to go read a book on Common Lisp.
<emaczen`> jackdaniel: I'm not aware of any heap exaustion condition?
<iqubic> I don't know that. You are right.
<iqubic> I am still very much a beginner.
<iqubic> I should go kill myself
<jackdaniel> minion: tell iqubic about pcl
<minion> iqubic: direct your attention towards pcl: pcl-book: "Practical Common Lisp", an introduction to Common Lisp by Peter Seibel, available at http://www.gigamonkeys.com/book/ and in dead-tree form from Apress (as of 11 April 2005).
<beach> That I have figured out. What I haven't figured out is why you prefer asking trivial questions in #lisp (which is not a Common Lisp support channel) rather than reading a book.
<jackdaniel> emaczen`: I'm not sure if there is such thing in sbcl
<emaczen`> ccl?
<jackdaniel> emaczen`: OK, I know: try --disable-ldb
<iqubic> for some reason I think that a thing is only a cons if it is a list.
<jackdaniel> then your program will simply crash if heap is exhausted
<iqubic> I don't think that a function application is a list, is it?
<emaczen`> jackdaniel: alright, I am trying it out
<jackdaniel> lmk if it worked
<beach> emaczen`: Such a condition would be hard to implement. I mean, if the heap is exhausted, how does it allocate space for the condition instance? And what would you do when it is signaled? Examine the stack? That requires form evaluation, taking up even more heap space.
<iqubic> am I right? or am I just barking up the wrong tree?
<jackdaniel> beach: ECL has a safety preallocated heap space for such situations
<beach> jackdaniel: I can imagine.
<emaczen`> jackdaniel: It worked, it just kept continuing
<jackdaniel> cool
<beach> iqubic: Yes, (consp object) implies (listp object), but not the other way around.
<beach> clhs cons
<beach> iqubic: See the "system class" entry?
<emaczen`> jackdaniel: Yep! thanks, now I can go to bed and my program should run all night, and I don't have to be here to restart it when it drops into ldb!
smurfrobot has quit [Remote host closed the connection]
<beach> It says that the precedence list is cons, list, sequence, t.
<beach> iqubic: That means a cons is a list, a list is a sequence, and a sequence is a t.
<jackdaniel> emaczen`: good night then :)
guna_ has quit [Ping timeout: 248 seconds]
<emaczen`> jackdaniel: hah not quite yet, but I am happy
igemnace has joined #lisp
kini has quit [Quit: No Ping reply in 180 seconds.]
sunwukong has joined #lisp
<pjb> iqubic: again, it depends on what the symbol designates.
<pjb> iqubic: if the symbol designates a lexical variable, then its value will be different from (symbol-value symbol).
<pjb> iqubic: on the other hand, if it designates a dynamic variable, then its value will be that of (symbol-value symbol).
<pjb> (let ((foo 42)) (list foo (and (boundp 'foo) (symbol-value 'foo)))) #| --> (42 nil) |#
<pjb> (let ((foo 42)) (declare (special foo)) (list foo (and (boundp 'foo) (symbol-value 'foo)))) #| --> (42 42) |#
<pjb> iqubic: just read chapter 3!
aindilis has joined #lisp
<z3t0> I have some code and am wondering what is the best way to return the object at data from this function
didi has left #lisp ["there are always reasons to /part"]
<z3t0> I understand that let returns the value of its final form, except the final form in this case must be closing the file
orivej has quit [Ping timeout: 252 seconds]
guna has joined #lisp
sfa has quit [Quit: leaving]
fourier has joined #lisp
Chream has joined #lisp
<pjb> z3t0: use with-open-file
<z3t0> pjb: oh... that was obvious :)
<pjb> z3t0: otherwise, there are prog1 and prog2.
<pjb> clhs prog1
<pjb> and unwind-protect
<pjb> clhs unwind-protect
selesdepselesnul has joined #lisp
fikka has joined #lisp
<z3t0> thank you
flamebeard has joined #lisp
vlatkoB has joined #lisp
kini has joined #lisp
Kaisyu has quit [Quit: Connection closed for inactivity]
fikka has quit [Ping timeout: 276 seconds]
selesdepselesnul has quit [Quit: Leaving]
LocaMocha has joined #lisp
LocaMocha has quit [Max SendQ exceeded]
fikka has joined #lisp
LocaMocha has joined #lisp
igemnace has quit [Quit: WeeChat 2.0.1]
fourier has quit [Ping timeout: 240 seconds]
Karl_Dscc has quit [Remote host closed the connection]
Tobbi has joined #lisp
igemnace has joined #lisp
ak5 has quit [Ping timeout: 252 seconds]
makomo has quit [Ping timeout: 256 seconds]
smurfrobot has joined #lisp
Arcaelyx has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
beach has quit [Ping timeout: 256 seconds]
damke_ has joined #lisp
smasta has joined #lisp
damke has quit [Ping timeout: 264 seconds]
smurfrobot has quit [Ping timeout: 256 seconds]
deng_cn has quit [Read error: Connection reset by peer]
deng_cn has joined #lisp
emaczen` has quit [Ping timeout: 252 seconds]
emaczen` has joined #lisp
dtornabene has quit [Quit: Leaving]
scymtym has quit [Ping timeout: 240 seconds]
didi has joined #lisp
varjag has joined #lisp
fikka has quit [Ping timeout: 268 seconds]
solyd has joined #lisp
Cymew has joined #lisp
hiroaki has joined #lisp
ozzloy has joined #lisp
ozzloy has joined #lisp
z3t0 has quit [Remote host closed the connection]
shrdlu68 has joined #lisp
z3t0 has joined #lisp
mingus has quit [Remote host closed the connection]
fikka has joined #lisp
z3t0 has quit [Ping timeout: 256 seconds]
itruslove has quit [Remote host closed the connection]
giraffe has quit [Remote host closed the connection]
smasta has quit [Ping timeout: 265 seconds]
smokeink has joined #lisp
_main_ has joined #lisp
mlf has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
__main__ has quit [Ping timeout: 240 seconds]
_main_ is now known as __main__
smokeink has quit [Remote host closed the connection]
fikka has quit [Quit: leaving]
smokeink has joined #lisp
fikka has joined #lisp
heisig has joined #lisp
__main__ has quit [Read error: Connection reset by peer]
damke has joined #lisp
__main__ has joined #lisp
_mjl has joined #lisp
beach has joined #lisp
milanj has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
FreeBirdLjj has quit [Remote host closed the connection]
SAL9000 has quit [Quit: ZNC - http://znc.in]
SAL9000 has joined #lisp
mishoo_ has joined #lisp
sjl__ has joined #lisp
sjl__ has quit [Ping timeout: 240 seconds]
fikka has quit [Ping timeout: 255 seconds]
scymtym has joined #lisp
johnnymacs has joined #lisp
quazimodo has quit [Ping timeout: 248 seconds]
<johnnymacs> How can I compile common lisp to webassembly?
smurfrobot has joined #lisp
<Shinmera> You cannot.
<Shinmera> Unless you write a compiler that does it.
<jackdaniel> building interpreter is an option too
<johnnymacs> Well anything that can be compiled to llvm should be compileable to webasm
<Shinmera> It's not that easy.
<jackdaniel> johnnymacs: if there is gcc which can produce webassembly binaries, you could compile ecl or clisp
<jackdaniel> or clang whatsoever
Murii has joined #lisp
<Shinmera> Anyway, good luck shipping like 10-20mb of wasm CL runtime or whatnot to run your few kilobytes of actual CL code.
<jackdaniel> for instance there were builds of ECL to NaCL and pNaCL (obsolete chrome runtimes)
<didi> How do I write a `check-type' that accepts both 'eq and #'eq?
lerax has joined #lisp
<Shinmera> didi: (or symbol function), if you're talking about any function, and not specifically eq.
<jackdaniel> Shinmera: given wasm binaries are not much bigger than linux ones, ecl should fit in around 1mb, what is comparable to some js scripts I saw in production
z3t0 has joined #lisp
<lerax> If someone have interest in Propositional Logic, I've been written this library with some efforts: https://github.com/ryukinix/lisp-inference
<didi> Shinmera: Thanks, but I'm specifically talking about eq. Actually, eq, eql, equal, and equalp.
<jackdaniel> not that I think its a good idea, but if its more a project for fun - why not
<jackdaniel> s/its/it's/
<Shinmera> didi: A type check is not what you want.
<didi> Shinmera: I see.
damke_ has joined #lisp
<johnnymacs> emscripten has emcc
<Shinmera> didi: Try (assert (or (eq thing 'eq) (eq thing #'eq)))
<johnnymacs> so I can compile c programs with it
<didi> Shinmera: Thank you.
<jackdaniel> then if you have time and resolve try compiling ecl and clisp and see how far you can get ;)
damke has quit [Ping timeout: 264 seconds]
z3t0 has quit [Ping timeout: 265 seconds]
<|3b|> (check-type x (member eq #.#'eq)) ?
<Shinmera> Euch
<didi> |3b|: Uh, that might work.
<Shinmera> Anyway, checking a value for a certain... well, value, with a type, seems just plain wrong to me
<|3b|> check-type lets you replace the value, so assert isn't quite the same thing
<didi> Shinmera: Use case: I have a data structure that uses only eq, eql, equal, or equalp as a test.
<didi> I want to put some speed bumps at the external API.
<didi> Something more than a reminder inside the docstring.
<heisig> lerax: This is a nice little project. Since you decided to represent statements as lists, have you considered using DEFSTRUCT with (:type list)? Then you get accessors and predicates for free.
fikka has joined #lisp
<lerax> This a old project that I'm re-touching this again now. Probably I'll define later better data-structures for this. On those days, I just was trying getting fun with propositional logic and Lisp. Later that I read some books... well, things changed. Yes, I need review that.
smasta has joined #lisp
<beach> johnnymacs: Even if you manage to translate Common Lisp to webassembly, you still need a complete Common Lisp system in the target (I assume a browswer), including all the "library" functions, the memory manager, etc.
<lerax> But I don't have sure if defstruct for this specific problem is a good idea because in general manipulating lists sometimes is basic always I need to parsing logic statements... but well, maybe with defstruct I can reduce the verbosity.
hhdave has joined #lisp
<beach> lerax: With standard classes, perhaps even more.
<heisig> lerax: Yes, listen to beach.
<beach> Heh, thanks!
<heisig> lerax: Unless you are under severe performance constraints and know what you are doing, represent your data with CLOS.
fikka has quit [Ping timeout: 240 seconds]
smasta has quit [Ping timeout: 256 seconds]
<lerax> Thanks for all the advices : D
<beach> Anytime.
z3t0 has joined #lisp
rapidshot64 is now known as kozy
_cosmonaut_ has joined #lisp
z3t0 has quit [Ping timeout: 248 seconds]
d4ryus1 is now known as d4ryus
z3t0 has joined #lisp
_main_ has joined #lisp
pfdietz has quit [Ping timeout: 255 seconds]
__main__ has quit [Ping timeout: 276 seconds]
_main_ is now known as __main__
z3t0 has quit [Ping timeout: 260 seconds]
pfdietz has joined #lisp
__main__ has quit [Read error: Connection reset by peer]
__main__ has joined #lisp
smurfrobot has quit [Remote host closed the connection]
daydayup_ has joined #lisp
smurfrobot has joined #lisp
fikka has joined #lisp
smurfrobot has quit [Ping timeout: 256 seconds]
smurfrobot has joined #lisp
z3t0 has joined #lisp
orivej has joined #lisp
z3t0 has quit [Remote host closed the connection]
daydayup__ has joined #lisp
z3t0 has joined #lisp
z3t0 has quit [Remote host closed the connection]
z3t0 has joined #lisp
daydayup_ has quit [Ping timeout: 256 seconds]
smasta has joined #lisp
jameser has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
smasta has quit [Ping timeout: 240 seconds]
z3t0 has quit [Remote host closed the connection]
red-dot has quit [Quit: Going offline, see ya! (www.adiirc.com)]
daydayup__ has quit [Ping timeout: 260 seconds]
z3t0 has joined #lisp
sukaeto has quit [Ping timeout: 256 seconds]
sjl__ has joined #lisp
z3t0 has quit [Ping timeout: 260 seconds]
sjl__ has quit [Ping timeout: 264 seconds]
makomo has joined #lisp
zooey has quit [Remote host closed the connection]
zooey has joined #lisp
solyd has quit [Quit: solyd]
python476 has joined #lisp
solyd has joined #lisp
smurfrobot has quit [Remote host closed the connection]
nika has quit []
binghe has joined #lisp
sukaeto has joined #lisp
binghe changed the topic of #lisp to: Common Lisp, the #1=(programmable . #1#) programming language <http://cliki.net/> logs:<https://irclog.whitequark.org/lisp, http://ccl.clozure.com/irc-logs/lisp/> | SBCL 1.4.0, CMUCL 21b, ECL 16.1.3, CCL 1.11.5
_death has joined #lisp
didi has left #lisp ["there are always reasons to /part"]
smasta has joined #lisp
damke has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
wigust has quit [Ping timeout: 240 seconds]
smurfrobot has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has joined #lisp
Xal has quit [Ping timeout: 256 seconds]
smasta has quit [Ping timeout: 256 seconds]
attila_lendvai has quit [Read error: Connection reset by peer]
Xal has joined #lisp
attila_lendvai has joined #lisp
makomo has quit [Quit: WeeChat 1.9.1]
attila_lendvai has quit [Read error: Connection reset by peer]
attila_lendvai has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has quit [Changing host]
markong has joined #lisp
attila_lendvai has quit [Read error: Connection reset by peer]
attila_lendvai has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has quit [Changing host]
Xal has quit [Ping timeout: 260 seconds]
igemnace has quit [Quit: WeeChat 2.0.1]
Xal has joined #lisp
attila_lendvai has quit [Read error: Connection timed out]
attila_lendvai has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has quit [Changing host]
smurfrobot has quit [Remote host closed the connection]
nirved has joined #lisp
EvW1 has joined #lisp
thinkpad has quit [Quit: lawl]
mjl has quit []
thinkpad has joined #lisp
attila_lendvai has quit [Read error: Connection reset by peer]
wigust has joined #lisp
mjl has joined #lisp
smurfrobot has joined #lisp
milanj has quit [Quit: This computer has gone to sleep]
thinkpad has quit [Client Quit]
attila_lendvai has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has quit [Changing host]
jameser has joined #lisp
attila_lendvai has quit [Read error: Connection reset by peer]
smasta has joined #lisp
attila_lendvai has joined #lisp
fikka has quit [Ping timeout: 256 seconds]
attila_lendvai has quit [Read error: Connection reset by peer]
m00natic has joined #lisp
splittist has quit []
splittist has joined #lisp
attila_lendvai has joined #lisp
smasta has quit [Ping timeout: 260 seconds]
attila_lendvai has quit [Read error: Connection reset by peer]
jameser has quit [Ping timeout: 240 seconds]
attila_lendvai has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has quit [Changing host]
jameser has joined #lisp
attila_lendvai has quit [Read error: Connection reset by peer]
<flip214> binghe: SBCL is released as 1.4.4 already...
thinkpad has joined #lisp
fikka has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has quit [Changing host]
Devon has joined #lisp
fikka has quit [Ping timeout: 248 seconds]
<Xach> how time flies
fikka has joined #lisp
<TMA> time flies like an arrow.
<Shinmera> TMA: because it hits you in the end?
<flip214> "banana flies like a fruit", is that the correct second part of the quote?
orivej has quit [Ping timeout: 248 seconds]
attila_lendvai has quit [Read error: Connection reset by peer]
<beach> "fruit flies like a banana", but there are actually many more ways of parsing that sentence. It could mean "please measure the time that flies take, just the way that you would measure the time an arrow takes".
attila_lendvai has joined #lisp
<beach> Or "please measure the time that flies take, just the way an arrow would measure the time that flies take".
milanj has joined #lisp
Murii has quit [Ping timeout: 240 seconds]
dec0n has quit [Quit: Leaving]
karswell_ has quit [Read error: Connection reset by peer]
iqubic` has joined #lisp
karswell_ has joined #lisp
nowhereman_ has quit [Ping timeout: 248 seconds]
iqubic has quit [Ping timeout: 265 seconds]
moei has joined #lisp
nullman has quit [Ping timeout: 240 seconds]
nullman has joined #lisp
gz_ has quit []
gz_ has joined #lisp
alms_clozure has quit []
alms_clozure has joined #lisp
loli has quit [Ping timeout: 252 seconds]
arbv has quit [Ping timeout: 252 seconds]
red-dot has joined #lisp
arbv has joined #lisp
smasta has joined #lisp
solyd has quit [Quit: solyd]
damke_ has joined #lisp
solyd has joined #lisp
smasta has quit [Ping timeout: 240 seconds]
rumbler31 has quit [Remote host closed the connection]
damke has quit [Ping timeout: 264 seconds]
anaumov has quit [Remote host closed the connection]
deng_cn has quit [Read error: Connection reset by peer]
<shrdlu68> I have a couple of inline functions and slime's compiler notes are confusing.
shifty has quit [Ping timeout: 268 seconds]
deng_cn has joined #lisp
aindilis has quit [Remote host closed the connection]
<shrdlu68> What does it mean when a whole function call is underlined? As is _(foo bar bar)_
nowhereman_ has joined #lisp
<flip214> shrdlu68: what does the note say?
<flip214> perhaps that call wasn't inlined because the function definition wasn't available yet.
dddddd has joined #lisp
Murii has joined #lisp
<shrdlu68> "The first argument is a T, not a FIXNUM"
kundry_wag has joined #lisp
kundry_wag has quit [Client Quit]
aindilis has joined #lisp
EvW1 has quit [Ping timeout: 276 seconds]
<shrdlu68> flip214: https://imgur.com/a/HZ03y
<|3b|> well, can't be much more specific than that, somewhere in the inlined code it didn't know the type of the first argument of something
<|3b|> *it can't
<|3b|> (there could be multiple calls to same inlined function with different notes, do it can't really point you at the original source either)
<|3b|> if you look at the repl, i think it might try to give you more info
FreeBirdLjj has joined #lisp
makomo has joined #lisp
danlentz has quit []
mbrock has quit []
danlentz has joined #lisp
mbrock has joined #lisp
EvW has joined #lisp
<shrdlu68> |3b|: I would expect it to issue the compiler note when I compile the inlined function itself in that case.
billstclair has quit []
billstclair has joined #lisp
<Shinmera> When it inlines it, well, inlines the code, which will lead to different inferences.
orivej has joined #lisp
<|3b|> yeah, inlining wouldn't be as much use if it didn't change that sort of thing :)
<Shinmera> For instance (defun foo (a) (typecase a (integer 1) (character 2))) (defun bar () (foo 0)) is going to eliminate the useless branch if foo is inlined.
jeremyheiler has quit []
<Shinmera> The optimisation constraints of the inliner are also going to affect the inlinee code.
jeremyheiler has joined #lisp
<Shinmera> So optimisation notes that you didn't see for the inlinee might start showing up.
lambda-p has joined #lisp
Chream has quit [Ping timeout: 260 seconds]
XachX has quit []
XachX has joined #lisp
<shrdlu68> I see.
attila_lendvai has quit [Quit: Leaving.]
<Shinmera> In the most basic sense think of inlining as copy-pasting the code before compiling for real.
solyd has quit [Quit: solyd]
_cosmonaut_ has quit [Ping timeout: 255 seconds]
arbv has quit [Ping timeout: 256 seconds]
arbv has joined #lisp
dec0n has joined #lisp
asarch has joined #lisp
dec0n has quit [Remote host closed the connection]
EvW has quit [Ping timeout: 265 seconds]
azahi has quit [Changing host]
azahi has joined #lisp
red-dot has quit [Read error: Connection reset by peer]
red-dot has joined #lisp
jameser_ has joined #lisp
Murii has quit [Ping timeout: 256 seconds]
jameser has quit [Ping timeout: 255 seconds]
smasta has joined #lisp
_cosmonaut_ has joined #lisp
smasta has quit [Ping timeout: 256 seconds]
Bike has joined #lisp
<shrdlu68> How do I fix "Unable to optimize because Upgraded element type of array is not known at compile time"
oleo has joined #lisp
<Bike> tell it the uaet at compile time
<Bike> like by a type declaration
<shrdlu68> (make-array 2 :element-type 'fixnum :initial-contents '(1 0))
<Bike> that's the type of the array you make, but that note is about access
<Bike> i don't know what your code looks like, but sbcl might not be smart enough to guess the element type at the access point based on that
<shrdlu68> Oh, okay - so a thing like (the fixnum (aref...)
<shrdlu68> Ought to fix it?
<Bike> more like (aref (the (simple-array fixnum) ...) ...)
rumbler31 has joined #lisp
<Bike> i'd just DECLARE the type, if possible, though
<shrdlu68> Got it.
EvW1 has joined #lisp
<Bike> a form being underlined just means that there's a note or warning or whatever about it, btw
<Shinmera> you can also hover over the underlining with your mouse and it should display the note
Chream_ has joined #lisp
itruslove has joined #lisp
dec0n has joined #lisp
dec0n has quit [Client Quit]
giraffe has joined #lisp
jameser_ has quit [Remote host closed the connection]
jameser has joined #lisp
SamSkulls has joined #lisp
lambda-p has quit [Remote host closed the connection]
random-nick has joined #lisp
fikka has quit [Ping timeout: 264 seconds]
fikka has joined #lisp
LiamH has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
sunwukong has quit [Quit: WeeChat 0.4.2]
sunwukong has joined #lisp
damke_ has joined #lisp
_cosmonaut_ has quit [Quit: Leaving.]
_cosmonaut_ has joined #lisp
smokeink has quit [Ping timeout: 240 seconds]
_cosmonaut_ has quit [Remote host closed the connection]
smasta has joined #lisp
_cosmonaut_ has joined #lisp
lambda-p has joined #lisp
Poeticold is now known as Poeticode
fikka has quit [Ping timeout: 248 seconds]
smasta has quit [Ping timeout: 260 seconds]
makomo has quit [Ping timeout: 256 seconds]
heisig has quit [Quit: Leaving]
EvW1 has quit [Remote host closed the connection]
EvW has joined #lisp
antgreen has joined #lisp
fikka has joined #lisp
aindilis has quit [Remote host closed the connection]
warweasle has joined #lisp
aindilis has joined #lisp
rumbler3_ has joined #lisp
jameser has quit [Ping timeout: 255 seconds]
makomo has joined #lisp
jameser has joined #lisp
EvW has quit [Ping timeout: 255 seconds]
rumbler3_ has quit [Ping timeout: 255 seconds]
fikka has quit [Ping timeout: 268 seconds]
nika has joined #lisp
Josh_2 has joined #lisp
fluxit has quit [Max SendQ exceeded]
fluxit has joined #lisp
pjb has quit [Ping timeout: 240 seconds]
pjb has joined #lisp
antgreen has quit [Ping timeout: 240 seconds]
zaquest has quit [Quit: Leaving]
zaquest has joined #lisp
scymtym has quit [Ping timeout: 265 seconds]
* Xach looks around for AccelerationNetters
papachan has quit [Quit: WeeChat 2.0.1]
binghe has quit [Ping timeout: 248 seconds]
aindilis has quit [Remote host closed the connection]
fikka has joined #lisp
CrazyEddy has quit [Ping timeout: 248 seconds]
binghe has joined #lisp
aindilis has joined #lisp
TCZ has joined #lisp
Cymew has quit [Remote host closed the connection]
Cymew has joined #lisp
smasta has joined #lisp
deng_cn has quit [Read error: Connection reset by peer]
deng_cn has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
damke_ has joined #lisp
Cymew has quit [Ping timeout: 276 seconds]
smasta has quit [Ping timeout: 256 seconds]
Cymew has joined #lisp
solyd has joined #lisp
lambda-p has quit [Remote host closed the connection]
solyd has quit [Client Quit]
Cymew has quit [Ping timeout: 264 seconds]
daydayup has joined #lisp
Cymew has joined #lisp
binghe has quit [Ping timeout: 276 seconds]
asarch has quit [Ping timeout: 248 seconds]
daydayup_ has joined #lisp
Cymew has quit [Ping timeout: 256 seconds]
daydayup has quit [Ping timeout: 264 seconds]
CrazyEddy has joined #lisp
papachan has joined #lisp
Cymew has joined #lisp
warweasle has quit [Quit: rcirc on GNU Emacs 24.4.1]
nowhereman_ has quit [Ping timeout: 256 seconds]
papachan has quit [Client Quit]
Cymew has quit [Ping timeout: 240 seconds]
daydayup_ has quit [Ping timeout: 264 seconds]
SaganMan has joined #lisp
Cymew has joined #lisp
FreeBirdLjj has quit [Remote host closed the connection]
Arcaelyx has joined #lisp
fikka has quit [Ping timeout: 265 seconds]
papachan has joined #lisp
Cymew has quit [Ping timeout: 240 seconds]
fikka has joined #lisp
FreeBirdLjj has joined #lisp
Cymew has joined #lisp
compro has quit [Ping timeout: 240 seconds]
raynold has quit [Quit: Connection closed for inactivity]
Cymew has quit [Ping timeout: 260 seconds]
rippa has joined #lisp
FreeBirdLjj has quit [Ping timeout: 260 seconds]
fluxit has quit [Max SendQ exceeded]
red-dot has quit [Quit: Going offline, see ya! (www.adiirc.com)]
fluxit has joined #lisp
FreeBirdLjj has joined #lisp
varjag has quit [Quit: ERC (IRC client for Emacs 24.5.1)]
FreeBirdLjj has quit [Ping timeout: 255 seconds]
fikka has quit [Ping timeout: 260 seconds]
<flip214> Does anyone know when ELS registration starts?
Karl_Dscc has joined #lisp
asarch has joined #lisp
<Shinmera> Soon™
<Shinmera> Still working on the actual registration page
fikka has joined #lisp
<flip214> ah, thanks a lot!
<beach> flip214: Do you have your travel organized yet?
<Shinmera> flip214: You can follow development here https://github.com/european-lisp-symposium/els-web
<flip214> beach: I'm afraid that HR will do that for me if I don't intervene soon ;/
flamebeard has quit [Quit: Leaving]
<flip214> Shinmera: no code left over from last years' registration pages?
<Shinmera> last year still used the old website
<Shinmera> and I'm frankly disgusted by what a mess that was
<flip214> yeah, so it's not coding per se but data entry?
<beach> flip214: I see, yes.
<Shinmera> No, I'm developing a new registration process.
<Shinmera> Previously you had to manually make a payment via bank transfer.
fikka has quit [Ping timeout: 276 seconds]
<beach> And now?
<Shinmera> Now you'll be able to either do that, or pay with credit card.
<Shinmera> via Stripe.
FreeBirdLjj has joined #lisp
<beach> OK. I prefer the bank transfer, since I already have the IBAN registered.
<Shinmera> The latter being preferable because it means all your data will be automatically recorded with the transaction.
deng_cn has quit [Read error: Connection reset by peer]
TCZ has quit [Quit: Leaving]
<Shinmera> And thus requires zero manual labour
<Shinmera> The bank transfer stuff is annoying because it means someone has to manually confirm that you are you and that you paid your registration.
warweasle has joined #lisp
<flip214> no CSV export of the transactions that could be matched up?
<flip214> *automatically matched up
<Shinmera> I don't know what Didier does with his bank stuff and don't think it's my business either.
<Shinmera> What I can do is offer CC payment which should be more convenient for both payer and payee.
<flip214> understood
<Shinmera> Since it's a single flow integrated into the registration form.
deng_cn has joined #lisp
fikka has joined #lisp
<flip214> is there some easy way to tag strings as different classes? like firstname, surname, street, etc.
<flip214> a simple (DEFCLASS name (STRING)) doesn't work, of course (invalid superclasS)
<Shinmera> There is not.
<flip214> thanks
<Shinmera> Plus it sounds redundant.
<Shinmera> Or rather, backwards
<Shinmera> Whether a string is a name, street, or whatever depends on who looks at it, so that information should be encoded in the container.
<Shinmera> eg (registration () (name street email))
<Shinmera> *defclass
<flip214> well, currently I'm storing a list of strings (just to print them out in the same order again)
<flip214> but now I need to filter based on parsed "type"
hiroaki has quit [Ping timeout: 276 seconds]
damke_ has quit [Ping timeout: 264 seconds]
FreeBirdLjj has quit [Ping timeout: 268 seconds]
damke has joined #lisp
solyd has joined #lisp
compro has joined #lisp
<_death> one way is to use a weak-key hash table for the mapping
scymtym has joined #lisp
FreeBirdLjj has joined #lisp
<Shinmera> Or don't store a list of strings, but a list of compund objects that carry that associated information
<_death> yep
Arcaelyx has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<_death> since strings aren't usually used for their identity the hash-table solution could be fragile
<flip214> Shinmera: yeah, that's what I'm doing now... is there a way to embed the string structure in my class slot and not have another indirection, to conserve memory?
<Shinmera> A string indirection is free as long as the type is known as the header will just be a constant offset to the contents.
<Shinmera> At least, if it's a simple-string.
<Shinmera> Either way
<Shinmera> are you sure you need to optimise right now?
SaganMan has quit [Quit: WeeChat 1.6]
<flip214> I already ran into memory limits quite a few times for that, so yes
<Shinmera> Just increase the heap
<flip214> Shinmera: yeah, thanks, did that already. 16GB (minus OS etc.) is too small.
<Shinmera> Yeesh. What are you even processing?
binghe has joined #lisp
rumbler3_ has joined #lisp
<flip214> one of the input files is 19M lines, each being parsed into multiple items... so 2 tagged-strings in a line would be 2*16 byte (?) for the indirection
<flip214> or 32*20M ~ 640MB just for that indirection
jmercouris has joined #lisp
<Shinmera> Well, you need to know a string's length, you can't get around that
<Shinmera> and even if you could, you cannot store raw data in a slow.
<Shinmera> *slot
<Shinmera> Besides, if you are sure you need to keep that much data around at all times (rather than, say, stream it), then classes will be too heavy anyway and you probably want structs instead.
<flip214> thanks, that's a possible optimization
<Shinmera> My advice would be to investigate other means of processing your data (stream oriented) so that you don't need that much memory to begin with.
FreeBirdLjj has quit [Ping timeout: 256 seconds]
rumbler3_ has quit [Ping timeout: 256 seconds]
deng_cn has quit [Read error: Connection reset by peer]
iqubic` is now known as iqubic
jameser has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
deng_cn has joined #lisp
compro has quit [Remote host closed the connection]
FreeBirdLjj has joined #lisp
<_death> or store offsets in memory instead of strings
fikka has quit [Ping timeout: 248 seconds]
makomo has quit [Quit: WeeChat 1.9.1]
loli has joined #lisp
mlf has joined #lisp
FreeBirdLjj has quit [Ping timeout: 265 seconds]
fikka has joined #lisp
smasta has joined #lisp
fisxoj has joined #lisp
binghe has quit [Ping timeout: 276 seconds]
smasta has quit [Ping timeout: 240 seconds]
binghe has joined #lisp
binghe has left #lisp [#lisp]
fisxoj has quit [Quit: fisxoj]
FreeBirdLjj has joined #lisp
<asarch> One stupid question: From this chapter: http://www.gigamonkeys.com/book/macros-standard-control-constructs.html
<asarch> In the DO section: "As with the variable definitions in a LET, if the init-form is left out, the variable is bound to NIL. Also as with LET, you can use a plain variable name as shorthand for a list containing just the name."
<Xach> That's not a question!
<asarch> How is this plain variable name?
<Xach> oh ok
<Xach> sorry i got impatient :(
<asarch> Mea culpa
FreeBirdLjj has quit [Ping timeout: 240 seconds]
<beach> asarch: It means you can write either (let ((x nil)) (let ((x)) ...) or (let (x) ...)
<dlowe> it means like you can do (let ((foo nil)) ...) and (let ((foo)) ...) you can also do (let (foo) ...)
<Xach> same with DO
* asarch takes notes...
<dlowe> or (do (foo) () ...)
nika has quit [Quit: Leaving...]
m00natic has quit [Remote host closed the connection]
_cosmonaut_ has quit [Remote host closed the connection]
hhdave has quit [Ping timeout: 240 seconds]
<beach> asarch: Let me take advantage of your question to point out the (moral, not semantic) difference between (let ((x nil)) (let ((x '()) and (let (x).
<beach> In the first case, you initialize x either to a Boolean false value or to some default value. It is fine to use x before assigning to it and to (conditionally) assign to it before using it, but you would not unconditionally assign to it before using it.
<beach> In the second case, you initialize x to the empty list. Again, it is fine to use x before assigning to it and to (conditionally) assign to it before using it, but you would not unconditionally assign to it before using it.
<beach> In the third case, you should unconditionally assign to it before using it.
<beach> I don't really see any use for (let ((x)), I must admit.
FreeBirdLjj has joined #lisp
<beach> I guess it could be useful in macro expansion code.
<beach> `(let ((x ,@(if ....)))
<asarch> Why I can't: (let (x 1) (...))?
<beach> Because that would be ambiguous.
<_death> you can, just write an asarch:let macro
<beach> asarch: Imagine (let (x y) ... Is that the same as (let ((x y)) or the same as (let ((x nil) (y nil))?
<asarch> I guess they actually are
<beach> are what?
<asarch> Re-define the standard LET macro _death?
<beach> asarch: You can safely forget that advice from _death. :)
<asarch> I mean, why ambiguous?
solyd has quit [Quit: solyd]
smasta has joined #lisp
<shrdlu68> asarch: Imagine the case where you want to initialize x and y to nil.
<beach> asarch: Because of what I wrote. It could either mean both X and Y to NIL, or binding X to Y.
<asarch> I see
<shrdlu68> So, you could do (let ((x nil) (y nil)) or (let (x y)
<shrdlu68> The second form would not be possible in a let form that took the form (let (x 1) (y 2)
<_death> beach: it wasn't meant as an advice, just an attitude perhaps meant for someone more experienced ;)
<shrdlu68> You'd have to always use (let (x nil) explicitly. But as _death points out, it's entirely possible to create such a let macro.
Ven`` has joined #lisp
smasta has quit [Ping timeout: 240 seconds]
FreeBirdLjj has quit [Ping timeout: 240 seconds]
<stacksmith> Alexandria's when-let compromises: if you only have a single binding, you can (when-let (a whatever) ...), and if you have multiple, it looks like (let).
<stacksmith> Mainly because when-let is generally used with a single binding...
<stacksmith> The 'founding fathers' could have gone with a lambda-list-like syntax: a name or a list containing a name and an initializer... (let (a b (c 9)) ...)
<stacksmith> Oh, they did...
<asarch> Yeah! Thank you guys
<asarch> Thank you very much :-)
<_death> stacksmith: multiple bindings for when-let is a relatively new thing
sz0 has quit [Quit: Connection closed for inactivity]
FreeBirdLjj has joined #lisp
<stacksmith> _death: I am not sure how useful they are - I always wind up with the second form needing unless, for some reason :)
<stacksmith> And start thinking about cond-let...
nowhereman_ has joined #lisp
<_death> don't think I used them.. could be once or twice
Devon has quit [Ping timeout: 240 seconds]
jmercouris has quit [Ping timeout: 276 seconds]
ig88th has quit [Ping timeout: 260 seconds]
FreeBirdLjj has quit [Ping timeout: 240 seconds]
daydayup has joined #lisp
daydayup has quit [Remote host closed the connection]
FreeBirdLjj has joined #lisp
daydayup has joined #lisp
smurfrobot has quit [Remote host closed the connection]
daydayup_ has joined #lisp
daydayup has quit [Ping timeout: 256 seconds]
fikka has quit [Ping timeout: 260 seconds]
warweasle has quit [Quit: later]
<shrdlu68> Is it safe to assume that arithmetic on rationals is slower than short floats?
<shrdlu68> ...of the same "value"
<Shinmera> Depends on your implementation and your FPU
<shrdlu68> But it's a safe assumption generally, right?
fikka has joined #lisp
FreeBirdLjj has quit [Ping timeout: 256 seconds]
daydayup_ has quit [Quit: Leaving]
<Shinmera> Rational operations typically require reduction after the actual operation, which is likely expensive
<Shinmera> So the answer is probably
<Bike> plus rationals can get bignums
<Bike> so i'd say yeah it's a reasonable assumption
nowhereman_ has quit [Remote host closed the connection]
nowhereman_ has joined #lisp
<Shinmera> Either way, usually you pick rationals for precision purposes
<Shinmera> In which case floats lose by default
raynold has joined #lisp
FreeBirdLjj has joined #lisp
smurfrobot has joined #lisp
<Bike> if you're using short floats precision can't be much of a priority, heh
smurfrobot has quit [Ping timeout: 260 seconds]
FreeBirdLjj has quit [Ping timeout: 260 seconds]
smurfrobot has joined #lisp
orivej has quit [Ping timeout: 276 seconds]
dieggsy has joined #lisp
iqubic has quit [Ping timeout: 276 seconds]
<asarch> In "(do ((n 0 (1+ n)) (cur 0 next) (next 1 (+ cur next))) ((= 10 n) cur))", is next part of the DO statement?
Xal has quit [Ping timeout: 260 seconds]
smurfrobot has quit [Ping timeout: 260 seconds]
Ven` has joined #lisp
<_death> no, it's a name of a variable, also introduced in this form
mnoonan_ has joined #lisp
<asarch> So, in "(cur 0 next)", cur = 0 and next = nil?
Ven`` has quit [Ping timeout: 248 seconds]
<_death> why nil?
<rme> If you macroexpand the do form, you'll probably clearly see what is going on.
FreeBirdLjj has joined #lisp
<_death> asarch: cur is zero in the first iteration, and then receives the value of next at the end of the iteration
<_death> you can also experiment in the repl to get intuition
<asarch> Yeah, I get 55 from SLIME
rippa has quit [Ping timeout: 248 seconds]
flak has joined #lisp
<asarch> Ok. Let's go by parts. Accordingly with the book, the general form of DO is: (do (variable-definition*) (end-test-form result-form*) statement*)
FreeBirdLjj has quit [Ping timeout: 240 seconds]
<asarch> In this expression "(do ((n 0 (1+ n)) (cur 0 next) (next 1 (+ cur next))) ((= 10 n) cur))", the (variable-defition*) part is "((n 0 (1+ n))", right?
<oleo> (do (((bla 1 (1+ bla)) (blabla.....)) ((if blablabla) result)) (body))
<oleo> no asarch
Ven` has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
FreeBirdLjj has joined #lisp
<Bike> ((n 0 (1+ n)) (cur 0 next) (next 1 (+ cur next))) are the variable definitions. (= 10 n) is the end-test-form. (cur) is the result forms.
<oleo> ya
<asarch> Thank you!
<oleo> successfull lisp covers it good
varjag has joined #lisp
aindilis has quit [Remote host closed the connection]
<oleo> wth
<oleo> i thought you'd need do* for ath
<oleo> taht*
aindilis has joined #lisp
<oleo> ah, i see it's in the update position
rumbler3_ has joined #lisp
fikka has quit [Ping timeout: 260 seconds]
<asarch> What would be the "statement*" part in the expression?
<asarch> Is it the same as "cur"?
<oleo> there's no body in that
<Bike> I think it's empty.
<oleo> jep
<oleo> it's allowed to be empty
fikka has joined #lisp
<oleo> it's for side effects
FreeBirdLjj has quit [Ping timeout: 256 seconds]
<asarch> I just added: (format t "Values: n: ~d cur: ~d next: ~d~%" n cur next)
smasta has joined #lisp
<oleo> well if the one of the variables is not what you return, but you rather accumulate in the body or so....that can be done yes
rumbler3_ has quit [Ping timeout: 264 seconds]
aindilis has quit [Remote host closed the connection]
aindilis has joined #lisp
<stacksmith> Can anyone think of a reason why SBCL compiles an extra check against structure layout when one would do? Given a structure mytype, an expression (if (mytype-p foo) 1 2) results in a double conditional, with two different things compared to <SB-KERNEL:Layout for MYTYPE>?
<Bike> what are the things?
<stacksmith> I cannot decipher the indirections. In one case it's RAX after some loadings, in the second case, an indirect DWORD PTR [RAX+17] in my case.
<Bike> well, it might be just part of the necessary procedure then.
emaczen` has quit [Quit: ERC (IRC client for Emacs 24.5.1)]
FreeBirdLjj has joined #lisp
<stacksmith> Somehow that is not very satisfying.
<_death> such a question should include the form, its disassembly, your expectations and the deviation
smasta has quit [Ping timeout: 252 seconds]
<stacksmith> _death: true enough; however, in absence of inheritance what would _ever_ be a reason to check type more than once? It is more of a philosophical question - or a puzzle if you will, as in can you think of a scenario where checking exactly twice makes sense?
<_death> it's not clear to me that it "checks twice".. I see a single call to mytype-p
<stacksmith> full optimization on...
<stacksmith> I've run across this a few times, leading me to veer away from dispatching on type and storing redundant type data in structures when optimization is necessary... But I just cannot think of a reason why...
<Bike> it sounds like you're looking at a disassembly
<Bike> it may not be checking the type more than once
<stacksmith> Bike: it compares something against the 'layout' twice, and there is an extra conditional
FreeBirdLjj has quit [Ping timeout: 268 seconds]
<Bike> i'm just saying, the assembly is nontrivial to interpret
<stacksmith> But doable to those skilled in the art.
<Bike> i'm looking at a similar diassembly. it looks like it compares with the layout, then jumps to a return if the comparison succeeds.
<stacksmith> With (speed 3)(safety 0)(debug 0)? I have 4 conditional jumps and 5 labels in my disassembly of (defun xtest (obj) (declare (optimize (speed 3) (safety 0) (debug 0))) (if (ldesc-p obj) 1 2))
<Bike> yeah, i have a couple jumps
<stacksmith> Do you have two separate comparisons against the layout?
<_death> stacksmith: the first comparison may be for the object being of the exact type mytype (the usual), the second comparison may be needed for proper subtypes..
<shrdlu68> Does anyone happen to know the hash function used by SBCL when :test = #'equal?
<Bike> there are two comparisons, yes
fourier has joined #lisp
<Bike> but it looks like it doesn't have to go through both of them for any comparison
<Bike> so it's probably something like _death said
<stacksmith> that's what I thought, but there are no subtypes, and SBCL knows that. I can see CLOS checking just in case something changes, but structs...
<Bike> you could define a new one later
<Bike> sbcl doesn't know you won't
<Bike> in the first place, is this actually a slow part of your code?
alexmlw has joined #lisp
<stacksmith> Bike: true, but structs are not generally too forward-looking in my experience, unlike CLOS.
<oleo> why are there no subtypes ?
<Bike> many kinds of redefinition are forbidden, but that doesn't change the fact that you could define a subtype
<oleo> wouldn't obj be subtype of t ?
<oleo> and the opposite of nil ?
<stacksmith> oleo: there are no subtypes of obj.
fourier has quit [Changing host]
fourier has joined #lisp
<Bike> don't worry about oleo
shka has joined #lisp
<stacksmith> Anyway - thanks, I think it makes sense.
<stacksmith> Maybe.
FreeBirdLjj has joined #lisp
<_death> (declaim (sb-ext:freeze-type mytype))
<_death> "The sb-ext:freeze-type declaration declares that a type will never change, which can make type testing (typep, etc.) more efficient for structure types."
warweasle has joined #lisp
<stacksmith> _death - bingo! Thanks.
nowhereman_ has quit [Ping timeout: 256 seconds]
FreeBirdLjj has quit [Ping timeout: 276 seconds]
random-nick has quit [Read error: Connection reset by peer]
fikka has quit [Ping timeout: 264 seconds]
fourier has quit [Remote host closed the connection]
fikka has joined #lisp
<Josh_2> Does CLX let me get the position of my mouse in my current x session or only in one created with CLX?
<flip214> Shinmera: stream oriented isn't possible, some early data might need fixing up when the later items are processed...
<flip214> the parts that can do streaming already are.
<flip214> but thanks for taking an interest!
solene has left #lisp ["Leaving"]
<Xach> Josh_2: current
<Josh_2> Thanks Xach
random-nick has joined #lisp
fikka has quit [Ping timeout: 264 seconds]
<Xach> Josh_2: when X was being specified, CL was considered very much a peer of C and other potential client languages
<Josh_2> Alrighty. I just gotta work out how to get the mouse input now.
vtomole has joined #lisp
Rawriful has joined #lisp
BitPuffin has quit [Remote host closed the connection]
smasta has joined #lisp
wigust has quit [Quit: ZNC 1.6.5 - http://znc.in]
fikka has joined #lisp
fikka has quit [Ping timeout: 248 seconds]
<Josh_2> So I downloaded CLX with quicklisp, and slime is saying that (clx:open-display .. ) isn't recognized. What's the package name?
LiamH has quit [Read error: Connection reset by peer]
<Josh_2> clx-system didn't work either
Cymew has joined #lisp
<Xach> Josh_2: clx defines a package called XLIB.
deng_cn has quit [Read error: Connection reset by peer]
<Josh_2> Alrighty thanks, that worked.
<Xach> no problem
deng_cn has joined #lisp
FreeBirdLjj has joined #lisp
Cymew has quit [Ping timeout: 248 seconds]
smasta has quit [Ping timeout: 260 seconds]
<Josh_2> I see it now at the back of the pdf manual..
Cymew has joined #lisp
LiamH has joined #lisp
smurfrobot has joined #lisp
EvW has joined #lisp
Cymew has quit [Ping timeout: 240 seconds]
Cymew has joined #lisp
FreeBirdLjj has quit [Ping timeout: 256 seconds]
smurfrobot has quit [Ping timeout: 276 seconds]
smasta has joined #lisp
z3t0 has joined #lisp
Cymew has quit [Ping timeout: 276 seconds]
z3t0 has quit [Remote host closed the connection]
Cymew has joined #lisp
<Josh_2> When (open-display .. ) asks for host it's asking for my computers hostname or localhost I assume?
<Josh_2> Darn documentation assuming I know what I'm doing
<Xach> Josh_2: in the past I've used (xlib:open-default-display) to have it try to connect to the display set in $DISPLAY
fikka has joined #lisp
<Josh_2> ahh that's probably a better way
Cymew has quit [Ping timeout: 268 seconds]
Cymew has joined #lisp
fisxoj has joined #lisp
fikka has quit [Ping timeout: 240 seconds]
<Josh_2> Finally got it. Thanks for the help
vtomole has quit [Ping timeout: 260 seconds]
Cymew has quit [Ping timeout: 240 seconds]
Cymew has joined #lisp
<Xach> No problem
fikka has joined #lisp
deng_cn has quit [Read error: Connection reset by peer]
deng_cn has joined #lisp
FreeBirdLjj has joined #lisp
Cymew has quit [Ping timeout: 260 seconds]
fikka has quit [Ping timeout: 256 seconds]
fikka has joined #lisp
fisxoj has quit [Quit: fisxoj]
FreeBirdLjj has quit [Ping timeout: 240 seconds]
fikka has quit [Ping timeout: 240 seconds]
ckonstanski has joined #lisp
fikka has joined #lisp
fikka has quit [Ping timeout: 248 seconds]
fikka has joined #lisp
<Josh_2> With X server can I create a window that is offscreen?
fikka has quit [Ping timeout: 255 seconds]
<Josh_2> Or I need to get raw mouse movement
<Josh_2> hmm
mnoonan_ has quit [Quit: Leaving]
warweasle has quit [Quit: rcirc on GNU Emacs 24.4.1]
fikka has joined #lisp
Devon has joined #lisp
smasta has quit [Ping timeout: 276 seconds]
fikka has quit [Ping timeout: 240 seconds]
Chream_2 has joined #lisp
JohnnyL has joined #lisp
smasta has joined #lisp
Chream_ has quit [Ping timeout: 268 seconds]
Chream_ has joined #lisp
Chream_2 has quit [Ping timeout: 248 seconds]
FreeBirdLjj has joined #lisp
Chream_ has quit [Ping timeout: 260 seconds]
Chream_ has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has quit [Changing host]
karswell_ has quit [Read error: No route to host]
gbyers has quit []
gbyers has joined #lisp
deng_cn has quit [Read error: Connection reset by peer]
attila_lendvai has quit [Read error: Connection reset by peer]
hiroaki has joined #lisp
FreeBirdLjj has quit [Ping timeout: 240 seconds]
deng_cn has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has quit [Changing host]
Devon has quit [Ping timeout: 252 seconds]
rme has quit []
rme has joined #lisp
nowhereman_ has joined #lisp
flak has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
nowhere_man has joined #lisp
gendl has quit []
Chream_2 has joined #lisp
gendl has joined #lisp
nowhereman_ has quit [Ping timeout: 248 seconds]
fikka has joined #lisp
Chream_ has quit [Ping timeout: 240 seconds]
pagnol has joined #lisp
sunwukong has quit [Ping timeout: 256 seconds]
FreeBirdLjj has joined #lisp
Chream_2 has quit [Ping timeout: 248 seconds]
Chream_ has joined #lisp
Josh_2 has quit [Remote host closed the connection]
shifty has joined #lisp
tobel has quit []
tobel has joined #lisp
random-nick has quit [Ping timeout: 248 seconds]
Chream_ has quit [Ping timeout: 260 seconds]
smasta has quit [Ping timeout: 248 seconds]
LiamH has quit [Quit: Leaving.]
Chream_ has joined #lisp
smurfrobot has joined #lisp
FreeBirdLjj has quit [Ping timeout: 240 seconds]
smasta has joined #lisp
python476 has quit [Ping timeout: 252 seconds]
Chream_2 has joined #lisp
milanj has quit [Quit: This computer has gone to sleep]
smurfrobot has quit [Ping timeout: 255 seconds]
Chream_ has quit [Ping timeout: 255 seconds]
pmc_ has joined #lisp
rumbler31 has quit [Ping timeout: 240 seconds]
Bike has quit [Ping timeout: 260 seconds]
FreeBirdLjj has joined #lisp
Chream_ has joined #lisp
milanj has joined #lisp
Chream_2 has quit [Ping timeout: 276 seconds]
Chream_ has quit [Ping timeout: 248 seconds]
infinisil has joined #lisp
pierpa has joined #lisp
sjl has joined #lisp
Chream_ has joined #lisp
FreeBirdLjj has quit [Ping timeout: 276 seconds]
orivej has joined #lisp
Chream_2 has joined #lisp
FreeBirdLjj has joined #lisp
Chream_ has quit [Ping timeout: 256 seconds]
shifty has quit [Ping timeout: 260 seconds]
Pixel_Outlaw has joined #lisp
FreeBirdLjj has quit [Ping timeout: 240 seconds]
attila_lendvai has quit [Read error: Connection reset by peer]
moei has quit [Quit: Leaving...]
asarch has quit [Quit: Leaving]
attila_lendvai has joined #lisp
borei has joined #lisp
<borei> hi all
Chream_ has joined #lisp
EvW has quit [Ping timeout: 276 seconds]
<borei> trying to find more or less detailed documentation on VOPs, but failed. Only couple articles. Any hint is more then welcome
hhdave has joined #lisp
Chream_3 has joined #lisp
Chream_2 has quit [Ping timeout: 268 seconds]
varjag has quit [Ping timeout: 264 seconds]
Chream_ has quit [Ping timeout: 248 seconds]
Cymew has joined #lisp
wxie has joined #lisp
varjag has joined #lisp
varjag has quit [Remote host closed the connection]
FreeBirdLjj has joined #lisp
vlatkoB has quit [Remote host closed the connection]
JohnnyL has quit [Quit: leaving]
hhdave has quit [Ping timeout: 248 seconds]
milanj has quit [Quit: This computer has gone to sleep]
Cymew has quit [Ping timeout: 240 seconds]
milanj has joined #lisp
Chream_3 has quit [Ping timeout: 248 seconds]
FreeBirdLjj has quit [Ping timeout: 248 seconds]
FreeBirdLjj has joined #lisp
Chream_ has joined #lisp
shka has quit [Ping timeout: 248 seconds]
Chream_ has quit [Ping timeout: 256 seconds]
Chream_ has joined #lisp
deng_cn has quit [Read error: Connection reset by peer]
FreeBirdLjj has quit [Ping timeout: 240 seconds]
rann has quit []
rann has joined #lisp
FreeBirdLjj has joined #lisp
jack_rabbit has quit [Ping timeout: 276 seconds]
Chream_ has quit [Ping timeout: 268 seconds]
papachan has quit [Quit: WeeChat 2.0.1]
attila_lendvai has quit [Read error: Connection reset by peer]
FreeBirdLjj has quit [Ping timeout: 252 seconds]
Bike has joined #lisp
attila_lendvai has joined #lisp
smasta has quit [Ping timeout: 248 seconds]
Chream_ has joined #lisp
deng_cn has joined #lisp
FreeBirdLjj has joined #lisp
Chream_ has quit [Ping timeout: 263 seconds]