Offset of the partial pointer starting with the token which caused the error. ```text "/foo/invalid~tilde/invalid" ↑ ``` ``` # use jsonptr::PointerBuf; let err = PointerBuf::parse("/foo/invalid~tilde/invalid").unwrap_err(); assert_eq!(err.pointer_offset(), 4) ```
(&self)
| 1276 | /// assert_eq!(err.pointer_offset(), 4) |
| 1277 | /// ``` |
| 1278 | pub fn pointer_offset(&self) -> usize { |
| 1279 | match *self { |
| 1280 | Self::NoLeadingSlash { .. } => 0, |
| 1281 | Self::InvalidEncoding { offset, .. } => offset, |
| 1282 | } |
| 1283 | } |
| 1284 | |
| 1285 | /// Offset of the character index from within the first token of |
| 1286 | /// [`Self::pointer_offset`]) |