• Kirill Smelkov's avatar
    xerr: Clarify that it is safe to compare Errorv to errors like io.EOF · e58c6ea2
    Kirill Smelkov authored
    Commit 79e328c5 (xerr += First, Merge) was not right saying that
    
    	if err == io.EOF
    
    will panic if err has dynamic type Errorv. It will not because
    interfaces with different dynamic types are always not equal.
    However Errorv == Errorv will indeed panic.
    
    Document and test that it is safe to compare error vectors to other
    errors, e.g. to io.EOF, and that Errorv == Errorv panics.
    e58c6ea2
xerr_test.go 4.81 KB