computer-sciencetypedweakly-typeduntyped-variables

Are weak languages also called untyped languages?


Are they also called loosely typed? Can a statically typed language be an untyped language or a dynamically typed one be a strongly typed one? Are strongly typed languages also called just Typed languages?

I mainly want to know if the definition for weakly typed languages differ from that of untyped languages or if it's acceptable for both.


Solution

  • The "weak" / "strong" typing thing has no universal definition. It depends on the author. Sometimes "weakly typed" means the language allows implicit type conversions, but that's a bit vague and generally "weakly typed" just means the author doesn't like the language. (For example, Python implicitly converts between integers and floating point numbers, yet people often call it "strongly typed".)

    From a static typing / type theory point of view, all "dynamically typed" languages are untyped because they lack a real (static) type system.

    I don't know what you mean by "loosely typed" or "static language".