freenode/#lisp - IRC Chatlog
Search
2:17:41
pfdietz
In general, any global change that you depend on should go into an eval-when that causes it to be performed when the fasl is loaded as well.
2:18:41
drmeister
I'm looking at asdf-viz - it visualizes these things but I can't make hide nor hair of it.
2:30:06
no-defun-allowed
dot's a program for spitting out SVGs from edges of a graph, so half the program would probably just be flattening the tree of dependencies
5:22:57
rk[ghost]
it returns icky, in values.. i forget.. how to grab first part of a values return?
5:30:02
rk[ghost]
pillton: thanks much. that saved me grepping thru a bunch of files to see how i used it in a project (who knows which one, long enough ago) :P
6:03:31
elderK
I've switched clients - it may have been a long long time ago. I didn't check the timestmap :P
6:04:03
equwal
I can't remember. I have a vague memory, probably I was talking about how in emacs you can get a library to rotate the in-frame windows.
6:33:00
elderK
Like, do they just use destructuring-bind and let it do checking, or do they first verify the structure /then/ call destructuring-bind
6:43:30
equwal
So only error check something that you think should be legal but which requires special treatment.
6:44:02
elderK
Right, so in that case I'd specify "Slots are of the form (name type &key (count 1)).
6:47:42
equwal
The point of my suggestion is that you wouldn't check any of that since it is a waste of your effort and isn't meaningful anyway. The only reason you might check is if you want to make sure that your program fails in a specific way when that happens.
6:57:59
equwal
Though I was just going to modify my emacs init file, but now I am programming udev and systemd.
7:00:37
equwal
Hasn't worked with GNOME in my experience, since GNOME has it's own incomplete system for keybindings.
7:01:17
no-defun-allowed
cause just in emacs is 4 lines of elisp, and ctrl-caps swapping was 2 in xmodmap so i imagine it's not too hard
7:01:17
equwal
So you have to change the keybinds on hotplug of the keyboard, which requires watching Udev with a systemd script.
7:06:10
equwal
Spent a decent amount of time trying to find that. Lots of bogus answers on stackoverflow.
8:08:55
hajovonta
work issues, family issues... I currently don't have a desk at home and did no CL recently :(
8:10:31
hajovonta
I couldn't find a way to incorporate CL into my daily job in the past year. We hopefully get a new assignment for next year though, and I'm optimistic.
9:40:47
hajovonta
sindan: I think many system engineering type assignments give possibilities to develop something in CL
9:44:08
sindan
hajovonta: just curious, CL is wonderful but it's far too powerful and flexible for many managers' taste, and if they know anything about software development, they know that the developer market is not big, therefore they resent having critical systems dependant on just one person, but maybe you knew that already
9:48:06
ogamita
Yes, anytime you start writing #!/bin/bash quick, type ^W^W usr/local/bin/clisp -ansi -q -E utf-8 instead.
9:49:32
ogamita
equwal: what pain do you have in swapping [] with ()? (apart the need to adapt to the new layout?)
9:54:23
sindan
bash is a horrible choice anyway, I'd choose python for anything now over, say, 0 lines
9:58:05
aeth
I think a language doesn't get a conciseness advantage over bash until 100 lines or so (but you probably want to go away from bash before that point)
9:59:25
hajovonta
sindan: you are right, they won't let me write critical systems, but there are many tedious tasks involved, like installing, configuring and integrating components, and chances are that procedures require manual effort, where CL can step in, to save time (for myself)
9:59:46
hajovonta
that's why I said system engineering, because software development is where you develop something that others will use
10:00:27
heisig
sindan: I would be more enthusiastic about Python if it were not about 50x slower than CL. Furthermore, I find it extremely hard to write Python programs that do not contain subtle errors.
10:01:48
hajovonta
heisig: care to share pointers on that topic? My colleagues are enthusiastic about Python.
10:03:41
heisig
In my benchmarks, Python is always 20-200 times slower than Common Lisp code. The 50x I mentioned was when comparing adventofcode solutions with one of my colleagues.
10:04:15
heisig
But that is not the biggest problem of Python. The big problem is that the language has so many pitfalls.
10:04:46
Cymew
All the world is enthusiastic about python, as it's everyones darling for some reason. It's dog slow, and Ruby is even slower. But, this is seriously off topic.
10:04:53
jdz
[My only $0.02 of off-topic material] My bet is that people like Python because of the many libraries, which means they only have to write glue code.
10:05:58
hajovonta
heisig: I'm interested in looking at your performant CL code. I sometimes need to improve my CL code performance, but struggle to do so
10:06:38
hajovonta
at hackerrank, the requirements of completion are some 10x higher for CL code than for say Java or C++
10:07:17
hajovonta
Cymew: no, but I use SBCL and I know it has a profiler, but don't know exactly how to use it or what to look for
10:08:30
aeth
hajovonta: most things are caught by SBCL when you (declare (optimize (speed 3))) in a function
10:08:44
Cymew
In general, you want to find where in the code you spend most time, and figure out why.
10:11:09
hajovonta
I know the basic principles, like look for tight loops, and don't optimize code sections that don't contribute much to the time elapsed, but usually stuck with optimizing the identified parts
10:12:50
heisig
hajovonta: Maybe I should write a blogpost about how to write fast Common Lisp code over Christmas :) But the examples that I mentioned were not even optimized code. Baseline CL beats Python by orders of magnitude.
10:13:56
Cymew
I've found the profiler usually tell me my code spend time in a place which makes me go "huh?" and then realize that I can pre-calculate data and do some inline DECLARE.
10:16:04
Cymew
Surprisingly often you really don't optimise at all, just rethink, after seeing the profiler output. But, maybe that says more about me being bad at using the best algorithm from the start... ;=)
10:20:05
sindan
I have profiled some SBCL code of mine, and the results also make me wonder. IIRC most of the time is used in consing thousands or millions of times, it's quite unexpected
10:21:06
sindan
heisig: would like to read some advanced post (meaning it doesn't have to be a boring "primer") on how to optimize CL code
10:24:21
ogamita
aeth: this is plain wrong. Any programming languages is a clear win from 0 lines of bash, just because bash has no data structure.
10:25:02
ogamita
aeth: when you start having to implement first class arrays, structures, trees, anything in bash, you explode the LOC!
10:28:31
sindan
bash is to cobble together two or three utilities, it barely does arithmetic, when I see bash scripts in the hundreds of lines I wonder what is on the author's mind. And yes, they are going to bomb on any mistake, unless you read the return code of everything you do and do if() error handling sprinkled all over the logic... a nightmare no matter how one tries to go about bash
10:30:26
sindan
and I would not write long programs in python (meaning well behaved, efficient system programs), but as glue code it's unmatched because there are libraries for everything.
10:40:36
beach
For one thing, it doesn't have an independent standard, so it is not such a great idea to choose it for a serious commercial project.
10:49:53
ogamita
beach: You're confusing the name and the essence of the thing. Here statement is just a non-terminal name in a grammar. It's definition is that of a form, and a form is an expression . The only things that are executable in lisp are expressions.
11:06:01
sindan
Well, typical #lisp: still, no valid criticism. And you reply, if any, still won't be valid criticism, just more snarky comments
11:06:50
jackdaniel
as of standards, I don't see a big practical difference between finished standard (like CL), and finished reference implementation (like python2), given both are freely available and won't change.
11:08:33
sindan
jackdaniel: true, but the stink of aristocratic pretentions about lisp here never goes away.
11:10:27
jackdaniel
sindan: I must warn you (for the last time), please do not try to offend people on this channel
11:11:39
sindan
I am not trying, it seems. It looks like I am suceeding. I asked about technical points. I only get personal opinions, at best.
11:18:50
jackdaniel
to make myself clear: "no big difference" was *not* about quality and under the assumption, that said reference implementation has a written specification of how it behaves. my point was that both a) won't change; b) may be reimplemented; the only difference is that one has a "standard" sticker
11:23:23
heisig
sindan: Sorry, I was having lunch. Are you still around and want to hear my thoughts about Python? (Btw, I use Python myself, especially when I intend to share the code with my coworkers afterwards).
11:59:53
ogamita
sindan: the problem is that you don't understand the consequences. We start from a very small number of apparently "small" things, such as no independent standard, statements, significant whitespaces, no multi-line lambda, but the consequences are huge. If you're not experimented, you may not forsee them and understand.
12:00:35
ogamita
sindan: but basically, any one of those items (or the mess with lexical scopes), would be already redhibitory.
12:01:04
ogamita
sindan: we could probably go on and find hundreds of problems, but it's no use, once there's already one disqualifying problem.
12:04:40
sindan
ogamita: thanks for some points. Down at #lispcafe I was saying that python is not to teach CS concepts. It's a language to get things done, admirably put together considering what it attempts to cover.
12:06:02
sindan
And the hyperspec is full of footnotes about quirks, I don't have to mention then dozens of them. We like lisp and program around its quirks.
13:22:51
xificurC
well this was fun to read. not. Let me ask something more on topic. I've seen people link to the OUT macro from ytools several times. However I don't see the package (ytools) in quicklisp. Is anyone using it? Is there a fork with a different name where the OUT macro is available? Or does everyone just stick to FORMAT?
13:26:35
xificurC
this is a link (pdf) to the docs if someone doesn't know what the heck am I talking about - http://cs-www.cs.yale.edu/homes/dvm/papers/ytdoc.pdf
13:29:04
xificurC
_death: link? Do you have some accompanying docs? Do you know of other FORMAT alternatives?
13:32:05
_death
it's also extensible, for example https://gist.github.com/death/4e273d14e671a3c64f3be10cab2aa1b2
13:56:01
elderK
_death: Also, unrelated: When I see your name, I think of Death, The Grim Reaper from Terry Pratchett's Discworld series :)
13:57:26
elderK
On another tangent: I wonder how many CL / Scheme programmers there are in the world. Like, those capable of writing CL / Scheme in a professional capacity.
13:58:00
elderK
I have specified "CL" and "Scheme" rather than "Lisp", because I don't want to include say, AutoLisp or Emacs Lisp :P
14:00:45
elderK
"Perhaps there is some Great Filter, that extinguishes most programmers before they become truly enlightened?" :P
14:01:08
elderK
Or perhaps the majority of the Lisp programmers are hidden somewhere, sleeping. Hibernating maybe :P
14:01:54
elderK
Or perhaps, the majority of programmers in the world are simply too young, too naive, too immature? And the Great Lispers are waiting for us to wisen before bestowing us with their knowledge? :D
14:11:12
dlowe
It's a somewhat unpopular opinion but I think the mystique of lisp is misplaced and actively harmful to its popularity
14:12:18
_death
there are some quantities that could help estimating.. e.g., number of quicklisp installs (Xach publishes quicklisp data every now and then.. guess he could log IP addresses or User-Agent for better estimates..), number of github users with CL repos, or committers to CL repos, number of lisp subreddit subscribers, number of stackoverflow users asking/answering CL questions, etc.
14:14:17
ogamita
xificurC: the only criterial for quicklisp is that it should have an asd file and compile without error on sbcl.
14:14:42
elderK
It would be interesting to get like some hard numbers on: How many people say, install some CL implementation, tinker with it for a little, then leave it behind. Of the number that do, you know, play for awhile and leave it behind, some fraction of them will have taken something neat from the language, from whatever dialect they may have used. Then the other, I assume the larger fraction, will simply leave it behind with nary another thought.
14:15:47
elderK
It's like recently I learned that one of the people who inspired me originally to look into Lisp, actually doesn't seem to think it's useful for day-to-day stuff. That amazes me. Instead, he believes that it has a lot of lessons to offer, things to learn and take from.