[Gmp-commit] /var/hg/gmp: Remove deprecated space after operator""

mercurial at gmplib.org mercurial at gmplib.org
Sat Apr 4 14:56:25 CEST 2026


details:   /var/hg/gmp/rev/1e504d187571
changeset: 18502:1e504d187571
user:      Marc Glisse <marc.glisse at inria.fr>
date:      Sat Apr 04 14:56:15 2026 +0200
description:
Remove deprecated space after operator""

diffstat:

 ChangeLog    |  5 +++++
 doc/gmp.texi |  6 +++---
 gmpxx.h      |  6 +++---
 3 files changed, 11 insertions(+), 6 deletions(-)

diffs (68 lines):

diff -r 28bab752af0d -r 1e504d187571 ChangeLog
--- a/ChangeLog	Sun Mar 15 19:39:27 2026 +0100
+++ b/ChangeLog	Sat Apr 04 14:56:15 2026 +0200
@@ -1,3 +1,8 @@
+2026-04-04  Marc Glisse <marc.glisse at inria.fr>
+
+	* gmpxx.h (operator""): Remove deprecated space.
+	* doc/gmp.texi: Likewise.
+
 2026-02-21  Marco Bodrato <bodrato at mail.dm.unipi.it>
 
 	* mpz/millerrabin.c: Improve description of the code with comments,
diff -r 28bab752af0d -r 1e504d187571 doc/gmp.texi
--- a/doc/gmp.texi	Sun Mar 15 19:39:27 2026 +0100
+++ b/doc/gmp.texi	Sat Apr 04 14:56:15 2026 +0200
@@ -6943,7 +6943,7 @@
 exception is thrown.  The same applies to @code{operator=}.
 @end deftypefun
 
- at deftypefun mpz_class operator"" _mpz (const char *@var{str})
+ at deftypefun mpz_class operator""_mpz (const char *@var{str})
 With C++11 compilers, integers can be constructed with the syntax
 @code{123_mpz} which is equivalent to @code{mpz_class("123")}.
 @end deftypefun
@@ -7053,7 +7053,7 @@
 exception is thrown.  The same applies to @code{operator=}.
 @end deftypefun
 
- at deftypefun mpq_class operator"" _mpq (const char *@var{str})
+ at deftypefun mpq_class operator""_mpq (const char *@var{str})
 With C++11 compilers, integral rationals can be constructed with the syntax
 @code{123_mpq} which is equivalent to @code{mpq_class(123_mpz)}. Other
 rationals can be built as @code{-1_mpq/2} or @code{0xb_mpq/123456_mpz}.
@@ -7170,7 +7170,7 @@
 is thrown.  The same applies to @code{operator=}.
 @end deftypefun
 
- at deftypefun mpf_class operator"" _mpf (const char *@var{str})
+ at deftypefun mpf_class operator""_mpf (const char *@var{str})
 With C++11 compilers, floats can be constructed with the syntax
 @code{1.23e-1_mpf} which is equivalent to @code{mpf_class("1.23e-1")}.
 @end deftypefun
diff -r 28bab752af0d -r 1e504d187571 gmpxx.h
--- a/gmpxx.h	Sun Mar 15 19:39:27 2026 +0100
+++ b/gmpxx.h	Sat Apr 04 14:56:15 2026 +0200
@@ -2160,19 +2160,19 @@
 /**************** User-defined literals ****************/
 
 #if __GMPXX_USE_CXX11
-inline mpz_class operator"" _mpz(const char* s)
+inline mpz_class operator""_mpz(const char* s)
 {
   return mpz_class(s);
 }
 
-inline mpq_class operator"" _mpq(const char* s)
+inline mpq_class operator""_mpq(const char* s)
 {
   mpq_class q;
   q.get_num() = s;
   return q;
 }
 
-inline mpf_class operator"" _mpf(const char* s)
+inline mpf_class operator""_mpf(const char* s)
 {
   return mpf_class(s);
 }


More information about the gmp-commit mailing list