From 7c879d9b0fada910bf6afc0a64d327f318a829de Mon Sep 17 00:00:00 2001 From: Andreas Rumpf Date: Sat, 14 Apr 2018 13:57:27 +0200 Subject: [PATCH] explicit effects for existsOrCreateDir --- lib/pure/os.nim | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/pure/os.nim b/lib/pure/os.nim index c06a9bd796..a77bee99da 100644 --- a/lib/pure/os.nim +++ b/lib/pure/os.nim @@ -925,7 +925,8 @@ proc rawCreateDir(dir: string): bool = else: raiseOSError(osLastError()) -proc existsOrCreateDir*(dir: string): bool = +proc existsOrCreateDir*(dir: string): bool {.rtl, extern: "nos$1", + tags: [WriteDirEffect, ReadDirEffect].} = ## Check if a `directory`:idx: `dir` exists, and create it otherwise. ## ## Does not create parent directories (fails if parent does not exist).