xref: /freebsd/contrib/llvm-project/lldb/bindings/interface/SBSectionDocstrings.i (revision 06c3fb2749bda94cb5201f81ffdb8fa6c3161b2e)
1*06c3fb27SDimitry Andric %feature("docstring",
2*06c3fb27SDimitry Andric "Represents an executable image section.
3*06c3fb27SDimitry Andric 
4*06c3fb27SDimitry Andric SBSection supports iteration through its subsection, represented as SBSection
5*06c3fb27SDimitry Andric as well.  For example, ::
6*06c3fb27SDimitry Andric 
7*06c3fb27SDimitry Andric     for sec in exe_module:
8*06c3fb27SDimitry Andric         if sec.GetName() == '__TEXT':
9*06c3fb27SDimitry Andric             print sec
10*06c3fb27SDimitry Andric             break
11*06c3fb27SDimitry Andric     print INDENT + 'Number of subsections: %d' % sec.GetNumSubSections()
12*06c3fb27SDimitry Andric     for subsec in sec:
13*06c3fb27SDimitry Andric         print INDENT + repr(subsec)
14*06c3fb27SDimitry Andric 
15*06c3fb27SDimitry Andric produces: ::
16*06c3fb27SDimitry Andric 
17*06c3fb27SDimitry Andric   [0x0000000100000000-0x0000000100002000) a.out.__TEXT
18*06c3fb27SDimitry Andric       Number of subsections: 6
19*06c3fb27SDimitry Andric       [0x0000000100001780-0x0000000100001d5c) a.out.__TEXT.__text
20*06c3fb27SDimitry Andric       [0x0000000100001d5c-0x0000000100001da4) a.out.__TEXT.__stubs
21*06c3fb27SDimitry Andric       [0x0000000100001da4-0x0000000100001e2c) a.out.__TEXT.__stub_helper
22*06c3fb27SDimitry Andric       [0x0000000100001e2c-0x0000000100001f10) a.out.__TEXT.__cstring
23*06c3fb27SDimitry Andric       [0x0000000100001f10-0x0000000100001f68) a.out.__TEXT.__unwind_info
24*06c3fb27SDimitry Andric       [0x0000000100001f68-0x0000000100001ff8) a.out.__TEXT.__eh_frame
25*06c3fb27SDimitry Andric 
26*06c3fb27SDimitry Andric See also :py:class:`SBModule` ."
27*06c3fb27SDimitry Andric ) lldb::SBSection;
28*06c3fb27SDimitry Andric 
29*06c3fb27SDimitry Andric %feature("docstring", "
30*06c3fb27SDimitry Andric     Return the size of a target's byte represented by this section
31*06c3fb27SDimitry Andric     in numbers of host bytes. Note that certain architectures have
32*06c3fb27SDimitry Andric     varying minimum addressable unit (i.e. byte) size for their
33*06c3fb27SDimitry Andric     CODE or DATA buses.
34*06c3fb27SDimitry Andric 
35*06c3fb27SDimitry Andric     @return
36*06c3fb27SDimitry Andric         The number of host (8-bit) bytes needed to hold a target byte"
37*06c3fb27SDimitry Andric ) lldb::SBSection::GetTargetByteSize;
38