Thema: Delphi Exception.StackTrace ?

Einzelnen Beitrag anzeigen

Benutzerbild von himitsu
himitsu

Registriert seit: 11. Okt 2003
Ort: Elbflorenz
43.152 Beiträge
 
Delphi 12 Athens
 
#1

Exception.StackTrace ?

  Alt 17. Mai 2011, 12:03
Delphi-Version: XE
Seit einer Weile gibt es in allen Exception-Klassen theoretisch einen Stacktrace, welchen man auslesen könnte.
Nur leider hat irgendein "Idiot" vergessen diesen zu füllen.

Gut, wenn man sich das nun genauer ansieht, müßte man diesen drei Property erstmal was zuweisen, damit das dann auch nutzbar ist.
So ist das aber eine vollkommen nutzlose Funktion.
Delphi-Quellcode:
Exception = class(TObject)
public
class var
  // Hook this function to return an opaque data structure that contains stack information
  // for the given exception information record. This function will be called when the
  // exception is about to be raised or if this is an external exception such as an
  // Access Violation, called soon after the object is created.
  GetExceptionStackInfoProc: function (P: PExceptionRecord): Pointer;
  // This function is called to return a string representation of the above opaque
  // data structure
  GetStackInfoStringProc: function (Info: Pointer): string;
  // This function is called when the destructor is called to clean up any data associated
  // with the given opaque data structure.
  CleanUpStackInfoProc: procedure (Info: Pointer);
Nur wo bekommt man das her und warum hat Emba das nicht gleich mitgeliefert?

Ach ja, die vielen neuen Hilfethemen ala "This is xxx, a member of xxx.", welche in der OH nun drin sind, sind nicht hilfreich, dann das weiß ich auch alles so schon.
Zitat von http://docs.embarcadero.com/products/rad_studio/delphiAndcpp2009/HelpUpdate2/EN/html/delphivclwin32/SysUtils_Exception_StackTrace.html:
Pascal
property StackTrace: string; .

Description
This is StackTrace, a member of class Exception.
Garbage Collector ... Delphianer erzeugen keinen Müll, also brauchen sie auch keinen Müllsucher.
my Delphi wish list : BugReports/FeatureRequests

Geändert von himitsu (17. Mai 2011 um 12:46 Uhr)
  Mit Zitat antworten Zitat