Nimrod renamed to Nim

This commit is contained in:
Araq 2014-08-28 09:59:26 +02:00
commit 4523b29d7a
23 changed files with 90 additions and 90 deletions

View file

@ -186,7 +186,7 @@ proc open*(connection, user, password, database: string): TDbConn {.
##
## Example:
##
## .. code-block:: nimrod
## .. code-block:: nim
##
## con = Open("", "", "", "host=localhost port=5432 dbname=mydb")
##
@ -194,7 +194,7 @@ proc open*(connection, user, password, database: string): TDbConn {.
## for more information.
##
## Note that the connection parameter is not used but exists to maintain
## the nimrod db api.
## the nim db api.
result = PQsetdbLogin(nil, nil, nil, nil, database, user, password)
if PQStatus(result) != CONNECTION_OK: dbError(result) # result = nil

View file

@ -228,7 +228,7 @@ template `=~` *(s: string, pattern: TRegex): expr =
## This calls ``match`` with an implicit declared ``matches`` array that
## can be used in the scope of the ``=~`` call:
##
## .. code-block:: nimrod
## .. code-block:: nim
##
## if line =~ re"\s*(\w+)\s*\=\s*(\w+)":
## # matches a key=value pair:
@ -271,12 +271,12 @@ proc replace*(s: string, sub: TRegex, by = ""): string =
## Replaces `sub` in `s` by the string `by`. Captures cannot be
## accessed in `by`. Examples:
##
## .. code-block:: nimrod
## .. code-block:: nim
## "var1=key; var2=key2".replace(re"(\w+)'='(\w+)")
##
## Results in:
##
## .. code-block:: nimrod
## .. code-block:: nim
##
## "; "
result = ""
@ -293,12 +293,12 @@ proc replacef*(s: string, sub: TRegex, by: string): string =
## Replaces `sub` in `s` by the string `by`. Captures can be accessed in `by`
## with the notation ``$i`` and ``$#`` (see strutils.`%`). Examples:
##
## .. code-block:: nimrod
## .. code-block:: nim
## "var1=key; var2=key2".replacef(re"(\w+)'='(\w+)", "$1<-$2$2")
##
## Results in:
##
## .. code-block:: nimrod
## .. code-block:: nim
##
## "var1<-keykey; val2<-key2key2"
result = ""
@ -360,13 +360,13 @@ iterator split*(s: string, sep: TRegex): string =
## Substrings are separated by the regular expression `sep`.
## Examples:
##
## .. code-block:: nimrod
## .. code-block:: nim
## for word in split("00232this02939is39an22example111", re"\d+"):
## writeln(stdout, word)
##
## Results in:
##
## .. code-block:: nimrod
## .. code-block:: nim
## "this"
## "is"
## "an"

View file

@ -8,7 +8,7 @@
#
## This module provides an easy to use sockets-style
## nimrod interface to the OpenSSL library.
## nim interface to the OpenSSL library.
{.deprecated.}

View file

@ -59,5 +59,5 @@ proc URLretrieveString*(url: string): TaintedString =
result = stream.data.TaintedString
when isMainModule:
echo URLretrieveString("http://nimrod-code.org/")
echo URLretrieveString("http://nim-code.org/")