Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
samth
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
56 ms
·
391.
▲
by
samth
15y ago
It's great the metaprogramming support seems to be a requirement for new languages these days. Unfortunately, this one combines the inconvenience of Template Haskell (explicit invocation of macros with @) and the bugs of Common Lisp (the se
392.
▲
by
samth
15y ago
There are two reasons: 1. `module` is about defining the modules that you're using in your program, some of which might be remote resources. `import` is about bringing names into scope. 2. Using `module` this way lets you, the client, deci
393.
▲
by
samth
15y ago
First, if you want to just use objects-as-prefixes, the way require(...) works in node today, that's easy to do: module m at "blah.com"; ... references to m go here ... We also want to support other use cases, like binding the
394.
▲
by
samth
15y ago
Since it came up on twitter, here's how you'd implement the `$` module I describe above: export function ajax(...) { ... }; // NB: not how jQuery actually works ;) export this(query) { return document.find(query); }; T
395.
▲
by
samth
15y ago
I don't think that's right about hash tables. In particular, the distinction I would make is that literal hash tables are part of the syntax of the language in Racket, like in Clojure, Python, etc, and not in C# or C. What this means in
396.
▲
by
samth
15y ago
To make my perspective here clear, I should mention that Dave Herman (of Mozilla Research) and I are the designers of the ES6 module system.
397.
▲
by
samth
15y ago
A different way to put it is: "the best way to iterate over collections is still being discussed, because we want to get it right". Also, for `Map`, how do you think `foreach` should work? Should the function be called with (a) the key, (b
398.
▲
by
samth
15y ago
I'll try to separate out the different issues you're raising here, and respond to each individually. 1. What if I want to have my module be a function, the way that $ in jQuery is both a function and a namespace for the rest of the function
399.
▲
by
samth
15y ago
6 weeks is exactly the same update cycle as Chrome, and much faster than Safari (or Mobile Safari, or the Android Browser).
400.
▲
by
samth
15y ago
I don't think that he was talking about Racket, but some of your points are mistaken. You might not like the literal syntax for maps in Racket, but it certainly exists. Typed Racket has lots of math-oriented types; we just wrote a paper abo
401.
▲
by
samth
15y ago
Imagine Firefox, but without segfaults, and using multiple cores. That's the use case. Rust is intended as a safe language for building a research browser that works in parallel.
402.
▲
by
samth
15y ago
Reference here: http://doc.rust-lang.org/doc/rust.html Tutorial (probably better at the moment): http://doc.rust-lang.org/doc/tutorial.html
403.
▲
by
samth
15y ago
In Scheme/Lisp/Dylan/Racket/Clojure/Your favorite lisp dialect everything except #f is true -- Dart is the other way around.
404.
▲
by
samth
15y ago
PLT Scheme was always a different language -- the name change merely makes that clear to everyone else.
405.
▲
Parallel programming in Racket
(scriptstoprograms.wordpress.com)
7 points
by
samth
15y ago
|
0 comments
406.
▲
by
samth
15y ago
There are two things here: an optimization, and a semantics guarantee. Obviously, if your language provides the guarantee, then implementing it correctly isn't just an optimization. But the original article claims that the transformation
407.
▲
by
samth
15y ago
The comment about tail calls is wrong -- it's not an optimization, it's a guarantee about semantics of your program. Not optimizing tail calls is like making array dereference run in linear time instead of constant: it changes the program
408.
▲
by
samth
15y ago
First, jashkenas isn't held up by standards committees -- he's able to experiment with cool new client-side web tech on whatever schedule he wants. And building on this, even more new stuff is happening, like Tim Disney's contracts.coffee
409.
▲
by
samth
15y ago
tl;dr: 1. You can't learn how to program quickly, but you can learn how to program. 2. Remember the design recipe. 3. The structure of your programs should follow the structure of your data.
410.
▲
by
samth
15y ago
I think this book is better for learning programming than SICP. Background on the differences is available from the paper the HtDP authors wrote about the difference: http://www.ccs.neu.edu/racket/pubs/jfp2004-fffk.pdf
411.
▲
by
samth
15y ago
Yes, the book has received significant updates lately. More updates are available from the draft version: http://www.ccs.neu.edu/home/matthias/HtDP2e/Draft/ . But, of course, it's not done yet, so there are still parts missing.
412.
▲
by
samth
15y ago
First, I don't think what you show is a DSL -- it's just some functions. Rather, what Tim has implemented is a DSL. Second, you need proxies to handle things like functions and mutable arrays. Third, that there's a DSL for describing contr
413.
▲
by
samth
15y ago
Are you referring to the implementation of `random' from `racket/base' (implemented here: https://github.com/plt/racket/blob/master/src/racket/src/ran... ) or the implementation in `srfi/27' (here: https://github.com/plt/racket/blob/mast
414.
▲
by
samth
15y ago
The Racket Guide [1] and Reference [2] are very nice (and almost all the work of just one person, Matthew Flatt). [1] http://docs.racket-lang.org/guide/ [2] http://docs.racket-lang.org/reference/
415.
▲
Come to RacketCon July 23-24. Schedule & Registration (free) now available
(con.racket-lang.org)
2 points
by
samth
15y ago
|
0 comments
416.
▲
by
samth
15y ago
This is, somewhat surprisingly, not true, especially if you're just considering the language proper. There are about 15 people who are regular members of the committee, and some of them end up having a big influence. Brendan is a prime exa
417.
▲
by
samth
15y ago
Nothing about Typed Arrays is static typing.
418.
▲
by
samth
15y ago
And if they're building a game full of misogyny and shit-throwing "because they enjoy it", that's somehow better?
419.
▲
by
samth
15y ago
This comment on Typed Racket isn't correct. Lots of macros work just fine in Typed Racket, and XML literals would certainly be among them [1]. The macros that don't work yet are the most complex ones, like the one implementing an entire c
420.
▲
by
samth
15y ago
And we did! Check out: http://blog.racket-lang.org/2011/03/languages-as-libraries-p...
More ›