User loginNavigation |
archivesDependent Types for JavaScriptDependent Types for JavaScript, by Ravi Chugh, David Herman, Ranjit Jhala:
Some good progress on inferring types for a very dynamic language. Explicit type declarations are placed in comments that start with "/*:".
/*: x∶Top → {ν ∣ite Num(x) Num(ν) Bool(ν)} */
function negate(x) {
if (typeof x == "number") { return 0 - x; }
else { return !x; }
}
By naasking at 2013-03-23 15:08 | Object-Functional | Theory | Type Theory | 128 comments | other blogs | 34460 reads
|
Browse archivesActive forum topics |
Recent comments
1 week 21 hours ago
1 week 4 days ago
6 weeks 5 days ago
6 weeks 6 days ago
18 weeks 6 days ago
19 weeks 13 hours ago
19 weeks 1 day ago
19 weeks 1 day ago
19 weeks 6 days ago
19 weeks 6 days ago