Stronger C++ Typing

LionKor
2 min readJul 27, 2021

C++ is, in principle, a strongly typed language. It does, however, allow some implicit conversions between types, making it “not quite as strong as it could be”-typed. Historically, a lot of these implicit conversions come from C — a language which we all agree could use a little less implicit conversions. C++ also doesn’t have a really easy way to add “units” to types, and allows any typedef to be implicitly converted to another.

Before we get to a solution to the issue, we need to understand what the issue is, and why it’s an issue.

--

--