freenode/lisp - IRC Chatlog
Search
22:58:42
makomo
stylewarning: a quick question, is your old blog done for good? i.e. the only way to access is through archive.org?
23:02:14
stylewarning
It’s done for good. It’s been on the back burner to get that content back up on stylewarning, but the db was hosed, so I have to copy manually
23:05:59
stylewarning
aeth: but it’s considered contrived to many because everybody already knows what a for-loop is (:
23:06:33
aeth
But I think many programmers can read between the lines and think about what loop construct they'd like to write as a macro.
23:07:21
aeth
e.g. It'd be trivial to write a foreach on top of map nil or loop, even though CL doesn't actually have one.
23:07:26
makomo
stylewarning: yeah, that's what i read out of the comments too. people are so accustomed to for loops that they take them for granted, but i do hope they could see the point
23:08:52
aeth
e.g. (foreach (foo foos) (whatever foo)) could just be macroexpanded into (map nil (lambda (foo) (whatever foo)) foos)
23:12:47
aeth
for (ending with oh, hey, it's in the language as dotimes) -> foreach (trivial on top of map nil) -> something more elaborate, maybe
23:13:50
stylewarning
Interviewed while I was in England to do a whole different thing (explain how to program a quantum computer)
23:14:25
aeth
Well, you could always start a YouTube channel (if you don't already have one) and take advantage of the YouTube related algorithm that would hopefully pick up a more in depth (20-30 minute?) video
23:17:01
aeth
(And in case anyone didn't pick it up, the difference between a foreach implemented via map nil and a foreach implemented via a portable usage of loop is that map nil is generic to all sequences, and the loop-based foreach would have to choose between lists or vectors.)
0:05:13
emaczen
Then I started SBCL and I get a TYPE-ERROR "QL-UTIL" is not of type (OR FUNCTION SYMBOL) in quicklisp/setup.lisp
0:06:02
Bike
but if you built sbcl wrong that usually manifests as more like, lacking an extension, or just outrifhg failure
0:18:20
jfrancis
In case anyone is still around from when I asked this morning about how to strip the Unicode Byte-Order-Mark from the beginning of an otherwise-clean 8-bit ASCII file, the suggestion of flexi-streams worked wonderfully. And is even portable. Thank you.
0:38:46
emaczen
why does SBCL keep failing to load quicklisp.lisp? I get the error: QL-UTIL is not of type (OR FUNCTION SYMBOL)?
0:47:13
emaczen
Ok, I just commented out my .sbclrc and SBCL will start, but then I just tried starting it in emacs, and it is telling me "The value SWANK/BACKEND is not of type (OR FUNCTION SYMBOL)"
0:54:04
mrcom
Are there any freenode archives (in particular, #lisp) which allow search over an entire year's IRC?
0:58:00
mrcom
Xach: , or anyone, any thoughts on updates to "Go-to libraries"? (Zach's 2015-04-06 blog post)
1:10:30
rumbler31
oh. can you load sbcl without init, then manually load and start swank, then use slime-connect manually?
2:39:12
rumbler31
after you do that, start with an empty sbclrc, and follow the quicklisp setup steps
2:43:32
emaczen
rumbler31: When I install stuff from homebrew it just seems to work, and this problem got started since I tried to build SBCL from source myself
2:46:27
emaczen
on_ion: Yes, what I just followed similar advice using those immobile-code flags when you build SBCL from source with "sh make.sh"
2:52:29
emaczen
How do I uninstall everything that I built from source? This is no uninstall script.
2:52:53
rumbler31
if you didn't place the installation andywere, just blow away the folders you're compiling in
2:58:25
rumbler31
but its the only other thing I can think of about "persistent files" that might need to be cleaned up
3:00:16
on_ion
emaczen: hmm, is it full build? i just built from git yesterday with --fancy and worked great (debian)
3:11:52
emaczen
What versionare you using? I think it is the latest stable build? It was what was linked on sbcl.org
3:13:12
rumbler31
use that version you just made, to compile a source tree that includes your patch, or the removal of immoblie-code
3:13:44
emaczen
rumbler31: I mostly use SBCL and CCL, but I don't know how to get CCL fast enough for some programs I write that need speed
3:14:37
rumbler31
so are you also specifically passing in the lisp to use for compilation? I think you need to specify that to make.sh as well
3:15:47
rumbler31
if you don't specify I think it uses whatever sbcl is in the path, if that isn't he one you just made then you might run into trouble
3:17:11
rumbler31
but even then I don't know if make.sh knows to use the sbcl binary that you just built, it probably still looks in the path
4:37:22
emaczen
shouldn't this be as simple as just evaluating: sh make.sh "path-to-ccl" --without-immobile-space --without-immobile-code --without-compact-instance-header?
4:39:32
emaczen
I'm trying that without the flags to see if I can even build SBCL correctly from source...
4:40:29
Bike
the function "e" is only passed the value of *global*, and doesn't know anything about that variable itself, per the basic evaluation rules
4:45:42
esthlos
x is lexical in the scope of the environment pointed to by the procedure; that's what I mean
4:46:20
Bike
well the lexical part isn't important. the fact is that there is a binding, and that's what push alters.
4:48:47
emaczen
So I can build SBCL fine from source, It just fails with that strange QL-UTIL type error when I add the immobile-code flags
4:49:05
ludston
This is probably not how it actually works, but I always think of it as, (defmacro push (x y) `(setf ,y (cons ,x ,y)))
4:51:19
emaczen
Just trying to build SBCL with immobile-pages since I keep getting an error that says no more immobile pages.
4:53:00
on_ion
maybe you dont need to worry about immobile page[s] if that is not the source/root/cause of the problem
4:53:41
esthlos
what I still don't fully understand, which is embarassing at this point, is that if we replace *global* with, say, an instance of a CLOS object (with appropriate push method, etc.), then *global* is mutated
4:54:22
Bike
(push x y) alters a variable binding. (push x (slot-value ...)) modifies an object. they are pretty distinct things to do.
4:54:51
emaczen
on_ion: Some others here linked me to some mailing lists where people got the same error I did, and emailed SBCL devs
4:55:13
ludston
It's like this: *global* has a memory dress, and x in (let ((x '()))) has a memory address
4:55:21
emaczen
The devs said that if your program uses a lot of symbols, then immobile pages can be exhausted
4:56:48
ludston
The fact that x, and *global*'s memory addesses happen to have the same value at first is just a coincidence, since you passed the value of *global* into the address of x
5:08:49
on_ion
well. it is starting to feel like a different approach could be considered if you are maxing out some runtime limits
5:12:37
emaczen
on_ion: I'm probably going to re-write my main code at some point using structs and defuns but until then, I'm just going to do what I go to do!
5:14:58
ludston
emaczen: As a test, I interned an entire english dictionary into sbcl and it worked fine. You must have a LOT of symbols.
5:18:18
beizhia
hope I'm not interrupting, but could someone give me a sanity check on this hello-world I'm trying to do?
5:18:39
beizhia
I'm not able to require my asdf system, but its the same config I have for another project and that one works fine
5:23:34
beizhia
I've got basically the same config for another project, and I'm able to build an executable with asdf:make, but I can't even (require :hello-world) for some reason
5:30:33
beach
beizhia: ASDF does not search all your available .asd files for a system with the right name. It turns the system name into a file name and looks for that file name.
5:36:13
beizhia
changed the filenames to hello-world.asd and hello-world.lisp, updated the system def to have ((:file "hello-world")) in the components
5:49:40
beizhia
ya... expecially since my other is called "bulk-rename", and that's what I copied all this from
7:46:11
on_ion
whoa, cant do underscores in function/symbol names? (defcfun "XT_Alpha" :void) => XT-ALPHA
7:56:04
edgar-rft
on_ion: yes, you can, but defcfun is not part of the ANSI standard, so its behaviour is implementation-dependent
8:00:36
on_ion
i dont understand this, however: name ::= lisp-name [foreign-name] | foreign-name [lisp-name]
8:10:58
beach
on_ion: I strongly recommend you program in Common Lisp rather than in some other language.
8:12:12
on_ion
just because the libraries i am interfacing are trying to be their own utopian api system platform environment
8:14:36
on_ion
i have been having troubles with SDL and the REPL, SDL wants to take over the world and be its own exclusive thing, and i just want to lisp
8:15:08
beach
Yes, more often than not, using foreign code creates problems rather than solving them.
8:15:52
on_ion
yea.. and its driving me bonkers. just decided today to stuff everything ugly into C because i need lisp
8:17:01
on_ion
SDL has its own thread stuff and whatnot, ive seen countless ways of dealing with it in CL, amongst the various SDL1/2 bindings for CL, and i'm accustomed to doing SDL/opengl by hand and C anyhow. it feels really good also, which is the most important to me
9:28:23
ludston
It's working pretty great for me though. I wound up hacking on slime a little though
9:30:11
ludston
Step two, pop (swank:handle-requests swank:*emacs-connection* t) somewhere in your (:idle) so that you can still use the emacs repl
9:31:28
on_ion
there were threading quirks and input event handling anomolies , works good right now though by using a C lib
9:32:57
on_ion
i want to evaluate code and type stuff in repl while the SDL window is rendering its loop
9:33:18
ludston
Yes, I don't think you understood what I mean by pop (swank:handle-requests swank:*emacs-connection* t) somewhere in your event loop
9:34:35
ludston
And also, any changes that you make via slime will be evaluated at a safe time during the event loop
9:38:25
on_ion
https://github.com/quakerquickoats/hoovy/blob/master/nova-cl/nova.lisp <-- stuff on the bottom here
9:40:55
on_ion
hmm =) i wonder if its similar to that lisp file there, or how a simple "thing" could be distributed for anyone to use
9:42:01
on_ion
i am not even sure if i could even have SDL running in a loop in the background with C, hrm