jackdaniel changed the topic of #lisp to: Common Lisp, the #1=(programmable . #1#) programming language | <http://cliki.net/> <https://irclog.tymoon.eu/freenode/%23lisp> <https://irclog.whitequark.org/lisp> <http://ccl.clozure.com/irc-logs/lisp/> | SBCL 1.5.4, CMUCL 21b, ECL 16.1.3, CCL 1.11.5, ABCL 1.5.0
cyraxjoe has quit [Quit: I'm out!]
shka_ has quit [Ping timeout: 245 seconds]
shka_ has joined #lisp
jeosol has joined #lisp
Duns_Scrotus has left #lisp [#lisp]
akoana has quit [Ping timeout: 244 seconds]
ikki has joined #lisp
count3rmeasure has joined #lisp
akoana has joined #lisp
mason- has quit [Ping timeout: 245 seconds]
count3rmeasure has quit [Quit: Leaving]
lalilulelo has joined #lisp
AndrewYoung has quit [Remote host closed the connection]
seok has quit [Remote host closed the connection]
shifty has quit [Ping timeout: 245 seconds]
akoana has quit [Ping timeout: 245 seconds]
akoana has joined #lisp
akoana has left #lisp [#lisp]
semz has quit [Ping timeout: 264 seconds]
EvW has quit [Ping timeout: 250 seconds]
ikki has quit [Ping timeout: 244 seconds]
cyraxjoe has joined #lisp
glamas has quit [Quit: ZNC 1.7.3 - https://znc.in]
glamas has joined #lisp
karlosz has quit [Quit: karlosz]
semz has joined #lisp
semz has quit [Changing host]
semz has joined #lisp
cyraxjoe has quit [Quit: I'm out!]
ikki has joined #lisp
cyraxjoe has joined #lisp
<fiddlerwoaroof> hi
cyraxjoe has quit [Client Quit]
khisanth_ has quit [Ping timeout: 244 seconds]
cyraxjoe has joined #lisp
cyraxjoe has quit [Client Quit]
makomo has quit [Ping timeout: 245 seconds]
ikki has quit [Ping timeout: 258 seconds]
alexanderbarbosa has quit [Ping timeout: 264 seconds]
t58 has quit [Quit: Night]
cyraxjoe has joined #lisp
khisanth_ has joined #lisp
karlosz has joined #lisp
cyraxjoe has quit [Client Quit]
cyraxjoe has joined #lisp
cyraxjoe has quit [Quit: I'm out!]
cyraxjoe has joined #lisp
shifty has joined #lisp
pjb has quit [Ping timeout: 252 seconds]
notzmv has joined #lisp
pjb has joined #lisp
karlosz has quit [Quit: karlosz]
techquila has joined #lisp
Bike has quit [Quit: Lost terminal]
kajo has quit [Ping timeout: 250 seconds]
__sos__ has joined #lisp
vaporatorius has quit [Read error: Connection reset by peer]
vaporatorius has joined #lisp
vaporatorius has quit [Read error: Connection reset by peer]
karlosz has joined #lisp
vaporatorius has joined #lisp
vaporatorius has quit [Changing host]
vaporatorius has joined #lisp
vaporatorius has quit [Read error: Connection reset by peer]
vaporatorius has joined #lisp
vaporatorius has quit [Read error: Connection reset by peer]
<stylewarning> Does anybody have any fast & efficient (TM) libraries for memory mapped files? Or do people do it the good ol fashioned way
<stylewarning> s/have/recommend or know to exist/
<no-defun-allowed> stylewarning: https://shinmera.github.io/mmap/
iovec has quit [Quit: Connection closed for inactivity]
<stylewarning> I need to learn more about mmap, and how to read truly huge files that don't fit in RAM
Ricchi has quit [Remote host closed the connection]
karlosz has quit [Quit: karlosz]
karlosz has joined #lisp
shifty has quit [Ping timeout: 244 seconds]
shifty has joined #lisp
yoeljacobsen has quit [Ping timeout: 244 seconds]
mulk has quit [Quit: ZNC - http://znc.in]
gravicappa has joined #lisp
lalilulelo has quit [Ping timeout: 258 seconds]
karlosz has quit [Quit: karlosz]
Mr-0dday_ has joined #lisp
davr0s_ has quit [Remote host closed the connection]
davr0s has quit [Remote host closed the connection]
hasebastian has joined #lisp
Mr-0dday_ has quit [Read error: Connection reset by peer]
<fiddlerwoaroof> stylewarning: I don't know how "fast and efficient" they are, but manardb and (I think) the viace graph database both use mmapped files, so perhaps they'd be worth looking at?
<stylewarning> I can check them out
<fiddlerwoaroof> One quirk I've found is that a lot of libraries use mremap, which often isn't available on non-Linux unices
schjetne has joined #lisp
mulk has joined #lisp
orivej has quit [Ping timeout: 245 seconds]
manualcrank has quit [Quit: WeeChat 1.9.1]
<beach> Good morning everyone!
dale has quit [Quit: My computer has gone to sleep]
schjetne has quit [Ping timeout: 245 seconds]
__sos__ has quit [Ping timeout: 244 seconds]
hasebastian has quit [Quit: Konversation terminated!]
shifty has quit [Ping timeout: 258 seconds]
shifty has joined #lisp
Inline has quit [Quit: Leaving]
varjag has joined #lisp
vaporatorius has joined #lisp
vaporatorius has quit [Read error: Connection reset by peer]
vaporatorius has joined #lisp
varjag has quit [Ping timeout: 264 seconds]
vaporatorius has quit [Read error: Connection reset by peer]
vaporatorius has joined #lisp
lanu has joined #lisp
sauvin has joined #lisp
schjetne has joined #lisp
JohnMS_WORK has joined #lisp
<fiddlerwoaroof> morning beach
vlatkoB has joined #lisp
shifty has quit [Ping timeout: 258 seconds]
shifty has joined #lisp
flamebeard has joined #lisp
sonologico has quit [Remote host closed the connection]
afterK has joined #lisp
nostoi has joined #lisp
varjag has joined #lisp
schjetne has quit [Ping timeout: 244 seconds]
EvW1 has joined #lisp
shifty has quit [Ping timeout: 245 seconds]
elderK has quit [Quit: Connection closed for inactivity]
ljavorsk has joined #lisp
jprajzne has joined #lisp
nanoz has joined #lisp
vaporatorius has quit [Read error: Connection reset by peer]
nostoi has quit [Read error: Connection reset by peer]
gko has joined #lisp
nostoi has joined #lisp
manualcrank has joined #lisp
ltriant has quit [Quit: leaving]
devon has joined #lisp
refpga has joined #lisp
<devon> Is there a nicer way to destructure a sequence other than coercing it to a list?
scymtym has joined #lisp
<devon> like (destructuring-bind (a b c ...) (coerce (nth-value 1 (cl-ppcre:scan-to-strings # #)) 'list) ...)
schjetne has joined #lisp
test1600 has joined #lisp
EvW1 has quit [Ping timeout: 250 seconds]
tourjin has joined #lisp
<tourjin> in interpreter i starts with * sign prompt but it change to some debug level or something prompting 0[4] . how can I go back to my original level with * sign prompt?
<beach> What implementation is this?
<tourjin> sbcl
<beach> You should have a list of restarts.
<beach> One restart is probably "return to top level"
<beach> But you should not be using SBCL from the command line like that.
<beach> It is best to use it through SLIME.
<beach> And, it is not an interpreter, by the way. SBCL compiles forms on the fly.
<tourjin> i don't have it for now. anyway I i can't go back "return to top level".
<tourjin> message says restarts (invokable by number or by possibly-abbreviated name):
<beach> So invoke it by number.
<tourjin> i can't find how I imply on it.
<beach> Do you have a restart ABORT?
<tourjin> 0: [ABORT] Reduce debugger level (to debug level 8).
<tourjin> 8: Exit debugger, returning to top level.
<beach> There you go.
<beach> Type the number of that restart.
<tourjin> oh... just number.
<tourjin> is that it? :-)
<tourjin> thanks
<beach> Sure.
<tourjin> slime is for emacs . i think I should try vlime.
<beach> I think you should use Emacs.
<tourjin> everyone says that but I've never used it.
<beach> I am sorry to hear that.
<tourjin> i've only used vim. with not so good laptop in limited resorces. so i don't have in mind trying emacs yet.
<no-defun-allowed> Depends on your definition of "limited resources", but Emacs runs about the same on my dinky 2006 laptop as it does my desktop.
<no-defun-allowed> Though, I've heard SLIMV is comparable to SLIME, the only difference being the former runs on an inferior editor.
<tourjin> generally it's said emacs is a lot heavier compared to vim. is'nt it?
red-dot has joined #lisp
<ck_> you can't expect to use them in the same way, but on any regular machine this side of the turn of the century, it shouldn't really matter
<beach> tourjin: That sounds like a pitiful excuse to avoid learning a better tool.
Cymew has quit [Quit: Konversation terminated!]
<tourjin> beach yes. u can say that. honestly i'm thinking i would like to go with vim . it was first and last editor i've used since i met linux.
nanoz has quit [Ping timeout: 245 seconds]
<schweers> tourjin: back when I tried Emacs (coming from vim) I was surprised to see that Emacs could scroll syntax highlighted LaTeX code smoothly, while (g)vim could not.
<schweers> Also, if you’re coming from vim, you might like spacemacs.
nanoz has joined #lisp
gravicappa has quit [Ping timeout: 264 seconds]
gravicappa has joined #lisp
<aeth> Emacs is heavier when it does more, i.e. run graphically instead of the terminal... and heavily customized
<tourjin> thanks for every suggestions u gave me guys.
<beach> tourjin: May I suggest you turn on the equivalent in vim of Emacs abbrev-mode, so that you can define "u" to expand to "you" automatically.
<beach> Though perhaps you are not using the IRC mode of vim, so you can't turn on abbrevs.
<tourjin> i'm using windows10 wsl
test1600_ has joined #lisp
<schweers> There is a windows port of both gvim and emacs, I suggest you use those, they work fairly decently.
test1600__ has joined #lisp
<tourjin> u suggest me try vim and emacs compare? interesting. but i'm at library now. i don't have good wifi connections. i don't have them installed for now. i'll give it a try later. thanks.
<fiddlerwoaroof> tourjin: when I started using Common Lisp, I used slimv exclusively, and it works pretty well
test1600 has quit [Ping timeout: 245 seconds]
<fiddlerwoaroof> I eventually switched to emacs when I realized I could still have my nice vim-style modal editing, but slimv is perfectly fine if you don't want to learn a new language and a new editor at the same time.
<tourjin> fiddlerwoaroof slimv and vlime which is better for begginers?
<fiddlerwoaroof> I've never used vlime
<tourjin> ok ur recommadation is slimv. thanks.
test1600_ has quit [Ping timeout: 245 seconds]
vyorkin has joined #lisp
HDurer has joined #lisp
tourjin has quit [Ping timeout: 245 seconds]
cosimone has joined #lisp
devon has quit [Ping timeout: 258 seconds]
ljavorsk has quit [Ping timeout: 244 seconds]
Lord_of_Life has quit [Ping timeout: 244 seconds]
Lord_of_Life has joined #lisp
Cymew has joined #lisp
nostoi has quit [Quit: Verlassend.]
<thijso> How do I go about debugging the error message 'Component "x" not found.'? I _think_ it's an ASDF error, but I'm stumped why I get it. The scenario is compiling stuff under EQL-Android. The thing is, I've tried bordeax-threads and sha1 and both compile without problems, but usocket for some reason ends up with that error message. They're all installed via quicklisp, so I'm not seeing why usocket fails, while
<thijso> the others don't. Any debugging strings I can try to dump in the process to see where it goes wrong?
<thijso> I think it's ASDF btw, because if I turn on (setf *break-on-signals* 'error) I get the message: Filesystem error with pathname "/opt/android-64/ecl/ecl-android-host/lib/ecl-16.1.3/.cl-source-registry.cache"
<thijso> I think that's ASDF trying to find it...
<thijso> And indeed, that file is not there.
<thijso> If this is a question for a different channel, I'm sorry, btw.
<thijso> That cache file isn't there, but when I CONTINUE I get a different location, etcetc. It's asdf going through all it's locations I think?
shifty has joined #lisp
ljavorsk has joined #lisp
orivej has joined #lisp
vaporatorius has joined #lisp
vaporatorius has joined #lisp
vaporatorius has quit [Changing host]
refpga has quit [Remote host closed the connection]
makomo has joined #lisp
refpga has joined #lisp
zaquest has quit [Remote host closed the connection]
q-u-a-n23 has joined #lisp
zaquest has joined #lisp
q-u-a-n2 has quit [Ping timeout: 244 seconds]
kajo has joined #lisp
cosimone has quit [Quit: Leaving]
shwouchk has quit [Quit: Connection closed for inactivity]
lanu has quit [Quit: lanu]
orivej_ has joined #lisp
orivej has quit [Ping timeout: 244 seconds]
vaporatorius has quit [Read error: Connection reset by peer]
vaporatorius has joined #lisp
vaporatorius has quit [Changing host]
vaporatorius has joined #lisp
jeosol has quit [Remote host closed the connection]
orivej has joined #lisp
orivej__ has joined #lisp
orivej_ has quit [Ping timeout: 246 seconds]
orivej has quit [Ping timeout: 244 seconds]
orivej__ has quit [Ping timeout: 258 seconds]
orivej has joined #lisp
<thijso> Hhmmm... It's looking like the line '(defparameter *version* #.(asdf:component-version (asdf:find-system :usocket)) .. ' is causing the problems. This is in usocket.lisp itself. Normally that would not be a problem I assume, but in this case it's messing up the compilation.
<thijso> because at that point the component 'usocket' is not yet defined?
ljavorsk has quit [Ping timeout: 245 seconds]
afterK has quit [Quit: WeeChat 1.9]
Insanity_ has joined #lisp
ljavorsk has joined #lisp
cosimone has joined #lisp
amerlyq has joined #lisp
cosimone has quit [Remote host closed the connection]
cosimone has joined #lisp
vaporatorius has quit [Ping timeout: 245 seconds]
cosimone has quit [Quit: Leaving]
<Cymew> I have no idea what EQL-Android is, but what did you type, and what was the error message you got?
<thijso> EQL5-Android: https://gitlab.com/eql/EQL5-Android , it's a port of EQL5 to the Android platform. EQL5 is Embedded Qt Lisp (Qt5 binding embedded in ECL, embeddable in Qt)
papachan has joined #lisp
<thijso> Cymew: I followed the build instructions in an EQL5-Android example, adapted to my own stuff, where I want to use usocket. Anyway, looks like the issue is with asdf searching for component usocket within usocket itself, and in the build system, that doesn't work.
<thijso> I've managed to work around it by changing the usocket code (1 line). Now I run into other issues, namely, it looks like sb-bsd-sockets isn't defined in the ECL version of EQL5-Android (as I know it's there in regular ECL).
beach` has joined #lisp
cosimone has joined #lisp
beach has quit [Disconnected by services]
beach` is now known as beach
hasebastian has joined #lisp
cosimone has quit [Client Quit]
vaporatorius has joined #lisp
vaporatorius has quit [Read error: Connection reset by peer]
lalilulelo has joined #lisp
test1600_ has joined #lisp
amerlyq has quit [Quit: amerlyq]
test1600__ has quit [Ping timeout: 245 seconds]
nanoz has quit [Ping timeout: 245 seconds]
<Cymew> sb-bsd-sockets is, AFAIK, sbcl specific thing.
kajo has quit [Ping timeout: 252 seconds]
<Cymew> I see no mention of asdf on the EQL-Android gitlb README.
<Cymew> Are you making it harder on yourself by freestyling?
makomo has quit [Quit: WeeChat 2.4]
<Cymew> BTW that sentence about embedding is someone having way to much fun with wordplay, actually obfuscating the matter at hand.
kajo has joined #lisp
hasebastian has quit [Quit: Konversation terminated!]
hasebastian has joined #lisp
kajo has quit [Client Quit]
ljavorsk has quit [Ping timeout: 245 seconds]
ljavorsk_ has joined #lisp
hasebastian has quit [Quit: Konversation terminated!]
<thijso> Cymew: yeah, sb-bsd-sockets is sbcl originally, but it's included in ECL. Nearly a verbatim copy of the sbcl code. It's socket.lisp file says: (require 'sb-bsd-sockets) and that's it. The implementation is in sb-bsd-sockets.lisp in the same directory.
mindCrime has joined #lisp
<thijso> Cymew: what do you mean with 'freestyling'? I'm trying to adapt one of the examples in EQL5-android (the 'my' one, which I succesfully built and tested on my android phone) so that I can use it for my own app. But I want to use a couple of other quicklisp libs, including usocket. That's giving me problems.
awolven has quit [Ping timeout: 264 seconds]
<thijso> I'm thinking I'm running into the limitations regarding this comment in the README: The following will first collect (recursively) all file names and save them in
<thijso> `files.txt`. For details of this **hack** see `make-ASDF.lisp`.
ljavorsk_ has quit [Ping timeout: 245 seconds]
JohnMS_WORK has quit [Read error: Connection reset by peer]
JohnMS_WORK has joined #lisp
ggole has joined #lisp
refpga has quit [Remote host closed the connection]
dmiles has quit [Read error: Connection reset by peer]
logicmoo has joined #lisp
<thijso> Right. It looks like it's as simple as a (require :sb-bsd-sockets) in the make.lisp file used to build the system...
logicmoo has quit [Read error: No route to host]
<thijso> As, yes, the sb-bsd-sockets.fas file is there, it's just not loaded by default during the build phase. Something like that, anyway.
dmiles has joined #lisp
JohnMS_WORK has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
nanoz has joined #lisp
orivej has quit [Ping timeout: 245 seconds]
amerlyq has joined #lisp
orivej has joined #lisp
cosimone has joined #lisp
awolven has joined #lisp
Baggers has joined #lisp
<Baggers> does adjust-array copy the contents in the case where it returns a new array?
Bike has joined #lisp
<shka_> Baggers: yes
<shka_> it is specified in the hyperspec
ikki has joined #lisp
cosimone has quit [Quit: Leaving]
LiamH has joined #lisp
vms14 has joined #lisp
<Baggers> shka_: thank you. I was reading that page but clearly not very well.
test1600__ has joined #lisp
<shka_> If initial-contents is supplied, it is treated as for make-array. In this case none of the original contents of array appears in the resulting array.
<shka_> for reference
test1600_ has quit [Ping timeout: 245 seconds]
<Baggers> shka_: thanks again. Yeah it was so explicit about that and displacing that I started doubting the behaviour in the :initial-contents nil case
<shka_> yeah, i was scratching my head back few months ago
<shka_> that's why i still remember this
lucasb has joined #lisp
<Baggers> hehe nice
<Cymew> thijso: So sb-bsd-sockets is incorporated in ecl, that I did not know.
test1600 has joined #lisp
<Cymew> thijso: 'freestyling' as in building eql-android your own way, but I might have misunderstood what it is you're doing, as I've never used eql-android.
ebzzry has quit [Quit: WeeChat 2.3]
test1600__ has quit [Ping timeout: 245 seconds]
<vms14> now you're talking about sockets, does usocket provide local sockets?
<vms14> sb-bsd-sockets does, with sb-bsd-sockets:local-socket
<vms14> but I saw nothing at the documentation of usocket for local sockets
<Shinmera> sb-bsd-sockets is in sbcl, ecl, clasp, and mkcl.
test1600 has quit [Ping timeout: 245 seconds]
<Cymew> Look at that.
<Cymew> I only use sbcl and ccl these days, so I had missed that.
cosimone has joined #lisp
cosimone has quit [Quit: Leaving]
makomo has joined #lisp
amerlyq has quit [Quit: amerlyq]
t58 has joined #lisp
cosimone has joined #lisp
cosimone has quit [Client Quit]
vaporatorius has joined #lisp
vaporatorius has quit [Changing host]
vaporatorius has joined #lisp
cosimone has joined #lisp
cosimone has quit [Remote host closed the connection]
vms14 has quit [Remote host closed the connection]
cosimone has joined #lisp
<Baggers> shka_: I got a message elsewhere that adjust-array doesnt guarentee element copying in the cases where a new array is returned. I need to look back into this but apparently (alexandria:copy-array array :adjustable t) should help
<shka_> oh
<thijso> vms14: usocket doesn't, I think
<shka_> If only new-dimensions and an initial-element argument are supplied, those elements of array that are still in bounds appear in the resulting array.
<shka_> Baggers: this depends i guess
<shka_> but above seems to be clear to me
<Baggers> yeah same. I'm back to being uncertain though :D
<shka_> that's because there is a lot of option combinations like displaced arrays
<shka_> but base case works
<Baggers> cool
<shka_> what if :adjustable t though…
amerlyq has joined #lisp
shifty has quit [Ping timeout: 245 seconds]
cosimone has quit [Remote host closed the connection]
cosimone has joined #lisp
<Baggers> shka_: in copy-array?
<shka_> in adjust-array
<Baggers> adjust-array doesnt have an arg named adjustable. The source array would have to have that set though
dale_ has joined #lisp
dale_ is now known as dale
igemnace has joined #lisp
<shka_> oh, ok
varjag has quit [Quit: ERC (IRC client for Emacs 25.2.2)]
paul0 has quit [Ping timeout: 244 seconds]
FreeBirdLjj has joined #lisp
igemnace has quit [Ping timeout: 246 seconds]
dddddd has joined #lisp
<pjb> If adjust-array is applied to an array that is actually adjustable, the array returned is identical to array. If the array returned by adjust-array is distinct from array, then the argument array is unchanged.
<pjb> Baggers: not necessarily.
<pjb> note that it is possible that (not (adjustable-array-p (make-array size :adjustable t)))
<pjb> or that (adjustable-array-p (make-array size :adjustable nil))
<pjb> It's implementation dependent.
<pjb> If adjustable is non-nil, the array is expressly adjustable (and so actually adjustable); otherwise, the array is not expressly adjustable (and it is implementation-dependent whether the array is actually adjustable).
awolven has quit [Read error: Connection reset by peer]
<pjb> Well, it seems I'm wrong.
<pjb> (adjustable-array-p (make-array size :adjustable t)) must be true.
<pjb> It may be an inconsistency in the clhs…
awolven has joined #lisp
<Bike> what's the inconsistency?
<pjb> Ah, no. It was in my mind. I read a <=> when it's a => in make-array. :adjustable t => expressly adjustable => actually adjustable.
<Bike> arrays are pretty confusing.
<pjb> but :adjustable nil & actually adjustable is possible.
<pjb> So an implementation can have only adjustable arrays, but cannot have only not-adjustable arrays.
paul0 has joined #lisp
igemnace has joined #lisp
cosimone has quit [Quit: Leaving]
awolven has quit [Ping timeout: 245 seconds]
papachan has quit [Ping timeout: 264 seconds]
sjl_ has joined #lisp
smazga has joined #lisp
schjetne has quit [Ping timeout: 245 seconds]
karlosz has joined #lisp
cosimone has joined #lisp
ebzzry has joined #lisp
jprajzne has quit [Quit: Leaving.]
karlosz has quit [Client Quit]
papachan has joined #lisp
sjl_ has quit [Ping timeout: 245 seconds]
papachan has quit [Client Quit]
iovec has joined #lisp
FreeBirdLjj has quit [Remote host closed the connection]
FreeBirdLjj has joined #lisp
papachan has joined #lisp
renzhi has joined #lisp
papachan has quit [Client Quit]
FreeBirdLjj has quit [Ping timeout: 245 seconds]
papachan has joined #lisp
protokaryote has joined #lisp
Bike has quit [Remote host closed the connection]
pjb has quit [Remote host closed the connection]
pjb has joined #lisp
awolven has joined #lisp
mtreis86 has joined #lisp
mtreis86 has left #lisp [#lisp]
mindCrime_ has joined #lisp
mindCrime has quit [Ping timeout: 245 seconds]
renzhi has quit [Ping timeout: 244 seconds]
schjetne has joined #lisp
cyraxjoe has quit [Quit: I'm out!]
cyraxjoe has joined #lisp
hasebastian has joined #lisp
protokaryote has quit [Quit: protokaryote]
FreeBirdLjj has joined #lisp
papachan has quit [Quit: Leaving]
Ricchi has joined #lisp
bjorkintosh has quit [Ping timeout: 276 seconds]
Bike has joined #lisp
Inline has joined #lisp
Baggers has quit [Remote host closed the connection]
Oladon_wfh has joined #lisp
hasebastian has quit [Quit: Konversation terminated!]
yoeljacobsen has joined #lisp
red-dot has quit [Quit: Going offline, see ya! (www.adiirc.com)]
v88m has joined #lisp
bnh^ has joined #lisp
mindCrime has joined #lisp
adom` has joined #lisp
mindCrime_ has quit [Ping timeout: 245 seconds]
flamebeard has quit []
scymtym has quit [Ping timeout: 250 seconds]
dvdmuckle has quit [Quit: Bouncer Surgery]
dvdmuckle has joined #lisp
<DrDuck> how can i read two numbers in lisp
ggole has quit [Quit: Leaving]
<DrDuck> and assign them to variables
<DrDuck> (setq a (read *standard-input* nil)) (setq b (read *standard-input* nil) ) ?
<DrDuck> or is there another way
<pjb> have you defined the variables a and b?
<DrDuck> no i will define them in the setq i guess
<pjb> (let ((a (progn (write-line "Please, enter an number: " *query-io*) (finish-output *query-io*) (read *query-io*))) (b (progn (write-line "Please, enter an number: " *query-io*) (finish-output *query-io*) (read *query-io*)))) (format t "~&Their sum is : ~A~%" (+ a b)))
<pjb> DrDuck: nope, setq doesn't define number. If you assign to an inexistant variable, you get nasal dragons, and missiles sent to the general direction of your home.
<pjb> s/define number/define variables/
niceplace has quit [Ping timeout: 244 seconds]
niceplace has joined #lisp
yoeljacobsen has quit [Ping timeout: 245 seconds]
Kevslinger has joined #lisp
rippa has joined #lisp
Ricchi has quit [Remote host closed the connection]
Insanity_ has quit [Quit: Connection closed for inactivity]
whartung has joined #lisp
Fare has joined #lisp
jlarocco has joined #lisp
FreeBirdLjj has quit [Remote host closed the connection]
FreeBirdLjj has joined #lisp
FreeBirdLjj has quit [Ping timeout: 246 seconds]
schjetne has quit [Ping timeout: 246 seconds]
Fare has quit [Ping timeout: 264 seconds]
papachan has joined #lisp
cosimone has quit [Quit: Leaving]
yoeljacobsen has joined #lisp
iovec has quit [Quit: Connection closed for inactivity]
FreeBirdLjj has joined #lisp
nanoz has quit [Ping timeout: 244 seconds]
Fare has joined #lisp
vyorkin has quit [Ping timeout: 245 seconds]
FreeBirdLjj has quit [Ping timeout: 245 seconds]
kajo has joined #lisp
scottj has left #lisp [#lisp]
Fare has quit [Ping timeout: 276 seconds]
ikki has quit [Ping timeout: 244 seconds]
nanoz has joined #lisp
sjl_ has joined #lisp
awolven has quit [Ping timeout: 245 seconds]
schjetne has joined #lisp
sauvin has quit [Read error: Connection reset by peer]
awolven has joined #lisp
FreeBirdLjj has joined #lisp
schjetne has quit [Ping timeout: 245 seconds]
FreeBirdLjj has quit [Ping timeout: 264 seconds]
cyraxjoe has quit [Quit: I'm out!]
cyraxjoe has joined #lisp
cosimone has joined #lisp
dyelar has quit [Quit: Leaving.]
FreeBirdLjj has joined #lisp
lnostdal has joined #lisp
FreeBirdLjj has quit [Ping timeout: 245 seconds]
<flip214> pjb: LET could do both things at the same time, in theory, right? So a LET* might be safer... A not-so-smart compiler might parallize that onto two cores ;)
vlatkoB has quit [Remote host closed the connection]
lnostdal has quit [Ping timeout: 258 seconds]
ravenous_ has joined #lisp
_jrjsmrtn has joined #lisp
__jrjsmrtn__ has quit [Ping timeout: 246 seconds]
varjag has joined #lisp
yoeljacobsen has quit [Ping timeout: 245 seconds]
<sjl_> LET has to evaluate the forms in order according to the spec
<sjl_> only the binding is in parallel
dmiles has quit [Read error: Connection reset by peer]
scymtym has joined #lisp
papachan has quit [Quit: Leaving]
<flip214> ah yes, right. Sorry about the noise!
dmiles has joined #lisp
orivej has quit [Ping timeout: 245 seconds]
yoeljacobsen has joined #lisp
hiroaki has joined #lisp
permagreen has quit [Remote host closed the connection]
karlosz has joined #lisp
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
zigpaw has quit [Quit: Vanishing into darkness in 1..2..3...]
karlosz has quit [Quit: karlosz]
bjorkintosh has joined #lisp
yoeljacobsen has quit [Ping timeout: 246 seconds]
zigpaw has joined #lisp
sonologico has joined #lisp
hiroaki has quit [Ping timeout: 245 seconds]
<Ober> pwd
ravenous_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
FreeBirdLjj has joined #lisp
gravicappa has quit [Ping timeout: 244 seconds]
mindthelion has joined #lisp
vms14 has joined #lisp
FreeBirdLjj has quit [Ping timeout: 244 seconds]
Ven`` has joined #lisp
techquila has quit [Ping timeout: 250 seconds]
Lord_of_Life_ has joined #lisp
maxxcan has joined #lisp
maxxcan has quit [Client Quit]
Kundry_Wag has joined #lisp
Lord_of_Life has quit [Ping timeout: 245 seconds]
Lord_of_Life_ is now known as Lord_of_Life
techquila has joined #lisp
mindthelion has quit [Ping timeout: 245 seconds]
Ven`` has quit [Read error: Connection reset by peer]
adom` has quit [Remote host closed the connection]
amerlyq has quit [Quit: amerlyq]
<Oladon_wfh> #lisp
shifty has joined #lisp
<vms14> (lisp)
davr0s has joined #lisp
davr0s_ has joined #lisp
ebrasca has quit [Remote host closed the connection]
ebrasca has joined #lisp
ebrasca has quit [Remote host closed the connection]
ebrasca has joined #lisp
ebrasca has quit [Remote host closed the connection]
<LdBeth> Good afternoon
ebrasca has joined #lisp
awolven has quit [Ping timeout: 246 seconds]
<vms14> ebrasca: you made mezzano right?
<vms14> can you say you'd made it without lisp, with other languages?
elderK has joined #lisp
<vms14> and did macros be an important part for the development?
<jackdaniel> vms14: the main developer of mezzano is froggey
karlosz has joined #lisp
<aeth> ebrasca is (distant) second in contributions. https://github.com/froggey/Mezzano/graphs/contributors
Fare has joined #lisp
FreeBirdLjj has joined #lisp
<vms14> oh
<vms14> froggey: then the questions are for you
gjvc has joined #lisp
nanoz has quit [Ping timeout: 245 seconds]
karlosz has quit [Quit: karlosz]
FreeBirdLjj has quit [Ping timeout: 268 seconds]
<froggey> vms14: I'm not quite sure I understand the first question. mezzano is written in common lisp, with very small amounts of assembly. you can write operating systems in other languages
<froggey> macros haven't been particularly important, I guess no more important than in any other software written in CL
shifty has quit [Ping timeout: 268 seconds]
Bike has quit [Quit: Bike]
<vms14> froggey: I mean, mezzano is an operating system written almost entirely by one person
mindCrime has quit [Ping timeout: 245 seconds]
<vms14> you guess you could have achieved this without lisp, using for example, C?
<froggey> yes. time spent is probably more important than language
sjl_ has quit [Quit: WeeChat 2.3-dev]
awolven has joined #lisp
cosimone has quit [Quit: Leaving]
<vms14> idk what you mean
<vms14> but seems to be that does not matter the language until you spent time in something
<LdBeth> vms14: MINIX?
<vms14> what?
<vms14> xD
awolven has quit [Client Quit]
LiamH has quit [Quit: Leaving.]
awolven has joined #lisp
<froggey> Toaruos is another OS developed by one person, it's written in C
<ebrasca> vms14: No , I am contributing to mezzano.
clothespin has joined #lisp
<froggey> if you're able to put the time & effort in, then you can use whatever language you want
<vms14> yeah that's right
<froggey> common lisp is certainly a nicer programming language to use than C
<vms14> but I suppose common lisp gave you some features that made the development better/easier or whatever
<vms14> and I was thinking if macros were key in that development or they did your development different
<ebrasca> vms14: common lisp is fun.
<vms14> it is
<froggey> garbage collection, bounds checking, type checking, etc. it's a less error prone language
<vms14> I'm trying to mix perl with common lisp in a dirty way
<vms14> I'm going to try with local sockets
<froggey> live development through a repl and slime too. clos/generic functions...
alexanderbarbosa has joined #lisp
renzhi has joined #lisp
<pjb> vms14: you should study http://cliki.net/Performance
<aeth> vms14: Perl (or maybe Perl 6, since it's standardized) is actually one of the languages I'd consider implementing on CL (in the very long run) since it's basically just a regex DSL that is increasingly ugly when you use it for things other than regex on lines of text.
<vms14> yeah, I wanted to learn perl because I think as a programmer or unix user I should have a text-editing tool
<vms14> and I was deciding if perl or awk
<vms14> I chose perl and I guess I did well, it's very useful and replaces bash
<aeth> Just use (loop :for line := (read-line file-stream nil nil) :while line ...)
<vms14> it seems the best language for unix scripting
<aeth> eh
<aeth> Python replaced Perl in most Unix scripts for a reason
<vms14> which reason?
<vms14> I thought it was for readibility and learning curve
<vms14> not for being "better" suited for unix scripting
<aeth> Perl has a lot of ugliness that only makes sense in a historical context of comparing it to sh and awk etc. Lots of things that hurt reliability.
<aeth> And it's hard to even do stuff like arrays.
<vms14> yeah but it boosts your productivity and you end writing a lot of scripts
<aeth> With most scripting languages (and even CL used in that role) it's very easy to have hash tables and a simple (and probably adjustable) generic array.
<vms14> automating everything and making a lot of little tools
renzhi has quit [Ping timeout: 245 seconds]
<vms14> in cl I would prefer lists and property lists instead of hash tables
<vms14> but, are in cl faster the hash tables than property lists?
<aeth> Even though it might be the ugliest, when I must script Unix as Unix and can't use CL, then I use bash (and I don't even use bash as a shell, I use zsh there) because I can assume that it's on nearly every machine
<aeth> Plain POSIX sh doesn't give enough convenience features.
<vms14> aeth: then use sh, not bash
<vms14> oh
<vms14> I have no bash, so for use your script I need to install bash
<vms14> perl is more likely to be installed than bash, if you're not in linux
<aeth> vms14: hash tables are O(1) but with a higher cost. plists are O(n) but with a lower cost. This means that for small data plists (or alists) are faster than hash tables, but for large data hash-tables are larger, and where that line crosses is implementation-specific (and possibly OS specific etc.)
<aeth> Well O(1) lookup vs. O(n) worstcase lookup
<aeth> Obviously there's a whole table of various tradeoffs
<aeth> s/for large data hash-tables are larger/for large amounts of data hash-tables are faster/
<vms14> then for "big" data hash tables and for small property lists?
<aeth> no, that's a micro-optimization
<aeth> I'd personally just use hash-tables unless they're particularly inconvenient, especially when you're using scripting idioms where you'd expect hash tables in other languages.
<vms14> I like a lot property lists, and I even see them as basic replacement for structs or CLOS
<aeth> When n is small, there's a higher fixed cost for hash-tables, but it doesn't matter as much, because n is small
<vms14> and CLOS, how much overhead adds?
<vms14> it's suitable for scripting? I guess nope
<vms14> idk why run program from asdf is a lot slower than sb-ext:run-program
<aeth> vms14: I personally tend to use plists for things in macros, or for things that are intended to be read and processed sequentially (which is usually the case for macros, anyway).
<vms14> and the reason seems to be CLOS
<aeth> So SBCL internally likes to use structs, but usually with the caveat that that's an implementation detail and could change at any time.
<aeth> And with SBCL in particular, SBCL can do more optimizations to structure-objects than to standard-objects (defined by defclass)
varjag has quit [Ping timeout: 244 seconds]
<aeth> In particular, in SBCL, storing it in a standard object will guarantee that the type information will be lost (same with storing it in a hash table, or a list, or an array without a supported specialized element-type)
<vms14> ah yeah, someone told me CLOS is very dynamic and the compiler cannot be sure of what type of value the slots are
<vms14> so it's not able to optimize it
<aeth> With a struct in SBCL, a slot can have a :type and the type will be respected in SBCL because redefining a struct by C-c C-c defstruct is undefined so the types in the accessors can be inlined (also, the accessors aren't very generic)
ltriant has joined #lisp
<aeth> A lot of the time, when you're using a struct accessor, something is either of the given type, or it's an error because it's not the right struct type. So the compiler can infer more.
<vms14> but a plist will be "cheaper" than a struct
<vms14> not?
<aeth> well, a struct doesn't get you a sequence, unless you make your own cons-like linked lists from them yourself
<vms14> yeah the problem is traversing the list
<aeth> and those tend to be about 30% slower than lists (but I tested them against regular lists being used as regular lists, not plists)
<aeth> maybe because they're larger in memory, maybe because not everything is optimized so there's some added type checks
<aeth> vms14: but... the context we were talking about is Unix scripting, and even SBCL at its slowest should be faster than Ruby, which is one of the languages that's used for Unix scripting.
<aeth> (In fact, I can't uninstall Ruby, Python 3, or Perl because they're all used by core things in my distro)
<vms14> specially python and perl
<vms14> python is in linux base
<vms14> you simply cannot remove python without breaking your system xD
<aeth> vms14: For scripting, the main thing you don't want is a JIT runtime, because JIT has a warmup time that adds a fixed cost to each run of the program. So it could e.g. be like 1-2 seconds minimum with no faster possibilities.
<aeth> You wouldn't want to compose things at the shell like that.
<vms14> and for make "scripts" with sbcl which is the best way
<vms14> save image, sbcl --script or compiled?
<pjb> vms14: for less than 5 entries alist and plist are usually faster than hash-table. This can go up to 35 in the case of clisp.
<aeth> vms14: what you'd probably want to do in a script is you'd put your code in an ASDF system, and have a very minimal file load it and run an entry point, possibly in a Python-style (defun main () ...) (main)
<vms14> clisp starts faster than sbcl
<vms14> so maybe is better option than sbcl for scripting
<aeth> It depends
<aeth> CLISP is faster than SBCL in a program that does nothing. Now make the program do something. CLISP will quickly fall behind. Do you want to microoptimize which implementation is the fastest for each script?
<vms14> xD
<aeth> There's some point at which CLISP is slower than SBCL for a script even with a faster start time. This might even depend on the particular machine.
<aeth> But it doesn't really matter. What's more important is that neither are JIT... JIT will add significant startup overhead
<pjb> A lot of scripts are one-liners or close…
<pjb> and I/O bound.
<vms14> a lot of unix scripts are oneliners
<vms14> and most of them write to files and exec commands
<aeth> I personally wouldn't use CLISP because I can't expect everything to run on CLISP these days. Interestingly, my distro's maintainers (I use Fedora) gave up on waiting for a new official CLISP and have been building a git version of CLISP for a while, and I just never noticed the RPM version string before.
<vms14> well clisp is used to build sbcl
<aeth> Right, so in a sense, CLISP can run every library, if it first compiles SBCL.
<vms14> xD
<aeth> That might add to startup time, though.
<pjb> Libraries that are sbcl-specific are bad libraries. They're not Common Lisp libraries, they're sbcl libraries. They're out of consideration in the first place in #lisp.
<no-defun-allowed> vms14: https://i.redd.it/x6rfr21bnqs21.jpg
<aeth> pjb: It's not that libraries are SBCL-specific, it's that libraries support m of n implementations where (<= m n) and once you use enough of them, eventually you get something that probably can only run on SBCL and CCL, although it normally doesn't get that bad.
<vms14> aeth: why you're thinking in mixing cl with perl/perl6 and how you're going to do it?
<pjb> The real problem with clisp is that it depends on ffcall (and libsigsegv) and those libraries are not available on all platforms, notably on Darwin. Which makes clisp much better on linux than on other platforms.
<pjb> But again, if you exclude non-lisp libraries, (ie. libraries using FFI), then you don't have any problem using clisp.
<no-defun-allowed> I couldn't build CLISP on my Raspberry Pi 2, since it couldn't find libsigsegv even after I built it using the exact instructions it gave me.
<aeth> pjb: to be fair, though, we're talking about CL as a scripting language, so performance should include FFI, and it should include performance of the run-external-program functionality, perhaps wrapped through a library like UIOP
<aeth> Unix scripting is always incredibly multilingual
<vms14> aeth: what benefits do you guess perl will add to lisp
<vms14> because I started by doing some dirty execs calling oneliners
<no-defun-allowed> Job security: no one can read your Lisp code with Perl in it.
<vms14> and the first benefit I see is cpan modules
<pjb> aeth: clisp run-program is one of the nicest.
<vms14> no-defun-allowed: yeah, ultra obfuscated by default
<vms14> parens hiding sigils
<vms14> inside a regexp
<aeth> vms14: A Perl-on-Lisp would provide better regex. It probably wouldn't run CPAN. Even though Perl 6 (aka Raku) is less popular, it's probably more likely to run libraries because it's a standardized language so you don't need to be bug for bug compatible with a large program.
karlosz has joined #lisp
<pjb> vms14: the quality of cpan module is very bad. Just forget perl. I refuse to install it on my systems…
<vms14> aeth: wasn't cl-ppcre faster than perl regexp engine?
<pjb> it is.
<vms14> I saw some posts arguing ppcre doubles perl speed
vaporatorius has quit [Ping timeout: 245 seconds]
<aeth> vms14: if cl-ppcre is ppc enough of re then wouldn't a cl-perl use cl-ppcre in its implementation?
<vms14> and what you're aiming to do?
<aeth> vms14: Competing with scripting languages is kind of a best case scenario for writing your own implementations in terms of performance, though. Besides JS and LuaJIT they tend to be very non-competitive.
<vms14> connect them with sockets?
<vms14> or putting perl features on lisp?
<vms14> I'm not sure if my decision of mixing perl and lisp was a good idea or not
<aeth> vms14: I intend to eventually have a language-on-CL platform. Some people have written $language on CL, but it's just a one-off, and there probably isn't much code sharing.
<vms14> I think yes, specially for oneliners and the available modules
<vms14> but, maybe would be better to do everything with lisp
<aeth> vms14: From what I've seen with individual attempts (e.g. Python), the advantage is improved performance (with the exception of the JS one, obviously) and easier embedding. The disadvantage is library compatibilty.
<aeth> vms14: I wouldn't mind if everyone wrote everything in CL...
<vms14> aeth: I think is what I should do
<vms14> write everything in lisp and forget other languages, but I'm not doing it
<pjb> vms14: and if you want to reuse something written in foreign language, wrap it in separate process, and use pipes to communicate. So you can stay 100% in CL.
anewuser has joined #lisp
<vms14> well the idea I have is run perl and daemonize it by using an infinite loop reading and accepting from a local socket
<vms14> and start by doing dirty evals from what I read and building lists as a response
<aeth> vms14: If you can compile Language X to CL, and in doing so you make a faster implementation of Language X (so e.g. probably won't convince C fans), then that's a good thing for CL imo, assuming there's a good enough Foo<->CL function call API.
<aeth> Just imo, though.
<aeth> vms14: I'm mainly looking at it from the perspective of CL applications aimed at desktop users, though. It's much easier to pitch to people "script this in 15 languages" than it is to pitch "script this in Common Lisp".
<vms14> yeah, but if no one sees common lisp is used they won't be interested
<vms14> if they see a lot of useful scripts written in common lisp
<vms14> maybe they look different
<aeth> Well, the Common Lisp will (probably) be faster, of course, since it's the native language, unless a CL-in-CL is used for sandboxing or something.
<vms14> and, isn't scheme better suited than cl for scripting?
<aeth> heh
aap has joined #lisp
<aeth> The first complete language I'm going to do on this platform in Scheme because it has a ton of similarities with CL and it's very simple. Then I might do something like Forth, which is notoriously simple, even though it's far more niche than even any (notable) Lisp language is.
<vms14> forth is interesting
<aeth> Next up is probably Lua, even though I don't particularly like Lua and I might not be able to beat LuaJIT in performance (although I'll probably beat official Lua) because it's probably the simplest of the popular (well, relatively speaking) scripting languages.
<aeth> And then maybe POSIX shell? Even uglier than Lua, but probably not that much harder.
<aeth> I doubt that'd be useful as a sandboxed scripting language, though!
<vms14> maybe some sort of transpiler or interpreter for bash in order to add compatibility
<aeth> And then if I'd get that far then Python 2/3, Perl 5/6, PHP, JavaScript/TypeScript, and Ruby would all make good candidates for later explorations. Maybe some other unpopular but interesting languages, too, like Smalltalk.
<vms14> but don't worry, once you start your first ideas start to change too
<aeth> It'd be pretty funny if I did implement both Python 2 and Python 3, though, because I'd then have 2-and-3 interop in the same platform. idk if that has been done before, maybe in PyPy?
<vms14> javascript will add popularity to your platform
<vms14> also python
<aeth> JavaScript/TypeScript, Forth, and LuaJIT are the ones I'm not sure I'd be able to beat in performance (at least, not using a general, portable framework)
<vms14> and if you make some sort of html css interpreter for graphic stuff
<vms14> this would be nice
<vms14> all front developers would be able to use what they know
<aeth> Well HTML/XML/SXP/CSS/CSV/Markdown/org/JSON/etc. would be a different project (or several).
<aeth> SXP being a formally specified s-expression format that can be read to and written from other languages.
vaporatorius has joined #lisp
vaporatorius has quit [Changing host]
vaporatorius has joined #lisp
<aeth> Because it's the conciseness of JSON with the structure of XML, sow hat's not to like?
<vms14> I dream with something like (title "hi" color "red")
<aeth> But Scheme is very doable because it has many data structures in common and hasn't diverged that much (although r7rs has diverged in places where r4rs had not yet done so)
<aeth> For other languages, they might have e.g. a specific string representation in mind that's incompatible with CL's and that requires a lot of work
<pjb> vms14: even if you're not programming in lisp, you can use (title "hi" color "red"). It's trivial to parse!!!
<aeth> It's possible that I might just have to settle for making languages superficially like Python/JS/etc. without actually implementing all of their quirks
<vms14> pjb: yeah I know, I hope I'll do something like that
<vms14> I know there is cl-who spinneret and css stuff
<vms14> but meh
<vms14> I'd like to have a lisp as a replacement for html css and js
<pjb> if char= #\( then read a list. if #\" then read a string. if alpha then read a symbol. if digit then read an integer (or float). and you're set.
<vms14> isn't better with reader macros?
<vms14> I have to try them
<vms14> just did a simple test
karlosz has quit [Quit: karlosz]
<aeth> vms14: there are quite a few XML/HTML/XHTML/etc. representations as s-expressions, where the hard part is how to handle attributes.
Oladon_wfh has quit [Remote host closed the connection]
<aeth> (:a (:href "https://example.com")) looks more elegant, but you'd afaik have to special case everything to distinguish between <a href...> and <a> <href> ...
orivej has joined #lisp
<aeth> I think (:a :href "https://example.com") would work as you expect, even though it doesn't look as elegant, and even though implementing things with a plist in front and an arbitrary tail isn't as elegant
<aeth> Essentially, anytime you see a keyword in the 1st through nth position (instead of the 0th) you'd know that it's an attribute, and you know that it has to alternate between key/value or it's an error.
<vms14> yeah, but I'd like to have something more like a "new" language
<aeth> e.g. (:foo :bar 42 :baz "quux" "This is a" (:em "sentence") "!")
<vms14> for example typing (title hi color red)
<vms14> would add <title> in head and h1 in the body
<vms14> with the same text
iskander has quit [Ping timeout: 250 seconds]
<aeth> once you have it in an s-expression form, you can do whatever you want with it with macros
<vms14> also add microdata, the bad part is for microdata I need to make questions
<aeth> that's the whole point of using s-expressions instead of templated HTML
<vms14> and/or let the user a way to add microdata
beirc is now known as gilberth__
iskander has joined #lisp
<gilberth__> aeth: It is unfortunate that the alternative S-expr syntax for SGML like (:A (:HREF "foo") ...) seems to be more common. I prefer (:A :HREF "foo" ...).
stux|RC-- has joined #lisp
<aeth> gilberth__: it's more common and I like the look of it more, and I like superficially how it's implemented more, but thinking about it, I think you'd have to hardcode a lot of information about HTML to make it work afaik
<vms14> I'd prefer (link "foo" "click here")
<vms14> and even have a way to add some onclick event or alike
<aeth> vms14: think about it as a multi-pass compiler... https://en.wikipedia.org/wiki/Multi-pass_compiler#/media/File:Multi-passcompiler.png
<aeth> vms14: the part where you generate a data file (e.g. HTML or XML) or source code (e.g. SQL or GLSL) is the last step, the code generation step, where you're taking s-expressions and turning them into strings (or whatever... maybe even compiling a language to ASM!)
danielvu has quit [Quit: WeeChat 2.5]
<aeth> But you're free to do as many steps as you want
<vms14> well the first attemtp was to emulate the js dom with CLOS
stux|RC has quit [Ping timeout: 252 seconds]
<vms14> and then make a recursive function that looks for the node you give it and goes rendering and traversing all the children
<vms14> but I guess I'll go with plists
danielvu has joined #lisp
xkapastel has joined #lisp
<vms14> so nodes are symbols and properties are in their property list
<aeth> vms14: It's trivial to turn (link "foo" "click here") into (:a :href "foo" "click here") which then is not-as-trivially (but not *too* difficultly) turned into "<a href=\"foo\"> click here </a>"
<aeth> vms14: What you want at the base layer is as close to a direct representation of the target (data or programming) language as possible.
<vms14> why?
<aeth> Because then every step is simple and isolated
<vms14> makes sense
<aeth> Even if you're writing everything yourself, pretend you're not. Alice is writing a program that turns (:a :href "foo" "click here") into "<a href=\"foo\"> click here </a>" and Bob is writing a program that turns (link "foo" "click here") into (:a :href "foo" "click here")
<aeth> (okay, maybe there wouldn't be spacing around the "click here" in the generated HTML, but it doesn't look as good without that spacing)
iskander has quit [Ping timeout: 264 seconds]
<vms14> long time not seen Alice and Bob
<vms14> xD
<vms14> the last time was with ssl explainations
<aeth> But notice how they're very different tasks. One is writing characters to a stream. The other is turning one CL list into another (although it might be at macro-expansion time)
Bike has joined #lisp
<aeth> And you can have as many layers of one CL list into another as you want. And you can even have a step that adds a parser so you can just read in text files that look like this: link "foo" "click here"
iskander has joined #lisp
<vms14> well it seems easier because you have the steps better defined
<vms14> and you can focus in doing just one thing
<vms14> also you gain isolation and flexibility
<vms14> and with flexibility come extensible programs
<aeth> That's 90% of programming in general. You have a big complicated task and you want to break it into as many trivial steps as possible, to the point where if any single piece is taken in isolation, then anyone would wonder what you're even doing or why it's taking you so long.
<aeth> The observers should be able to say "I could do that myself!" because they could.
<aeth> Except, of course, there's 10,000 such things, and what makes your program different is you took the time to do all of them (or found suitable libraries where available)
<aeth> And the whole reason you're generating XML/HTML/XHTML/etc. is because such data formats are *NOT* like that at all. They're unreadable messes, but you don't have to write them by hand.
smazga has quit [Quit: leaving]
Kundry_Wag has quit [Remote host closed the connection]
clothespin has quit [Ping timeout: 245 seconds]
vms14 has quit [Remote host closed the connection]
mindthelion has joined #lisp
karlosz has joined #lisp
FreeBirdLjj has joined #lisp
techquila has quit [Ping timeout: 245 seconds]
t58 has quit [Quit: Leaving]
FreeBirdLjj has quit [Ping timeout: 246 seconds]
Kundry_Wag has joined #lisp
anewuser has quit [Ping timeout: 245 seconds]
Kundry_Wag has quit [Ping timeout: 268 seconds]
edgar-rft has quit [Ping timeout: 258 seconds]
<drmeister> How does one suppress the debugger from coming up? Bind *debugger-hook* that just returns?
<Bike> what do you want to happen instead?
edgar-rft has joined #lisp
papachan has joined #lisp
sonologico has quit [Remote host closed the connection]
edgar-rft has quit [Ping timeout: 268 seconds]
edgar-xxx has joined #lisp
zigpaw has quit [Remote host closed the connection]
zigpaw has joined #lisp
karlosz has quit [Quit: karlosz]