[flang-commits] [flang] [Flang] Fix grammar in pointer assignment error message (PR #150909)

via flang-commits flang-commits at lists.llvm.org
Mon Jul 28 02:30:30 PDT 2025


https://github.com/Sekar-C-Mca created https://github.com/llvm/llvm-project/pull/150909

This PR corrects a grammatical mistake in an error message emitted during pointer assignment checks in Flang.
The message previously read:

"%s is associated with the result of a reference to function '%s' that is a not a pointer"

The extra "a" before "not a pointer" has been removed.

>From e2108a8bf5e94b1cd6fd89aed4202b5d047140bc Mon Sep 17 00:00:00 2001
From: Sekar <sekarmca2024 at gmail.com>
Date: Mon, 28 Jul 2025 09:28:28 +0000
Subject: [PATCH] [Flang] Fix grammar in pointer assignment error message

---
 flang/lib/Semantics/pointer-assignment.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/flang/lib/Semantics/pointer-assignment.cpp b/flang/lib/Semantics/pointer-assignment.cpp
index 090876912138a..47973cca35654 100644
--- a/flang/lib/Semantics/pointer-assignment.cpp
+++ b/flang/lib/Semantics/pointer-assignment.cpp
@@ -281,7 +281,7 @@ bool PointerAssignmentChecker::Check(const evaluate::FunctionRef<T> &f) {
           " function '%s' that is a procedure pointer"_err_en_US;
   } else if (!funcResult->attrs.test(FunctionResult::Attr::Pointer)) {
     msg = "%s is associated with the result of a reference to function '%s'"
-          " that is a not a pointer"_err_en_US;
+          " that is not a pointer"_err_en_US;
   } else if (isContiguous_ &&
       !funcResult->attrs.test(FunctionResult::Attr::Contiguous)) {
     auto restorer{common::ScopedSet(lhs_, symbol)};



More information about the flang-commits mailing list