@@ -19,31 +19,37 @@ impl<'a, T: StdError + 'a> AsDynError<'a> for T {
19
19
#[ derive( Debug ) ]
20
20
#[ non_exhaustive]
21
21
pub enum Error {
22
- /// Failure to read input file, this error occurs in the `Session::read_input` function
23
- /// provided by the user of `thorin`.
22
+ /// Failure to read input file.
23
+ ///
24
+ /// This error occurs in the `Session::read_input` function provided by the user of `thorin`.
24
25
ReadInput ( std:: io:: Error ) ,
25
- /// Failed to parse kind of input file. Input file kind is necessary to determine how to parse
26
- /// the rest of the input, and to validate that the input file is of a type that `thorin` can
27
- /// process.
26
+ /// Failed to parse kind of input file.
27
+ ///
28
+ /// Input file kind is necessary to determine how to parse the rest of the input, and to
29
+ /// validate that the input file is of a type that `thorin` can process.
28
30
ParseFileKind ( object:: Error ) ,
29
31
/// Failed to parse object file.
30
32
ParseObjectFile ( object:: Error ) ,
31
33
/// Failed to parse archive file.
32
34
ParseArchiveFile ( object:: Error ) ,
33
35
/// Failed to parse archive member.
34
36
ParseArchiveMember ( object:: Error ) ,
35
- /// Invalid kind of input. Only archive and elf files are supported input files.
37
+ /// Invalid kind of input.
38
+ ///
39
+ /// Only archive and elf files are supported input files.
36
40
InvalidInputKind ,
37
- /// Failed to decompress data. `thorin` uses `object` for decompression, so `object` probably
38
- /// didn't have support for the type of compression used.
41
+ /// Failed to decompress data.
42
+ ///
43
+ /// `thorin` uses `object` for decompression, so `object` probably didn't have support for the
44
+ /// type of compression used.
39
45
DecompressData ( object:: Error ) ,
40
46
/// Section without a name.
41
47
NamelessSection ( object:: Error , usize ) ,
42
48
/// Relocation has invalid symbol for a section.
43
49
RelocationWithInvalidSymbol ( String , usize ) ,
44
50
/// Multiple relocations for a section.
45
51
MultipleRelocations ( String , usize ) ,
46
- /// Unsupport relocations for a section.
52
+ /// Unsupported relocations for a section.
47
53
UnsupportedRelocation ( String , usize ) ,
48
54
/// Input object that has a `DwoId` (or `DebugTypeSignature`) does not have a
49
55
/// `DW_AT_GNU_dwo_name` or `DW_AT_dwo_name` attribute.
@@ -72,8 +78,10 @@ pub enum Error {
72
78
OffsetAtIndex ( gimli:: read:: Error , u64 ) ,
73
79
/// Failed to read string from `.debug_str` at offset.
74
80
StrAtOffset ( gimli:: read:: Error , usize ) ,
75
- /// Failed to parse index section. If an input file is a DWARF package, its index section needs
76
- /// to be read to ensure that the contributions within it are preserved.
81
+ /// Failed to parse index section.
82
+ ///
83
+ /// If an input file is a DWARF package, its index section needs to be read to ensure that the
84
+ /// contributions within it are preserved.
77
85
ParseIndex ( gimli:: read:: Error , String ) ,
78
86
/// Compilation unit in DWARF package is not its index.
79
87
UnitNotInIndex ( u64 ) ,
0 commit comments