1,751 karma · joined Mar 26, 2008 (18y ago) · 893 submissions
shaunxcode@gmail.com
comment 14y ago · link · parent
comment 14y ago · link · parent
[
a: 1
b: 2
,
a: 3
b: 4
]
If you forget that "," which MUST be dedented a level - you are hosed.This becomes uglier w/ nested objects
[
age: 30
aliases: [
first: "peter"
last: "jensen"
,
first: "walter"
last: "gregor"
]
,
age: 20
aliases: [
first: "tony"
last: "foulard"
,
first: "sam"
last: "jakob"
]
]
I think I almost prefer: [
{
a: 1
b: 2
}{
a: 3
b: 4
}
]
[
{
age: 30
aliases: [{
first: "peter"
last: "jensen"
}{
first: "walter"
last: "gregor"
}]
}{
age: 20
aliases: [{
first: "tony"
last: "foulard"
}{
first: "sam"
last: "jakob"
}]
}
]comment 14y ago · link · parent
comment 14y ago · link · parent
So in short: I really hope this is a sign of change but I also know that money thrown at these programs is often just squandered on projectors and digital white boards.
edit: upon reflection I think I feel guilty that I did not do more to make things the way I envisioned. I could have easily created a "programming class" image that we flashed the systems with to let them have linux, learn emacs, vim, apache etc. but I think I was too inexperienced to really be sure of myself. I'd love the opportunity now as I could offer a scratch/squeak course, a scheme course, web apps, lua/love for game programming. So many awesome free tools for every type of aptitude.
comment 14y ago · link · parent
461.
Qi (lisp dialect preceding Shen) being deleted from wikipedia (en.wikipedia.org ↗)
2 points · by shaunxcode · 14y ago · 1 comment
comment 14y ago · link · parent
comment 14y ago · link · parent
Also: http://archive.vector.org.uk/art10500180 - great article on array languages for lisp programmers.
comment 15y ago · link · parent
class Object {
public function __call($method, $args) {
if(isset($this->$method) && $this->$method instanceof \Closure) {
$this->$method->bindTo($this);
return call_user_func_array($this->$method, $args);
}
}
}
$context = new Object;
$context->foo = "Hello World";
$context->closure = function() {
echo $this->foo;
};
$context->closure();
Once traits are in the language (5.5?) that could just be mixed in.comment 15y ago · link · parent
https://github.com/ORDER-OF-NO/scphpeme
(CONS (QUOTE R) (LIST (QUOTE I) (QUOTE P)))
comment 15y ago · link · parent
comment 15y ago · link · parent
comment 15y ago · link · parent
Tag.ul(
Tag.li('unclickable li tag')
.addClass('unclickable'),
Tag.li('test clickable li tag')
.addClass('clickable')
.click(function() {
alert('clicked on test')}))
I prefer this as it keeps my view code "in language" and makes it easy to apply any sort of jquery methods which I need to the different elements.comment 15y ago · link · parent
In a nut shell though it's essentially a write up of my library which allows for creating keyword function wrappers so you can do stuff like:
myStrPos(
needle, 'peter',
haystack, 'is peter in here?'
);