@Nonnull
	public static RegexValidation validate(@Nonnull String pattern) {
		// Check prior failed patterns
		RegexValidation result = FAILED_PATTERNS.get(pattern);
		if (result == null) {
			try {
				new Pattern(pattern);
				result = RegexValidation.VALID;
			} catch (Throwable t) {
				// Record new invalid pattern.
				result = new RegexValidation(false, t.getMessage());
				FAILED_PATTERNS.put(pattern, result);
			}
		}
		return result;
	}
@param pattern
		Pattern to check.

@return {@code true} when valid. {@code false} otherwise.
recaf-core/src/main/java/software/coley/recaf/util/RegexUtil.java