summary refs log tree commit diff stats
path: root/lib/impure
Commit message (Collapse)AuthorAgeFilesLines
* Implement Markdown definition lists (+ migration) (#20333)Andrey Makarov2022-09-111-14/+14
| | | | | | | | | | | | | | | Implements definition lists Markdown extension adopted in a few implementations including: * [Pandoc]( https://pandoc.org/MANUAL.html#definition-lists) * [kramdown]( https://kramdown.gettalong.org/quickref.html#definition-lists) * [PHP extra Markdown]( https://michelf.ca/projects/php-markdown/extra/#def-list) Also affected files have been migrated. RST definition lists are turned off for Markdown: this solves the problem of broken formatting mentioned in https://github.com/nim-lang/Nim/pull/20292.
* Implement Pandoc Markdown concise link extension (#20304)Andrey Makarov2022-09-043-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 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
* Markdown code blocks part 6 (#20292)Andrey Makarov2022-08-311-37/+39
|
* make implicit cstring conversions explicit (#19488)ee72022-08-194-21/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* fixes #20153; do not escape `_` for mysql [backport] (#20164)ringabout2022-08-051-2/+1
| | | | | | | | | | | * fixes #20153; do not escape `_` for mysql * add a test * Update db_mysql.nim * Update tdb_mysql.nim Co-authored-by: Clay Sweetser <Varriount@users.noreply.github.com>
* fix typo in nre.nim (#19915)flintforge2022-06-211-2/+1
| | | | | Update nre.nim typo in proc replace description
* Revert "fix db_sqlite.tryInsertID does raise exceptions in 1.6.0 #19743 ↵Andreas Rumpf2022-04-251-14/+11
| | | | | (#19744)" (#19745) This reverts commit b10f0e7bca43761316f6424786a771af33254e19.
* fix db_sqlite.tryInsertID does raise exceptions in 1.6.0 #19743 (#19744)flywind2022-04-241-11/+14
|
* enable style:usages for stdlib tests [backport: 1.6] (#19715)flywind2022-04-131-10/+10
| | | | | | | | | | | | | | | * enable style:usages for stdlib tests * freeAddrInfo * more tests * importc * bufSize * fix more * => parseSql and renderSql
* db_sqlite: added a spaceAraq2022-03-181-1/+1
|
* fix not flushing stdout in MSYS (#19590)Hamid Bluri2022-03-071-0/+1
| | | I did this pull request according to what xflywind said: https://github.com/nim-lang/Nim/pull/19584#issuecomment-1060085141
* stylecheck usages part two: stdlib cleanup (#19338)flywind2022-01-081-1/+1
| | | | | | | | | | | | | * stylecheck usages part two: stdlib cleanup typeinfo.nim: importCompilerProc => importcompilerproc nre.nim: newLineFlags => newlineFlags system.nim: JSRoot => JsRoot ref #19319 * prefer importCompilerProc
* fix bug #14468 zero-width split (#19248)Carlo Capocasa2021-12-131-4/+7
|
* libs/impore/re: Add note about the requirement of `matches` to be ↵Kaushal Modi2021-11-021-0/+34
| | | | | | | pre-allocated (#19081) Add few runnableExamples for `findBounds` for clarity. Fixes https://github.com/nim-lang/Nim/issues/18775
* fix a sqlite bug (#18669)flywind2021-08-121-11/+4
|
* [nre]fix #17129 (#18632)flywind2021-08-081-3/+2
| | | | | | | | | | | | | | | * fix #17129 * correct * give reference implementaion links * add comment * typo * I'm conservative * change
* improve runnableExamples and docs for std/nre (#18634)Timothee Cour2021-08-021-68/+49
| | | | | * improve runnableExamples and docs for std/nre * avoid too long lines in example
* fix comment (#18473)sivchari2021-07-111-6/+6
|
* simplify rdstdin (#18382)Timothee Cour2021-06-281-10/+4
|
* PCRE, nimgrep: add limit for buffer size (#18280)Andrey Makarov2021-06-171-3/+10
|
* fix #9437(fix `re.replace` wrong behaviour) (#17546)flywind2021-06-101-2/+18
| | | | | * fix nim js cmp fails at CT * fix
* Improve db_postgres iterators (#18144)Artem Klevtsov2021-06-031-62/+117
| | | | | | | | | | | | | | | * Fix pqSetSingleRowMode case. Add links to the docs * Add missing PGContextVisibility enum * Remove unused PGContextVisibility enum * Improve db_postgres iterators * Fix instantRows with DbColumns. Cosmetics. * Reduce copy&paste in db_postgres * Move pqclear inside loop
* [std/re] fix findBounds and find procs (#18028)flywind2021-05-311-2/+2
| | | | | | | * [std/re] make interface consistent * tiny * revert
* docs: make inline markup more compatible with Markdown (#18053)Andrey Makarov2021-05-211-1/+1
| | | fixes https://github.com/timotheecour/Nim/issues/739
* Revert "[std/re]fix terrible and strange interface" (#18027)flywind2021-05-161-6/+6
| | | This reverts commit c218f2ba0b8e27110087ea754c11cff123806a94.
* [std/re]fix terrible and strange interfaceflywind2021-05-161-6/+6
|
* Escape `%00` / `\0` in `dbQuote` (#18015) [backport:1.4]Thomas T. Jarløv2021-05-151-1/+3
| | | Fix https://github.com/nim-lang/Nim/issues/17925
* Fix `insert` calling wrong function (#17856)Fröhlich A2021-04-291-1/+1
| | | | The `insert` method is calling `tryInsertID`, which ignores the `pkName` parameter. Calling `tryInsert` instead should be correct.
* fix RST parsing when no indent after enum.item (fix #17249) (#17257)Andrey Makarov2021-03-121-1/+1
|
* use `-r:off` for runnableExamples that should compile but not run (#17203)Timothee Cour2021-03-011-9/+8
| | | | | * use -r:off for runnableExamples that should compile but not run * use -r:off in other RT disabled tests
* Change stdlib imports to use std prefix in most examples (#17202)Danil Yarantsev2021-02-286-12/+12
|
* use single backtick (#17133)flywind2021-02-211-6/+6
|
* use single backtick (#17115)flywind2021-02-202-153/+153
|
* use single backtick (#17100)flywind2021-02-184-27/+27
|
* remove all uses of condsyms symbols defined prior to bootstrap nim 0.20.0 ↵Timothee Cour2021-02-171-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (#16918) * nimNoArrayToCstringConversion deadcode * nimbabel deadcode * nimHasalignOf deadcode * nimvarargstyped deadcode * nimhygiene deadcode * nimNewTypedesc deadcode * nimlocks deadcode * nimHasCppDefine deadcode * nimHasRunnableExamples deadcode * nimHasNilChecks deadcode * nimSymKind deadcode * minor macros refactoring * nimVmEqIdent deadcode * nimNoNil deadcode * nimNoZeroTerminator deadcode * nimHasSymOwnerInMacro deadcode * nimVmExportFixed deadcode * nimNewRuntime deadcode * nimAshr deadcode * nimUncheckedArrayTyp deadcode * nimHasTypeof deadcode * nimErrorProcCanHaveBody deadcode * nimHasHotCodeReloading deadcode * nimHasSignatureHashInMacro deadcode * nimHasDefault deadcode * nimMacrosSizealignof deadcode
* add linenoise.readLineStatus to get status (eg: ctrl-D or ctrl-C) (#16977)Timothee Cour2021-02-091-9/+11
| | | | | * add linenoise.readLineStatus to get status (eg: ctrl-D or ctrl-C) * changelog
* fix some warnings (#16952)flywind2021-02-081-1/+1
|
* Deprecate TaintedString (#15423)Juan Carlos2021-01-151-11/+11
| | | | Co-authored-by: Timothee Cour <timothee.cour2@gmail.com> Co-authored-by: Dominik Picheta <dominikpicheta@googlemail.com>
* fix #16103 (#16109) [backport:1.0]flywind2020-11-241-5/+21
| | | | | * fix #16103 * docs
* fixes #16080 (#16091) [backport:1.2]RokkuCode2020-11-231-1/+1
| | | | | | | * fixes #16080 db_sqlite: Error: undeclared field: 'untypedLen' * redacting fix
* fixes db_mysql broken quoting; refs ↵Andreas Rumpf2020-11-181-1/+0
| | | | https://github.com/nim-lang/Nim/commit/c16ee37a7106c645a0d17cc6bd8d399e20f61d96#r44209990 [backport:1.4] (#16035)
* Handle BLOB column type in SQLite as binary data (#15681)Regis Caillaud2020-11-021-15/+78
| | | | | | * Fixed not handling blob correctly in sqlite * Fixed setLen commented by mistake * Added binary example as db_sqlite doc * Added tests for sqlite binary data
* fixes #15560 (#15587)Andreas Rumpf2020-10-151-2/+1
|
* various documentation fixes [backport] (#15422)Miran2020-09-291-4/+4
|
* odbc regression from #14357 (#15417)shirleyquirk2020-09-291-1/+1
| | | | #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"
* .noalias annotation; frontend support (#15419)Andreas Rumpf2020-09-281-1/+1
| | | | | * .noalias annotation; frontend support * added .noalias support to Nim; implements https://github.com/nim-lang/RFCs/issues/204
* Fix #15219 SQL escape in db_mysql is not enough (#15234)Bung2020-09-041-3/+17
|
* fixes #15221 (#15230)Andreas Rumpf2020-08-271-1/+1
|
* better strict funcs, WIP (#15199)Andreas Rumpf2020-08-181-2/+4
| | | | | * better strict funcs, WIP * progress
* db_postgres document how to use it with unix socket (#15187)Juan Carlos2020-08-171-2/+22
|
'' href='/ahoang/Nim/commit/compiler/vmdeps.nim?h=devel&id=70ea45cdbaa9d26a7196ab2718f60c9ca77e2d12'>70ea45cdb ^
752052e90 ^
35d7a99b6 ^
d462cca21 ^
0356f53b5 ^



35d7a99b6 ^

70ea45cdb ^
0356f53b5 ^
d462cca21 ^
40ec7be45 ^
ec50dab57 ^

35d7a99b6 ^
ec50dab57 ^

35d7a99b6 ^
40ec7be45 ^
ec50dab57 ^
752052e90 ^
f9a3de984 ^
c89397f82 ^
0356f53b5 ^
c89397f82 ^
f9a3de984 ^
e8aa6f6c3 ^
5f4e98bbc ^
c89397f82 ^
dc5e4b018 ^
5f4e98bbc ^
dc5e4b018 ^
752052e90 ^
0356f53b5 ^

2a7fc84c8 ^

752052e90 ^
0356f53b5 ^


e8aa6f6c3 ^
40ec7be45 ^
0356f53b5 ^
2a7fc84c8 ^
752052e90 ^
0356f53b5 ^

2a7fc84c8 ^
0356f53b5 ^
2a7fc84c8 ^
0356f53b5 ^



dc5e4b018 ^
752052e90 ^
936265df7 ^
2a7fc84c8 ^
3bffb3ba3 ^

0356f53b5 ^

e2567e2e0 ^

47335aab4 ^
e2567e2e0 ^


0755f902d ^
e2567e2e0 ^

0356f53b5 ^
5f4e98bbc ^

0356f53b5 ^




5f4e98bbc ^
0356f53b5 ^




5f4e98bbc ^
822d2b508 ^





e4081a720 ^

5f4e98bbc ^
e879da579 ^
0356f53b5 ^




2a7fc84c8 ^
0356f53b5 ^




dec97924a ^

0356f53b5 ^
5f4e98bbc ^

752052e90 ^
936265df7 ^
5f4e98bbc ^
752052e90 ^

5f4e98bbc ^
















5f4e98bbc ^
5f4e98bbc ^


0b0a3e5f2 ^





5f4e98bbc ^





fedc13698 ^
e879da579 ^
d462cca21 ^

5f4e98bbc ^
d462cca21 ^

5f4e98bbc ^
d462cca21 ^

fedc13698 ^
752052e90 ^
40ec7be45 ^

d462cca21 ^
c89397f82 ^

40ec7be45 ^

0356f53b5 ^


40ec7be45 ^

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298