summary refs log tree commit diff stats
path: root/examples/parsecfgex.nim
diff options
context:
space:
mode:
authorawr1 <41453959+awr1@users.noreply.github.com>2018-09-04 16:33:52 -0500
committerGitHub <noreply@github.com>2018-09-04 16:33:52 -0500
commiteb668003bf35671d7358e5f54e05820c0f4aef3d (patch)
treee5c5d6315f8ba4a5dd647bf67a4d0afb609916e7 /examples/parsecfgex.nim
parent89ad1cc9b18db8320e5b170ee45888cf79d52001 (diff)
parent4aba2981dd47672744191bd17b39bb149f494637 (diff)
downloadNim-eb668003bf35671d7358e5f54e05820c0f4aef3d.tar.gz
Merge branch 'devel' into experimentalize-reorder
Diffstat (limited to 'examples/parsecfgex.nim')
-rw-r--r--examples/parsecfgex.nim25
1 files changed, 0 insertions, 25 deletions
diff --git a/examples/parsecfgex.nim b/examples/parsecfgex.nim
deleted file mode 100644
index 0fa03ffb5..000000000
--- a/examples/parsecfgex.nim
+++ /dev/null
@@ -1,25 +0,0 @@
-
-import
-  os, parsecfg, strutils, streams
-
-var f = newFileStream(paramStr(1), fmRead)
-if f != nil:
-  var p: CfgParser
-  open(p, f, paramStr(1))
-  while true:
-    var e = next(p)
-    case e.kind
-    of cfgEof:
-      echo("EOF!")
-      break
-    of cfgSectionStart:   ## a ``[section]`` has been parsed
-      echo("new section: " & e.section)
-    of cfgKeyValuePair:
-      echo("key-value-pair: " & e.key & ": " & e.value)
-    of cfgOption:
-      echo("command: " & e.key & ": " & e.value)
-    of cfgError:
-      echo(e.msg)
-  close(p)
-else:
-  echo("cannot open: " & paramStr(1))