From f37ff441da35df47d7a9b379ea3f917e399dc89a Mon Sep 17 00:00:00 2001 From: Simon Bjorklen Date: Tue, 19 Oct 2021 09:17:24 +0200 Subject: [PATCH] Make cpp assembly file extensions case sensitive again This fixes an issue introduced by PR #14005 where .s and .S extensions were handled case-insensitive on Windows so the action assemble was triggered instead of preprocess_assemble. --- .../com/google/devtools/build/lib/rules/cpp/CppFileTypes.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/google/devtools/build/lib/rules/cpp/CppFileTypes.java b/src/main/java/com/google/devtools/build/lib/rules/cpp/CppFileTypes.java index 5140b4afdd5625..de59714497f674 100644 --- a/src/main/java/com/google/devtools/build/lib/rules/cpp/CppFileTypes.java +++ b/src/main/java/com/google/devtools/build/lib/rules/cpp/CppFileTypes.java @@ -99,8 +99,8 @@ public ImmutableList getExtensions() { @Override public boolean apply(String path) { - return (OS.endsWith(path, ext) && !PIC_ASSEMBLER.matches(path)) - || OS.endsWith(path, ".asm"); + return (path.endsWith(ext) && !PIC_ASSEMBLER.matches(path)) + || path.endsWith(".asm"); } @Override