User loginNavigation |
Static typing may require runtime type checking?This may be obvious to many of you, but it got me thinking:
module Main where
data Z = X Int | Y Int
xy z = case z of
X a -> "X"
Y a -> "Y"
x = X 0
y = Y 1
Above Haskell program works as expected: (xy x) outputs X and (xy y) outputs Y. So although Haskell uses static typing, at times it needs to do type checking at runtime? Any studies on overhead of runtime type checking in languages employing static vs. "dynamic" typing? By sidhu at 2009-05-04 07:47 | LtU Forum | previous forum topic | next forum topic | other blogs | 7136 reads
|
Browse archives
Active forum topics |
Recent comments
18 hours 54 min ago
19 hours 9 min ago
5 days 19 hours ago
5 days 20 hours ago
5 days 20 hours ago
3 weeks 6 days ago
4 weeks 4 days ago
4 weeks 5 days ago
4 weeks 6 days ago
4 weeks 6 days ago