| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Implement Pandoc Markdown concise link extension
This implements https://github.com/nim-lang/Nim/issues/20127.
Besides reference to headings we also support doing references
to Nim symbols inside Nim modules.
Markdown:
```
Some heading
------------
Ref. [Some heading].
```
Nim:
```
proc someFunction*() ...
... ## Ref. [someFunction]
```
This is substitution for RST syntax like `` `target`_ ``.
All 3 syntax variants of extension from Pandoc Markdown are supported:
`[target]`, `[target][]`, `[description][target]`.
This PR also fixes clashes in existing files, particularly
conflicts with RST footnote feature, which does not work with
this PR (but there is a plan to adopt a popular [Markdown footnote
extension](https://pandoc.org/MANUAL.html#footnotes) to make footnotes work).
Also the PR fixes a bug that Markdown links did not work when `[...]`
section had a line break.
The implementation is straightforward since link resolution did not
change w.r.t. RST implementation, it's almost only about new syntax
addition. The only essential difference is a possibility to add a custom
link description: form `[description][target]` which does not have an
RST equivalent.
* fix nim 1.0 gotcha
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The Nim manual says that an implicit conversion to cstring will
eventually not be allowed [1]:
A Nim `string` is implicitly convertible to `cstring` for convenience.
[...]
Even though the conversion is implicit, it is not *safe*: The garbage collector
does not consider a `cstring` to be a root and may collect the underlying
memory. For this reason, the implicit conversion will be removed in future
releases of the Nim compiler. Certain idioms like conversion of a `const` string
to `cstring` are safe and will remain to be allowed.
And from Nim 1.6.0, such a conversion triggers a warning [2]:
A dangerous implicit conversion to `cstring` now triggers a `[CStringConv]` warning.
This warning will become an error in future versions! Use an explicit conversion
like `cstring(x)` in order to silence the warning.
However, some files in this repo produced such a warning. For example,
before this commit, compiling `parsejson.nim` would produce:
/foo/Nim/lib/pure/parsejson.nim(221, 37) Warning: implicit conversion to 'cstring' from a non-const location: my.buf; this will become a compile time error in the future [CStringConv]
/foo/Nim/lib/pure/parsejson.nim(231, 39) Warning: implicit conversion to 'cstring' from a non-const location: my.buf; this will become a compile time error in the future [CStringConv]
This commit resolves the most visible `CStringConv` warnings, making the
cstring conversions explicit.
[1] https://github.com/nim-lang/Nim/blob/d2318d9ccfe6/doc/manual.md#cstring-type
[2] https://github.com/nim-lang/Nim/blob/d2318d9ccfe6/changelogs/changelog_1_6_0.md#type-system
|
| |
|
| |
|
|
|
|
| |
#14357 changed from sending 'val', an int, to a pointer to int, which is understandable, but not how SQLSetEnvAttr works.
"Depending on the value of Attribute, ValuePtr will be a 32-bit integer value or point to a null-terminated character string"
|
|
|
|
|
|
|
|
|
| |
* fix sqlgetdata import
* fix db_odbc
* more fixes
* fix style
|
|
|
|
|
|
|
|
|
|
|
| |
* add insert,tryInsert unify for postgres that need pk name
* add ReadDbEffect to new procs
* add .since and changelog
* change since to 1.3
* Update lib/impure/db_postgres.nim
Co-authored-by: bung87 <crc32@qq.com>
Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
Co-authored-by: alaviss <leorize+oss@disroot.org>
|
|
|
|
|
|
|
| |
* fix #9771
* map SQLLEN SQLULEN
* fix proc params take TSqlLen
Co-authored-by: bung87 <crc32@qq.com>
|
| |
|
| |
|
|
|
|
| |
InstantRow (#11647)
|
| |
|
|
|
|
|
| |
* Fix wrong parameter type in SQLErr
* Fix wrong types of integers passed to SQLGetData
|
|
|
|
|
|
|
|
| |
* Restrict ptr/ref to ptr/ref implicit conversion
Fixes #10409
* Make the ptr conversions explicit in db_odbc
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
ODBC Errors were presented to the users as a sequence of characters.
I.e.:
>test_oracle.exe
Error: ['H', 'Y', '0', '0', '0', '\x00', '\x00', ...]
test_oracle.nim(15) test_oracle
test_oracle.nim(8) test_oracle
db_odbc.nim(534) open
db_odbc.nim(168) dbError
Error: unhandled exception: ODBC Error [DbError]
This patch fix the string decoding, creating a real string:
>test_oracle.exe
Error: HY000 [Oracle][ODBC][Ora]ORA-12541: TNS:no listener
test_oracle.nim(15) test_oracle
test_oracle.nim(8) test_oracle
db_odbc.nim(534) open
db_odbc.nim(168) dbError
Error: unhandled exception: ODBC Error [DbError]
|
| |
|
| |
|
|\ |
|
| |
| |
| |
| |
| |
| | |
SQL_NO_DATA
change SqlCheck() and SqlGetDBMS() to sqlCheck() and sqlGetDBMS() (camelCase consistency)
|
|/
|
|
| |
compiled in the release mode, the return of the field value is null.
|
| |
|
| |
|
|
|