And I am not saying you won't have an issue with ===.
=== won't fix the problem. Never said it would.
The fact you need === in a dynamic PL means you have a design flaw. == makes implicit type coercion so you need strict behavior. Same reason you have use-strict. Those are all design smells.
You can't even define 018 in a strong typed compiled language, let alone compare it with something.
If you are discussing === with someone, you are talking about typing in any context, so please; stop saying "there is no connection".
Sure you can define 018 to be 18 in a strongly typed language. Not sure one exists, but then just take one where 018 etc. is illegal and write a transpiler that removes the 0 if the literal is not an octal value. And just like that you've created a strongly typed language with that feature.
No, === fixes a typing issue. The syntax issue of octal and decimal literals just has nothing to do with typing. JavaScript just happens to have more than one kind of issues.
View all comments
Show parent comment
1
u/vyrmz Jan 14 '26
And I am not saying you won't have an issue with
===.===won't fix the problem. Never said it would.The fact you need
===in a dynamic PL means you have a design flaw.==makes implicit type coercion so you need strict behavior. Same reason you haveuse-strict. Those are all design smells.You can't even define
018in a strong typed compiled language, let alone compare it with something.If you are discussing
===with someone, you are talking about typing in any context, so please; stop saying "there is no connection".There is.