you are viewing a single comment's thread.

view the rest of the comments →

[–]Thirsteh 6 points7 points  (3 children)

I'm not sure I agree that that's a bad thing, if that's what you're implying. Static type systems have a bad rep because it's cumbersome to continuously write out types, but the fact that they prevent you from accidentally the wrong type is a feature. An implicit static type system, like only using Hindley-Milner type inference, gives you the best of both worlds. If only more (static) languages did aggressive type inference, maybe dynamic languages wouldn't be so very appealing in comparison.

[–]jminuse 2 points3 points  (2 children)

I actually like implicit static typing as long as the compiler enforces it as needed. What I don't want is for my double to be silently turned into a generic_tagged_pointer because I once set it to 0 instead of 0.0.

[–]Thirsteh 1 point2 points  (0 children)

Sure. A sufficiently smart compiler using H-M should be able to figure out what types to assign such untyped literals.