[clang-format] Reimplement InsertNewlineAtEOF (#108513)
commita4ace8347084101a2a0b6eaf16eca72ffa59c1f2
authorOwen Pan <owenpiano@gmail.com>
Wed, 18 Sep 2024 04:16:20 +0000 (17 21:16 -0700)
committerTobias Hieta <tobias@hieta.se>
Tue, 24 Sep 2024 06:31:46 +0000 (24 08:31 +0200)
treebcf965464643d4f2c62aaa98181bfd8c9652f6d9
parenta8ddc3ce6b9560caf1b349b01be1267766a4365a
[clang-format] Reimplement InsertNewlineAtEOF (#108513)

Fixes #108333.

(cherry picked from commit 7153a4bbf6d46e58ce32d59220515c5ab9f35691)
clang/lib/Format/FormatTokenLexer.cpp
clang/lib/Format/TokenAnnotator.cpp
clang/unittests/Format/FormatTest.cpp