entlicher commented on a change in pull request #3025:
URL: https://github.com/apache/netbeans/pull/3025#discussion_r662575810



##########
File path: 
java/java.lsp.server/src/org/netbeans/modules/java/lsp/server/Utils.java
##########
@@ -206,4 +206,35 @@ public static synchronized FileObject fromUri(String uri) 
throws MalformedURLExc
     private static File getCacheDir() {
         return Places.getCacheSubfile("java-server");
     }
+
+    private static final char[] SNIPPET_ESCAPE_CHARS = new char[] { '\\', '$', 
'}' };
+    /**
+     * Escape special characters in a completion snippet. Characters '$' and 
'}'
+     * are escaped via backslash.
+     */
+    public static String escapeCompletionSnippetSpecialChars(String text) {
+        if (text.isEmpty()) {

Review comment:
       I'm not calling it with `null` anywhere AFAIK.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to