https://gcc.gnu.org/g:8d7d70cd10eb4bdd1803d524f9077fff215734ec

commit r17-6271-g8d7d70cd10eb4bdd1803d524f9077fff215734ec
Author: Ata Borla <[email protected]>
Date:   Wed Nov 4 16:21:39 2026 +0300

    gccrs: changing NULL to nullptr
    
    gcc/rust/ChangeLog:
            * rust-linemap.cc (instance_): Changed ... nullptr.
            (Linemap::start_file): Likewise.
            (Linemap::location_to_string): Likewise.
    
    Signed-off-by: Ata Borla <[email protected]>

Diff:
---
 gcc/rust/rust-linemap.cc | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/gcc/rust/rust-linemap.cc b/gcc/rust/rust-linemap.cc
index 42ff6b7190e2..ce887cffdcb6 100644
--- a/gcc/rust/rust-linemap.cc
+++ b/gcc/rust/rust-linemap.cc
@@ -20,7 +20,7 @@
 
 #include "rust-linemap.h"
 
-Linemap *Linemap::instance_ = NULL;
+Linemap *Linemap::instance_ = nullptr;
 
 // Start getting locations from a new file.
 
@@ -28,7 +28,7 @@ void
 Linemap::start_file (const char *file_name, unsigned line_begin)
 {
   if (this->in_file_)
-    linemap_add (line_table, LC_LEAVE, 0, NULL, 0);
+    linemap_add (line_table, LC_LEAVE, 0, nullptr, 0);
   linemap_add (line_table, LC_ENTER, 0, file_name, line_begin);
   this->in_file_ = true;
 }
@@ -45,7 +45,7 @@ Linemap::location_to_string (location_t location)
   // only for simple file:line locations.
   resolved_location = linemap_resolve_location (line_table, location,
                                                LRK_SPELLING_LOCATION, &lmo);
-  if (lmo == NULL || resolved_location < RESERVED_LOCATION_COUNT)
+  if (lmo == nullptr || resolved_location < RESERVED_LOCATION_COUNT)
     return "";
   const char *path = LINEMAP_FILE (lmo);
   if (!path)

Reply via email to