public static boolean isCanonicalConstructor(@NotNull PsiMethod method) {
    if (method instanceof LightRecordCanonicalConstructor) return true;
    if (!method.isConstructor()) return false;
    PsiClass aClass = method.getContainingClass();
    if (aClass == null || !aClass.isRecord()) return false;
    return method.getParameterList().getText() == null || hasCanonicalSignature(method, aClass.getRecordComponents());
  }
public static boolean isCanonicalConstructor(@NotNull PsiMethod method)