Search
Friday, 15th of February 2019, 7:41:00 UTC
7:42:20
phoe
fe[nl]ix: lemme make a more descriptive ping: is my current version of split-sequence better for reviewing?
8:04:10
fiddlerwoaroof
Is something like (defmacro :/ ()) conforming code?
8:04:57
no-defun-allowed
i belive so, keywords are only variable-bound
8:05:50
fiddlerwoaroof
rutils, which gets frequently pulled in as a dependency declares a macro on :+ :- :/ and :* to do in-place math
8:06:10
fiddlerwoaroof
that's really annoying to me, because it leaks everywhere
8:06:25
fiddlerwoaroof
and, Lispworks complains when it processes the macro form
8:06:39
fiddlerwoaroof
Error: Defining macro :FOOBAR visible from package KEYWORD { *handle-warn-on-redefinition* is :ERROR }
8:06:44
no-defun-allowed
fair enough
8:06:58
fiddlerwoaroof
(I guess I can just rebind that variable to make it less annoying)
8:07:31
phoe
rutils shouldn't do that, defining functions/macros on keywords is left for the user
8:33:16
dim
the main problem I have with pgloader/SBCL is “Heap exhausted during garbage collection”, where can I read about how to handle “consing” in CL and limit it drastically?
8:36:08
_death
dim: you can start here https://github.com/sbcl/sbcl/blob/master/src/code/aprof.lisp
8:43:53
dim
thanks! do you know if that works well with multi-threaded programs?
8:45:06
_death
seems so according to the note
8:46:41
dim
last time I tried to profile pgloader the profiler worked but didn't get useful information, because in a typical small-data run we start a lot of short-lived threads
8:56:37
splittist
morning, all y'all
12:01:26
Lord_of_Life_
** NICK Lord_of_Life
12:48:55
Ukari
https://plaster.tymoon.eu/view/1178, is it impossible to export function printop in eval-when block in this situation?
12:51:24
_death
it is impossible to export functions.. only symbols are exported
12:51:58
_death
what is the purpose of eval-when and #. here
12:53:16
Ukari
https://lispcookbook.github.io/cl-cookbook/process.html#print-a-message-onto-the-top-level--read-time-eval-macro
12:54:02
_death
this is bad.. don't emulate it
12:55:21
Ukari
how to print message in a thread without eval-when and #.*standard-output*
12:55:42
_death
my advice is to use a logging library, such as log4cl
12:56:29
phoe
Ukari: what do you mean, print message in a thread?
12:56:54
phoe
you don't print messages in threads, you print stuff to streams
12:56:59
phoe
which stream do you want to print to?
12:57:17
_death
when you create a thread, it is possible to bind *standard-output* to the calling thread's *standard-output* value
12:59:56
phoe
https://trac.common-lisp.net/bordeaux-threads/wiki/ApiDocumentation
13:00:04
phoe
look at *default-special-bindings*
13:00:12
phoe
Ukari: the standard-output of what exactly?
13:00:40
phoe
the value of *standard-output*? if yes, then the value in which thread?
13:13:27
Ukari
https://plaster.tymoon.eu/view/1179
13:14:14
Ukari
it didn't work as I thought, where wrongs?
13:16:19
phoe
beach: those are quotes, not earmuffs
13:16:39
phoe
Ukari: you want `((*standard-output* . ,*standard-output*))
13:16:45
phoe
you want an alist, not a cons
13:16:49
phoe
so a list of conses, not a single cons
13:17:04
phoe
also, it is already defined as a variable; just SETF it
13:17:28
Ukari
in my sbcl it is undefined
13:17:45
phoe
are you using bordeaux-threads?
13:18:06
phoe
well, I don't know SBCL-specific functionality for that
13:18:46
Ukari
I will switch to use bordeaux-threads
13:38:05
Ukari
Is it a good practise to change a third library global variable, like bt:*default-special-bindings*?
13:39:02
phoe
(let ((*bt:default-special-bindings* ...)) (bt:make-thread ...))
13:39:21
phoe
but generally, only set it globally if you really need to
16:04:20
Xach
when i was young i thought it was weird to write pkg:*foo* instead of *pkg:foo*
16:04:36
Xach
but now i don't think that way
16:05:03
antoszka
does it work both ways?
16:12:56
phoe
CL-USER> (defpackage *pkg (:export #:foo*))
16:12:56
phoe
CL-USER> (defvar *pkg:foo*)
16:14:11
antoszka
yeah, I did the same in my mind :)
16:16:14
phoe
look, that's a dynamic variable in a dynamic package
16:17:55
Ukari
could (let ((*pkg:foo* nil))) works? i get a "Package *pkg does not exist." error
16:18:12
Xach
Ukari: if the package is nmaed "*PKG" and the symbol is named "FOO*"
18:06:30
cage_
i have two systems with conflicting nicknames, how can load (via ASDF) both in the same system?
18:07:23
cage_
my best "solution" (so to say) is to define a system that just remove the offending nickname from one of the system that needs to be loaded
18:07:53
phoe
load one system, remove the offending nickname, load another system.
18:08:27
phoe
either that or wait for package-local nicknames to gain widespread usage and then for library writers to stop using nicknames
18:09:09
cage_
i am one of those that use nicknames in library, sorry :(
18:09:19
phoe
cage_: nah, no problem with it
18:09:23
phoe
(until there's a collision)
18:09:26
cage_
i won't i future i promise! ;)
18:09:52
phoe
cage_: when there's PLNs, there will not be much use for short nicknames since library writers will be able to define their own per-package nicknames
18:10:55
cage_
i see, so far is just CCL that does not have this feature?
18:12:13
phoe
https://github.com/Clozure/ccl/issues/111
18:12:24
phoe
I'm getting closer and closer to close that gap
18:12:44
phoe
(and LW and ACL, but these are beyond repair)
18:14:56
phoe
cage_: I won't say it's done 'til it's merged
Friday, 15th of February 2019, 19:41:00 UTC