[Lldb-commits] [lldb] r134246 - in /lldb/trunk: include/lldb/API/SBBlock.h include/lldb/API/SBCompileUnit.h include/lldb/API/SBFrame.h include/lldb/API/SBFunction.h include/lldb/API/SBLineEntry.h include/lldb/API/SBModule.h include/lldb/API/SBProcess.h include/lldb/API/SBSymbol.h include/lldb/API/SBSymbolContext.h include/lldb/API/SBTarget.h include/lldb/API/SBThread.h include/lldb/API/SBValue.h scripts/lldb.swig

Johnny Chen johnny.chen at apple.com
Fri Jul 1 11:39:47 PDT 2011


Author: johnny
Date: Fri Jul  1 13:39:47 2011
New Revision: 134246

URL: http://llvm.org/viewvc/llvm-project?rev=134246&view=rev
Log:
Add docstrings for some API classes and auto-generates docstrings for the methods of them.
A few of the auto-generated method docstrings don't look right, and may need to be fixed
by either overwriting the auto-gened docstrings or some post-processing steps.

Modified:
    lldb/trunk/include/lldb/API/SBBlock.h
    lldb/trunk/include/lldb/API/SBCompileUnit.h
    lldb/trunk/include/lldb/API/SBFrame.h
    lldb/trunk/include/lldb/API/SBFunction.h
    lldb/trunk/include/lldb/API/SBLineEntry.h
    lldb/trunk/include/lldb/API/SBModule.h
    lldb/trunk/include/lldb/API/SBProcess.h
    lldb/trunk/include/lldb/API/SBSymbol.h
    lldb/trunk/include/lldb/API/SBSymbolContext.h
    lldb/trunk/include/lldb/API/SBTarget.h
    lldb/trunk/include/lldb/API/SBThread.h
    lldb/trunk/include/lldb/API/SBValue.h
    lldb/trunk/scripts/lldb.swig

Modified: lldb/trunk/include/lldb/API/SBBlock.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBBlock.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBBlock.h (original)
+++ lldb/trunk/include/lldb/API/SBBlock.h Fri Jul  1 13:39:47 2011
@@ -14,8 +14,16 @@
 
 namespace lldb {
 
+#ifdef SWIG
+%feature("docstring",
+         "Represents a lexical block. SBFunction contains SBBlock(s)."
+         ) SBBlock;
+#endif
 class SBBlock
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
 public:
 
     SBBlock ();

Modified: lldb/trunk/include/lldb/API/SBCompileUnit.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBCompileUnit.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBCompileUnit.h (original)
+++ lldb/trunk/include/lldb/API/SBCompileUnit.h Fri Jul  1 13:39:47 2011
@@ -15,8 +15,16 @@
 
 namespace lldb {
 
+#ifdef SWIG
+%feature("docstring",
+         "Represents a compilation unit, or compiled source file."
+         ) SBCompileUnit;
+#endif
 class SBCompileUnit
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
 public:
 
     SBCompileUnit ();

Modified: lldb/trunk/include/lldb/API/SBFrame.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBFrame.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBFrame.h (original)
+++ lldb/trunk/include/lldb/API/SBFrame.h Fri Jul  1 13:39:47 2011
@@ -17,8 +17,18 @@
 
 class SBValue;
 
+#ifdef SWIG
+%feature("docstring",
+         "Represents one of the stack frames associated with a thread."
+         " SBThread contains SBFrame(s)."
+         ) SBFrame;
+#endif
 class SBFrame
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
+
 public:
     SBFrame ();
 
@@ -161,7 +171,9 @@
     bool
     GetDescription (lldb::SBStream &description);
 
+#ifndef SWIG
     SBFrame (const lldb::StackFrameSP &lldb_object_sp);
+#endif
 
 protected:
     friend class SBValue;

Modified: lldb/trunk/include/lldb/API/SBFunction.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBFunction.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBFunction.h (original)
+++ lldb/trunk/include/lldb/API/SBFunction.h Fri Jul  1 13:39:47 2011
@@ -16,8 +16,16 @@
 
 namespace lldb {
 
+#ifdef SWIG
+%feature("docstring",
+         "Represents a generic function, which can be inlined or not."
+         ) SBFunction;
+#endif
 class SBFunction
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
 public:
 
     SBFunction ();

Modified: lldb/trunk/include/lldb/API/SBLineEntry.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBLineEntry.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBLineEntry.h (original)
+++ lldb/trunk/include/lldb/API/SBLineEntry.h Fri Jul  1 13:39:47 2011
@@ -16,8 +16,17 @@
 
 namespace lldb {
 
+#ifdef SWIG
+%feature("docstring",
+         "Specifies an association with a contiguous range of instructions and"
+         " a source file location. SBCompileUnit contains SBLineEntry(s)."
+         ) SBLineEntry;
+#endif
 class SBLineEntry
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
 public:
 
     SBLineEntry ();

Modified: lldb/trunk/include/lldb/API/SBModule.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBModule.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBModule.h (original)
+++ lldb/trunk/include/lldb/API/SBModule.h Fri Jul  1 13:39:47 2011
@@ -16,8 +16,18 @@
 
 namespace lldb {
 
+#ifdef SWIG
+%feature("docstring",
+         "Represents an executable image and its associated object and symbol"
+         " files."
+         ) SBModule;
+#endif
 class SBModule
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
+
 public:
 
     SBModule ();

Modified: lldb/trunk/include/lldb/API/SBProcess.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBProcess.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBProcess.h (original)
+++ lldb/trunk/include/lldb/API/SBProcess.h Fri Jul  1 13:39:47 2011
@@ -19,8 +19,17 @@
 
 class SBEvent;
 
+#ifdef SWIG
+%feature("docstring",
+         "Represents the process associated with the target program."
+         ) SBProcess;
+#endif
 class SBProcess
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
+
 public:
     //------------------------------------------------------------------
     /// Broadcaster event bits definitions.

Modified: lldb/trunk/include/lldb/API/SBSymbol.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBSymbol.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBSymbol.h (original)
+++ lldb/trunk/include/lldb/API/SBSymbol.h Fri Jul  1 13:39:47 2011
@@ -17,8 +17,16 @@
 
 namespace lldb {
 
+#ifdef SWIG
+%feature("docstring",
+         "Represents the symbol associated with a stack frame."
+         ) SBSymbol;
+#endif
 class SBSymbol
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
 public:
 
     SBSymbol ();

Modified: lldb/trunk/include/lldb/API/SBSymbolContext.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBSymbolContext.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBSymbolContext.h (original)
+++ lldb/trunk/include/lldb/API/SBSymbolContext.h Fri Jul  1 13:39:47 2011
@@ -20,8 +20,16 @@
 
 namespace lldb {
 
+#ifdef SWIG
+%feature("docstring",
+         "A container that stores various debugger related info."
+         ) SBSymbolContext;
+#endif
 class SBSymbolContext
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
 public:
     SBSymbolContext ();
 

Modified: lldb/trunk/include/lldb/API/SBTarget.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBTarget.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBTarget.h (original)
+++ lldb/trunk/include/lldb/API/SBTarget.h Fri Jul  1 13:39:47 2011
@@ -18,8 +18,16 @@
 
 class SBBreakpoint;
 
+#ifdef SWIG
+%feature("docstring",
+         "Represents the target program running under the debugger."
+         ) SBTarget;
+#endif
 class SBTarget
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
 public:
     //------------------------------------------------------------------
     // Broadcaster bits.

Modified: lldb/trunk/include/lldb/API/SBThread.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBThread.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBThread.h (original)
+++ lldb/trunk/include/lldb/API/SBThread.h Fri Jul  1 13:39:47 2011
@@ -18,8 +18,18 @@
 
 class SBFrame;
 
+#ifdef SWIG
+%feature("docstring",
+         "Represents a thread of execution."
+         " SBProcess contains SBThread(s)."
+         ) SBThread;
+#endif
 class SBThread
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
+
 public:
     SBThread ();
 

Modified: lldb/trunk/include/lldb/API/SBValue.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/include/lldb/API/SBValue.h?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/include/lldb/API/SBValue.h (original)
+++ lldb/trunk/include/lldb/API/SBValue.h Fri Jul  1 13:39:47 2011
@@ -16,8 +16,16 @@
 
 namespace lldb {
 
+#ifdef SWIG
+%feature("docstring",
+         "Represents the value of a variable, a register, or an expression."
+         ) SBValue;
+#endif
 class SBValue
 {
+#ifdef SWIG
+    %feature("autodoc", "1");
+#endif
 public:
     SBValue ();
 

Modified: lldb/trunk/scripts/lldb.swig
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/scripts/lldb.swig?rev=134246&r1=134245&r2=134246&view=diff
==============================================================================
--- lldb/trunk/scripts/lldb.swig (original)
+++ lldb/trunk/scripts/lldb.swig Fri Jul  1 13:39:47 2011
@@ -26,7 +26,7 @@
 o SBFunction: Represents a generic function, which can be inlined or not.
 o SBBlock: Represents a lexical block. SBFunction contains SBBlock(s).
 o SBLineEntry: Specifies an association with a contiguous range of instructions
-      and a source file location. SBCompileUnit contains SBLineEntry(s)"
+      and a source file location. SBCompileUnit contains SBLineEntry(s)."
 %enddef
 
 /*  The name of the module to be created.  */





More information about the lldb-commits mailing list