From d52f5fd2aa6a573e8cb5d35d9a5e4317635297b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kamil=20=C5=9Aliwak?= Date: Tue, 24 Jan 2023 17:21:33 +0100 Subject: [PATCH] fixup! User-defined operators: Documentation --- docs/contracts/using-for.rst | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/docs/contracts/using-for.rst b/docs/contracts/using-for.rst index 18f0f2d7a..c8414de9d 100644 --- a/docs/contracts/using-for.rst +++ b/docs/contracts/using-for.rst @@ -50,10 +50,8 @@ performed even if none of these functions are called. If you define an operator for a user-defined type (``using {f as +} for T``), then the type (``T``), types of function parameters and the type of the function return value -have to be the same. The type (``T``) does not include data location. -But, data location of the function parameters and function return value must be -the same. There is an exception for comparison operators for which, the return value -type is always ``bool``. +have to be the same. One exception from this is the result type of comparison operators +for which it is always ``bool``. The ``using A for B;`` directive is active only within the current scope (either the contract or the current module/source unit),