renamed optional to discardable

This commit is contained in:
Araq 2011-09-24 19:18:08 +02:00
commit 485c371942
15 changed files with 72 additions and 63 deletions

View file

@ -136,7 +136,8 @@ proc RaiseFormatException(s: string) =
proc getValue(t: PStringTable, flags: set[TFormatFlag], key: string): string =
if hasKey(t, key): return t[key]
if useEnvironment in flags: result = os.getEnv(key)
# hm difficult: assume safety in taint mode here. XXX This is dangerous!
if useEnvironment in flags: result = os.getEnv(key).string
else: result = ""
if result.len == 0:
if useKey in flags: result = '$' & key