Tumgik
puercopop · 7 years
Video
vimeo
Alan Kay at CresstCon 2016
1 note · View note
puercopop · 8 years
Text
Inaimathi’s Congregate
In his latest post, Leo Zovic annouced his has started working on a group management system (think meetup). The code is up on github. Although incipient the code is a small example of how one would prototype a web page in Common Lisp. In particular it uses two libraries from the author that one should check out as well: House and fact-base. House is a web server with an interesing interface for defining handles and http-types. Fact-base is a persistent triple store.
0 notes
puercopop · 8 years
Quote
This is so bad that one should regard the visitor pattern (with or without factory methods) as a hacky workaround for missing generic functions.
Svante
0 notes
puercopop · 8 years
Quote
Our country has lots of problems. One of them is BASIC. BASIC fits the minds of the people who run our secondary schools—simple, tidy, relatively cheap. And teachers find it is no more difficult to teach than anything else they teach. So it seems to fit into our secondary schools and kids are now coming to college already suffering from a disease that I don't think we'll ever be able to excise. When they come into my course, and I ask them to start programming in APL, I find they can't. They're crippled already. Their minds are already deranged. The first thing they do is set / equal to 1. The natural first step out of the womb is to set / equal to 1. Then you cast around for some place to use it. Let's use it in X, so you have X(I). And you manipulate it for a while and then you increment /, and then you test and you jump, and that's programming. That's life. When I tell these people that that's not the way to do things at all, but that they should look for a pattern and do things in parallel, to erect the whole structure at once, they can't. Then they come to me after a while and they say, "APL is unstructured. There's no while in it." I say, "It's got nothing but wiles", which pun they don't get.
Alan Perils
0 notes
puercopop · 8 years
Text
Pattern Directed Macros in CL
The other day Vincent Toups pointed out that that one can do pattern directed macros in CL. I don’t know where I got the idea that it was only possible in Racket. But I'm glad he made my realise my mistake
To illustrate the advantages I'll rewrite let. Henry Baker wrote the following implementation in Metacircular Semantics for Common Lisp Special Forms.
(defmacro hb-let (vs &body forms) `(funcall #'(lambda ,(mapcar #'car vs) ,@forms) ,@(mapcar #'cadr vs)))
However the implementation doesn't work for clauses without an init form, those that bind the symbol to nil. For example, (let (x) x) signals a type-error in the implementation provided by Baker.
I'll start with let* because it is simpler to implement, using trivia as the pattern matcher.
(defmacro pd-let* (bindings &body body) (match bindings (nil `(funcall (lambda () ,@body))) ((list* (list name value) rest) `(pd-let* ,rest (funcall (lambda (,name) ,@body) ,value))) ;; The guard is to prevent matching the form (x 1 3) and bind name to ;; (x 1 3) and rest to nil. ((guard (list* name rest) (symbolp name)) `(pd-let* ,rest (funcall (lambda (,name) ,@body) nil))) (_ (error "Cannot recognize binding clause in pdl-let: ~A" bindings))))
and some test cases
(pd-let* ((x 1)) (is x 1)) #+error(pd-let* ((x 1 3)) (princ x)) ;; Cannot recognize binding clause in pdl-let: ((X 1 3)) ;; [Condition of type SIMPLE-ERROR] (pd-let* (x) (is x nil)) (pd-let* (x (y 2)) (is x nil) (is y 2))
In the case of let, the idea is the same but because the names have to bound in parallel we have to use one lambda, so we'll accumulate the values and generate the lambda in the base case
(defmacro pd-let (bindings &body body) `(%pd-let ,bindings () () ,@body)) (defmacro %pd-let (bindings names values &body body) (match bindings (nil `(funcall (lambda (,@names) ,@body) ,@values)) ((list* (list name value) rest) `(%pd-let ,rest ,(cons name names) ,(cons value values) ,@body)) ((guard (list* name rest) (symbolp name)) `(%pd-let ,rest ,(cons name names) ,(cons nil values) ,@body)) (_ (error "Cannot recognize binding clause in pdl-let: ~A" bindings)))) (pd-let ((x 1)) (pd-let ((x 3) (y x)) (is x 3) (is y 1)))
The code for used in thie post can be found in this gist
0 notes
puercopop · 8 years
Video
youtube
0 notes
puercopop · 9 years
Link
What is the cost of not listening to Alan Kay?
0 notes
puercopop · 9 years
Link
Tumblr media
0 notes
puercopop · 9 years
Link
MLK came to believe in "Letter from Birmingham Jail" that white moderates are worse than Ku Klux Klansmen. Here's his quote.
0 notes
puercopop · 9 years
Link
0 notes
puercopop · 9 years
Link
Most real-world problems are big enough that you can’t just head for the end goal, you have to break them down into smaller parts and set up …
0 notes
puercopop · 9 years
Link
"To me Pharo is like an autobus full of people and I want that it transforms itself into a jet during our journey"
0 notes
puercopop · 10 years
Video
vimeo
0 notes
puercopop · 10 years
Text
When people tells me that golang is the language of the future
Tumblr media
3 notes · View notes
puercopop · 10 years
Quote
Perlis, as usual, summed it up well in one of his aphorisms: The string is a stark data structure, and everywhere it occurs there is much hiding of information. This is what is wrong with both Unix and tcl. Their power is also a great weakness: they are designed around a "least common denominator" representation, strings. What it buys you is that everything interoperates. The above aphorism explains what it costs you.
Olin Shivers
1 note · View note
puercopop · 10 years
Quote
Computer scientists retort that computer programs are more complex than physical systems. If this is true, then computer scientists should be embarrassed, considering the fact that computers and computer software are "cultural" objects--they are purely a product of man's imagination, and may be changed as quickly as a man can change his mind.
http://home.pipeline.com/~hbaker1/ReverseGC.html
1 note · View note
puercopop · 10 years
Link
0 notes