From b787c32233efa96f5c7ded0db1e0c5c9b47354f2 Mon Sep 17 00:00:00 2001 From: Doggo <51878487+Dev-Doggo@users.noreply.github.com> Date: Mon, 17 Oct 2022 13:28:01 +0300 Subject: [PATCH] Update receive function documentation The receive function documentation is slightly inaccurate currently, as a contract can still receive Ether through payable functions even if no receive or payable fallback function is present. --- docs/contracts/functions.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/contracts/functions.rst b/docs/contracts/functions.rst index f14e4b8a5..902ad1ce5 100644 --- a/docs/contracts/functions.rst +++ b/docs/contracts/functions.rst @@ -297,7 +297,7 @@ on plain Ether transfers (e.g. via ``.send()`` or ``.transfer()``). If no such function exists, but a payable :ref:`fallback function ` exists, the fallback function will be called on a plain Ether transfer. If neither a receive Ether nor a payable fallback function is present, the -contract cannot receive Ether through regular transactions and throws an +contract cannot receive Ether through a transaction that does not represent a payable function call and throws an exception. In the worst case, the ``receive`` function can only rely on 2300 gas being