Talk:System.SysUtils.EInvalidOp

From RAD Studio API Documentation
Jump to: navigation, search

First, I really surprised, EInvalidOp is NOT raised if the CPU encounters an undefined instruction include UD2 instruction!! Instead, RTL will raise EExternalException.

Description should be...

EInvalidOp is the exception class for invalid instructions and abnormal condition for Floating-point calculation. Note: I think word "abnormal" in this sentence sounds too intense. please find better word.

EInvalidOp is raised when the FPU encounters an undefined instruction, invalid mathematical operations include square-root(-1), 0.0 / 0.0 and atan(10) Partial Loss of Precision (inexact calculation result ) , or floating-point stack overflow (on Intel x87 FPU)

Run-time exception information may be saved in fields provided by System.SysUtils.EExternal if available. (depended with the platforms)

Note: Do not confuse EInvalidOp with System.Classes.EInvalidOperation, the exception class for invalid component operations.

--Tarisawa (talk) 02:30, 18 February 2015 (PST)