patch 8.1.0495: :filter only supports some commands

Problem:    :filter only supports some commands.
Solution:   Add :filter support for more commands. (Marcin Szamotulski,
            closes #2856)
diff --git a/src/syntax.c b/src/syntax.c
index e00746e..5b9aec4 100644
--- a/src/syntax.c
+++ b/src/syntax.c
@@ -352,7 +352,7 @@
 
 /*
  * A state stack is an array of integers or stateitem_T, stored in a
- * garray_T.  A state stack is invalid if it's itemsize entry is zero.
+ * garray_T.  A state stack is invalid if its itemsize entry is zero.
  */
 #define INVALID_STATE(ssp)  ((ssp)->ga_itemsize == 0)
 #define VALID_STATE(ssp)    ((ssp)->ga_itemsize != 0)
@@ -9189,7 +9189,10 @@
     struct hl_group	*sgp;
     int			didh = FALSE;
 
-    sgp = &HL_TABLE()[id - 1];	    /* index is ID minus one */
+    sgp = &HL_TABLE()[id - 1];	    // index is ID minus one
+
+    if (message_filtered(sgp->sg_name))
+	return;
 
     didh = highlight_list_arg(id, didh, LIST_ATTR,
 				    sgp->sg_term, NULL, "term");