_SECURE_SCL_THROWS

Important

_SECURE_SCL_THROWS is deprecated. We strongly discourage its use, and recommend that you use more direct defensive programming techniques to ensure that you are passing valid input.

Defines whether incorrect use of Checked Iterators causes an exception or a program termination. If defined as 1, use of an out-of-range iterator causes an exception at run time. If defined as 0, the program is terminated by calling invalid_parameter. By default, the value is 0. Requires that _SECURE_SCL is also defined.

Remarks

To enable checked iterators to throw an exception on incorrect use, set _SECURE_SCL to 1 and _SECURE_SCL_THROWS to 1, as follows.

#define _SECURE_SCL 1
#define _SECURE_SCL_THROWS 1

To enable checked iterators to terminate the program on incorrect use, set _SECURE_SCL to 1 and _SECURE_SCL_THROWS to 0.

#define _SECURE_SCL 1
#define _SECURE_SCL_THROWS 0

To disable checked iterators, set _SECURE_SCL to 0.

See Also

Reference

Checked Iterators

Debug Iterator Support

Safe Libraries: Standard C++ Library