+ /**
+ * Filter rewrite rules used for root-level archives.
+ *
+ * Likely root-level archives would include pagination rules for the homepage
+ * as well as site-wide post feeds (e.g. /feed/, and /feed/atom/).
+ *
+ * @since 1.5.0
+ *
+ * @param array $root_rewrite The root-level rewrite rules.
+ */
+ $root_rewrite = apply_filters( 'root_rewrite_rules', $root_rewrite );
+
+ // Comments rewrite rules.
+ $comments_rewrite = $this->generate_rewrite_rules($this->root . $this->comments_base, EP_COMMENTS, false, true, true, false);
+
+ /**
+ * Filter rewrite rules used for comment feed archives.
+ *
+ * Likely comments feed archives include /comments/feed/, and /comments/feed/atom/.
+ *
+ * @since 1.5.0
+ *
+ * @param array $comments_rewrite The rewrite rules for the site-wide comments feeds.
+ */
+ $comments_rewrite = apply_filters( 'comments_rewrite_rules', $comments_rewrite );
+
+ // Search rewrite rules.