freenode/#lisp - IRC Chatlog
Search
12:57:33
Shinmera
shka: I depend on documentation-utils in a lot of my projects for docstring reasons, and don't see the problem.
12:57:53
kolb
Zhivago: the root of the problem is people wanting to decide what’s "right" for everyone else
12:58:48
Shinmera
myrkraverk: The first line should describe the overall function in full, which can make it a tad long sometimes, yeah.
12:59:23
Zhivago
kolb: Yes, you want to decide that weird crap in docstrings is right for everyone else. :)
12:59:23
myrkraverk
Shinmera: Yes, I know; I tend to break the first line for my docstrings anyway; but the first line *is special*.
13:00:54
myrkraverk
And about long lines; I tend to split my screen horizontally, so I can put two code pages side by side (or manual, page, etc) -- but because most "modern" IDEs don't do that, developers have gotten extremely lazy about shortening long lines.
13:03:00
Zhivago
kolb: Are you putting weird mark-up into docstrings and expecting random systems to deal with that as you expect or not?
13:46:34
kolb
Shinmera: Regarding documentation-utils, can I get the untranslated docstring for a a symbol/type tuple?
13:46:53
Shinmera
There's currently no translation going on at all, so just DOCUMENTATION will do that
13:47:35
kolb
Shinmera: yeah but I would use a translator, but still need to get to the original source to generate my HTML docs
13:48:07
Shinmera
You're asking me about features that aren't implemented. How am I supposed to know how they would work?
13:48:25
kolb
http://shinmera.github.io/documentation-utils/#DOCUMENTATION-UTILS:*DOCUMENTATION-TRANSLATORS*
13:49:44
Shinmera
You COULD output some other place that side-effects documentation and stores the original string somewhere else to do what you want
13:50:45
shka
https://github.com/sirherrbatka/cl-data-structures/blob/master/src/api/docstrings.lisp
13:56:58
shka
i don't see need for docstample as a separate project, so i would rather add all features into documentation-utils, should i use github issues to discuss this?
14:45:35
lisp_guest
how exactly is LAMBDA as a symbol vs. LAMBDA as a macro differentiated by the evaluator?
14:46:11
lisp_guest
are the possible cases where a lambda expression is acceptable just enumerated on a case-by-case basis?
14:46:42
lisp_guest
yes, indeed. so how does the evaluator know when it's a macro and when it's a symbol?
14:47:21
beach
lisp_guest: It depends on the occurrence. If it is in a position where the form is evaluated normally, it is a macro call.
14:47:43
lisp_guest
Bike: right, that's what i'm wondering about. so it's basically hardwired into FUNCTION itself?
14:47:46
beach
lisp_guest: Otherwise, it is just a lambda expression starting with the symbol LAMBDA.
14:48:43
Bike
there are a few functions that deal with lambda expressions, like COMPILE and COERCE, but they take expressions as quoted data
14:49:53
lisp_guest
mhm. so basically, there are few special places when a lambda form has special meaning (like FUNCTION and calling a function), and in all other cases it's treated as a macro
14:50:42
Bike
function and lambda forms (which is what you call what beach said) are not normal evaluation contexts
14:51:59
TMA
lisp_guest: it is the same as with other symbols designating a macro -- when in normal evaluation context, the list (A ...) is a macro call for any symbol A designating a macro (including the symbol LAMBDA)
14:53:36
TMA
lisp_guest: there are special contexts (such as inside (QUOTE ...) or (FUNCTION ...) or other special forms where the context dictates following other rules as specified by that special form.
14:54:46
lisp_guest
mhm. so there's really nothing *that* special and black magic about it. the interpretation of the expression depends on the context and that's it
14:55:14
TMA
lisp_guest: additonally the (LAMBDA (...) ...) expression can be used in the operator place in a compound form. this is the only special case for (LAMBDA (...) ...)
14:57:04
TMA
lisp_guest: so that you can use ((lambda (a) (+ a a)) 1) instead of (funcall (lambda (a) (+ a a)) 1)
14:59:28
lisp_guest
what was weird when i first learned about this is that it seemed like black magic because i couldn't tell when it had its special meaning
14:59:42
lisp_guest
fiding out and confirming that it's "hard coded" into the standard makes it very easy to understand
15:01:34
Bike
it's described on the page for function, and lambda forms are explained in the pages on evaluation semantics.
15:05:49
Bike
a lambda expression. a list beginning with LAMBDA. like (lambda (x) x). like we've been talking about.
15:08:55
lisp_guest
Bike: exactly, but when i read "expression" i didn't think of such a list. i guess it's because i got used to what the term meant in other languages
16:26:24
nyef`
Today I learned: The AMOP specification for MAKE-METHOD-LAMBDA includes an example which uses FLET to bind CALL-NEXT-METHOD, an action forbidden by CLHS.
16:28:35
beach
I am not sure that's the right interpretation of what the Common Lisp HyperSpec says.
16:35:16
nyef`
CLHS FLET says that it establishes a function binding. CLHS 11.1.2.1.2 forbids this for external symbols of package COMMON-LISP. CLHS 11.1.2.1.2.1 provides exceptions for symbols which don't name standardized functions, macros, or special operators. CLHS CALL-NEXT-METHOD says that the exceptions of CLHS 11.1.2.1.2.1 don't apply.
16:58:52
Bike
make-method-lambda also respecifies call-method and make-method without giving detail on new syntax. it's kind of extracurricular.
18:18:41
akkad
is there any trivial-repl sorts of packages to provide the consistent niceties some repls offer. e.g. :pwd :cd :ls
18:32:21
pjb
and there's also a com.informatimago.common-lisp.interactive.interactive:rep if you need to implement the loop yourself.
19:11:49
fourier
is where a more/less portable way to get posix file descriptor from open file stream or at least file name? I could get it (filename) relatively easy on LispWorks and apparently on ccl, but dont have sbcl to test...
20:26:52
rme
It's probably too late for this year, but I wonder if it would be good to look into having a Lisp room at FOSDEM (which I just learned about). https://fosdem.org/2018/
20:31:51
rme
I keep talking about moving to France. If I ever do that, FOSDEM will even be close by.
21:09:19
alandipert
i can't figure out how to use fixnum-only * in this function, anyone have advice on how to type hint? https://gist.github.com/alandipert/f2602716487f29701b94e0db3a628e14 (everything is always fixnum)
21:24:21
fourier
alandipert: try (optimize (speed 3) (safety 0))and (float 0) (not sure about last one, maybe its lispworks only)
21:41:42
jasom
ever have one of those moments where sbcl tells you some code is unreachable, and you just can't figure out why?
21:59:50
jasom
well changing the type of depth to (mod 16) doesn't change things. Plus it shouldn't be *unreachable* because clearly if depth is 0 (which it's allowed to be) everything works fine
22:01:29
aeth
rme: One idea would be to do something that can be visualized through computer graphics. There are 6 or so libraries in CL that can handle visualizations, e.g. https://github.com/vydd/sketch
22:03:36
jmercouris
I feel bad because I use a global var to store completion candidates temporarily, but the whole minibuffer/command system needs an overhaul/rethink anyway
22:03:49
jasom
Bike: derived type is just "function"; it returns the result of a map-into which ought always be a vector, but it might not have been able to infer that
22:04:24
Bike
have you tried macroexpanding the loop? it's ugly, but that tends to help me understand how the compiler is thinking
22:05:39
jasom
yeah. Also, removing the type declaration for result doesn't change the dead-code note
22:09:57
jasom
https://gist.github.com/jasom/c95e083e4ba7c42e8321ede0e3d12583 is now updated with the maxroexpansion
22:15:59
Bike
yeah, i hardly see any way the make-array could be dead other than prefix-buckets being weird somehow.
22:24:25
pierpa
doens't the LAMBDA in (map-into new-level (lambda () (ironclad:make-digest +hash+))) needs an (ignored) argument?
22:42:45
AeroNotix
I wrote a browser with CL/webkit a while back, then real life + job got in the way. I still longingly look at the repo on github sometimes and think what could've been
22:43:43
jmercouris
AeroNotix: I WAS using QT, but now I am working on a GTK port for Linux, better bindings and speed
22:44:49
AeroNotix
interesting. In my research (that I did a while ago) I found that Qt, at least at first, looked better
22:45:06
jmercouris
I've already completely implemented it in QT, so I'm very familiar with that path :D
22:46:09
jmercouris
AeroNotix: On OSX the rendering was absymal, not necessarily due to the web-engine, but due to QT limitations, their port of any web engine requires them to do rendering, and that was always too slow
22:47:35
jmercouris
for example, there are literally 0 side effects when loading the code until you hit base.lisp
22:49:02
AeroNotix
I used that parenscript highlighter for a while. Eventually it started crashing a lot on me.
22:49:52
AeroNotix
jmercouris: I would be interested but my day job is ridiculous (and has been for for 3 years plus)
22:50:15
jmercouris
If you simply complete the GTK port, nEXT is literally ready to use as your daily driver
22:51:00
jmercouris
This is it, all you have to implement: https://github.com/nEXT-Browser/nEXT/blob/master/next/source/package.lisp
22:52:04
AeroNotix
If you're full steam ahead though with next I really wish you luck in seeing that idea come to fruition.
22:52:07
jmercouris
Hmm, I would rather work together on one project and get farther than divide our efforts
22:52:58
AeroNotix
so having a proper, fully, extensible browser done in The Lisp Way will have been realised.
22:54:59
jmercouris
If you're interested in the project goals thery can be seen here: https://github.com/nEXT-Browser/nEXT/tree/master/next#release-timeline
22:55:44
jmercouris
I also hope to be able to one day monetize nEXT, make some contributions back to the Lisp community, develop some tools stuff like that
22:56:10
AeroNotix
jmercouris: actually one of the reasons I initially started developing lispkit was because I couldn't ever find a browser that I could regexp search within a page
22:56:48
jmercouris
AeroNotix: Hmm, I don't have that working yet, I only JUST added a really basic search
22:57:06
AeroNotix
I think actually I was using the webkit APIs for it. I think they genuinely let you use regexp searches on a webkit browser instancce
22:57:11
jmercouris
I'm only now really getting to grips with parenscript, but I can already do some cool things
22:57:40
jmercouris
I literally only need to be able to 1. make a webkit view, 2. set the url, 3. execute JS
22:58:29
jmercouris
bought heavily into QT webkit, and the port to QT Webengine took almost like a year or something insane
22:58:40
jmercouris
I was able to complete my port in like 3 weeks, and 2 of those weeks were spent learning cocoa
22:59:40
AeroNotix
The lisp community was generally quite excited about lispkit/similar things. As much as the lisp community can be. I mean you have 900 stars on github
23:00:01
AeroNotix
got to remember there really isn't a huge active community behind lisp these days
23:00:02
jmercouris
AeroNotix: I have a feeling those are mostly like emacs users/ random programmers
23:01:26
jmercouris
I'll probably pilfer a bunch of code from Lispkit for the GTK port, so in a way, it will live on :D
23:03:18
jmercouris
I have your License located here https://github.com/nEXT-Browser/nEXT/tree/master/documents/external
23:03:19
AeroNotix
Cool. I'll star next and see where it goes. When it gets to the point of `make && make install` I'll probably switch to it. As I said, day job is just too demanding at the minute for anything deep and dark with non-work related programming if you get me
23:08:02
jmercouris
Your last name also didn't seem Polish, but I figured maybe you had ancestors from another country or something
23:08:35
AeroNotix
I am not sure about my surname. My mum did some ancestry stuff a few years ago and couldn't figure it out
23:10:41
rme
I need a better profile picture. I was trying to be artistic, but now I think it looks dumb.
23:12:18
jmercouris
rme: You know, that's an interesting name, we have a U Bahn Station here in Berlin named "Bellevue" it's pronounced "Bell Voo"
23:12:57
AeroNotix
Where I grew up in the UK we have a pub at the bottom of my mum's road called The Bellevue
23:16:38
runejuhl
For numbers 21-99 we say the last digit first, so 21 would be twenty-one in English and en-og-tyve (lit. one and twenty) in Danish
23:18:07
runejuhl
jmercouris: the worst thing is that kids in Danish schools have a harder time learning numbers (and math) because of the language
23:18:41
jmercouris
In literally every other language I know, numbers are consistent, except for the germanic derivatives
23:18:46
runejuhl
I've heard about teachers using the "correct" way of pronuncing numbers even though it's not valid Danish
23:19:54
runejuhl
There are a bunch more oddities about numbers in Danish. The system used to be based on multiples of 20, so 60 is "tres" (3 x 20) and 50 is "halvtreds" (2 x 20 + one half 20)
23:23:05
runejuhl
I better get to bed and catch a few zzzzs before my fever-ridden offspring decides to wake up and terrorize me...
0:46:28
AeroNotix
jasom: you should really pare that down to a very small example, I can't run that code you've given me without libraries/etc