deng_cn has quit [Read error: Connection reset by peer]
turkja has joined #lisp
deng_cn has joined #lisp
markong has quit [Ping timeout: 256 seconds]
fikka has joined #lisp
trocado has joined #lisp
nowhereman_ has joined #lisp
nowhere_man has quit [Ping timeout: 248 seconds]
damke_ has joined #lisp
hhdave has quit [Quit: hhdave]
z3t0 has quit [Remote host closed the connection]
z3t0 has joined #lisp
damke has quit [Ping timeout: 264 seconds]
Kaisyu has joined #lisp
ebrasca has quit [Read error: Connection reset by peer]
ebrasca has joined #lisp
FreeBirdLjj has joined #lisp
dddddd has quit [Ping timeout: 256 seconds]
arescorpio has joined #lisp
FreeBirdLjj has quit [Ping timeout: 268 seconds]
saki has joined #lisp
pmc_ has joined #lisp
rjid has joined #lisp
sjl has joined #lisp
rjid is now known as ansatz
sjl has quit [Ping timeout: 248 seconds]
z3t0 has quit [Remote host closed the connection]
ansatz has quit [Quit: Page closed]
dddddd has joined #lisp
EvW has quit [Ping timeout: 276 seconds]
Pixel_Outlaw has joined #lisp
ebzzry has joined #lisp
Rawriful has quit [Quit: WeeChat 1.4]
eli has quit [Remote host closed the connection]
trocado has quit [Ping timeout: 248 seconds]
brendyn has joined #lisp
bigfondue has joined #lisp
fittestbits has left #lisp [#lisp]
zazzerino has joined #lisp
fikka has quit [Ping timeout: 248 seconds]
pmetzger has quit []
Denommus has joined #lisp
fikka has joined #lisp
Arcaelyx has joined #lisp
dieggsy has joined #lisp
zmt00 has quit [Quit: Leaving]
jstypo has quit [Ping timeout: 260 seconds]
deng_cn has quit [Read error: Connection reset by peer]
deng_cn has joined #lisp
quazimodo has joined #lisp
Tobbi has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jstypo has joined #lisp
randomstrangerb has quit [Ping timeout: 240 seconds]
randomstrangerb has joined #lisp
Oladon has joined #lisp
pmc_ has quit [Ping timeout: 240 seconds]
fikka has quit [Ping timeout: 240 seconds]
nowhere_man has joined #lisp
nowhereman_ has quit [Ping timeout: 248 seconds]
fikka has joined #lisp
z3t0 has joined #lisp
safe has quit [Read error: Connection reset by peer]
pagnol has quit [Ping timeout: 248 seconds]
d4ryus1 has joined #lisp
whoman has quit [Remote host closed the connection]
whoman has joined #lisp
d4ryus has quit [Ping timeout: 248 seconds]
openthesky has quit [Quit: Page closed]
openthesky has joined #lisp
z3t0 has quit [Remote host closed the connection]
openthesky has quit [Quit: Leaving.]
openthesky has joined #lisp
fittestbits has joined #lisp
twouhm has joined #lisp
red-dot has quit [Quit: Going offline, see ya! (www.adiirc.com)]
alphor has quit [Quit: Bye!]
openthesky has left #lisp [#lisp]
alphor has joined #lisp
zmt00 has joined #lisp
fikka has quit [Ping timeout: 256 seconds]
z3t0 has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
z3t0 has quit [Ping timeout: 240 seconds]
kamog has joined #lisp
fikka has joined #lisp
safe has joined #lisp
red-dot has joined #lisp
oleo has joined #lisp
Denommus has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
borei has joined #lisp
<borei>
hi all !
EvW has joined #lisp
arescorpio has quit [Excess Flood]
ckonstanski has quit [Remote host closed the connection]
<borei>
i have question about lisp code optimization - matrix multiplication in my case. i undestand that topic is rather big, but still, some recommendations would be nice. I was trying to find best solution in C/C++ but didn't get explicit answer for it
<borei>
so what i have
<borei>
matrix, double-float, arbitrary size
damke_ has joined #lisp
<borei>
i store matrix elements in 1-dimensional array (simple-array) - that guarantee that data will be continouse
<borei>
to multiply matricies i can create nested loop with proper indexing, so it will do proper elements multiplication
<borei>
or i can pull row(s) and column(s) from input matricies and do multiplication (scalar multiplication) on them
<borei>
in second approach im hoping that vectors (rows and colums) will fit cache, but i can't control it
<borei>
so potentially i'll be loosing CPU cycles on moving data from one area to another
<borei>
in first approach more or less big matrix will not fit cache for sure, but there is no overhead on moving data, only access to elements
FreeBirdLjj has joined #lisp
alphor has quit [Quit: Bye!]
<borei>
there is 3rd approach - block matrix multiplication, but it's more complex in terms of the algorithm
alphor has joined #lisp
<pierpa>
in CL arrays are a continuous chunk of memory, whatever the number dimensions
<pierpa>
+of
<pierpa>
and your worries about cache don't make much sense
<pierpa>
by copying parts of the arrays somewhere else you won't diminish the amount of cache needed. On the contrary.
FreeBirdLjj has quit [Ping timeout: 260 seconds]
fikka has quit [Ping timeout: 256 seconds]
milanj has quit [Quit: This computer has gone to sleep]
rumbler31 has joined #lisp
<beach>
Good morning everyone!
<borei>
hi beach !
JuanDaugherty has quit [Quit: Ex Chat]
<borei>
pierpa: i was hoping that when i extract row (or columns) from matrix it will fit CPU cache, and multiplication will be done much faster, comparing pulling out individual element from huge array
<pierpa>
the extracted column may fit the cache, but to extract the it in the first place you have to traverse the data in the matrix, no?
<pierpa>
-the
<pierpa>
since you are traversing the matrix just multiply the numbers rather than copying them somewhere and then multiplying them
<borei>
correct
fikka has joined #lisp
rumbler31 has quit [Ping timeout: 264 seconds]
<borei>
ic your point
alphor has quit [Quit: Bye!]
alphor has joined #lisp
orivej has quit [Ping timeout: 240 seconds]
shka has joined #lisp
EvW has quit [Ping timeout: 265 seconds]
dieggsy has quit [Ping timeout: 252 seconds]
pierpa has quit [Quit: Page closed]
dessm has joined #lisp
SpikeMaster has joined #lisp
d4ryus1 has quit [Ping timeout: 248 seconds]
zazzerino has left #lisp ["ERC (IRC client for Emacs 25.1.1)"]
randomstrangerb has quit [Ping timeout: 248 seconds]
randomstrangerb has joined #lisp
d4ryus1 has joined #lisp
SpikeMaster has quit [Client Quit]
Pixel_Outlaw has quit [Quit: Leaving]
smasta has joined #lisp
dddddd has quit [Remote host closed the connection]
milanj has joined #lisp
Bike has quit [Quit: sleep]
schoppenhauer has quit [Ping timeout: 240 seconds]
rumbler31 has joined #lisp
schoppenhauer has joined #lisp
fikka has quit [Ping timeout: 240 seconds]
rumbler31 has quit [Ping timeout: 240 seconds]
fikka has joined #lisp
LocaMocha has joined #lisp
Amplituhedron has quit [Read error: Connection reset by peer]
igemnace has joined #lisp
damke has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
damke_ has joined #lisp
damke has quit [Ping timeout: 264 seconds]
bigfondue has quit [Quit: WeeChat 1.6]
kamog has quit [Quit: Leaving.]
bigfondue has joined #lisp
openthesky has joined #lisp
randomstrangerb has quit [Ping timeout: 248 seconds]
pyx has joined #lisp
pyx has quit [Client Quit]
randomstrangerb has joined #lisp
red-dot has quit [Quit: Going offline, see ya! (www.adiirc.com)]
<borei>
1000x1000 matrix multiplication ~apprx 28 sec.
<borei>
Intel(R) Core(TM) i7-4600M CPU @ 2.90GHz
<borei>
not sure is it good or bad
fikka has quit [Ping timeout: 240 seconds]
<borei>
sounds like not good
<beach>
borei: What algorithm are you using?
<borei>
my own
<beach>
You invented a new algorithm? Is it better than the naive one?
<borei>
well, not invented, i'd implementation is mine
fikka has joined #lisp
<borei>
what is native one ?
<beach>
The cubic algorithm that we were taught in math class.
<beach>
borei: I think if you are going to build a library for such things, you need to read up on current best practice.
<beach>
borei: Careful though, it looks like Strassen's algorithm is based on the idea that multiplication is way more expensive than addition. That may no longer be the case.
<shka>
beach: it will be true for integers
<beach>
Indeed.
<beach>
borei: Also, since all modern Common Lisp systems have threads, you may want to investigate parallel algorithms for use when the matrices are big.
<shka>
btw, I could use matrix library that is actually good
<shka>
and has no C in it
<shka>
… and if you are going to use threads, please stick to the lparallel
<shka>
you will make plenty of people happy :-)
<beach>
borei: But then again, perhaps your goal is not excellent performance. I was just guessing that since you mentioned execution time.
<borei>
there are a lot of reading
<borei>
i did implementation of block matrix multiplication (in C++)
<beach>
It is a vast domain that many very smart people have been working on for a long time, so yes, there is a lot of reading to be done.
<borei>
and it's pretty close to what i read now
<borei>
shak: why lparallel ?
<borei>
in any cases seems like i need to get deep dive in linear algebra - so exciting field
michalisko has quit [Ping timeout: 256 seconds]
<borei>
i do have thread support, but at this moment it's sbcl native one
<borei>
so my library is not portable
damke has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
michalisko has joined #lisp
<beach>
Do you use any thread features that are not available in Bordeaux-threads?
<borei>
can't say, currently i have only threads it self, mutexes and queues
<borei>
apperantly it will be covered by Bordeaux library
<stylewarning>
borei: feel free to contribute to MAGICL!
<rme>
Speaking of Bordeaux, I'm going to be there for about 10 days starting Feb. 23rd.
<jack_rabbit>
I've noticed in some .asd files that keywords are prefixed with '#'. What is the difference between e.g. :foo and #:foo?
sjl has joined #lisp
<borei>
stylewarning: i still consider myself entry lisp level
<borei>
have some progress, but still don't have answers for some basic questions
<borei>
just taking the facts as-is
<jackdaniel>
jack_rabbit: :foo is a keyword
<jackdaniel>
#:foo is an uninterned symbol
<jackdaniel>
if you use :foo in asd definition, you "pollute" keyword package with foo
sjl has quit [Ping timeout: 248 seconds]
<jackdaniel>
if you use foo in asd definition, you "pollute" asdf-user package (or whichever package you are in)
<jack_rabbit>
I see. So it's just to avoid interning the symbols, since they're only needed for loading.
<jackdaniel>
using #:foo doesn't intern symbol in any package
<jack_rabbit>
but is (eq #:foo #:foo) ?
<jackdaniel>
yes, especially that they are used only for their names. afair asdf coerces them to downcase strings anyway
<jackdaniel>
it is not eq
<jack_rabbit>
okay, I figured.
<jackdaniel>
but that doesn't matter for asdf which operates on strings
<jack_rabbit>
that makes sense.
<shka>
borei: because thread pool, that's why
red-dot has joined #lisp
fikka has quit [Ping timeout: 240 seconds]
nox2 has joined #lisp
igemnace has quit [Quit: WeeChat 2.0.1]
oleo has quit [Remote host closed the connection]
Oladon has quit [Quit: Leaving.]
smasta has quit [Ping timeout: 248 seconds]
<beach>
jack_rabbit: It is not only a matter of avoiding the "pollution" of the keyword package. It is also a message to the person reading your code, that the package of the symbol does not matter. If you use a keyword, then the person reading your code can't immediately know whether the package is important or not.
<jack_rabbit>
beach, aren't keywords package-independent? Or rather, they are all interned into the keyword package? When would the package be important when using a normal keyword?
Fare has joined #lisp
<jack_rabbit>
Or are you contrasting with non-keyword symbols?
<jackdaniel>
jack_rabbit: it may be important for instance in eq comparison (which you have mentioned)
<jackdaniel>
or take example, which is untrue for asdf: systems are represented by symbols (not strings) - in such scenario you could specialize methods via eql
<jackdaniel>
that is an example, where "symbol" matters
<beach>
jack_rabbit: A keyword is by definition a symbol that has the KEYWORD package as its package.
<jack_rabbit>
beach, right.
<jack_rabbit>
jackdaniel, so I would use non-interned symbols when I don't care that they are eq.
Karl_Dscc has joined #lisp
<beach>
jack_rabbit: There are a number of situations where the package of a symbol is important. For example, if you do (find ... :test ...) you can't do (find ... #:test ...) and expect the same result.
<jack_rabbit>
beach, of course.
<beach>
jack_rabbit: No, you would use uninterned symbols when you want the person reading your code to know that the package of the symbol doesn't matter.
<jackdaniel>
jack_rabbit: that's not exactly what I meant. If systems were represented by symbols, you wouldn't want to use uninterned symbols at all, you'd want to use interned ones instead (all the time). but this is only hyphotetical situation
<jack_rabbit>
jackdaniel, Yes, I get that. But that is due to the fact that you'd want to be able to compare the symbols and determine that they are eq or not, right?
<jack_rabbit>
beach, Sorry, maybe I'm being dense. I don't get the association with package. Can you give an example of when the package does not matter?
<beach>
jack_rabbit: EQ comparison is one possibility, but I can see situations where nobody cares about EQ, but the package is still important.
<stylewarning>
Package doesn’t matter when symbols are used as string designators
<jackdaniel>
not only that – imagine hypothetical function find-system. you don't care how it is compared, but if it is implemented to work on symbols then you wouldn't be able to look for a system denoted by a specific symbol
<stylewarning>
For example, the symbols in LOOP
<jackdaniel>
stylewarning: asdf is another example - it works on downcased designators
<rme>
people often use uninterned symbols (and keywords) as string designators. Instead of writing "FOO", they write :foo or #:foo
<beach>
jack_rabbit: One such example is in the name of the symbols exported in a DEFPACKAGE form. These names are used only as string designators.
<jack_rabbit>
beach, So with keywords, you say that the package is still important because the fact that they are all in keyword package has consequences?
<phoe>
jack_rabbit: again, depends on the context
<phoe>
if the symbols are used as string designators, the package does not matter
<phoe>
if the symbols are used as symbols, the package most likely will matter.
<jack_rabbit>
Because to me, it seems that keywords are a way to use symbols without regard to a particular package (except implicit keyword package I guess.)
<phoe>
keywords are a way to use keywords, not all symbols.
<jack_rabbit>
OK. So the only time non-interned symbols are useful is if they are used as string designators?
<jack_rabbit>
phoe, yes, that is what I meant.
<phoe>
not really, also as gensyms and they also have a few more discrete use cases
<stylewarning>
jack_rabbit: they are also useful when you wish to produce symbols for bindings
<beach>
jack_rabbit: I am not saying that the package IS important for ALL uses of keywords. We already had an example of that, e.g. when you use a keyword as a string designator. I am saying that the person reading your code MUST ASSUME (until proven wrong) that the package of a symbol is important, unless it is an uninterned symbol.
<jack_rabbit>
mmmmm I didn't think of that.
<phoe>
(let ((gensym '#:foo)) ...) - though this is mostly abstracted away via #'GENSYM and ALEXANDRIA:WITH-GENSYMS.
<jack_rabbit>
beach, sure. I think I get it.
<phoe>
and what beach said - using an interned symbol implies that the package *may* be important in that context.
<phoe>
doesn't have to be, like LOOP discards package information for its loop keywords, but in general, you can't rule out the possibility.
<jack_rabbit>
Could I also do (let ((#:foo "hello")) (write-string #:foo)) ?
<phoe>
jack_rabbit: nope.
<beach>
Exactly. So you put an additional burden on the person reading your code by being less specific than you could be.
<jack_rabbit>
phoe, mmm. Why does the gensym work, then?
mishoo has joined #lisp
<beach>
jack_rabbit: Why does it work?
<phoe>
jack_rabbit: because you generate the symbol once and put the same generated symbol in all the places.
<beach>
That's a strange question.
<jack_rabbit>
phoe, ahhhhhh.
<phoe>
just because (let ((foo 42)) (frob foo)) works.
<phoe>
(let ((#1=foo 42)) (frob #1#))
<phoe>
(let ((#1=bar 42)) (frob #1#))
<phoe>
(let ((#1=#:baz 42)) (frob #1#))
<phoe>
(let ((#1=#.(gensym) 42)) (frob #1#))
<jack_rabbit>
phoe, yes. Because something is bound to the instance of the symbol, I can reference the same symbol in multiple places through the binding.
<beach>
phoe: Nice explanations and examples!
fikka has joined #lisp
<jack_rabbit>
Even though it isn't interned.
<phoe>
jack_rabbit: LET doesn't care about internedness.
<jack_rabbit>
phoe, sure, I don't mean to suggest that.
<phoe>
LET only wants symbols that already aren't constant variables so it can bind lexivars to them.
<phoe>
which is why you can't bind T, NIL, PI or keywords.
<phoe>
beach: thanks. (:
<jack_rabbit>
I just mean, I understand that the reader reads each instance of #:foo as a different symbol, but with the gensym, I'm binding a particular instance and reusing that, which is why it works, right?
<phoe>
Yes, exactly.
<jack_rabbit>
great.
<phoe>
(eq #:foo #:foo) ;=> NIL
<jack_rabbit>
yes.
<phoe>
because you have two different instances.
<jack_rabbit>
I don't understand the #1=... syntax. I need to read about that.
<phoe>
jack_rabbit: it's a reader macro. What it does, is.
<phoe>
#1=foo - this reads and "memorizes" the object represented by FOO.
<phoe>
#1# - this puts another reference to FOO in the place where this is read.
<flip214>
is there some machine-readable version of ROOM? One that returns an alist or plist or so?
smasta has joined #lisp
<phoe>
So (list #1=(make-hash-table) #1# #1# #1#) will give you a list of four elements. All of these elements will be EQ to each other, meaning they're the same object.
z3t0 has joined #lisp
<jack_rabbit>
phoe, I see. It's a short-hand binding to an integer #n#?
<phoe>
jack_rabbit: not really. The integer is used as a reference number internally in the reader.
<jack_rabbit>
Yeah, that works for my understanding. Maybe I'm not expressing it correctly.
<phoe>
flip214: definitely not a standard thing. ROOM prints to standard-output, and it's implementation-dependent so it may print nothing in the most degenerate case.
<jack_rabbit>
I guess it's not a binding because it happens only in the reader?
<phoe>
jack_rabbit: you may think of it as a read-time binding.
<jack_rabbit>
right, good.
<jack_rabbit>
That makes sense.
<phoe>
But once the read time is over, that binding is discarded.
<jack_rabbit>
Yes, perfect.
<phoe>
It is not used anymore.
<jack_rabbit>
What is the lexical scope of the bindings?
<phoe>
The currently read form.
<jack_rabbit>
makes sense.
<phoe>
'(1 (2 (3 (4 #1#=foo))) #1#) will work.
<flip214>
phoe: yeah, that's why I'm asking. so no TRIVIAL-ROOM or similar library yet, right? Thanks anyway!
<jack_rabbit>
phoe, oh. hmmm.
<phoe>
flip214: none that I know of, but my knowledge is limited in scope.
smasta has quit [Ping timeout: 240 seconds]
<jack_rabbit>
phoe, So it's the scope of the top-level form?
<phoe>
jack_rabbit: again, the reader doesn't really care about the scope.
<phoe>
all it cares for is, "am I still reading, or do I return?".
<phoe>
and that, in turn, implies the scope of the top-level form, just as you have said.
<jack_rabbit>
great.
<jack_rabbit>
So it is valid until the outer-most form is finished being read.
<phoe>
The above is also why setting RECURSIVEP in calls to READ is important.
z3t0 has quit [Ping timeout: 264 seconds]
<jack_rabbit>
phoe, I need to read on that. I've seen it many times and wondered about it.
<phoe>
Because the RECURSIVEP setting preserves the #1# bindings if set. If it is not set, they are started from scratch.
<phoe>
RECURSIVEP has other uses, but in this context, it's the most important.
<phoe>
s/uses/implications/
<jack_rabbit>
So RECURSIVEP (in this context) if nil, resets the bindings.
<jack_rabbit>
Then the bindings are global?
<phoe>
Define "global".
<phoe>
They are per invocation of non-recursive READ.
<phoe>
An example of non-recursive read is REPL reading the toplevel.
<phoe>
All other READs issued by that non-recursive READ *must* be recursive.
<jack_rabbit>
OK. So when a non-recursive read returns, they are lost.
<phoe>
Yes.
<jack_rabbit>
cool.
makomo has joined #lisp
<jack_rabbit>
That makes more sense than what I assumed, which is that they were preserved between read calls.
smasta has joined #lisp
<phoe>
You can think that a toplevel READ does something like (let ((*sharpsign-sharpsign-bindings* (make-hash-table))) ...)
fikka has quit [Ping timeout: 240 seconds]
<phoe>
and the non-toplevel READ does *not* do it.
<jack_rabbit>
phoe, Yes, that is what I am thinking now.
<jack_rabbit>
(how I'm modelling it in my head, anyway.)
<phoe>
It merely uses the dynavar value from previous READ calls.
<jack_rabbit>
yes.
<jack_rabbit>
It must also check if it's actually bound, too, yes? Or can I not set RECURSIVEP to t if I'm not already in a call to read?
<phoe>
jack_rabbit: I just used it as an example.
<phoe>
But if you already are in a READ call, you must set RECURSIVEP.
<jack_rabbit>
phoe, sure. I'm curious about the behaviour anyway.
<phoe>
What READ does internally is implementation-dependent.
<jack_rabbit>
surely.
<jack_rabbit>
Can I set RECURSIVEP if I'm *NOT* already in a read call, though?
<beach>
jack_rabbit: No, RECURSIVE-P is a lexical argument to READ, so it is not accessible to you.
<jack_rabbit>
So it says it's expected.
<phoe>
"If recursive-p is true, the call to read is expected to be made from within some function that itself has been called from read or from a similar input function, rather than from the top level. "
<beach>
jack_rabbit: Just like if you do (defun f (x) ...) you can't set X unless you are inside the call to F.
<jack_rabbit>
So I would assume I cannot set RECURSIVE-P if I'm not already in a call to READ.
<phoe>
I am interpreting it this way. Otherwise I think it's UB.
<beach>
jack_rabbit: But you are never "in a call to READ" unless you edit the code of the READ function
<beach>
jack_rabbit: It is a LEXICAL variable, not a special variable.
<jack_rabbit>
beach, I understand that. Maybe I am using the wrong terminology.
<phoe>
Inside symbol macro functions, for example, you're always in some toplevel READ call.
<jack_rabbit>
phoe, naturaly.
<phoe>
wait a second, symbol macro function
<phoe>
did I get the term right
_mjl has joined #lisp
<phoe>
no, I did not - READER-macro-function.
<beach>
jack_rabbit: The only code that can assign to the variable RECURSIVE-P is the code inside the READ function, just like my F and X example.
<jack_rabbit>
phoe, Is that not true of non-reader macro functions?
<jack_rabbit>
beach, by "set RECURSIVE-P" I mean call read with argument RECURSIVE-P equal to t.
<beach>
jack_rabbit: Unless you call READ, you are not in some top-level call to READ.
<beach>
jack_rabbit: That is VERY DIFFERENT.
<phoe>
jack_rabbit: normal macro functions do not have to be called inside READ.
fikka has joined #lisp
<jack_rabbit>
beach, I understand that, but I did not introduce that terminology.
<jack_rabbit>
beach, That appeared to be shorthand for what we were talking about.
<beach>
jack_rabbit: You can always pass whatever value you want for RECURSIVE-P to your call to READ.
<phoe>
you can all MACROEXPAND, for example, which does not require #'READ to be on the stack anywhere.
<jack_rabbit>
phoe, ahh, yes.
<phoe>
and reader macro functions are used exclusively in the reader, AFAIK.
<jack_rabbit>
You *could* call them manually outside the reader?
<phoe>
Is it even legal to funcall reader macro functions via user code?
<phoe>
That's exactly my question.
<beach>
I think it is.
<beach>
Good question though.
<beach>
The result may not be what you expect.
<phoe>
This would imply that recursive READs are allowed at the toplevel.
<beach>
Like I said, nothing prevents you from calling READ yourself with RECURSIVE-P equal to a true value.
<phoe>
Because this means that you can funcall a (get-macro-character #'() for example.
<jack_rabbit>
hmmmm
<phoe>
Which may contain a recursive READ-DELIMITED-STRING call.
<phoe>
And there would be no toplevel READ in that call.
<phoe>
Heh, funny.
<beach>
Ah, hold on...
<phoe>
!
<beach>
"If recursive-p is true, the call to read is expected to be made from within some function that itself has been called from read or from a similar input function, rather than from the top level. "
<phoe>
Yep, that is what I quoted before.
<beach>
Oh, sorry.
<beach>
Missed it.
<phoe>
Therefore it might be UB if there is no non-recursive READ on the stack but you call a recursive READ.
<beach>
So I take that to mean "the consequences are undefined if READ is called with RECURSIVE-P being true at the top level".
<phoe>
Because if that expectation is missed--- yes.
<beach>
jack_rabbit: Passing a value as an argument to a function ESTABLISHES A BINDING for the corresponding parameter. Establishing a binding for a variable is a very different process from that of SETTING the value of a variable.
<phoe>
aaaaaah, lispin' in the morning~
<jack_rabbit>
beach, I am not confused about that. Again, I interpreted phoe's statements as a convenient shorthand for what we were talking about.
<phoe>
beach: what about the people who are against the establishment?
z3t0 has quit [Ping timeout: 252 seconds]
<yggdrasil_core>
so, has anyone here gotten renderdoc to work with a common lisp program using cl-opengl in sbcl?
* phoe
goes to #lispcafe with that
<beach>
Good plan.
safe has quit [Read error: Connection reset by peer]
fikka has joined #lisp
<jack_rabbit>
beach, phoe> But if you already are in a READ call, you must set RECURSIVEP
<yggdrasil_core>
I figure it's a streatch but I can't get the two to work together and it is making debugging my texture loading hard
<jack_rabbit>
I knew what phoe meant.
<phoe>
yggdrasil_core: just a random thought, people over at #lispgames might have more experience with OpenGL in CL
<yggdrasil_core>
yeah I asked in there last night :<
<phoe>
:( I see.
<yggdrasil_core>
no one said anything so maybe I'll ask again at some point :p
<phoe>
Yep, do it, and perhaps post more concrete errors.
<yggdrasil_core>
it doesn't give me any errors, it just doesn't do anything
<phoe>
It's hard to figure out general cases like getting X to work on Y, and easier to figure out why error X happens with stacktrace Y.
<phoe>
...ouch.
<phoe>
Does it hang, or something?
<phoe>
If yes, you could interrupt it and *then* get a stacktrace.
<yggdrasil_core>
when I set it up to run the binary it just either doesn't open it, or it immediately closes, when I inject into the process it just doesn't capture anything
<phoe>
Is it a separate program and not a Lisp-invokable library?
<yggdrasil_core>
I have tested it on some binaries produced from c code and those worked
<yggdrasil_core>
it's a binary that I am producing with sbcl
Karl_Dscc has quit [Remote host closed the connection]
<yggdrasil_core>
I use save-lisp-and-die to produce the binary, which does work just fine when ran outside of renderdoc
borei has quit [Ping timeout: 256 seconds]
asarch has quit [Quit: Leaving]
<phoe>
hm.
<phoe>
You might want to ask in #sbcl in that case.
<ecraven>
can you add in liberal FORMATs to see what's going on?
<ecraven>
printf-debugging ;)
<phoe>
^
<yggdrasil_core>
I can't since the problem is on the gpu side
<ecraven>
do you check for opengl errors at every possible place?
<yggdrasil_core>
unless you mean to see how far it is getting when renderdoc starts it (if it is actually starting it)
<phoe>
I'd check that first, yes
z3t0 has joined #lisp
<yggdrasil_core>
I'm not, but thats because in this particular case I don't think there is an error happening :p
<ecraven>
well, when in doubt, start from the beginning and see how far it gets
<ecraven>
as in profiling, what we think is sometimes not what actually happens ;)
<yggdrasil_core>
I'm submitting texture data and having problems with it being loaded right, because I am not sure what pngload is giving me ._.
<ecraven>
dump whatever pngload gives you, look at that?
<ecraven>
if it's just rgba, you should be able to open it with some graphics program
<yggdrasil_core>
I'll screw around some more and see if I can find something out
<yggdrasil_core>
thanks for the help
smasta has quit [Ping timeout: 248 seconds]
z3t0 has quit [Ping timeout: 240 seconds]
<makomo>
anyone see what's going on in #clnoobs? :-D
dessm has quit [Remote host closed the connection]
<phoe>
not anymore
<beach>
Can you summarize?
<phoe>
spambot.
<beach>
Oh.
<makomo>
yup, it's been dealt with
<phoe>
it seems all of freenode is under siege.
<yggdrasil_core>
was it the one that posts a bunch of square characters and then highlights everyone in the channel?
<makomo>
yggdrasil_core: yes :-)
<phoe>
yessss.
<phoe>
again.
<yggdrasil_core>
It's been hitting a lot of channels then :v
<shka>
there is awful lot of spam lately
mishoo has quit [Ping timeout: 248 seconds]
markong has joined #lisp
scymtym has quit [Ping timeout: 260 seconds]
pillton has quit [Remote host closed the connection]
<jack_rabbit>
I've seen a few channels that are voicing regular users.
<jack_rabbit>
to confront the pop-ins
vlatkoB has joined #lisp
smasta has joined #lisp
SAL9000_ has quit [Ping timeout: 246 seconds]
randomstrangerb has quit [Ping timeout: 248 seconds]
SAL9000 has joined #lisp
randomstrangerb has joined #lisp
z3t0 has joined #lisp
House2 has joined #lisp
z3t0 has quit [Ping timeout: 248 seconds]
SAL9000_ has joined #lisp
<House2>
(#\a #\b #\c) - howto convert to "abc"?
Arcaelyx has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
SAL9000 has quit [Ping timeout: 268 seconds]
<jack_rabbit>
House2, coerce
<jack_rabbit>
(coerce '(#\a #\b #\c) 'string)
mishoo has joined #lisp
<Fare>
(map 'string 'identity '(#\a #\b #\c))
<Fare>
(uiop:strcat #\a #\b #\c)
House2 has quit [Client Quit]
nox2 has quit [Ping timeout: 256 seconds]
ym has quit [Ping timeout: 240 seconds]
shka has quit [Ping timeout: 252 seconds]
z3t0 has joined #lisp
<makomo>
phoe: did you see that #freenode got flooded too?
<makomo>
bots randomly popping in, dropping a line and quitting
<asdfjkla>
jackdaniel: ty would you use macros or rearrange code another way?
scymtym has joined #lisp
red-dot has quit [Quit: Going offline, see ya! (www.adiirc.com)]
fikka has quit [Ping timeout: 240 seconds]
sjl__ has joined #lisp
sjl has quit [Ping timeout: 265 seconds]
<jackdaniel>
what do you need macros for?
<jackdaniel>
regarding arrangement, I've mentioned: factor main program into function
<jackdaniel>
preferably global variables should be function arguments instead
<jackdaniel>
if you don't need macros don't use them (this is a rule of a thumb, when you known what you are doing you may bend this rule of course)
<jackdaniel>
minion: tell asdfjkla about pcl
<minion>
asdfjkla: have a look at pcl: pcl-book: "Practical Common Lisp", an introduction to Common Lisp by Peter Seibel, available at http://www.gigamonkeys.com/book/ and in dead-tree form from Apress (as of 11 April 2005).
z3t0 has joined #lisp
ft has quit [Ping timeout: 240 seconds]
<asdfjkla>
ty
<asdfjkla>
using defvar instead creates infinite loop
<phoe>
asdfjkla: show us how you use it
<asdfjkla>
phoe: just did s/setq/defvar
fikka has joined #lisp
deng_cn has quit [Read error: Connection reset by peer]
<phoe>
asdfjkla: still don't see how it would infinite-loop anything.
<jackdaniel>
no, try something like (defun hangman (word guesses current-word) …)
<jackdaniel>
don't use earmuffs, because they won't be global anymore
<jackdaniel>
since current-word is result of computation on word and guesses, you may have (Defun hangman (word guesses) (let ((current-word (current-matches word guesses))) …))
<jackdaniel>
because current-word is not really an argument, it is more a helper variable
<jackdaniel>
then you'll call hangman like (hangman "apple" "")
<asdfjkla>
(I could just use current-matches word "", just noticed)
<asdfjkla>
(no forget that)
thijso has joined #lisp
<jackdaniel>
also gusesses should be put in let (same as current-word)
<jackdaniel>
not as defvar
<asdfjkla>
ok
damke has joined #lisp
fikka has quit [Ping timeout: 246 seconds]
damke_ has quit [Ping timeout: 264 seconds]
z3t0 has joined #lisp
hhdave has joined #lisp
whoman has quit [Remote host closed the connection]
whoman has joined #lisp
z3t0 has quit [Ping timeout: 256 seconds]
whoman has quit [Remote host closed the connection]
whoman has joined #lisp
thijso has quit [Ping timeout: 268 seconds]
fikka has joined #lisp
asdfjkla has quit [Quit: Page closed]
solyd has joined #lisp
red-dot has joined #lisp
marusich has joined #lisp
schweers has joined #lisp
ym has joined #lisp
Murii has joined #lisp
paule32 has quit [Ping timeout: 256 seconds]
Murii has quit [Ping timeout: 252 seconds]
paule32 has joined #lisp
randomstrangerb has quit [Ping timeout: 240 seconds]
fikka has quit [Ping timeout: 240 seconds]
randomstrangerb has joined #lisp
fikka has joined #lisp
z3t0 has joined #lisp
z3t0 has quit [Ping timeout: 240 seconds]
z3t0 has joined #lisp
z3t0 has quit [Ping timeout: 256 seconds]
ryanbw has joined #lisp
shifty has quit [Ping timeout: 268 seconds]
deng_cn has quit [Ping timeout: 248 seconds]
nirved has joined #lisp
<beach>
I started working on rules for indenting Common Lisp code. Here is a first version of what I came up with: http://metamodular.com/indentation.pdf
<beach>
Comments are welcome.
jmercouris has joined #lisp
z3t0 has joined #lisp
<flip214>
beach: looks good.
<flip214>
beach: what about multi-line strings?
<flip214>
and other special constructs, eg. CL-INTERPOLs #?rx( reg-ex ) ?
<flip214>
beach: how should comments be indented?
<beach>
For a multi-line string, the beginning of the string would be indented as usual, and the rest of it, just left alone.
<phoe>
what about keyword args? (foo bar :baz 1 \n :quux 2)
<flip214>
that means the second and other lines have to be indented manually?
<beach>
Comments are part of the parse result, so in the case of ;; they are indented with the code.
<phoe>
emacs currently indents :baz and :quux together
<flip214>
phoe: right, and how about pairs like in SETF?
attila_lendvai has joined #lisp
<flip214>
I might like
<beach>
flip214: Sure, because indentation would be part of the string in that case.
<beach>
phoe: I think it is impossible to come up with a general rule.
sjl__ has quit [Ping timeout: 276 seconds]
<phoe>
beach: slime often utilizes function lambda lists to enhance its indentation.
<phoe>
if a function accepts &key args then slime seems to figure it out and indent accordingly.
<beach>
flip214: Pairs like that are not a problem. The rules only compute the indentation of the first parse result on the line.
<beach>
phoe: That would certainly be possible.
z3t0 has quit [Ping timeout: 276 seconds]
<phoe>
beach: I suggest that you include that. &key args are pretty important to indent properly because they tend to come aplenty at times.
<beach>
Good idea.
<beach>
I'll do that.
<phoe>
Also I suggest that you spend a little bit of time on indenting macro lambda lists, too.
<phoe>
basically - indenting all kinds of lambda lists that may come.
<beach>
Noted.
<phoe>
I think that would be a very good basis for general indentation.
Cymew has quit [Remote host closed the connection]
<phoe>
Since most Lisp forms are function/macro/specop calls, and these have their lambda lists and lambda lists keywords.
<phoe>
You can leverage this fact to your advantage.
z3t0 has joined #lisp
<phoe>
...just like slime does it nowadays.
<phoe>
I'm pretty excited, actually.
z3t0 has quit [Ping timeout: 255 seconds]
damke has quit [Ping timeout: 264 seconds]
<Shinmera>
Don't forget a mechanism to allow customising indentation from code.
<phoe>
The moment your editor has utilities for paren matching and ability to do general indentation, then it has the two utilities required for sane Lisp writing.
<phoe>
That one, yes, something like TRIVIAL-INDENTATION does for slime nowadays.
<flip214>
Maerj: instead of string= and string/= in finish you could use COND
<flip214>
and use the return value of that in the main loop condition
<flip214>
need to pass lives in as well, of course
<Maerj>
flip214: thx
<flip214>
Maerj: or you store the string-comparison result and do
<jmercouris>
It looks pretty alright though, kind of hard to read through at first glance I thought "play" would be the main loop, then I scrolled down and it was "hangman"
vyzo has quit [Read error: Connection reset by peer]
<Maerj>
would you recommend macros? maybe they are only useful for longer programs..
<jmercouris>
Generally, don't write a macro where a function will do
<jmercouris>
I would say your program is sufficiently simple where it is not really necessary
<Maerj>
ok
vyzo has joined #lisp
damke has quit [Ping timeout: 264 seconds]
quazimodo has quit [Ping timeout: 240 seconds]
<attila_lendvai>
it doesn't depend on the length so much as on readability. look at macros as a thin layer of syntax sugar. i.e. you should implement most of the functionality as functions, and if the syntax of that API is cumbersome (e.g. you need to create many (lambda () ...) wrappers), *then* create a thin layer of macro(s) that smoothen out the syntax
<Maerj>
attila_lendvai: ok, thanks for the insight
JuanDaugherty has joined #lisp
z3t0 has joined #lisp
damke has joined #lisp
z3t0 has quit [Ping timeout: 252 seconds]
fittestbits1 has joined #lisp
fittestbits has quit [Quit: Leaving.]
EvW1 has joined #lisp
quazimodo has joined #lisp
attila_lendvai has quit [Read error: Connection reset by peer]
saki has joined #lisp
chiyosaki has quit [Ping timeout: 252 seconds]
attila_lendvai has joined #lisp
porky11 has joined #lisp
<porky11>
hi
Maerj has quit [Quit: Page closed]
<porky11>
how do I upload an image with hunchentoot?
<porky11>
I want others to download images from my server
<porky11>
or see images
<porky11>
on a website
<Xach>
Ok
z3t0 has quit [Ping timeout: 268 seconds]
rumbler31 has joined #lisp
<Xach>
porky11: there is more than one way. i think the easiest is with the easy-handler system. But a file response is mostly the same as any other response - you load the data from the file and send it as the response.
<porky11>
I have set something to "image" instead of "text/html" and just read the file char by char and write it into a string
<Xach>
porky11: It would be better to load it into an unsigned-byte 8 array.
<Xach>
porky11: When I was faced with a similar issue, I used a dedicated server for images (nginx) because it is more efficient.
<porky11>
but hunchentoot seems to return strings from it's handlers
<Xach>
and let lisp handle the dynamic content
<porky11>
*its
<Xach>
porky11: i believe the easy-handler code demonstrates how to serve a binary file
<Xach>
it is part of hunchentoot
papachan has joined #lisp
orivej has joined #lisp
z3t0 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]
z3t0 has quit [Ping timeout: 260 seconds]
tonton has quit [Ping timeout: 260 seconds]
Achylles has joined #lisp
nowhereman_ has joined #lisp
nowhere_man has quit [Ping timeout: 248 seconds]
rumbler31 has quit [Remote host closed the connection]
z3t0 has joined #lisp
makomo has quit [Ping timeout: 248 seconds]
red-dot has joined #lisp
fluke` has quit [Read error: Connection reset by peer]
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]
z3t0 has quit [Ping timeout: 240 seconds]
saki has quit [Remote host closed the connection]
jmercouris has quit [Ping timeout: 240 seconds]
saki has joined #lisp
damke_ has joined #lisp
damke has quit [Ping timeout: 264 seconds]
tessier has joined #lisp
tessier has joined #lisp
tessier has quit [Changing host]
larme has joined #lisp
Lord_of_Life has quit [Changing host]
Lord_of_Life has joined #lisp
Lord_of_Life has joined #lisp
dieggsy has joined #lisp
rumbler31 has joined #lisp
terpri has joined #lisp
fluke` has joined #lisp
dieggsy has quit [Ping timeout: 240 seconds]
python476 has joined #lisp
EvW1 has quit [Ping timeout: 276 seconds]
Bike has joined #lisp
raynold has quit [Quit: Connection closed for inactivity]
scymtym_ has quit [Ping timeout: 265 seconds]
scymtym_ has joined #lisp
drewc has joined #lisp
mishoo has quit [Ping timeout: 248 seconds]
nullman has quit [Remote host closed the connection]
nullman has joined #lisp
<dim>
depending on the project I like have a self-contained lisp image that embeds all the static resources (css, js, html, images) and serve from memory, and then for efficiency you can add nginx/varnish in front of hunchentoot
<dim>
the ability to deploy a single binary file that is self-contained, even for web based projects, is still something that I really like
CharlieBrown has joined #lisp
kjeldahl has quit [Ping timeout: 248 seconds]
dddddd has quit [Ping timeout: 264 seconds]
Jach[m] has joined #lisp
dddddd has joined #lisp
<ecraven>
that sounds really nice
<ecraven>
do you have a database that you interface with?
kjeldahl has joined #lisp
dddddd has quit [Excess Flood]
z3t0 has joined #lisp
dddddd has joined #lisp
<dim>
depends on the projects, for pgcharts yeah, but not in the way you'd think
Tobbi has joined #lisp
z3t0 has quit [Ping timeout: 252 seconds]
nox2 has quit [Ping timeout: 240 seconds]
sz0 has joined #lisp
brendyn has quit [Ping timeout: 268 seconds]
randomstrangerb has quit [Ping timeout: 264 seconds]
red-dot has quit [Quit: Going offline, see ya! (www.adiirc.com)]
randomstrangerb has joined #lisp
heurist` has joined #lisp
heurist has quit [Ping timeout: 248 seconds]
z3t0 has joined #lisp
oleo has joined #lisp
itruslove has quit [Remote host closed the connection]
giraffe has quit [Remote host closed the connection]
cuso4 has joined #lisp
z3t0 has quit [Ping timeout: 248 seconds]
Denommus has joined #lisp
warweasle has joined #lisp
didi has left #lisp ["there are always reasons to /part"]
kupad has quit [Ping timeout: 240 seconds]
kami has joined #lisp
<kami>
Hello #lisp
<oleo>
sup kami
z3t0 has joined #lisp
tessier has joined #lisp
tessier has joined #lisp
tessier has quit [Changing host]
z3t0 has quit [Ping timeout: 252 seconds]
jmercouris has joined #lisp
<jmercouris>
Shinmera: when evaluating trivial-indent:define-indentation, I should be able to just M-q and it will use that new indentation right?
FreeBirdLjj has joined #lisp
nox2 has joined #lisp
FreeBirdLjj has quit [Client Quit]
kami has quit [Ping timeout: 260 seconds]
* beach
should look at trivial-indentation before writing something new.
jmercouris has quit [Remote host closed the connection]
jmercouris has joined #lisp
mishoo has joined #lisp
FreeBirdLjj has joined #lisp
sjl__ has joined #lisp
z3t0 has joined #lisp
sjl__ has quit [Ping timeout: 256 seconds]
malice has joined #lisp
shifty has joined #lisp
z3t0 has quit [Ping timeout: 240 seconds]
<Shinmera>
jmercouris: Yes. Check if (trivial-indent:initialize-slime) returns T.
<Shinmera>
jmercouris: Also check if slime notes something in the minibuffer when you indent. It'll say something about an invalid structure if the indentation hint is malformed.
<jmercouris>
Interestingly enough, I was taking the default form for a defun, and applying it
<jmercouris>
but it was being ignored when I'd change the values
<jmercouris>
I didn't change the structure of the form
<jmercouris>
though, I don't think this is an issue with trivial indent, but somehow with emacs, or my lisp installation
<jmercouris>
Just simply this: (trivial-indent:define-indentation defcommand (4 &lambda &body))
<jmercouris>
and when I am over the body, in the minibuffer body shows as being selected
<jmercouris>
or if I M-x slime-reindent-defun it'll also make it 4
<jmercouris>
having to manually reindent every defcommand is certainly a damper on fun
<phoe>
I kind of wish (coerce 2 'boolean) would work
z3t0 has quit [Ping timeout: 264 seconds]
<jmercouris>
you'd think that coercing any truthy value should result in t
<malice>
you can just (not (not )) it
<malice>
which is a more general way to convert to boolean
<dlowe>
you could also (when 2 t)
<malice>
yup
<Shinmera>
Or... you know... just use it straight up. Cause we have generalised booleans.
<jmercouris>
Don't bring logical solutions into this discussion, I was just lighting up the torches
<dlowe>
prevents you from doing (eql bool-a bool-b)
<Shinmera>
jmercouris: I don't know what's going on but your setup is fucked somehow
<dlowe>
which is more succinct than (or (and bool-a bool-b) (and (not bool-a) (not bool-b)))
<Shinmera>
jmercouris: Try a bare minimum emacs with just slime or something.
scymtym_ has quit [Ping timeout: 264 seconds]
<jmercouris>
Shinmera: Yeah, it really is, the macro indents properly on other people's computers
killerstorm has joined #lisp
Cymew has quit [Remote host closed the connection]
makomo has joined #lisp
nullman has quit [Ping timeout: 276 seconds]
asarch has joined #lisp
nullman has joined #lisp
<killerstorm>
Hi, is anybody interested in a tiny gig, paid in cryptocurrency? I need a parser for a certain language. Might be like a hour of work if you have experience with parsing.
<makomo>
i was trying to find a decent one but haven't settled on any of them
Cymew has joined #lisp
<dlowe>
ooh, that's much better
dddddd has quit [Ping timeout: 248 seconds]
<dlowe>
well, not of esrap
random-nickname has joined #lisp
z3t0 has joined #lisp
random-nick has quit [Disconnected by services]
random-nickname is now known as random-nick
lnostdal has quit [Remote host closed the connection]
Cymew has quit [Ping timeout: 240 seconds]
Cymew has joined #lisp
fisxoj has joined #lisp
z3t0 has quit [Ping timeout: 240 seconds]
Arcaelyx has joined #lisp
FreeBirdLjj has joined #lisp
FreeBirdLjj has quit [Read error: Connection reset by peer]
FreeBirdLjj has joined #lisp
Cymew has quit [Ping timeout: 252 seconds]
Cymew has joined #lisp
<Shinmera>
Writing ad-hoc parsers from scratch is my thing
blackwolf has joined #lisp
ebzzry has quit [Ping timeout: 240 seconds]
Cymew has quit [Ping timeout: 256 seconds]
openthesky has quit [Quit: Leaving.]
openthesky1 has joined #lisp
openthesky1 has left #lisp [#lisp]
Cymew has joined #lisp
MrMc has joined #lisp
<killerstorm>
dlowe: Thx for example. Does esrap generate some nice error messages? Or at least a point where error happens...
Cymew has quit [Ping timeout: 256 seconds]
<killerstorm>
My offer stands, by the way. I'm short on time and would rather save myself a bit of effort.
Cymew has joined #lisp
<dlowe>
killerstorm: good error messages are hard - the usual way is to write more grammar rules that cover the entire input space that generate errors.
<dlowe>
unfortunately, my day job is a bit too intense to take this on atm
Cymew has quit [Ping timeout: 248 seconds]
<killerstorm>
Well currently I have Lisp-base DSL which doesn't even point to a line of code where error happened. So I guess anything would be an improvement...
sjl__ has joined #lisp
Cymew has joined #lisp
* beach
wonders how much energy and money is spent annually to avoid using Lisp.
Kaisyu has quit [Quit: Connection closed for inactivity]
<dim>
beach: +1
<jmercouris>
probably not that much, as there is not many "legacy" lisp projects that require maintenance
Arcaelyx has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<jmercouris>
s/is/are
<beach>
dim: Oh, yes, you would know, right? At least judging from your stories from your domain.
<dim>
well in my new position I'm doing some Python and C
<beach>
jmercouris: That is not the only point. I am talking about Greenspunning as well.
<dim>
C is ok, because it's meant to run within PostgreSQL code space and PostgreSQL is a very old C program (20+ years) so it comes with all the high-level abstractions you actually need
<beach>
jmercouris: I.e. people spending way more energy using a language that is not adapted to their problem just in order to avoid learning and using Lisp.
z3t0 has joined #lisp
<dim>
but having to use Python doesn't feel nice
<dim>
other than that, most of the stories I follow are where people are re-inventing SQL in their application language
<dim>
I'm not sure about Lisp itself apart from re-inventing it poorly in so called “modern” programming languages, and with what I could achieve with pgloader on my free time, I'd rather do CL
Cymew has quit [Ping timeout: 248 seconds]
killerstorm has quit [Ping timeout: 260 seconds]
Cymew has joined #lisp
<jmercouris>
beach: Ah okay, yeah, that would be interesting to know indeed, I'm sure it happens quite often as lisp is "intimidating"
z3t0 has quit [Ping timeout: 240 seconds]
<jmercouris>
I guess it would be akin to learning a non-latin language, not necessarily more complex, just unfamiliar, and that is why it scares users
<jmercouris>
dim: Python is just Lisp without all the benefits and magical indentation rules
<jmercouris>
Also lots of "great ideas" like decorators
<dim>
learning Common Lisp means questioning some of the things you took for granted and some of the well-known trivia such as “lisp is old and useless”, “there are no libs in lisp”, “you can't do XXX in lisp”, etc
<beach>
And without the object system, and without the speed.
<jmercouris>
speed is definitely an issue in python, which amazes me, as so many people spend their time on a single implementation
<beach>
The design of the language makes it hard.
<dim>
and then when you get to it you're like what? how come there are so many control operators, what is this OO model, handler-bind and restart-value what? packages are only about symbols? what's a system? etc
<jmercouris>
I was having GIL problems in so many of my projects, now you might say "you are the weakest link", and sure, maybe I am :P
<dim>
you basically have to retrain from scratch on many notions you though you'd know
<dim>
so I can't blame people for not wanting to put in the effort, unless they just don't feel like it for the wrong reasons without having had a curious look first
<jmercouris>
dim: Yes, there were lots of times where I THOUGHT I knew, but didn't, and still all the time as I am learning new lisp I am having to "relearn" concpets
Cymew has quit [Ping timeout: 268 seconds]
<jmercouris>
It is hard decision to make because learning lisp basically will not put food on the table for you, with any degree of ease another language will
<jmercouris>
You could learn OCaml and you'd probably find a job easier
<beach>
dim: True, one can't blame the lone programmer for not wanting to invest in a new language with unknown benefits. But one CAN (and I DO) blame project leaders in industry who don't even bother doing the math to see whether Common Lisp would be a better choice for their projects and products.
<beach>
But I have done this rant before, so I won't continue.
<jmercouris>
beach: maybe you could add a minion alias
<jmercouris>
so anytime this comes up you can automate your rants
<beach>
I think at this point, I could just have a few abbreviations, one for each rant, and most #lisp participants would know what I mean.
<dim>
beach: we used to have the same rant in the PostgreSQL community, and it boils down to “you're never going to be fired for using XXX”, with XXX being IBM, then Microsoft, then Java, then many other things, but PostgreSQL and Common-Lisp kind of never made it to the list
<dim>
so rather than complaining about that beach (which I do too), how to we have Common Lisp enter that “never going to be fired for picking it” list?
<beach>
Very good question.
rippa has joined #lisp
randomstrangerb has quit [Ping timeout: 240 seconds]
<rme>
I keep thinking about that problem.
randomstrangerb has joined #lisp
fluke` has quit [Remote host closed the connection]
lnostdal has joined #lisp
fluke` has joined #lisp
fluke` has quit [Remote host closed the connection]
<dim>
maybe we should build some important piece of infrastructure in common lisp and have it flexible and very reliable and have people depend on it
<dim>
that's how C and Unix got there I think, and Go with docker and the family around it nowadays, and Python I'm not sure it's just because it was easy to hack code in the language I guess; Java got a lot of infra project I believe, nowadays maybe Kafka and Zookeeper would be on the top list?
<dim>
Erlang has RabbitMQ and people hate it but still run it because it does the job, mostly, and in a good enough fashion and not too much competition in this space I presume
<dim>
etc
<malice>
Yes, making some infrastructure work really well would be a strong upside
<beach>
dim: I share that strategy, and I am working on it.
<dim>
what's a good Common Lisp “infrastructure” project that non-CL people could rely on in their production architecture, and discover later that it's actually been developped in CL, to a great benefits
<dim>
beach: you're beginning with the compiler and the OS, right?
<jmercouris>
dim: How about a firewall
LiamH has joined #lisp
<beach>
Not really. I do several things in parallel. Editor, debugger, GUI library, compiler, etc.
<jmercouris>
or some network traffic router tool
<beach>
dim: But yeah, they are all for Common Lisp developers for now.
z3t0 has joined #lisp
<jmercouris>
you could also increase common lisp traction by writing a popular tool in it, you know, like a browser ;)
<beach>
dim: I have done some applications in the past. And I do want to make better versions of some of them. In particular Gsharp which is an editor for standard music notation.
kamog has joined #lisp
<jmercouris>
beach: Is GSharp written with mcclim?
<beach>
jmercouris: Yes, McCLIM was a result of my needing a pure Common Lisp GUI library for Gsharp.
fluke` has joined #lisp
<dim>
that's quite nice! I think I've looked at Gsharp and found it cool in the past, but as a guitar player well, chords and tabs :/
Kevslinger is now known as Kevin
<beach>
dim: Sure. I also made some design mistakes that I intend to correct in version 2.
fluke` has quit [Read error: Connection reset by peer]
z3t0 has quit [Ping timeout: 256 seconds]
<dim>
anyway, Gsharp and McCLIM or a browser or pgloader even won't be a crucial part of a production infrastructure that people would deploy without feeling like they need to be able to hack the product
Kevin is now known as Guest7701
<dim>
and then rely on it, using an API of sorts, etc
marusich has joined #lisp
arbv has quit [Ping timeout: 240 seconds]
<jmercouris>
there is yet another question to ask though, does popular support mean a better future for CL?
<jmercouris>
I'm still not sure about that, some days I lean one way, and some days another
Guest7701 is now known as Kevslinger
<dim>
Kafka, Varnish, Docker, PostgreSQL of course, Memcache, Redis, etc are examples of what I mean by infra-with-an-api
<jmercouris>
on one hand, python has a ton of users, but what has that done for python? some machine learning bindings?
arbv has joined #lisp
varjagg has quit [Quit: ERC (IRC client for Emacs 24.5.1)]
Bike has quit [Ping timeout: 260 seconds]
<jmercouris>
dim: I guess you could write yet another provisioning system like salt, chef etc
<jmercouris>
and it could use sexp to represent the state of the system instead of awkward yaml files
<dim>
I'm thinking maybe a non-ACID memory database system with a producer/consumer mechanism would be good
<beach>
dim: I don't think Common Lisp will ever be on that list of yours. But I think one can hope for some highly-educated project leaders in industry understanding that Common Lisp might be a better choice for some of their projects. For that to be the case, I think we need much better programming tools.
<dim>
the thing that sits in the middle of the infra and allow the other pieces to seamlessly work independantly
MrMc has quit [Remote host closed the connection]
<dim>
beach: I understand your position, I don't think that's the best option/leverage we can have, though
<beach>
dim: Maybe not. But that's the domain where I feel I have the competence to pitch in.
<dim>
that's another aspect of it yeah, to each its own etc
randomstrangerb has quit [Ping timeout: 256 seconds]
<dim>
one project I though of is a replacement for pgbouncer
<beach>
Also, in order to put in as much work as possible, I need to justify it as research, and this domain fits well with that goal.
<dim>
that's a PostgreSQL “proxy” that implements the PostgreSQL protocol and does some connection pooling / admission control, but it doesn't know how to support prepared statements and people who've been trying to add that feature failed, because the C code is intricate to work with
randomstrangerb has joined #lisp
<dim>
I guess we could write a nice pgbouncer-like software with all the features in lisp
<beach>
That sounds like a great project.
<dim>
thanks!
<beach>
And it would be good publicity for it to replace an existing program in C.
<dim>
well I already have so much on my plate that I'm not approaching it, be my guest
<beach>
Heh. Not me. Sorry.
schweers has quit [Remote host closed the connection]
<dim>
(also pgbouncer is 1-core only by design, with event-loop based processing, and when doing lots of traffic that's a bottleneck)
<Xach>
I was hoping to write a configurable DNS server so I could do some dynamic DNS without much hassle
<dim>
ala route53 from AWS maybe?
<Xach>
dim: sort of, but on a much more local level.
<dim>
I think PowerDNS might be flexible enough for what you're saying?
sjl__ is now known as sjl
<Xach>
Maybe!
<Xach>
I have many of the pieces to make what I want, though. I wrote a packet parser long ago.
<dim>
then there's also unbind which is great, and dnsmasq
<Xach>
Oh, I am not looking for a packaged solution, but a project that would be a fun hobby and result in something useful to me :)
<dim>
a kind of etcd / zookeeper with automatic DNS handling would be fun and useful maybe?
smurfrobot has quit [Remote host closed the connection]
<dim>
etcd & zookeeper and the like are used to register alternative resource providers (web servers, db servers, you name it) and guarantee that a single provider is elected at all time, and allows to then connect to the current “leader” easily ; I don't think they handle DNS changes when a new leader is elected
lnostdal has quit [Remote host closed the connection]
beach has quit [Ping timeout: 240 seconds]
lnostdal has joined #lisp
sz0 has quit [Quit: Connection closed for inactivity]
porky11 has quit [Remote host closed the connection]
Karl_Dscc has joined #lisp
fikka has quit [Ping timeout: 260 seconds]
shrdlu68 has joined #lisp
scymtym has joined #lisp
arbv has quit [Ping timeout: 264 seconds]
arbv has joined #lisp
fikka has joined #lisp
<rme>
beach: are students at your university still taught lisp?
smurfrobot has joined #lisp
samebchase has quit [Ping timeout: 240 seconds]
smurfrobot has quit [Ping timeout: 240 seconds]
attila_lendvai has quit [Read error: Connection reset by peer]
smasta has quit [Ping timeout: 256 seconds]
makomo has quit [Quit: WeeChat 1.9.1]
attila_lendvai has joined #lisp
quazimodo has quit [Ping timeout: 240 seconds]
CrazyEddy has joined #lisp
lnostdal has quit [Remote host closed the connection]
<rme>
oh, he left, duh
lnostdal has joined #lisp
nika has quit [Quit: Leaving...]
marusich has quit [Quit: Leaving]
fikka has quit [Ping timeout: 252 seconds]
<jmercouris>
rme: whoopsie :P
Murii has quit [Ping timeout: 256 seconds]
shka has joined #lisp
arbv has quit [Ping timeout: 256 seconds]
papachan has quit [Quit: WeeChat 2.0.1]
arbv has joined #lisp
<jmercouris>
how can I highlight my macros in my source file?
hhdave has quit [Quit: hhdave]
<jmercouris>
I want defcommand to be highlighted like a defun
<Shinmera>
name them define-foo
<Shinmera>
and not deffoo
<jmercouris>
Shinmera: so in this case define-command?
<Shinmera>
Yes
<jmercouris>
is this a standard thing? or an implementation detail of lisp-mode in emacs?
<Shinmera>
Other things that will automatically be highlighted are with-foo, check-foo, and do-foo.
<jmercouris>
and, if it is not a standard thing, do other people do this as well?
<Shinmera>
I use define-* for all my definitions.
Mqrius has joined #lisp
<jmercouris>
I'll have to think about it, thank you for the info
smasta has joined #lisp
<Shinmera>
The reason deffoo doesn't highlight is because def* is ambiguous. Consider stuff like default.
<jmercouris>
I see the ambiguity, but if I have my system and macros loaded, emacs should be aware of them
<jmercouris>
but that'd require modification of that regex for highlighting dynamically
<jmercouris>
not sure what the regex is called, but you know what I mean
fikka has joined #lisp
wigust has joined #lisp
Fare has quit [Ping timeout: 268 seconds]
ebrasca has quit [Remote host closed the connection]
raynold has joined #lisp
arbv has quit [Ping timeout: 240 seconds]
jardon has joined #lisp
arbv has joined #lisp
randomstrangerb has quit [Ping timeout: 260 seconds]
dyelar has quit [Remote host closed the connection]
randomstrangerb has joined #lisp
kamog has quit [Quit: Leaving.]
solyd has quit [Quit: solyd]
<kini>
dumb question - I'm looking at some code containing (load "foo.lisp"), and I'd like to add a form after that LOAD which looks like (setq bar:baz 'xyzzy), but the bar package is defined in foo.lisp so the function containing the LOAD fails to compile because package bar doesn't exist (at compile time). How do I get around this? Or is it not possible?
<jmercouris>
just don't put it in a top level form
<jmercouris>
have it be loaded as part of a "startup"
<jmercouris>
having said that, this feels like an x-y problem, can you please describe on a high level what the situation is?
<Xach>
kini: one common workaround involves using read-from-string, but it's something to avoid, usually
<shka>
kini: can't just define systems like reasonable man?
<rme>
I think (set (find-symbol "BAZ" "BAR") 'xyzzy) will do what you want.
<Xach>
shka: There are plenty of reasons to do plenty of things. More context would help.
<shka>
well, certainly, but it is just so much simpler this way!
attila_lendvai has quit [Read error: Connection reset by peer]
<kini>
Er, I don't quite follow -- both the existing LOAD and the SETQ I'm trying to add are inside a function body, not at the top level. (Or maybe that's not what you meant?)
<kini>
The situation: I have a program whose purpose is to figure out the dependencies of a quicklisp package; it does this by installing quicklisp in a tempdir, pulling in the package, and looking to see what else gets pulled in. To do this, it LOADs quicklisp's setup.lisp at runtime. I'm trying to make it work behind a proxy by setting ql-http:*proxy-url* right after that setup.lisp is loaded.
<dlowe>
ooh, there's an if-feature option in asdf now
<jmercouris>
shka: You don't know the context, how do you know that?
<kini>
I should add that I really don't know much about common lisp :) I don't know what a system is for example...
<jardon>
does lisp have builtin (not 3rd party) gui libraries?
<dlowe>
that should come in handy
<dlowe>
kini: it's instructions for building a program
<shka>
jardon: no
<jmercouris>
jardon: Do you consider a terminal a GUI?
<dlowe>
kini: we call them systems instead of packages because the word "package" already meant something in CL
<jardon>
jmercouris: no
attila_lendvai has joined #lisp
attila_lendvai has joined #lisp
attila_lendvai has quit [Changing host]
<jardon>
shka: ok, thanks
<jmercouris>
jardon: then no
<shka>
jmercouris: linking files to each other is a complete mess.
<Xach>
kini: the function ql:dependency-tree kind of does what you're trying to do
<jmercouris>
shka: I can't conjure a situation in which it makes sense, but there must be one :D
<shka>
wow
<shka>
dependency-tree!
<kini>
Xach: yes, it seems this program I'm looking at already uses that function
<shka>
didn't knew about that
jardon has quit [Quit: Page closed]
<kini>
I'm not trying to write the logic for quicklisp dependency detection or anything, just trying to one-line hack this existing program so that it will work behind a proxy :)
<jmercouris>
kini: I'm not sure how a proxy is causing issues with quicklisp
<jmercouris>
unless of course you've incorrectly setup the proxy on your machine
<Xach>
kini: you can (setf (ql-config:config-value "proxy-url") <something>) and it will remember it between sessions.
<kini>
remembering stuff between sessions probably won't work because this program runs in a sandbox
<Xach>
kini: how does quicklisp get set up in the sandbox?
attila_lendvai has quit [Read error: Connection reset by peer]
<kini>
jmercouris: not sure what you mean by "incorrectly" -- I have it in all the traditional environment variables, if you mean
<Xach>
kini: maybe the quicklisp setup could include the proxy setup?
<kini>
well yes, that's what I'm trying to achieve (I think?)
<jmercouris>
kini: I was imagining a machine where you've setup a proxy because somehow the quicklisp servers are inaccessible in your country or something, I misunderstood the situation, my apologies
<Xach>
kini: no, i mean how does quicklisp/setup.lisp come to exist in the sandbox?
<kini>
jmercouris: oh, nah -- I'm just behind a corporate firewall, haha
<Xach>
curious about that primordial setup
<kini>
Xach: I believe a bundle is downloaded and extracted
fluke` has joined #lisp
<Xach>
kini: a possible hack: echo "<the proxy url>" > ~/quicklisp/config/proxy-url.txt
fluke` has quit [Remote host closed the connection]
<Xach>
although that path doesn't exist by default
<kini>
for the moment I'll try rme's solution -- that may be the simplest
<Xach>
ah
<Xach>
good luck!
<kini>
thanks! (and thanks to the rest of you too!)
<Xach>
that seems like something to push upstream too
<kini>
yes, I intend to make a pull request if I get it working.
randomstrangerb has quit [Ping timeout: 240 seconds]
arbv has quit [Ping timeout: 240 seconds]
randomstrangerb has joined #lisp
arbv has joined #lisp
Murii has joined #lisp
<jmercouris>
let's say I have (defun a () (print *some-global* "some-new-value"))
<jmercouris>
and let's say that as soon as (a) is invoked, in between the invokation and the actual printing, *some-global* is changed somewhere else, perhaps in another thread
<jmercouris>
what will print?
<jmercouris>
sorry, that print makes no sense
<jmercouris>
it was a setf at first, and then I changed it to print without removing the string
<jmercouris>
the question still stands though
Lamdaeon has joined #lisp
<Lamdaeon>
easiest clisp gui to install on ubuntu?
fikka has quit [Ping timeout: 256 seconds]
fisxoj has quit [Quit: fisxoj]
nox2 has quit [Read error: Connection reset by peer]
nox2 has joined #lisp
dyelar has joined #lisp
Lamdaeon has quit [Client Quit]
turkja has quit [Ping timeout: 260 seconds]
BitPuffin has quit [Remote host closed the connection]
Bike has joined #lisp
<kini>
rme: thanks, your solution seems to be working great :)
fikka has joined #lisp
<rme>
old school stuff sometimes comes in handy
<_death>
jmercouris: if it's a special variable, it's likely the implementation has per-thread storage for it
<_death>
jmercouris: at least if it's not the global binding
<jmercouris>
_death: Hmm ok
<jmercouris>
_death: Maybe this is a stupid question, but is the lambda of a function body a closure?
<jmercouris>
Well, it's definitely a stupid question
<jmercouris>
I feel like the answer is yes, but I just want to be sure
<Bike>
"lambda of a function body" is not something i understand
<jmercouris>
Bike: how about just "function body"
<jackdaniel>
funciton body is a function body. function may be a closure, if it closes over some variables
<jmercouris>
jackdaniel: Ok
<_death>
jmercouris: if it's the global binding, then there's a race condition, and you could use synchronization primitives
<jmercouris>
_death: It's not a real problem I have, I was just thinking about it
<rme>
If a function doesn't refer to any free variables, then it's not really a closure.
z3t0 has joined #lisp
<jmercouris>
When I pass an argument to a function, let's say I pass a var to a variable, and that var changes somewhere else, what happens to that variable?
<jmercouris>
e.g. (defun a (b) (print b))
<jmercouris>
then (a *some-var-that-will-be-changed-elsewhere-during-exeuction-of-a*)
<_death>
jmercouris: Lisp uses pass-by-value
<jmercouris>
_death: Aha, ok
<jmercouris>
I guess I was imagining a "closure" over the variables that are passed in as args
<_death>
jmercouris: most values are references, though, so people like KMP call it pass-by-identity
<jmercouris>
_death: Who is kmp? knuth morris pratt?
<_death>
Kent M. Pitman
<jmercouris>
_death: When you say references, you mean like pointers?
<random-nick>
afaik variables behave like cons cells about setting and getting their values
Achylles has quit [Quit: Leaving]
<random-nick>
if you take a car of a cons and then rplaca it, the old value you took doesn't change
<_death>
jmercouris: I mean references.. you can think of them as pointers that are implicitly dereferenced and that can't be changed, I guess
<jmercouris>
_death: Okay so references in the java sense then?
<jmercouris>
random-nick: aha, okay, that makes sense
<jmercouris>
if it is true
<_death>
jmercouris: and not everything requires a pointer, e.g. fixnums or characters may simply be copied
<jmercouris>
right right
<jmercouris>
thank you everyone for the explanations/patience
markong has quit [Quit: Konversation terminated!]
markong has joined #lisp
<dlowe>
So I have a style question to present. ASDF 3 allows you to check for features before loading a file. This is great, because #+/#- is insufficient to account for implementation differences.
<dlowe>
so now for each implementation, I can have a source file, gated by an :if-feature :implementation
<dlowe>
the question is... what should be the form of the source pathname?
smurfrobot has joined #lisp
<dlowe>
right now I just have something like "impl-sbcl" in the main dir
<_death>
dlowe: I think that makes sense if you don't need more than one file per implementation
<dlowe>
I don't expect to.
z3t0 has quit [Remote host closed the connection]
smurfrobot has quit [Ping timeout: 268 seconds]
<jackdaniel>
dlowe: in what way :if-feature is more sufficient thatn #+/#- ?
m00natic has quit [Ping timeout: 248 seconds]
<jackdaniel>
I mean - do you have an example for that?
<_death>
the form can be read and such dependencies analysed
moei has joined #lisp
<dlowe>
jackdaniel: implementations differ on how they handle unpackaged symbols and symbol macros inside a #-
FreeBirdLjj has quit [Remote host closed the connection]
<Xach>
dlowe: what do you mean by unpackaged?
<jackdaniel>
dlowe: I'm afraid I don't understand
<dlowe>
Xach: I mean symbols that do not have a valid package
<_death>
(that is, without hacking the reader)
vertigo has quit [Changing host]
vertigo has joined #lisp
<dlowe>
for instance, the java package doesn't exist in the ccl implementation (by default)
ckonstanski has joined #lisp
<dlowe>
so #-abcl (java:jstatic ...) may break when the ccl reader tries to read it
<dlowe>
similarly, ccl uses #_systemcallname pervasively, but symbol macros aren't ignored in lispworks
<_death>
don't you want #+abcl there?
<dlowe>
yes.
<jackdaniel>
it will break with :if-feature as well
<jackdaniel>
asdf uses normal reader, so if package doesn't exist it will error right away
<dlowe>
...
<dlowe>
no, because if I put it in its own file it will never get read
<jackdaniel>
I mean: how #+abcl(:file "foo") less sufficient than (:file "foo" :if-feature "abcl")
<_death>
well, #+abcl (java:...) won't break anything on an implementation that doesn't have an abcl feature
<jackdaniel>
and that ↑ so using feature expressions is even less error-prone
<dlowe>
jackdaniel: uh, I'm talking about #+abcl in the source file, not the system file
<jackdaniel>
than if-feature funcionality, that's why I'm confused
<_death>
jackdaniel: like I said, such dependencies can be taken notice of without readtable hacks
<jackdaniel>
I'm referring to < dlowe> So I have a style question to present. ASDF 3 allows you to check for features before loading a file. This is great, because #+/#- is insufficient to account for implementation differences.
<dlowe>
yes, I realize that was ambiguous
<dlowe>
and that you alighted on the most improbable interpretation.
<dlowe>
mea culpa
<dlowe>
:if-feature in the system file is still better
<jackdaniel>
how is that?
beach has joined #lisp
<dlowe>
it enables examining the system as a whole even if you don't have the feature.
<beach>
rme: No, unfortunately not. But we are very proud to have managed to do it for 15 years or more.
<jackdaniel>
dlowe: what about (abcl-ext:static-file "foo" :if-feature "abcl") ;?
<jackdaniel>
your system definition is broken right away on sbcl thanks to that
<jackdaniel>
of course abcl-ext:static-file is imaginatory
<dlowe>
jackdaniel: so don't do that.
<jackdaniel>
don't use if-feature? but it's clearly better ,)
<dlowe>
jackdaniel: I don't believe you're arguing in good faith anymore.
smasta has quit [Ping timeout: 268 seconds]
<jackdaniel>
well, I've presented you argument where :if-feature is clearly worse than #+foo and you say "then don't do that"
<jackdaniel>
at this point I lost good faith
<jmercouris>
let's not be so dramatic
<_death>
jackdaniel: maybe the questions are which convention should be used by default, and what are the cases where it may be broken
<dlowe>
jackdaniel: okay, assuming you're trying to make a valid point then, your example would break with #+abcl too
<dlowe>
jackdaniel: implementations differ how they treat unfound packages within an unread #+ or #- expression
<dlowe>
like I said at 14:11:57 EDT
fikka has quit [Ping timeout: 268 seconds]
<jackdaniel>
I don't think it is a valid point, you will break many many things binding *read-suppres* to t when you read files (and I'm not talking only about asd definitions)
<rumbler31>
if i understand correctly, the discussion is between an asdf feature that can be used to conditionally load a file, vs placing #+/#- forms in source files for implementation specific behavior?
<dlowe>
rumbler31: that was my comparison, yes.
<jackdaniel>
it's the same as if I had argued, that software which has #+nil foo is invalid, because nil may be pushed to features. in theory it is, in practice it doesn't matter (because many systems do that to comment blocks of code)
<dlowe>
rumbler31: then jackdaniel pointed out correctly that I could have used the #+/- in the system definition to do the same thing
<jmercouris>
I would use the ASDF feature personally, why would you not, when it exists?
<_death>
jackdaniel: I linked it because #+ and #- may bind it to T, where it may be used to skip invalid package markers (i.e. it should be OK to have them)
LocaMocha has quit [Ping timeout: 240 seconds]
damke has joined #lisp
<jackdaniel>
jmercouris: one way to look at it is that it was introduced quite late to the party (so your lib will break on clisp), second is example of using package:foo notation (where package is guaranteed to exist when bar is in features). Only benefit I can see for if-feature is when you want to scrap information about how system definition would behave on other implementations
<_death>
dlowe: in what implementation does #+nonfeature nonpackage:something fails?
<jackdaniel>
I'm not sure if any software uses that possibility (I remember that when if-feature was introduced it was argued, that it could be used for archive-op or doc-op to name two examples)
<Bike>
ccl, they said
<jackdaniel>
I just did #+foo bam:kam on ccl
<jackdaniel>
it didn't break
<jackdaniel>
(I have repl fired)
<jmercouris>
jackdaniel: all valid points, but I generally do want diffrent system definition behavior on other implementations, at least in my example where ccl and sbcl are radically different
<jmercouris>
or rather, my system that runs on ccl is radically different than my system that runs on sbcl
damke_ has quit [Ping timeout: 264 seconds]
<jackdaniel>
jmercouris: I think you miss the point. we discuss which notation of such conditionalization is better
damke__ has joined #lisp
<jackdaniel>
not whenever conditionalization is beneficial
<jmercouris>
okay, then I will address your points directly
<jmercouris>
1. sounds like a problem with clisp more than anything, 2. I have no rebuttal
<rme>
beach: Congratulations on having taught CL for so long. I was thinking that your university might be a source of possibly-enthusiastic junior Lisp hackers for my imaginary CL startup in Bordeaux.
<jmercouris>
rme: why do they have to be junior devs? so they can work longer hours for less pay :D?
<phoe>
rme: if you're looking for remote Lisp programmers, count me in.
<rumbler31>
rme: me too
damke has quit [Ping timeout: 263 seconds]
<shrdlu68>
rme: Me too.
* rme
takes notes
<jmercouris>
me too
Fare has joined #lisp
<jmercouris>
let's make a startup
<rme>
I am working on a better business plan than "hack lisp".
<sjl>
rme: me too
damke__ has quit [Ping timeout: 264 seconds]
<sjl>
I've been fully remote for 4+ years now and don't think I'll ever want to go back to meatspace work
<rme>
I've worked remotely for years, but I am finding that I really enjoy and need some social interaction as well.
<phoe>
that's why we have ELS
<Xach>
yes, once per year for two days should suffice
<rme>
Maybe I need to develop a better non-work life somehow, but I don't think I can just stay in my own little office by myself any more.
<phoe>
Xach: irony does not transmit well through the internet.
<phoe>
I know that feeling and I wish remote work allowed for better human-human interfacing.
<rumbler31>
it transmits perfectly fine!
<phoe>
Or maybe that's just how it is.
<phoe>
...
<sjl>
I've got enough non-work hobbies to fill the socializing I need, usually.
<phoe>
(incf rumbler31)
<phoe>
that was a good one
<rumbler31>
sarcasm on the otherhand....
<rme>
I asked about students in Bordeaux because if I end up living there I thought that I could organize some lisp meetups or workshops or something, and that they'd be a potential audience.
<rme>
Knowning students, however, most of them probably just learn enough to pass the course and then forget it all anyway.
<rme>
I just slandered all students. Sorry about that; I'm sure that's just my cynicism talking.
<phoe>
rme: I understand the sentiment as someone who attempted to popularize Lisp in my region.
<phoe>
So far, I ended up having a 100% growth of Lispers in my direct circles. That is, I have inspired KZiemian to pick up Lisp for good.
<rme>
I admit that sometimes I get discouraged.
<phoe>
So do I. I sometimes wish I could have a worse taste and stand doing C# and Java like everyone around.
<phoe>
Forget about Lisp's interactivity and flexibility and such.
<phoe>
Sigh, now I'm getting romantic.
EvW has joined #lisp
<rme>
I worked in Clojure for a year, but the enterprise software business is not for me.
<rme>
And Clojure is definitely not CL.
varjag has joined #lisp
<phoe>
I am working in enterprise right because it pays decently, and I can spend a portion of my sanity for the money that it gives me.
fikka has joined #lisp
<rme>
I used up all my sanity and had to leave :-)
ln has joined #lisp
<phoe>
I am glad to still have some left. {:
fikka has quit [Ping timeout: 240 seconds]
didi has joined #lisp
ln has quit [Quit: Page closed]
<didi>
You know what would be cool? If we could change the value of `multiple-value-bind' variables in the vars list.
<dlowe>
there goes the sanity
<_death>
multiple-value-setq?
<phoe>
didi: wait, what
<phoe>
m-v-b is a binding construct
<phoe>
not a mutating construct
<jmercouris>
rme: "enterprise" is a keyword for shitty and bloated
<shrdlu68>
The trials and tribulations of the 21st-century hunter-gatherer.
<phoe>
didi: oh, m-v-b followed by a let.
<shka>
didi: metabang-bind may be good for you
<didi>
phoe: Indeed. I don't want to use `let'.
fikka has joined #lisp
<didi>
shka: I will look it up. Thank you.
<phoe>
use bind then, it'll help you with more crazy binding structures.
<dlowe>
or just (setf x (mod x))
<didi>
dlowe: Nah, I prefer `let', thanks.
damke_ has joined #lisp
<_death>
bind is a fashion that some people have to go through, but later see its folly
<didi>
_death: It is a journey, you say.
<phoe>
you embrace it only to discover that you have always been at the goal
<didi>
:-)
<phoe>
which is abolishing LET for LAMBDA
<phoe>
((lambda (x y) (+ x y)) 2 2)
ckonstanski has quit [Remote host closed the connection]
<shrdlu68>
Eh, &aux
<phoe>
leave.
<phoe>
(:
<rumbler31>
what
<shka>
well, i kinda like bind
Petit_Dejeuner has joined #lisp
<shka>
it is a bit overkillish, but i like it
<dlowe>
I like it like I like series and iterate. I can see how it's cool and then I don't use it.
papachan has joined #lisp
<dlowe>
*I like it how ..
shifty has quit [Ping timeout: 256 seconds]
fikka has quit [Ping timeout: 268 seconds]
<cgay>
I liked I like it like I like better.
nullman has quit [Remote host closed the connection]
nullman has joined #lisp
shrdlu68 has quit [Ping timeout: 252 seconds]
<yggdrasil_core>
like likes
<_death>
buffalos, where?
<kolb>
rme: keep me posted about that lisp startup :-)
<phoe>
#smuglispstartup
<aeth>
phoe: that is not smug
shrdlu68 has joined #lisp
malice has quit [Ping timeout: 276 seconds]
<Petit_Dejeuner>
Hi, I've been trying to get lib-cffi to load, but I get a "Unable to load any of the alternatives ("libffi.so.6" "libffi32.so.6" "libffi.so.5" "libffi32.so.5")". libffi is installed, but it's in the directory "/usr/lib/x86_64-linux-gnu/" instead of something like "/lib/" or "/usr/lib/". I tried copying the libraries into /usr/lib/ to see if maybe cffi just wasn't searching the right place, but I still get the same e
<Petit_Dejeuner>
rror. Is there anything obvious I can check?
<aeth>
phoe: if you want a really arrogant Lisp startup channel name, call it #startups-easy-mode and make it clear in the topic that only Lisp is allowed.
<rme>
kolb: that's "imaginary lisp startup" (at least for now)
<phoe>
aeth: I chose that name because #humblelistartup seemed a litte bit out of place.
<phoe>
Petit_Dejeuner: that's more of a OS problem than a Lisp problem.
<phoe>
First question: are you sure that libffi matches your architecture? 64-bit ffi for 64-bit Lisp image?
<_death>
Petit_Dejeuner: check out cffi:*foreign-library-directories*
<Petit_Dejeuner>
"64-bit ffi" That's probably it. Let me check.
damke_ has quit [Ping timeout: 264 seconds]
_mjl has quit [Ping timeout: 276 seconds]
<phoe>
if ffi's .so is in x86_64-linux-gnu then it's 64bit.
<phoe>
is your Lisp 64bit?
<Petit_Dejeuner>
Yeah, that was it. I installed sbcl through the website since my package manager's version was outdated and I installed the 32bit instead of the 64bit.
<Petit_Dejeuner>
Thanks.
<phoe>
<3
<phoe>
I'm giggling. I had no idea this would be the culprit.
<Petit_Dejeuner>
I've had this happen several times now, but it's always when I start to use Lisp again after a long break.
<Petit_Dejeuner>
So I forget.
<Petit_Dejeuner>
Er, the errors are usually different, but the cause is the same.
<Mqrius>
If only everyone had stuck with 8 bit punchcards then we wouldn't have had this problem!
<didi>
Petit_Dejeuner: What's the version of your package manager?
<didi>
What's the version _in_ your package manager, I guess.
damke_ has joined #lisp
python476 has quit [Remote host closed the connection]
<aeth>
(1+ (integer-length most-positive-fixnum)) should be the first thing everyone does on a fresh Lisp install. If it's < 32, it's probably 32-bit. Elseif it's < 64, it's probably 64-bit. If it's >= 64, I'm jealous of your computer and/or your Lisp.
<phoe>
c'mon, are we comparing integer lengths now
* phoe
checks just to be sure
fikka has joined #lisp
<_death>
and most-positive-bignum
<aeth>
Hmm, that doesn't actually work as universally as I thought it would. The ABCL I have installed gives "32" when I do that.
shrdlu68 has quit [Remote host closed the connection]
<aeth>
_death: There is a most-positive-bignum, and you'll find out when you try to get past it.
makomo has joined #lisp
dieggsy has joined #lisp
daydayup has joined #lisp
<daydayup>
有人嗎
<sjl>
aeth: abcl probably uses java int's as fixnums
<Xach>
Hmm, anyone got an rfc 2822 date parser handy?
shrdlu68 has joined #lisp
dieggsy has quit [Remote host closed the connection]
damke has joined #lisp
<daydayup>
lisp還有前途嗎
<dlowe>
Xach: there was one that worked with local-time, I think.
fikka has quit [Ping timeout: 240 seconds]
<dlowe>
chronicity has a bunch of parsers
<Xach>
dlowe: thanks
damke_ has quit [Ping timeout: 264 seconds]
damke_ has joined #lisp
<Xach>
Hmm, chronicity doesn't quite do what I'd like.
<Xach>
looking to parse something like: Thu, 01 Feb 2018 00:23:38 GMT
shrdlu68 has quit [Ping timeout: 276 seconds]
* Xach
looks to rip some code out of usenet-legend
fisxoj has joined #lisp
shrdlu68 has joined #lisp
damke has quit [Ping timeout: 264 seconds]
<phoe>
Xach: I asked for a similar thing one time ago
<dlowe>
rebol has a parser generator built-in to the language, and I'm starting to think that's admirable. So many problems are parsing problems.
<_death>
net.telent.date can parse it, fwiw
fikka has joined #lisp
Cymew has quit [Ping timeout: 260 seconds]
dddddd has joined #lisp
<Xach>
thank
<didi>
dlowe: So much of what we do is dealing with ourselves. I think of it like an expanding sphere: the volume grows faster than the surface.
<Petit_Dejeuner>
lol, even the Chinese come in here to ask about the future/popularity of lisp
fikka has quit [Ping timeout: 256 seconds]
<random-nick>
what did that person ask?
<phoe>
why didn't Lisp shine in machine learning
<phoe>
that's what google translate tells me
<random-nick>
also, how did that chinese person get here in the first place without knowledge of english?
smasta has joined #lisp
<Petit_Dejeuner>
didi: SBCL 1.2.4.debian
<didi>
Petit_Dejeuner: Old Stable?
<Petit_Dejeuner>
I'm actually on Devuan.
<didi>
oic
z3t0 has joined #lisp
<aeth>
Wow, that's old.
damke has joined #lisp
<jmercouris>
random-nick: isn't freenode banned in china?
markong has quit [Ping timeout: 256 seconds]
<jmercouris>
maybe they are taiwanese
<random-nick>
I don't know
<Petit_Dejeuner>
aeth: You should see the results of apt-cache search lisp.
<Petit_Dejeuner>
Half of it is lisp libraries with apt packages.
<aeth>
I'm on Fedora and Fedora basically updates it with the distro and never again (so currently 1.4.2 because Fedora is roughly every 6 months and the upgrade was recent).
<aeth>
Fedora does that sort of thing with some languages (perl, python, ruby), but not with Lisp (yet)
<aeth>
The most annoying one is with LaTeX, whose package manager apparently is set up to prefer hundreds/thousands of tiny packages
<dlowe>
package managers could use some namespacing
<aeth>
Petit_Dejeuner: Is that because there is something that depends on those in Debian?
<phoe>
Petit_Dejeuner: same with debian.
<cgay>
I'm not an expert but those do look like traditional Chinese characters, so maybe Taiwan.
<phoe>
there are just people who package lisp libraries in apt for some reason.
<aeth>
The only thing that depends on a CL (SBCL) is Maxima afaik.
damke_ has quit [Ping timeout: 264 seconds]
<phoe>
aeth: pgloader
<aeth>
(In Feodra, I mean.)
<didi>
phoe: I like those people. They are nice people. :-)
<phoe>
didi: I don't doubt they're nice, I don't doubt that some people who do Linux more than they do Lisp find them useful
<Petit_Dejeuner>
There's some old airport passenger routing algorithm running on an old debian server that uses apt-get for cl-split-sequence or something.
<phoe>
it's just that with quicklisp, I have no use for them.
<didi>
phoe: Fair.
Rawriful has joined #lisp
<aeth>
I think any properly-run distro is probably going to essentially never update the Lisp installations except during new distro releases (well, unless it's a rolling release distro). Especially SBCL. They tend to have a lot of "minor incompatible change"s, but I guess a good packager would update until the first one. http://www.sbcl.org/all-news.html
<aeth>
The distro packages should be stable enough to rely on them.
<aeth>
I'm not sure that's very feasible when you start pulling in Lisp, Python, Ruby, Perl, etc., packages from the language package managers, though.
z3t0 has quit [Remote host closed the connection]
z3t0 has joined #lisp
damke has quit [Ping timeout: 263 seconds]
wigust has quit [Ping timeout: 256 seconds]
Cymew has joined #lisp
damke has joined #lisp
JuanDaugherty has quit [Quit: Ex Chat]
damke_ has joined #lisp
z3t0 has quit [Remote host closed the connection]
python476 has joined #lisp
z3t0 has joined #lisp
smurfrobot has joined #lisp
Cymew has quit [Ping timeout: 240 seconds]
<rme>
I have the impression that it is usual in python to use a virtualenv (and pip) to isolate yourself from the system python libraries installed by the system package manager.
<rme>
So it's not just lispers who look with suspicion on distribution-packaged libraries.
<White_Flame>
yep, we're getting into all that in our heterogeneous language environment
damke has quit [Ping timeout: 252 seconds]
<White_Flame>
node really popularized it
damke__ has joined #lisp
<aeth>
Distribution-packaged libraries should basically just be there to handle dependencies for distribution-packaged applications that are written in that language.
fikka has joined #lisp
<aeth>
i.e. they're for /, quicklisp is for ~
Cymew has joined #lisp
damke_ has quit [Ping timeout: 264 seconds]
smurfrobot has quit [Ping timeout: 248 seconds]
z3t0 has quit [Ping timeout: 265 seconds]
dieggsy has joined #lisp
shka has quit [Ping timeout: 265 seconds]
Cymew has quit [Ping timeout: 260 seconds]
Cymew has joined #lisp
warweasle has quit [Quit: rcirc on GNU Emacs 24.4.1]
Cymew has quit [Ping timeout: 248 seconds]
z3t0 has joined #lisp
sjl has quit [Read error: Connection reset by peer]
<rme>
where "stuff" is a substitute for another word that starts with "sh" and ends with "t" and has an "i" in the middle.
hhdave has joined #lisp
smasta has quit [Ping timeout: 240 seconds]
<daydayup>
有人會中文嗎
<pjb>
rme: the problem with python is different; there is not a single python, but 3 or 6 different pythons. Different languages. They use the same name and same library names, mostly.
<phoe>
我不這麼認為
<pjb>
rme: that's what you get when you don't have a fixed standard.
<aeth>
pjb: The big problem with Python is 2 vs 3. It's finally now being resolved 10 years later, but I still run into issues with it. e.g. A program I used to compile with scons now no longer compiles with scons because the scons in my distro is now using Python 3, but the program's stable branch hasn't been (and afaik won't be) updated for that scons.
<pjb>
aeth: if by resolved you mean duplicating everything, then yes.
<aeth>
Python would probably have been word-dominatingly popular (its strategy of being the newbie language is a good one) if it wasn't for 2 vs 3 issues for literally 10 years now.
hiroaki has joined #lisp
<pjb>
and when I say "duplicate": $ port search sphinx|grep -e 'py..-sphinx '
<pjb>
obviously there are also issues between 3.4, 3.5 and 3.6…
<aeth>
pjb: That's probably the developer wanting to use newer features.
<phoe>
這裡沒有人知道中國人.
<pjb>
Nonetheless, all the packages are multiplied this way.
nox2 has quit [Ping timeout: 276 seconds]
<Rawriful>
I still think in terms of popularity. Java has the right approach with backcompat. Purely due to the fact that business prefers it. A business has nothing to gain from having to port it's application to a new version of a lang.
<daydayup>
不是還有我們知道
<phoe>
Rawriful: so basically CL did the right thing 24 years ago
<aeth>
pjb: Right, but Python 2.7 code probably won't run in Python 3. Python 3.4 code will run in 3.6, it's just that they want to use 3.6 features. Afaik.
<aeth>
The last thing you want to do to a language is break programs.
<Rawriful>
phoe: imo yes, if there was an initial significant commercial hold with cl it would be a lot stronger. But the other thing about java is that it's quite difficult to make bad code *really* bad due to it's lack of expressionality.
<aeth>
Although, actually, it's not that big of a deal in CL. CL *could* have breaking changes because of how it's structured. e.g. Just have new programs (:use #:cl2019) or something instead of (:use #:cl) and there you go. Problem solved.
<Rawriful>
if you added AST macros to java I can only imagine the horror stories.
<phoe>
companies prefer dumb languages because it seems that it's harder to write unmaintainable code in them
<phoe>
and then you get unmaintainable code anyway because life always finds a way~
<aeth>
phoe: Well, I think what they want is replacable, cheap employees even if they need more. The Common Lisp approach is aiming more for smaller teams that are paid more per person.
<phoe>
ayup, and that is why popularity causes popularity in case of Javalike languages.
<Rawriful>
phoe: I think yes but I think how bad that gets is more limited in java. and sort of what aeth said as well.
<White_Flame>
I've been reading some 1960s LISP code (yes, all-caps to be time-appropriate), and man it's a tangle of GO and COND
<aeth>
Java is programming as a factory. CL is programming as an art.
Cymew has joined #lisp
<aeth>
(Of course, you can write Java in any language, and you can definitely do that in CL if you ban a few things like defmacro.)
<phoe>
Rawriful: except if you write unmaintainable code in Java, people might not notice and might even get used to it, and it may even pass reviews beacuse it's so huge and so God damn tangled with all the files, classes and classes of classes.
<phoe>
it's harder with Lisp because you have much less code to begin with and it's harder to hide shit in there.
<Petit_Dejeuner>
'It's finally now being resolved 10 years later' if only
<Rawriful>
phoe: Oh I'm totally not saying it's impossible, but I've seen some shit and one of my reactions have basically been. "I am so glad that this person did not know about macros"
<phoe>
and if you do really weird shit like readtable modification, it immediately catches a reviewer's eye.
<Petit_Dejeuner>
intro unix classes at my uni were teaching Python less than two years ago
<Petit_Dejeuner>
Pytohn2*
<Petit_Dejeuner>
Python2 will die as soon as perl5 does.
<phoe>
Rawriful: I've seen some Lisp shit too. (Un)luckily it was just a person trying to write C in Lisp.
<phoe>
Horrible, in its own way.
<phoe>
But it is also nice to ask the person if it works, and then, if it works, show them how this can be reduced to idiomatic Lisp.
<Petit_Dejeuner>
phoe: closing parens on their own lines?
<Rawriful>
phoe: I work in scala and maintain a codebase that is basically written like it's js.
<Rawriful>
it's terrifying
<aeth>
Petit_Dejeuner: Universities are like giant enterprises in their tech choices and move about as slowly as them.
<Rawriful>
it reinvents *classes*
<phoe>
Which usually takes a 50% to 80% reduction in code volume as a first effect.
<phoe>
Petit_Dejeuner: yes.
<phoe>
Rawriful: what the fuck
<aeth>
(I wonder what percent of university tuition money goes to overpaying for Oracle stuff.)
<Petit_Dejeuner>
aeth: That's my point. For every open source code base ported to 3, there's several university courses, internal software at a corporation, and research numpy/scipy scripts in 2 that will never be ported.
<Rawriful>
phoe: it's true horror.
Cymew has quit [Ping timeout: 256 seconds]
<aeth>
Petit_Dejeuner: Yes, but it has finally, after 10 years, gotten to the point where 3 is inevitable. Perl 5 will probably never be replaced by Perl 6. They're even more different.
<Rawriful>
phoe: they use maps and validate the maps using json schemas.
<phoe>
ಠ_ಠ
<White_Flame>
needs moar XML
<aeth>
Petit_Dejeuner: Meanwhile in CL, a new breaking specification *would* just require (:use #:cl2019) instead of (:use #:cl) unless they changed how packages or the reader worked.
damke has joined #lisp
* Petit_Dejeuner
wrote new Python2 code today.
<phoe>
Why JSON schemas? This could have been done more enterprisefully by using XSLT transforms and SOAP.
fikka has quit [Ping timeout: 268 seconds]
<Rawriful>
phoe: because that would involve reusing a technology.
Cymew has joined #lisp
* phoe
facepalms
<Petit_Dejeuner>
Hey, JSON is nice.
<aeth>
JSON is simple.
<phoe>
are people who write code like this doing, uh, what, are they trying to ensure a job for life or something
<Rawriful>
it is, but in a static language, you don't need json schemas to validate your types.
<White_Flame>
aeth: in theory, it could swap out reader macros or whatever on toplevel (in-package ...)s as well
<phoe>
JSON is a nice reinvention of S-expressions
damke__ has quit [Ping timeout: 264 seconds]
<White_Flame>
JSON's lack of numeric map keys is frustrating, though
pagnol has joined #lisp
<White_Flame>
not everything wants to be a string
<aeth>
phoe: XML is closer to s-expressions than JSON imo
* phoe
cough {"1": "foo", "2": "bar", ...} cough
<White_Flame>
XML just has that stupid child vs attribute problem, though, which isn't very sexpr-like
<phoe>
aeth: I know, but XML is way too verbose. We don't need each closing paren to state which opening paren it closes.
dieggsy has quit [Remote host closed the connection]
<Rawriful>
I actually quite like xml, I think some of the biggest problems with it were the parsers people generating for schemas had bad error warnings where that really shouldn't be the case.
z3t0_ has joined #lisp
<White_Flame>
and XML has no native datatypes besides text, either. And supports mixing of "body text" with tags
<Rawriful>
that and people started to try and program in xml which is obviously not going to end well
dieggsy has joined #lisp
<Petit_Dejeuner>
This is where someone comes in a says "SGML > XML"
<Rawriful>
White_Flame: I thought you could specify numbers in schemas and date patterns etc?
<White_Flame>
Rawriful: I haven't used JSON schemas, but JSON itself only has string keys
<Rawriful>
White_Flame: ah sorry I was talking about xml schemas.
Cymew has quit [Ping timeout: 276 seconds]
fikka has joined #lisp
Cymew has joined #lisp
z3t0 has quit [Ping timeout: 276 seconds]
daydayup has quit [Quit: Leaving]
<aeth>
White_Flame: I think the most difficult but potentially desirable change in a hypothetical future CL would be case sensitivity instead of upcasing, but that would break a lot of code that assumes 'foo is the symbol represented by the string "FOO", and that "-BAR" would generate 'foo-bar and not 'foo-BAR
<aeth>
That's what I mean by changing the reader.
Cymew has quit [Ping timeout: 240 seconds]
<White_Flame>
I don't see any desirability there
<Shinmera>
Me neither
<phoe>
me neither
<White_Flame>
in our communications platform, we even explicitly made symbols case-insensitive
<aeth>
White_Flame: I'm just using this as an example of something that can't be easily fixed just by using a package other than CL
<White_Flame>
they should be simple keywords, not carry meaning in their character-by-character syntax
<phoe>
the above would mean that people would come in and start coding things in caseLikeThis or CaseLikeThis instead of traditional-kebab-case
Murii has quit [Quit: WeeChat 1.4]
<Shinmera>
aeth: you can change the readtable case easy
<phoe>
and also all the typos that come from things like symbolCase and SymbolCase
z3t0_ has quit [Remote host closed the connection]
quazimodo has joined #lisp
<White_Flame>
cymbalcase
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
<aeth>
phoe: You can probably detect that and warn at the compiler level.
Cymew has joined #lisp
markong has joined #lisp
<phoe>
aeth: "but I totally intended this!!!1"
<phoe>
"don't warn me about code that I broke purposefully to ensure myself a maintenance job for life"
<aeth>
You can program Java in any language. I've seen a Java program written in Python before.
Cymew has quit [Ping timeout: 260 seconds]
Cymew has joined #lisp
<aeth>
phoe: If Common Lisp ever became popular, there would probably be an Eternal September moment where the community could no longer keep up with the influx of new users, and we'd see things like camelCase and )s on their own line.
<Shinmera>
We already do
<Shinmera>
Don't need lots of users for that, just clueless or stubborn ones.
<Mqrius>
Ah, but then we'll let them have their Commoner Lisp, and we'll write proper ANSI Common Lisp
<yggdrasil_core>
I think you mean lisp++
<aeth>
Shinmera: Sorry, I mean, we'd see things like that as the *majority* rather than an outlier
pfdietz_ has joined #lisp
<Shinmera>
I don't think so
Cymew has quit [Ping timeout: 252 seconds]
<pfdietz_>
(incf lisp)
<aeth>
The only large community I know of that has a very uniform style is Python's, with their PEP 8 that they constantly point to and that even Python linters can check for.
<yggdrasil_core>
I would say go is probably more uniform
<aeth>
CL has several large style guides, but none that's even close to authoritative.
<aeth>
yggdrasil_core: I think Go enforces that with a tool.
smurfrobot has joined #lisp
<yggdrasil_core>
it's built into the interpreter
<yggdrasil_core>
something I don't personally agree with but whatever :l
<aeth>
tabs iirc
varjag has quit [Remote host closed the connection]
<White_Flame>
at least we have SLIME to give a canonical indentation
<aeth>
Code with tabs is imo archaic. These days, most code is read online without ever being downloaded, via websites that have terrible tab settings (8 spaces and other ridiculous things like that)
<aeth>
So people don't get the indentation level they want with tabs, they get pretty much the worst (too much indentation) with tabs
<pfdietz_>
I run into that issue when I paste sbcl bug examples into launchpad.
<yggdrasil_core>
I always used spaces because most of what I write is C and I like to align things, and a proper editor makes navigating groups of spaces work like tabs
<aeth>
Emacs's default for languages like C iirc is to mix tabs and spaces. Tabs for indentation level, and then spaces for the final alignment.
<aeth>
Unless they changed that.
<aeth>
(No one uses Emacs for its defaults.)
Cymew has joined #lisp
jmercouris has quit [Ping timeout: 240 seconds]
<aeth>
It's really great that CL's style is so uniform, though.
<Xach>
uniform!!
<aeth>
One of the few style disputes I've seen is ";;;;" vs ";;;" for in-file comment headings. The top of the file heading is ";;;;" and top level comments for things like defun are ";;;" and internal line comments are ";;" and end of line comments are ";". But ";;;; Foo Section" vs. ";;; Foo Section" in the middle of a file is an area where you can have a style argument.
fisxoj has quit [Quit: fisxoj]
<Xach>
(open :direction ':output) is something I saw once!
<pfdietz_>
The great thing about standards is there's so many to choose from?
Cymew has quit [Ping timeout: 248 seconds]
<Shinmera>
The great thing about standards is that the only good ones are the ones you choose
Cymew has joined #lisp
pillton has joined #lisp
<Xach>
Shinmera: in chirp, what kind of argument is display-coordinates?
python476 has quit [Read error: Connection reset by peer]
<Shinmera>
I don't know what that means though
vlatkoB has quit [Remote host closed the connection]
<Shinmera>
Probably something related to the geo field, but I have no idea.
Cymew has quit [Ping timeout: 256 seconds]
Cymew has joined #lisp
<Mqrius>
Let's make a true final universal lisp style though. I mean, lisp is great and all, but there's so many brackets! If we just move them away a little, everything will look much cleaner, like python! Take for example this fibonnaci function. Isn't it beautiful? https://pastebin.com/5YkNS2Da
Cymew has quit [Ping timeout: 256 seconds]
Bike has quit [Ping timeout: 260 seconds]
<didi>
Mqrius: No?
<yggdrasil_core>
that code looks like it is underwater
<Mqrius>
yggdrasil_core: That's because it's so fluent to write in!
<Mqrius>
Hmmm yes, and the style should probably be enforced rigorously. I'm thinking the compiler deletes your file if it's wrong, and tells you to do it over.
hhdave has quit [Quit: hhdave]
<jasom>
we should obvioulsy abandon s-expressions in favor of the more flexible yaml notation for lists
<random-nick>
or the industry standard json
<didi>
mexps are the wave of the future
<yggdrasil_core>
just use xml
<Mqrius>
I've had great success scribbling notes and using a human to parse them.
<Mqrius>
Additional benefit is that we don't need electricity
Cymew has quit [Ping timeout: 240 seconds]
<pfdietz_>
Any data can be turned into Big Data by encoding it in xml.
mishoo has quit [Ping timeout: 248 seconds]
<Mqrius>
It's hard to remember big data though. How do I turn it back into small data?
Karl_Dscc has quit [Remote host closed the connection]
rumbler31 has quit [Ping timeout: 248 seconds]
iqubic has joined #lisp
eivarv has quit [Quit: Sleep]
wxie has joined #lisp
kupad has joined #lisp
damke_ has joined #lisp
trocado has joined #lisp
damke has quit [Ping timeout: 264 seconds]
EvW has quit [Ping timeout: 240 seconds]
Mqrius has quit []
vap1 has quit [Ping timeout: 248 seconds]
jmercouris has joined #lisp
<jmercouris>
Does there exist a linter tool for lisp? surely there is one?
smurfrobot has quit [Remote host closed the connection]
<aeth>
SBCL's compiler gives many linter-style warnings and notes.
<aeth>
I guess a lot of people see that as good enough.
EvW has joined #lisp
blackwolf has quit [Remote host closed the connection]
attila_lendvai has joined #lisp
fikka has quit [Quit: leaving]
fikka has joined #lisp
Bike has joined #lisp
ckonstanski has joined #lisp
<_death>
there is lisp-critic
z3t0 has joined #lisp
z3t0 has quit [Remote host closed the connection]
z3t0 has joined #lisp
varjag has quit [Quit: ERC (IRC client for Emacs 25.2.1)]
z3t0 has quit [Ping timeout: 252 seconds]
<jmercouris>
interesting
smurfrobot has joined #lisp
z3t0 has joined #lisp
random-nick has quit [Ping timeout: 240 seconds]
fikka has quit [Ping timeout: 248 seconds]
pbgc has joined #lisp
smurfrobot has quit [Ping timeout: 276 seconds]
drcode has joined #lisp
stacksmith has joined #lisp
<pillton>
jasom: Haha
fikka has joined #lisp
wxie has quit [Ping timeout: 276 seconds]
<stacksmith>
Hello. Can someone clarify a keyword lambda-list parameter issue for me?
<Bike>
probably!
<didi>
Speaking of keyword, today I defined a function using a keyword as its name. Naughty.
smasta has joined #lisp
<stacksmith>
Great. I am having trouble figuring out the standard about arguments that are not symbols.
<stacksmith>
For instance, functions that return symbols.
<Bike>
arguments can be anything, of course. in (+ 2 3) the arguments are numbers. do you mean parameter names?
fikka has quit [Ping timeout: 240 seconds]
<stacksmith>
By parameter I mean lambda-list description in the definition. So if I have (blah &key q &allow-other-keys), there is what I refer to as a keyword parameter :q. However, when I later call this function, the argument q may be actual :q (blah :q 1) or something like (blah (some-function-that-returns :q) 1)
<White_Flame>
oh, you mean which arguments are evaluated and which arguments are literal?
<stacksmith>
So I was getting SBCL warnings about non-symbol arguments weakening checking... But now I can't. So I tried to figure out what the standard says, but got even more confused.