xref: /llvm-project/lldb/bindings/interface/SBFileSpecDocstrings.i (revision 662548c82683bd8657a3179afee693c4965a3dfd)
1*662548c8SAlex Langford %feature("docstring",
2*662548c8SAlex Langford "Represents a file specification that divides the path into a directory and
3*662548c8SAlex Langford basename.  The string values of the paths are put into uniqued string pools
4*662548c8SAlex Langford for fast comparisons and efficient memory usage.
5*662548c8SAlex Langford 
6*662548c8SAlex Langford For example, the following code ::
7*662548c8SAlex Langford 
8*662548c8SAlex Langford         lineEntry = context.GetLineEntry()
9*662548c8SAlex Langford         self.expect(lineEntry.GetFileSpec().GetDirectory(), 'The line entry should have the correct directory',
10*662548c8SAlex Langford                     exe=False,
11*662548c8SAlex Langford             substrs = [self.mydir])
12*662548c8SAlex Langford         self.expect(lineEntry.GetFileSpec().GetFilename(), 'The line entry should have the correct filename',
13*662548c8SAlex Langford                     exe=False,
14*662548c8SAlex Langford             substrs = ['main.c'])
15*662548c8SAlex Langford         self.assertTrue(lineEntry.GetLine() == self.line,
16*662548c8SAlex Langford                         'The line entry's line number should match ')
17*662548c8SAlex Langford 
18*662548c8SAlex Langford gets the line entry from the symbol context when a thread is stopped.
19*662548c8SAlex Langford It gets the file spec corresponding to the line entry and checks that
20*662548c8SAlex Langford the filename and the directory matches what we expect.") lldb::SBFileSpec;
21