[all-commits] [llvm/llvm-project] 636628: [clang] Enforce 1-based indexing for command line ...
Naveen Seth Hanig via All-commits
all-commits at lists.llvm.org
Thu May 15 06:36:51 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 636628d8fde45fc2bb99a1016f7503d0e744ab89
https://github.com/llvm/llvm-project/commit/636628d8fde45fc2bb99a1016f7503d0e744ab89
Author: Naveen Seth Hanig <naveen.hanig at outlook.com>
Date: 2025-05-15 (Thu, 15 May 2025)
Changed paths:
M clang/docs/ReleaseNotes.rst
M clang/include/clang/Basic/DiagnosticDriverKinds.td
M clang/include/clang/Frontend/CommandLineSourceLoc.h
M clang/lib/Frontend/CompilerInvocation.cpp
A clang/test/CodeCompletion/source-loc-zero.cpp
A clang/test/Refactor/source-loc-zero.cpp
M clang/tools/clang-refactor/ClangRefactor.cpp
Log Message:
-----------
[clang] Enforce 1-based indexing for command line source locations (#139457)
Fixes #139375
Clang expects command line source locations to be provided using 1-based
indexing.
Currently, Clang does not reject zero as invalid argument for column or
line number, which can cause Clang to crash.
This commit extends validation in `ParsedSourceLocation::FromString` to
only accept (unsinged) non-zero integers.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list