From 3602419d95b3b8d807a5c7cb6d151ecc9166be86 Mon Sep 17 00:00:00 2001 From: Ian Lynagh Date: Wed, 11 Aug 2010 18:27:30 +0000 Subject: [PATCH] Add emptyPermissions --- System/Directory.hs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/System/Directory.hs b/System/Directory.hs index 1291d71..e179c93 100644 --- a/System/Directory.hs +++ b/System/Directory.hs @@ -56,6 +56,7 @@ module System.Directory -- $permissions , Permissions + , emptyPermissions , readable -- :: Permissions -> Bool , writable -- :: Permissions -> Bool , executable -- :: Permissions -> Bool @@ -163,6 +164,14 @@ data Permissions executable, searchable :: Bool } deriving (Eq, Ord, Read, Show) +emptyPermissions :: Permissions +emptyPermissions = Permissions { + readable = False, + writable = False, + executable = False, + searchable = False + } + setOwnerReadable :: Bool -> Permissions -> Permissions setOwnerReadable b p = p { readable = b } -- 1.7.10.4