33 lines
1.1 KiB
Diff
33 lines
1.1 KiB
Diff
From b102ea1008f34a468981562ad57a9e98b990c3d5 Mon Sep 17 00:00:00 2001
|
|
From: =?UTF-8?q?Mari=C3=A1n=20Kon=C4=8Dek?= <marian.koncek@mailbox.org>
|
|
Date: Wed, 8 Mar 2023 18:23:42 +0100
|
|
Subject: [PATCH] Skip interface keyword as annotation in name matching only
|
|
|
|
Fixes: #5
|
|
---
|
|
src/java_symbols.hpp | 4 ++--
|
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/src/java_symbols.hpp b/src/java_symbols.hpp
|
|
index 2253f0e..69f555b 100644
|
|
--- a/src/java_symbols.hpp
|
|
+++ b/src/java_symbols.hpp
|
|
@@ -536,12 +536,12 @@ inline std::string remove_annotations(std::string_view content, std_span<const s
|
|
auto next_position = std_ssize(content);
|
|
auto copy_end = std_ssize(content);
|
|
|
|
- if (annotation.begin() != content.end() and annotation_name != "interface")
|
|
+ if (annotation.begin() != content.end())
|
|
{
|
|
copy_end = annotation.end() - content.begin();
|
|
next_position = copy_end;
|
|
|
|
- if (name_matches(annotation_name, patterns, names, imported_names))
|
|
+ if (annotation_name != "interface" and name_matches(annotation_name, patterns, names, imported_names))
|
|
{
|
|
copy_end = annotation.begin() - content.begin();
|
|
|
|
--
|
|
2.39.1
|
|
|