Return an auxiliary span. This span exists only for some errors that benefit from being able to point to two locations in the original regular expression. For example, "duplicate" errors will have the main error position set to the duplicate occurrence while its auxiliary span will be set to the initial occurrence.
(&self)
| 64 | /// main error position set to the duplicate occurrence while its |
| 65 | /// auxiliary span will be set to the initial occurrence. |
| 66 | pub fn auxiliary_span(&self) -> Option<&Span> { |
| 67 | use self::ErrorKind::*; |
| 68 | match self.kind { |
| 69 | FlagDuplicate { ref original } => Some(original), |
| 70 | FlagRepeatedNegation { ref original, .. } => Some(original), |
| 71 | GroupNameDuplicate { ref original, .. } => Some(original), |
| 72 | _ => None, |
| 73 | } |
| 74 | } |
| 75 | } |
| 76 | |
| 77 | /// The type of an error that occurred while building an AST. |