Skip to content

Commit a10d710

Browse files
committed
Add path info to AbsPathBuf::assert's assert
1 parent 4717bdf commit a10d710

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • src/tools/rust-analyzer/crates/paths/src

‎src/tools/rust-analyzer/crates/paths/src/lib.rs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ impl AbsPath {
197197
///
198198
/// Panics if `path` is not absolute.
199199
pub fn assert(path: &Utf8Path) -> &AbsPath {
200-
assert!(path.is_absolute());
200+
assert!(path.is_absolute(), "{path} is not absolute");
201201
unsafe { &*(path as *const Utf8Path as *const AbsPath) }
202202
}
203203

0 commit comments

Comments
 (0)