[Libreoffice-commits] core.git: sc/inc

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Fri Mar 26 09:29:12 UTC 2021


 sc/inc/address.hxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 216561c4a8f4731901dcc34805e7a66cccb79ee1
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Thu Mar 25 16:40:36 2021 +0000
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Fri Mar 26 10:28:26 2021 +0100

    add some nodiscard to address/range validators
    
    Change-Id: I2a66ebc2517c1470585be630fd0ed70d82e140d9
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113106
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sc/inc/address.hxx b/sc/inc/address.hxx
index be8e16c59071..f7e928b88b6a 100644
--- a/sc/inc/address.hxx
+++ b/sc/inc/address.hxx
@@ -487,7 +487,7 @@ struct ScAddressHashFunctor
     }
 };
 
-inline bool ValidAddress( const ScAddress& rAddress, SCCOL nMaxCol = MAXCOL, SCROW nMaxRow = MAXROW )
+[[nodiscard]] inline bool ValidAddress( const ScAddress& rAddress, SCCOL nMaxCol = MAXCOL, SCROW nMaxRow = MAXROW )
 {
     return ValidCol(rAddress.Col(), nMaxCol) && ValidRow(rAddress.Row(), nMaxRow) && ValidTab(rAddress.Tab());
 }
@@ -789,7 +789,7 @@ inline size_t ScRange::hashStartColumn() const
 #endif
 }
 
-inline bool ValidRange( const ScRange& rRange, SCCOL nMaxCol = MAXCOL, SCROW nMaxRow = MAXROW )
+[[nodiscard]] inline bool ValidRange( const ScRange& rRange, SCCOL nMaxCol = MAXCOL, SCROW nMaxRow = MAXROW )
 {
     return ValidAddress(rRange.aStart, nMaxCol, nMaxRow) && ValidAddress(rRange.aEnd, nMaxCol, nMaxRow);
 }


More information about the Libreoffice-commits mailing list