def expr_key_re(replacement: ':')
      @expr_key_re ||= begin
        # disallow patterns with no keys
        ignore_pattern_re = /\A[\.#{replacement}]*\z/
        patterns          = used_in_source_tree(strict: false).key_names.select do |k|
          k.end_with?('.') || k =~ /\#{/
        end.map do |k|
          pattern = "#{replace_key_exp(k, replacement)}#{replacement if k.end_with?('.')}"
          next if pattern =~ ignore_pattern_re
          pattern
        end.compact
        compile_key_pattern "{#{patterns * ','}}"
      end
    end
def expr_key_re(replacement: ':')
      @expr_key_re ||= begin
        # disallow patterns with no keys
        ignore_pattern_re = /\A[\.#{replacement}]*\z/
        patterns          = used_in_source_tree(strict: false).key_names.select do |k|
          k.end_with?('.') || k =~ /\#{/
        end.map do |k|
          pattern = "#{replace_key_exp(k, replacement)}#{replacement if k.end_with?('.')}"
          next if pattern =~ ignore_pattern_re
          pattern
        end.compact
        compile_key_pattern "{#{patterns * ','}}"
      end
    end
keys in the source that end with a ., e.g. t("category.#{ cat.i18n_key }") or t("category." + category.key)
 @param [String] replacement for interpolated values.