[PATCH] D30035: Add const to function parameters

Aditya Kumar via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 16 02:30:14 PST 2017


hiraditya created this revision.

https://reviews.llvm.org/D30035

Files:
  include/locale


Index: include/locale
===================================================================
--- include/locale
+++ include/locale
@@ -385,12 +385,12 @@
                                       _CharT& __thousands_sep);
     static int __stage2_int_loop(_CharT __ct, int __base, char* __a, char*& __a_end,
                   unsigned& __dc, _CharT __thousands_sep, const string& __grouping,
-                  unsigned* __g, unsigned*& __g_end, _CharT* __atoms);
+                  unsigned* __g, unsigned*& __g_end, const _CharT* __atoms);
     static int __stage2_float_loop(_CharT __ct, bool& __in_units, char& __exp,
                                    char* __a, char*& __a_end,
                                    _CharT __decimal_point, _CharT __thousands_sep,
                                    const string& __grouping, unsigned* __g,
-                                   unsigned*& __g_end, unsigned& __dc, _CharT* __atoms);
+                                   unsigned*& __g_end, unsigned& __dc, const _CharT* __atoms);
 };
 
 template <class _CharT>
@@ -421,7 +421,7 @@
 int
 __num_get<_CharT>::__stage2_int_loop(_CharT __ct, int __base, char* __a, char*& __a_end,
                   unsigned& __dc, _CharT __thousands_sep, const string& __grouping,
-                  unsigned* __g, unsigned*& __g_end, _CharT* __atoms)
+                  unsigned* __g, unsigned*& __g_end, const _CharT* __atoms)
 {
     if (__a_end == __a && (__ct == __atoms[24] || __ct == __atoms[25]))
     {
@@ -468,7 +468,7 @@
 int
 __num_get<_CharT>::__stage2_float_loop(_CharT __ct, bool& __in_units, char& __exp, char* __a, char*& __a_end,
                     _CharT __decimal_point, _CharT __thousands_sep, const string& __grouping,
-                    unsigned* __g, unsigned*& __g_end, unsigned& __dc, _CharT* __atoms)
+                    unsigned* __g, unsigned*& __g_end, unsigned& __dc, const _CharT* __atoms)
 {
     if (__ct == __decimal_point)
     {


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D30035.88706.patch
Type: text/x-patch
Size: 1947 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20170216/64aa02e3/attachment-0001.bin>


More information about the cfe-commits mailing list