By submitting your personal information, you agree that TechTarget and its partners may contact you regarding relevant content, products and special offers.
The problem is with achieving 100% correctness in a world where 99% correctness is not good.
The JS++ type system is optional & sound
This notion of ‘sound’ means that if a developer chooses to declare types, the types are guaranteed to always be correct — at compile time and runtime. This gives developers confidence that one small change won’t break the application and they can incrementally improve the quality of their code.
“It’s ‘santizing’ the data so the types will always remain correct. Conversions are a very ‘lightweight’ mechanism because they only need to happen on variable declarations, assignments, and function calls. Thus, we get type safety without sacrificing the ability to build performance-sensitive applications,” he adds.
Most programming languages share the same primitive data types such as Booleans, strings, and various number types. Conversions in these cases are straightforward, but JS++ takes it further. In object-oriented programming, developers can often construct classes that can expand the types for a program to thousands of types.
How can data with unpredictable formats and structures be converted?
In this case, JS++ enables developers to define custom conversion rules.
JS++ has been released in open beta and is free to download.