<aeth>
It's not a hard concept, or an unusual concept, it's just slightly different.
<White_Flame>
oh, and variable keys would need multiple results: unify {?:3 . ?} with {a:3 b:3 c:3}
<aeth>
I think the first thing this library would need to do is introduce the trivial HASH macro (or HASH-TABLE or whatever) that turns (hash :foo 42 :bar 43) into (let ((#:hash1234 (make-hash-table))) (psetf :foo 42 :bar 43) #:hash1234) because now we have a concise way to say (hash :a 3 :b 3 :c 3)
<aeth>
oops the psetf needs to setf on the gethash
john2x has quit [Ping timeout: 244 seconds]
<rpg>
White_Flame: I don't need anything as ambitious as matching on values; just keys + values. It occurs to me that what I'm looking for is DAG unification (well, for DAGs with named edges).
<rpg>
aeth: One way to think about it is that unification solves equations over a particular kind of symbolic algebrar.
<rpg>
s/algebrar/algebra/
<White_Flame>
ok, then you just need a representation for an "entry". A cons cell probably suffices
<White_Flame>
but I think your problem is still strangely specified
<White_Flame>
are you always going to "unify" two hashtables where 1 is exactly 1 element shorter than the other?
<White_Flame>
do you have actual unification variables?
<rpg>
White_Flame: The two tricky details are paths in the unifiers, and that the semantics is that if you don't have an entry for a key, then you match *any* entry for that key.
<White_Flame>
what's the issue with paths?
<White_Flame>
if there is a key whose value is another hashtable... then that entry is simply that key/value pair
<White_Flame>
I think showing an example would be good
<aeth>
You could probably greatly simplify things by assuming keyword/symbol keys...
<aeth>
if you don't need to support an arbitrary hash table
lavaflow has joined #lisp
<rpg>
So we extend your example to {x:?X} {p: foo x: { y: {z: bar}}} and we get a unifier that is ?X = {y: {z: bar}} and... I'm not sure what I do with p: foo.... In this case I guess it's the same as if there is an additional, implicit top-level variable -- ?TOP1 = {x: ?X}, ?TOP2 = {p: foo x: { y: {z: bar}}} and ?TOP1 = ?TOP2...
<rpg>
aeth: You are right -- symbolic, or even keyword keys are good enough for me.
<White_Flame>
that wouldn't actually unify in what's normally done
<White_Flame>
because you're trying to match a hashtable of size 1 with one of size 2
<White_Flame>
eliminating the keys adn converting them to positional slots, it'd be like trying to unify (?X) with (foo (bar))
<rpg>
White_Flame: Right; that's what's difficult about this case; the entries are extensible. That's why I was saying that the semantics are odd.
<White_Flame>
but {x:?X . ?} would unify with that p:foo table
<White_Flame>
as would {x:?X ?:?}
<White_Flame>
because that's compatible with a 2-element table
<White_Flame>
having hidden implicit matches I think is bad idea
<rpg>
White_Flame: If this was prolog, I would make these things out of difference lists, like your {x: ?x . ?} -- these are data structures that are extensible.
<White_Flame>
ie, have magic result buckets for differing-size tables
<White_Flame>
prolog does have the equivalent of hashtables, with key/values and these sorts of operations
lnostdal has quit [Ping timeout: 252 seconds]
<rpg>
White_Flame: That's a neat idea, because I can treat these objects as always having a sort of &rest logical variable.
leb has joined #lisp
<White_Flame>
(I did say I thought that was a bad idea ;) )
meepdeew has quit [Remote host closed the connection]
<rpg>
If I do that, then standardization (making variables unique) will solve my problem, because the logical variable for the "hole" will always end up with a unique name.
<rpg>
Then there's only the more limited problem of treating these things as non-positional.
mindCrime has quit [Ping timeout: 259 seconds]
moldybits has quit [Quit: WeeChat 2.4]
<rpg>
White_Flame: Your suggestion is really like difference lists; thanks for mentioning that -- it suggests a path to a solution.
<White_Flame>
I've thought about this a long time for our tools, and it actually ends up exacly the same a prolog's tools
<rpg>
The issue for me is that I want to have operations on something like a python dictionary, *but* I want to be able to backtrack over it, so doing the updates by something functional.
<White_Flame>
backtracking & search are beyond unification
rumbler31 has quit [Remote host closed the connection]
<White_Flame>
unification is just a single step in a backtracking search
<White_Flame>
it doesn't encompass the search itself
<rpg>
White_Flame: There were a lot of good ideas in prolog, but it never caught on.... I think for good reasons. But some of the ideas developed for programming it are quite clever...
<White_Flame>
my biggest problem with prolog is that there's too many imperative practicalities shoved into it, breaking its declarative nature
<White_Flame>
but yes, it is a great language in concept
<rpg>
White_Flame: Yes, that's true. It's possible that what I need is simply a data structure with an undo-able assignment. More thought is required!
<White_Flame>
also, probably the only non-Lisp homoiconic language of note
<rpg>
White_Flame, aeth -- thanks for discussing this with me. I have to go now -- there is a dog scraping at the door. Hope to chat with you again sometime soon. Good night!
<dlowe>
tcl
<White_Flame>
tcl is a concatenative language
libertyprime has quit [Ping timeout: 245 seconds]
<White_Flame>
there isn't really any structure to be homoiconic with
<dlowe>
space delimited strings is a structure
<dlowe>
it's of note, it's not lisp, and it's homoiconic
<White_Flame>
its homoiconicity is very arguable
<dlowe>
apparently
<rpg>
I think homoiconicity requires something stronger -- something intuitively like "the syntax IS the abstract syntax tree."
<White_Flame>
or put differently, TCL's syntax is degenerate to a point underneath which homoiconicity is determinable :-P
<White_Flame>
erm, not stated exactly correctly but whatever
<aeth>
cltcl when?
moldybits has joined #lisp
<no-defun-allowed>
Common Lisp the Common Lisp?
ebrasca has quit [Remote host closed the connection]
Kaisyu7 has joined #lisp
techquila has quit [Ping timeout: 252 seconds]
lavaflow has quit [Ping timeout: 258 seconds]
john2x has joined #lisp
techquila has joined #lisp
zotan has quit [Ping timeout: 252 seconds]
zotan has joined #lisp
<oni-on-ion>
tcl strings all the way down
lavaflow has joined #lisp
zotan has quit [Ping timeout: 250 seconds]
zotan has joined #lisp
dale has quit [Read error: Connection reset by peer]
dale has joined #lisp
zotan has quit [Ping timeout: 272 seconds]
zotan has joined #lisp
paule32 has quit [Ping timeout: 258 seconds]
mindCrime has joined #lisp
rumbler31 has joined #lisp
zotan has quit [Ping timeout: 258 seconds]
zotan has joined #lisp
rumbler31 has quit [Ping timeout: 268 seconds]
orivej has quit [Remote host closed the connection]
orivej has joined #lisp
anewuser has joined #lisp
Necktwi has quit [Ping timeout: 245 seconds]
pierpal has quit [Ping timeout: 272 seconds]
linack has joined #lisp
linack has quit [Quit: Leaving]
libertyprime has joined #lisp
lavaflow has quit [Ping timeout: 258 seconds]
milanj has quit [Quit: This computer has gone to sleep]
flip214 has quit [Ping timeout: 245 seconds]
GoldRin has joined #lisp
flip214 has joined #lisp
lavaflow has joined #lisp
pillton has quit [Read error: Connection reset by peer]
papachan has quit [Quit: Saliendo]
Necktwi has joined #lisp
rpg has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
orivej has quit [Ping timeout: 272 seconds]
orivej has joined #lisp
FreeBirdLjj has joined #lisp
FreeBirdLjj has quit [Ping timeout: 258 seconds]
Lycurgus has joined #lisp
<beach>
Good morning everyone!
<Lycurgus>
moin beach
caltelt_ has joined #lisp
anamorphic has joined #lisp
<anamorphic>
In SBCL, is there some way to treat a compile warning as an error?
<oni-on-ion>
"The first implementation of OPS5 was written in Lisp, and later rewritten in BLISS for speed. " <--- are you sure
vibs29 has joined #lisp
<logicmoo>
the problem i have againt Logtalk is merely that it is an experiement with static OO (that never gets to OO)
<oni-on-ion>
experiment? it feels quite mature
<logicmoo>
its very mature.. but all it need is aobut 500 lines of code to do the type of OO i am refering to
<logicmoo>
("but" there is that the author code introduce those lines even but hasnt)
<oni-on-ion>
"type" of OO <--- wait wait. types and oo? =P
<logicmoo>
in fact at his place of business (Kyndi) he had to pay someone 6k $ to circumvent his not adding it :)
<logicmoo>
sorry i just mean OO that lets you call "new" on a virtual object
<oni-on-ion>
thats about half a year salary for me
<logicmoo>
what he does is creates a new "module" for each new instance
<logicmoo>
though i did mean static types.. he does have that!
<logicmoo>
but lets say you want to (make-isntance 'Person :name "Fred") (make-isntance 'Person :name "Joe") .. you cannot do that in Logtalk
Lycurgus has quit [Quit: Exeunt]
pierpal has joined #lisp
<logicmoo>
you have to litteraly design a "type" with a name of Joe and another type named of "Fred"
<logicmoo>
which is very fun in an experimental way
<oni-on-ion>
hmm
<oni-on-ion>
for strings ..?
<logicmoo>
and you can _even runtime generate those modules_ (Types = MNodues) in Logtalk.. Instance == modules to
<logicmoo>
well you wouldnt want to use strings here you use Atoms
<logicmoo>
he wanted to show off that neat trick where instances are just inheriting from a parent instance
<logicmoo>
nothing wrong with this at all! the only problem is that is the only type of instancing/iheritance available
<anamorphic>
oni-on-ion, thanks for that pointer. Didn't think to look in asdf for hints
<oni-on-ion>
anamorphic, np hope you find the solution. i'd like to know it as well
<oni-on-ion>
logicmoo, hmm well about modules, i'm still learning them in OCaml and their clear difference between "Objects/Classes"
<logicmoo>
where program programmers normally will pass aorund a term refernce like person("Joe") and person("Fred").. Logtalk does not yet supprt this.. it could ina couple hundred lines
<logicmoo>
program programmers/prolog programmers
<logicmoo>
the term reference model is the most propular and there is even low level support .. basically its like a C struct
<oni-on-ion>
hmm i havent had the chance to use Logtalk
<oni-on-ion>
it looks robust and well thought out though
<logicmoo>
i go for it about once a year for about 10 years now .. the author is awesome dude.. i love the concept
Josh_2 has joined #lisp
<oni-on-ion>
cool =)
orivej has quit [Ping timeout: 272 seconds]
<logicmoo>
he wants to open peoples mind to his "static object system"
Jesin has quit [Quit: Leaving]
<oni-on-ion>
been avoiding the OO-stuff in ocaml (interestingly, objects can be created/instantiated without classes), but learning all the Module stuff
<oni-on-ion>
prolog KB is a bit static anyway, by nature: what with assert/etc not entirely meant to be "dynamic"
karlosz has quit [Remote host closed the connection]
<oni-on-ion>
also see: dynamic predicates
libertyprime has joined #lisp
karlosz has joined #lisp
<logicmoo>
it comes down to Object = Code Modules.. and Logtalk doesnt want to cupprt dynamicly crea5ed isntances.. since veryhting a person might create an object for can be redesigned
<logicmoo>
i meran anything that needed "dynamic" Code Modules .. are dubious and proabably should be redesigned
<logicmoo>
in order to support lisp CLOS i could not use Logtalk :(
<oni-on-ion>
heh unless you restart the PL system on each class change =)
libertyprime has quit [Ping timeout: 248 seconds]
<logicmoo>
I ended up using all 6 data models for CLOS objects (the user can choose!) .. they can keep Fields in the assert/retract database.. they can call static code (for read only fields) .. i support FFI Object OO, Hashmaps, ALists and Prolog-Terms-Refs
Oladon has joined #lisp
<logicmoo>
Logtalk could have done that to
<logicmoo>
Paulo wants *everyone* to use "call static code" so ensures that was all the language could support.. I want *everyone* to use assert/retract since that is the most OPS5-y .. but neither I or Paulo should get our way
<logicmoo>
line 664 allows me to use logtalk objects
<oni-on-ion>
six! *reads*
<oni-on-ion>
this reminds me of an ocaml library, forget which; that supplies two intrfaces, "Modular" style code and "OO" style code. i think it was ocaml
* anamorphic
only ; caught 4408 STYLE-WARNING conditions to go
<oni-on-ion>
anamorphic, wow. maybe suppress is what you want =)?
dddddd has quit [Remote host closed the connection]
<logicmoo>
yeah .. deep down it is all about style
Oladon has quit [Read error: Connection reset by peer]
GoldRin has quit [Remote host closed the connection]
<anamorphic>
Yeah, I have a macro that creates a function with signature &rest rest &key ... lots of key args, but the logic inside the uses the rest argument to do the processing of the key args. It's harmless, but I can probably generate a (declare (ignore ...)) as part of that definition
meepdeew has joined #lisp
pillton has joined #lisp
anamorphic has quit [Ping timeout: 246 seconds]
mindCrime has quit [Ping timeout: 248 seconds]
caltelt_ has quit [Ping timeout: 245 seconds]
<oni-on-ion>
ah he/she left
<oni-on-ion>
logicmoo, what about prototypes/cloning ?
<logicmoo>
cloning can be used to "break an instance off" from its prototype
<logicmoo>
though a clone can still be achived via useage of prototype as long as a prototype field values wont affect the extender (non-prototype object)
<logicmoo>
in my impl since i have to roll back side effects for "unwinding objects" i litternaly extend the object each time the program sets a feild
<logicmoo>
allows my to roll back by just returning the parent class reference
<logicmoo>
i wished/need Logtalk to to that to ( in cases of Prolog backtracking )
torbo has quit [Remote host closed the connection]
anewuser has quit [Ping timeout: 258 seconds]
<oni-on-ion>
it feels disparate
<oni-on-ion>
ie. if the cloned-from proto was changed and other such situations
rpg has joined #lisp
<logicmoo>
I suppsoe every time you clone something you can perhaps create a second clone that takes over for the oringal
vlatkoB has joined #lisp
<logicmoo>
(the system in this case makes all callers find the original thru a replaced (repointed to) refernce)
<oni-on-ion>
hmm true; sounds like functional record update (FRU) now =)
jsatk has quit [Read error: Connection reset by peer]
<oni-on-ion>
Objects are interesting, but i've been wondering what "Subjects" would be like. modules perhaps?
<loke>
oni-on-ion: that would be your code
* oni-on-ion
ponders
<oni-on-ion>
so objects = data, subjects = code ?
rumbler31 has quit [Ping timeout: 268 seconds]
<logicmoo>
Logtalk might call those "protocals" as long as you didnt mean "Subject Predciate Object" :P
<oni-on-ion>
oh traits / types ?
p_l has quit [Ping timeout: 276 seconds]
meepdeew has joined #lisp
travv0 has joined #lisp
johs has joined #lisp
<oni-on-ion>
well if Object were "addition" and Subject were "subtraction", perhaps. im not quite sure...
jsatk has joined #lisp
elderK has joined #lisp
stylewarning has joined #lisp
p_l has joined #lisp
nowhere_man has joined #lisp
nowhereman has quit [Ping timeout: 245 seconds]
campy_fellow has quit [Ping timeout: 258 seconds]
moldybits has quit [Quit: WeeChat 2.4]
campy_fellow has joined #lisp
lnostdal has joined #lisp
JohnMS_WORK has joined #lisp
campy_fellow has quit [Read error: Connection reset by peer]
campy_fellow has joined #lisp
leb has quit []
SaganMan has joined #lisp
shangul has joined #lisp
campy_fellow has quit [Ping timeout: 248 seconds]
campy_fellow has joined #lisp
emar has joined #lisp
cross_ has quit [Quit: Lost terminal]
meepdeew has quit []
jprajzne has joined #lisp
shifty has quit [Ping timeout: 258 seconds]
Nilby has joined #lisp
gravicappa has quit [Ping timeout: 248 seconds]
dale has quit [Quit: dale]
Lycurgus has joined #lisp
libertyprime has joined #lisp
nowhere_man has quit [Ping timeout: 257 seconds]
gabbiel has joined #lisp
<gabbiel>
can macros have setftability, or are only functions allowed to have setftability?
<LdBeth>
gabbiel: you mean (setf macro-function) ?
schweers has joined #lisp
nowhere_man has joined #lisp
orivej has joined #lisp
schjetne has joined #lisp
nowhere_man has quit [Ping timeout: 245 seconds]
scymtym has joined #lisp
libertyprime has quit [Ping timeout: 258 seconds]
libertyprime has joined #lisp
varjag has joined #lisp
libertyprime has quit [Read error: Connection reset by peer]
libertyprime has joined #lisp
rumbler31 has joined #lisp
<beach>
gabbiel: I think you must give an example of what you think you can or can not do.
campy_fellow has quit [Read error: Connection reset by peer]
campy_fellow has joined #lisp
rumbler31 has quit [Ping timeout: 268 seconds]
vlatkoB has quit [Remote host closed the connection]
schjetne has quit [Ping timeout: 245 seconds]
fivo has joined #lisp
gxt has quit [Ping timeout: 250 seconds]
<aeth>
gabbiel: the macro equivalent is defsetf iirc. Also, sometimes you get setf for "free" with a macro if e.g. you have a macro that expands to (aref foo 42) it will work as expected with setfs... iirc
pierpal has quit [Remote host closed the connection]
hhdave has joined #lisp
hhdave has quit [Client Quit]
pankajgodbole has joined #lisp
hhdave_ has joined #lisp
elderK has quit [Quit: Connection closed for inactivity]
nirved has joined #lisp
ggole has joined #lisp
xantoz has joined #lisp
vlatkoB has joined #lisp
Oladon has quit [Read error: Connection reset by peer]
<fivo>
scymtym: Good morning
<fivo>
scymtym: Do you want to share your thoughts/ideas on macroexpansion with source location annotations?
JohnMS_WORK has quit [Read error: Connection reset by peer]
JohnMS_WORK has joined #lisp
X-Scale has quit [Quit: HydraIRC -> http://www.hydrairc.com <- Nine out of ten l33t h4x0rz prefer it]
v88m has quit [Ping timeout: 258 seconds]
avnerium_ has joined #lisp
<scymtym>
fivo: hi. sorry, i'm super busy today
wigust has joined #lisp
<fivo>
scymtym: sure, no worries
beach has quit [Disconnected by services]
wigust- has quit [Ping timeout: 258 seconds]
beach has joined #lisp
<fivo>
scymtym: do you want me to open a git issue, so you can reply when it suits you and we also have a better trace of the thing?
Necktwi has quit [Ping timeout: 272 seconds]
Necktwi has joined #lisp
<scymtym>
fivo: i'm not sure this is in scope for concrete-syntax-tree (if that's the project you wanted to create the issue in)
avnerium_ has quit [Ping timeout: 272 seconds]
<schweers>
Are macros at a toplevel somehow special? I have a macro which I have been using for a long time inside fiveam tests to setup my fixtures. I now tried to use this as a toplevel form in order to not run the test setup for every test case, and it doesn’t seem to macroexpand.
techquila has quit [Ping timeout: 252 seconds]
<beach>
It should.
jmercouris has joined #lisp
pjb has joined #lisp
sz0 has quit []
sz0 has joined #lisp
kayront- has joined #lisp
<fivo>
scymtym: yes I was thinking of cst. Why do you think it's outside of its scope? The final output would be a cst of the expanded macro call.
<fivo>
scymtym: anyways just let me know if you want to have a discussion on it somewhere
<oni-on-ion>
ah wait didnt i mention "functional record update" ? o_o
<beach>
schweers: You should have gotten a warning about an undefined function. No?
<schweers>
If so, I didn’t see it.
<beach>
Hmm.
<beach>
I take my warnings very seriously, which is why I am a bit annoyed, when there are "note"s that I can't seem to avoid, because they force me to look at every compiler message to make sure I am not missing anything.
<oni-on-ion>
is there a way [for sbcl] to treat warnings as errors? someone asked earlier
<shka__>
no
<shka__>
as far as i know
<beach>
ASDF can do it though, as I recall.
<shka__>
oh, that's cool
<beach>
asdf:*compile-file-failure-behavior* it seems
<aeth>
Can it do it for warnings and not notes? Or is it for everything? Because some notes in SBCL seem literally impossible to avoid. Like "hey, if you change the semantics of your program, it's faster".
<beach>
I set it to IGNORE when I had to compile huge sequence functions. I should set it back to whatever it was.
<shka__>
aeth: i think so
<jackdaniel>
sbcl has muffle-warnings machinery
<jackdaniel>
to filter what you are not interested in
<oni-on-ion>
beach, ok, thats what i found earlier as well
<beach>
jackdaniel: Can it filter notes?
<beach>
jackdaniel: I am interested in every warning, but usually not in the notes.
<jackdaniel>
afair it works on condition class basis
<jackdaniel>
so if notes have their own class, then it should work
<flip214>
is rejected with an error, but the other is not - and both are wrong
<flip214>
(ql:who-depends-on "alexandria")
<Xach>
flip214: "alexandria" would get what you seek. i think someone has a PR for making it downcase by default.
<flip214>
works
<flip214>
Xach: ah, thanks
<flip214>
would've been my next thought ;)
hiroaki has joined #lisp
lumm has joined #lisp
eabarbosa has quit [Remote host closed the connection]
ravenous_ has joined #lisp
fitzsim has joined #lisp
ravenous_ has quit [Client Quit]
Jesin has quit [Quit: Leaving]
rumbler31 has joined #lisp
ravenous_ has joined #lisp
torbo has joined #lisp
warweasle has joined #lisp
Jesin has joined #lisp
cosimone has quit [Quit: WeeChat 2.3]
rumbler31 has quit [Ping timeout: 268 seconds]
gxt has joined #lisp
t58_ has joined #lisp
t58 has quit [Ping timeout: 258 seconds]
manualcrank has joined #lisp
ravenous_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
lavaflow has joined #lisp
cosimone has joined #lisp
Kundry_Wag has joined #lisp
nowhere_man has quit [Ping timeout: 245 seconds]
Kundry_Wag has quit [Ping timeout: 248 seconds]
nanoz has joined #lisp
longshi has joined #lisp
milanj has quit [Quit: This computer has gone to sleep]
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
X-Scale has joined #lisp
shangul has quit [Ping timeout: 258 seconds]
sauvin has quit [Ping timeout: 272 seconds]
shifty has quit [Ping timeout: 259 seconds]
rumbler31 has joined #lisp
cosimone has quit [Quit: WeeChat 2.3]
sz0 has quit [Quit: Connection closed for inactivity]
shangul has joined #lisp
rumbler31 has quit [Ping timeout: 246 seconds]
longshi has quit [Quit: WeeChat 2.4]
fivo has joined #lisp
ym555 has joined #lisp
lavaflow has quit [Ping timeout: 257 seconds]
jxy_ has quit [Quit: leaving]
jxy has joined #lisp
lavaflow has joined #lisp
gravicappa has quit [Ping timeout: 272 seconds]
varjag has joined #lisp
ravenous_ has joined #lisp
vlatkoB_ has quit [Remote host closed the connection]
Zaab1t has quit [Quit: bye bye friends]
Inline has quit [Ping timeout: 264 seconds]
Inline has joined #lisp
cosimone has joined #lisp
torbo has quit [Remote host closed the connection]
maxxcan has quit [Quit: maxxcan]
cyraxjoe has quit [Ping timeout: 246 seconds]
shangul has quit [Ping timeout: 248 seconds]
pfdietz has joined #lisp
leb has quit []
warweasle has quit [Quit: rcirc on GNU Emacs 24.4.1]
rpg has quit [Ping timeout: 248 seconds]
elderK has joined #lisp
gxt has quit [Quit: WeeChat 2.4]
jgodbout has joined #lisp
cosimone has quit [Ping timeout: 248 seconds]
linack has joined #lisp
Josh_2 has joined #lisp
cosimone has joined #lisp
dkmuelle1 has quit [Quit: WeeChat 1.6]
dkmuelle1 has joined #lisp
dkmueller has quit [Disconnected by services]
dkmuelle1 is now known as dkmueller
nicklaf has joined #lisp
dkmuelle1 has joined #lisp
dkmueller has quit [Quit: WeeChat 1.6]
<nicklaf>
I am reading the introduction to R5Rs, where the features that scheme introduced to lisp are enumerated
<nicklaf>
I would be curious to know if any of these features didn't make their way into common lisp
<nicklaf>
I guess hygienic macros would be one
<nicklaf>
"Scheme was one of the first programming languages to incorporate first
<nicklaf>
class procedures as in the lambda calculus, thereby proving the
<nicklaf>
usefulness of static scope rules and block structure in a dynamically
<nicklaf>
typed language."
t58_ is now known as t58
<nicklaf>
and then: "Scheme was the first major dialect of Lisp to distinguish procedures from lambda expressions and symbols..."
<pfdietz>
Scheme has guaranteed tail calls, CL does not. Scheme evaluates the operator position of an expression the same way as other positions; CL does not.
<pfdietz>
Lisp-1 vs. Lisp-2
<nicklaf>
right i was just about to mention that latter point
<nicklaf>
but the other ones i'm still figuring out
<nicklaf>
many common lisp implementations perform tail calls, i believe?
<pfdietz>
They do, but it is not required.
<pfdietz>
So you cannot depend on it happening.
<pfdietz>
Scheme has explicit continuations (I believe?), CL does not.
<nicklaf>
it has call-cc, think?
<nicklaf>
*i think
<nicklaf>
anyway i've been looking at some very early lisp code, and am unfamiliar with dynamic scope
<nicklaf>
and i was somewhat startled by the claim in R5Rs that scheme was one of the first languages to have first class procedures
gxt has joined #lisp
<nicklaf>
I thought lambdas were in there very the very early days
<nicklaf>
and i am still trying to figure out what this has to do with lexical scoping
ober has left #lisp ["ERC (IRC client for Emacs 26.1)"]
ravenous_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<pfdietz>
"Most Lisps specify an order of evaluation for procedure arguments. Scheme does not." This difference from CL is, by itself, enough to consign the language to the depths of hell. :)
<Bike>
i believe in early lisps, binding was dynamic so there were no actual closures
<pfdietz>
That's right.
<nicklaf>
ahh that makes sense
<nicklaf>
that sounds kind of insane
<Bike>
and scheme, like, the RABBIT compiler and stuff, early on, was all lexical
<Bike>
which lisps at the time probably weren't, but i'm not sure.
<tfb>
nicklaf: I think Scheme was one of the first implementations to have really coherent lexical scope, and you could argue functions are not first class without that
<nicklaf>
tfb: thanks, i think that's what R5Rs is saying
<nicklaf>
i think i understand now
<tfb>
Lots of older lisps had dynamic scope in the interpreter and perhaps half of lexical scope in compiled code (so, yes, code behaved differently if it was compiled)
<tfb>
'half of lexical scope' means lexical scope but definite extent
<nicklaf>
do you think this was a hardcoded limitation made to make implementation possible?
rumbler31 has joined #lisp
rumbler31 has quit [Ping timeout: 246 seconds]
<tfb>
I think many people thought that dynamic scope was better (this seems odd now but I have heard this from people). But it's a bit hostile to any reasonable compilation strategy, so they compromised.
cosimone has quit [Ping timeout: 252 seconds]
<nicklaf>
According to Paul Graham, there is a typo in Mccarthy's original 'metacircular' eval function, and graham blames it on dynamic scope
<nicklaf>
actually i take that back
<nicklaf>
i think he might have said that it was because it was written before it was programmed :)
cosimone has joined #lisp
<nicklaf>
or, no, i was right the first time: "It's an eloquent testimony to the dangers of dynamic scope that even the very first example of higher-order Lisp functions was broken because of it. It may be that McCarthy was not fully aware of the implications of dynamic scope in 1960."
<tfb>
I think it was also a lisp-1 (at least, something I used in that era was): lisp-1s with dynamic scope can be ... exciting, in bad ways
dkmueller has joined #lisp
dkmueller has quit [Client Quit]
dkmueller has joined #lisp
nanoz has quit [Ping timeout: 248 seconds]
fivo has quit [Quit: WeeChat 1.9.1]
linack has quit [Quit: Leaving]
<pfdietz>
I have wondered if the scheme-ish approach of compiling with continuations would be useful for a CL compiler where one would want to be able to recompile functions even when they are on the current call stack (for example, if class definitions changed).
pjb has quit [Read error: Connection reset by peer]
hiroaki has quit [Ping timeout: 248 seconds]
<amerlyq>
pfdietz: sounds like a good way to splash your brain matters over walls. Execute half of continuation, then recompile, and... continue from the middle of "somewhere"
okeg has quit [Quit: WeeChat 2.4]
mahabhusuku has quit [Ping timeout: 244 seconds]
dkmueller has quit [Quit: WeeChat 1.6]
fitzsim has quit [Read error: Connection reset by peer]
Bike has quit []
cyraxjoe has joined #lisp
malm has quit [Ping timeout: 248 seconds]
LiamH has quit [Quit: Leaving.]
lumm has quit [Quit: lumm]
Nilby has quit [Ping timeout: 268 seconds]
varjag has quit [Ping timeout: 268 seconds]
moldybits has joined #lisp
Lord_of_Life_ has joined #lisp
Lord_of_Life has quit [Ping timeout: 268 seconds]
Lord_of_Life_ is now known as Lord_of_Life
john2x has joined #lisp
caltelt has joined #lisp
malm has joined #lisp
eabarbosa has joined #lisp
mindCrime has joined #lisp
Bike has joined #lisp
techquila has quit [Remote host closed the connection]
moldybits has quit [Ping timeout: 248 seconds]
rumbler31 has joined #lisp
moldybits has joined #lisp
amerlyq has quit [Quit: amerlyq]
pjb has joined #lisp
rumbler31 has quit [Ping timeout: 246 seconds]
Jesin has quit [Quit: Leaving]
libertyprime has joined #lisp
Nomenclatura has quit [Quit: q]
wxie has joined #lisp
Jesin has joined #lisp
leb has quit []
mindCrime has quit [Remote host closed the connection]