This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@SethTisue @pfn @paulp @retronym | |
I'm back online after a 4 hour train travel and had the opportunity to contemplate the conversational | |
session on scala/scala about whether it is possible in principle to implement the ackermann function | |
by "just typing in it's recursive definition in scala" [1], i.e. without applying some mental | |
translation from the mathematical definition into the scala language, and without applying some scala | |
library construct, and without me writing a trampoline for some part of the recursive definition for | |
that matter. | |
My current understanding is that this is _not_ possible, but would be happy to be proven wrong. I know |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
WHITESPACE ODDITY | |
by Paul Phillips, in eternal admiration of David Bowie, RIP | |
Bound Ctrl to Major mode | |
Bound Ctrl to Major mode | |
Read inputrc and set extdebug on | |
Bound Ctrl to Major mode (Ten, Nine, Eight, Seven, Six) | |
Connecting readline, options on (Five, Four, Three) | |
Check the syntax, may terminfo be with you (Two, One, Exec) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Latency Comparison Numbers | |
-------------------------- | |
L1 cache reference 0.5 ns | |
Branch mispredict 5 ns | |
L2 cache reference 7 ns 14x L1 cache | |
Mutex lock/unlock 25 ns | |
Main memory reference 100 ns 20x L2 cache, 200x L1 cache | |
Compress 1K bytes with Zippy 3,000 ns | |
Send 1K bytes over 1 Gbps network 10,000 ns 0.01 ms | |
Read 4K randomly from SSD* 150,000 ns 0.15 ms |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
object naming { | |
object dsl { | |
import scala.language.implicitConversions | |
implicit def pathNameToNameOps(name: PathName): PathNameDsl = new PathNameDsl(name) | |
implicit def verbNameToNameOps(name: VerbName): VerbNameDsl = new VerbNameDsl(name) | |
implicit def typeNameToNameOps(name: TypeName): TypeNameDsl = new TypeNameDsl(name) | |
class PathNameDsl(val path: PathName) { |
NewerOlder