diff --git a/vlib/builtin/result.v b/vlib/builtin/result.v index 395a83ba08effb..74ba8098f97271 100644 --- a/vlib/builtin/result.v +++ b/vlib/builtin/result.v @@ -5,10 +5,6 @@ module builtin // IError holds information about an error instance pub interface IError { - // >> Hack to allow old style custom error implementations - // TODO: remove once deprecation period for `IError` methods has ended - msg string - code int // << msg() string code() int } @@ -43,10 +39,6 @@ pub fn (err IError) str() string { (*err).str() } else { - // >> Hack to allow old style custom error implementations - // TODO: remove once deprecation period for `IError` methods has ended - // old_error_style := unsafe { voidptr(&err.msg) != voidptr(&err.code) } // if fields are not defined (new style) they don't have an offset between - // << '${err.type_name()}: ${err.msg()}' } } diff --git a/vlib/picohttpparser/request_test.v b/vlib/picohttpparser/request_test.v index b9182bff3d8a1f..bc4935e700164d 100644 --- a/vlib/picohttpparser/request_test.v +++ b/vlib/picohttpparser/request_test.v @@ -54,7 +54,7 @@ pub fn test_handles_incomplete_requests() { assert req.prev_len == 0 remaining_parsed := req.parse_request(' HTTP/1.1\r\n\r\n') or { - assert err.msg == 'error parsing request: invalid character "13"' + assert err.msg() == 'error parsing request: invalid character "13"' 0 } assert remaining_parsed == 0