Type-safe code is code that accesses types only in well-defined, allowable ways. For example, given a valid object reference, type-safe code can access memory at fixed offsets corresponding to actual field members. However, if the code accesses memory at arbitrary offsets outside the range of memory that belongs to that object's publicly exposed fields, it is not type-safe.
JIT compilation performs a process called verification that examines code and attempts to determine whether the code is type-safe. Code that is proven during verification to be type-safe is called verifiably type-safe code. Code can be type-safe and yet not be verifiably type-safe, due to the limitations of the verification process or of the compiler. Not all languages are type-safe, and some language compilers, such as Visual C++, cannot generate type-safe managed code. To find out whether the language compiler you use will allow you to generate verifiably type-safe code, consult the compiler's documentation. If you use a language compiler that generates verifiably type-safe IL only when you avoid certain language constructs, you might decide to use an NGWS SDK utility called PEVerify to determine whether your IL code and metadata is verifiably type-safe.
If code is not verifiably type-safe, it can still execute if security policy allows the code to bypass verification; however, security cannot be reliably enforced if the code violates rules of type-safety.