libera/#commonlisp - IRC Chatlog
Search
8:59:13
lotuseater
Hi beach nice that you're writing. :) Don't worry I have no silly questions atm. ^^
9:18:55
lotuseater
I thought about constructing a LET-like macro named ILET for defining lexical immutable symbols by looking at the macro body if there are none of '(DECF INCF SETQ SETF) in the body paired with the symbol name. okay actually I did that some weeks ago
9:20:49
lotuseater
Was about two years ago around 2 months I stumbled into the CL world that i wrote a macro HLET* where it wasn't needed that the dependent symbols are given in linear order. It looked for references of symbols and sorted this topologically and that worked. :)
9:26:24
beach
lotuseater: You could have (let ((x ...)) (f x)) where F is a macro that expands to (setf x ...).
9:33:33
moon-child
lotuseater: and on the topic of macros, it's possible that a macro expansion could generate code like (when nil (setf x ...)), which _is_ ok, but which it's not possible in the general case to reject statically
9:35:59
moon-child
if you would like a high-quality conservative implementation of immutability, haskell is probably a better choice than cl
9:39:37
lotuseater
oh damn, the Halting Problem o_O so wait to when quantum computers ship out in hobby editions
9:40:45
beach
As I recall, quantum computing doesn't pretend any additional computational power over Turning machines.
9:41:22
lotuseater
yes static typing locks one out I learned, not even in prototyping, but could of course by powerful with a good mathematical based type system (so there is no void type)
9:42:51
moon-child
yes; quantum computers are algorithmically faster than traditional computers at certain, but there's nothing they _can_ do that an ordinary turing machine can't
9:43:14
moon-child
and the strong form of the church-turing hypothesis says that hypercomputation can't be realised
9:46:38
kakuhen
i come from a mathematics background so i'm not too acquainted with the wisdom in computer stuff
9:47:27
moon-child
kakuhen: I'm going to bed now, so not going to stick around and chat, but: it devolves into dynamic typing
9:49:21
lotuseater
are there also some video conferences the next weeks? I saw videos from the Common Lisp study group, they do much topics of interests.
13:14:54
_death
it uses sbcl internals, which have changed.. so you can (i) work to fix it (ii) switch to a different library (maybe one that doesn't make use of FFI)
13:54:30
francogrex
Hi, for learning, I am trying to "optimize" this (and it's not high level optimization), only at the declarations level: https://benchmarksgame-team.pages.debian.net/benchmarksgame/program/pidigits-sbcl-3.html
13:57:10
francogrex
a lot of unable to do inline fixnum arithmetic, because of the integer/fixnum thing there
14:07:19
jackdaniel
sbcl tells you that if /you could/ guarantee that these integers are fixnums, then it would be able to apply a certain optimization
14:16:00
francogrex
jackdaniel: ok, i am sure i cannot guarantee that the output of the arithmetic operations will be fixnum (actually i can guarantee that they will not be :( )
14:18:07
francogrex
i though there would be a way for optimized integer operations without using fixnums
14:21:21
aeth
some notes are inherently unfixable, but you probably still want optimized code to be optimized so you can just hide the remaining notes in a LOCALLY
14:21:40
aeth
well, no, sometimes SBCL complains that the problem isn't... an easier to optimize problem
14:22:07
aeth
Especially when there's division. Like, thanks, if I was solving a different problem, it would really work out.
14:23:16
aeth
You could experiment with TYPECASE and having a fast path and a slow path, but the slow path will then always complain (unless moved to a separate function entirely)
14:37:42
aeth
That being said, depending on the problem, you could make your own "bignum" out of a fixed-size array of numbers that are all known to be of a fixed size and thus fully optimizable. Definitely doable for simpler things (especially if you just want the bits of an integer, or just want to add). Probably not doable if you want to use all of the features of a bignum (writing your own EXPT, division, etc., is
15:08:55
lisp123
I assume I can't have generic functions & functions named by the same symbol in the same package?
15:12:08
beach
lisp123: What would that mean? How would the system know which one you refer to when you say (NAME ...)?
15:13:04
lisp123
beach: Yeah that's what I was thinking. Was hoping for the system to try the global function after exhausting all generic function options
15:15:39
lisp123
So what I have is, an accessor function for a CLOS slot (which from reading online is a generic function), say object-slot-name --> I want to then write a function called object-slow-name to generate the value to populate this slot
15:26:22
jcowan
pjb: That's why I want to get the Common Lisp in Medley updated to the ANS, so that all those tools *will* be vaailable. "Develop in Medley, deploy in SBCL!" Only you can't quite, yet.
16:30:12
jcowan
e.g. IL: is case-sensitive but all standard symbols are uppercase (you need your CAPS LOCK key)
16:31:17
jcowan
Medley will boot and run file, and you can start either a CL or IL REPL. The main problem with CL is that it is basically CLtL1. Some work (nobody yet knows how much) was done to add CLtL2 facilities.
16:33:27
jcowan
CL has NLAMBDA (elsewhere known as FEXPR) pseudo-functions, which look like macros to CL; I'm not sure if the reverse is true. But IL isn't that big a language: the Interlisp teams in the past worked on tooling, not on embiggening the library.
16:34:25
beach
I see, so getting full ANSI Common Lisp is a bigger problem than getting the Interlisp environment to work.
16:53:11
cheers
beach: How close is SICL to being completed? totally fine if you don’t have an exact estimate
17:22:17
jcowan
_death: Yes, in the CL Exec (REPL) you are using the CL readtable instead of the IL readtable. If you start an IL Exec then nil should not work but NIL will.
19:03:29
Posterdati
please help, how is it possible to simulate a button click on a webpage using drakma?