detectDuplicateNames :: Module.Raw -> NonEmpty Info -> Task.Task_ E.Error ()
detectDuplicateNames name (info :| otherInfos) =
  case otherInfos of
    [] ->
      return ()

    _ ->
      Task.throw (E.RootModuleNameDuplicate name (map _path (info : otherInfos)))




-- READ SOURCE
detectDuplicateNames :: Module.Raw -> NonEmpty Info -> Task.Task_ E.Error ()
detectDuplicateNames name (info :| otherInfos) =
  case otherInfos of
    [] ->
      return ()

    _ ->
      Task.throw (E.RootModuleNameDuplicate name (map _path (info : otherInfos)))




-- READ SOURCE
detectDuplicateNames name (info :| otherInfos) =
  case otherInfos of
    [] ->
      return ()

    _ ->
      Task.throw (E.RootModuleNameDuplicate name (map _path (info : otherInfos)))




-- READ SOURCE