diff --git a/doc/socket.html b/doc/socket.html index 8a81414..a43a208 100644 --- a/doc/socket.html +++ b/doc/socket.html @@ -220,13 +220,6 @@ Returns an equivalent function that instead of throwing exceptions, returns nil followed by an error message.

-

-Note: Beware that if your function performs some illegal operation that -raises an error, the protected function will catch the error and return it -as a string. This is because the try function -uses errors as the mechanism to throw exceptions. -

-

@@ -424,8 +417,7 @@ socket.try(ret1 [, ret2 ... retN]) Throws an exception in case of error. The exception can only be caught -by the protect function. It does not explode -into an error message. +by the protect function.

@@ -436,7 +428,10 @@ nested with try.

The function returns ret1 to retN if -ret1 is not nil. Otherwise, it calls error passing ret2. +ret1 is not nil or false. +Otherwise, it calls error passing ret2 wrapped +in a table with metatable used by protect to +distinguish exceptions from runtime errors.