It looks like the FPC RTL function CaptureBacktrace uses a system call if FPC_SYSTEM_HAS_CAPTUREBACKTRACE is true and a custom routine if it is false. The define FPC_SYSTEM_HAS_CAPTUREBACKTRACE seems to be true for Windows with Structured Exception Handling (FPC_USE_WIN64_SEH) where RtlCaptureStackBackTrace is called instead of the FPC built-in routine.

My question now is if there is a reason why FPC doesn't call backtrace (see man backtrace) on Linux and Unix (including MacOS) platforms ?

Another question is whether and how NSException.callStackReturnAddresses and NSException.callStackSymbols can be used here (on MacOS) ?

Regards,

Adriaan van Os



_______________________________________________
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel

Reply via email to