C-enhancementgood first issue
仓库指标
- Star
- (10,406 star)
- PR 合并指标
- (平均合并 19天 22小时) (30 天内合并 113 个 PR)
描述
We just added if_then_panic, but then I realized there's a possible enhancement for assert_eq!/assert_ne!:
// before
if a != b {
panic!("hi");
}
// after
assert_eq!(a, b, "hi");
I think a rename to manual_assert would be best. But we could also keep the current name (it still kinda makes sense) or create a new lint for this case.