Commit Graph

8196 Commits

Author SHA1 Message Date
Andrey R (cooldome)
1663ad77e3 Revert "fix #15623 (#16009)"
This reverts commit 0f7f159a35.
2020-11-17 18:54:14 +00:00
flywind
0f7f159a35 fix #15623 (#16009)
* fix #15623

* add testcase for #15623

* fix

* add testcase
2020-11-17 17:05:20 +00:00
Juan Carlos
a8858eb93e htmlgen: Add lazy loading (#15986) 2020-11-16 10:15:05 -08:00
Andreas Rumpf
fc735e4b08 fix #15934 and #15620 (#15938) [backport:1.4]
* make workaround for #15934 and #15620
* add testcase for #9754
2020-11-15 18:12:53 +01:00
Andreas Rumpf
122f22d163 asynchttpserver cleanups [backport:1.0] (#15966)
* asynchttpserver cleanups [backport:1.0]
2020-11-15 07:27:13 +01:00
Andreas Rumpf
562c6275b8 attempt to make asynchttpserver better; fixes #15925; [backport:1.0] (#15957)
* attempt to make asynchttpserver better; fixes #15925; [backport:1.0]
* better documentation
* fixes 'nim doc'
* makes test green again
* ported to FreeRTOS
* fixes the doc rendering
2020-11-13 20:57:43 +01:00
Araq
02f8b11a71 fixes the doc rendering 2020-11-13 17:16:00 +01:00
Araq
9f566881f1 ported to FreeRTOS 2020-11-13 17:03:07 +01:00
landerlo
c39fa0d495 Make IntSet a generic ordinal set OrdSet[A] (#15564)
* Make IntSet an ordinal set OrdSet[A: Ordinal]

Backward compatibility with IntSet is maintained.
IntSet is an alias for OrdSet[int]

* move ordsets to new file, intsets exports it
* ordset, move to lib/std folder

* Fix `$` for ordsets and test cleanup
* Fix ordsets compilation in doc example
* Rename ordsets to packedsets
2020-11-13 14:12:51 +01:00
c-blake
a9bd4c4e80 Alternate to https://github.com/nim-lang/Nim/pull/15915 (#15937)
* Alternate PR to https://github.com/nim-lang/Nim/pull/15915 to
resolve the problem mentioned there (`hash() == 0`) as well as
to close https://github.com/nim-lang/Nim/issues/15624

* Address https://github.com/nim-lang/Nim/pull/15937#discussion_r522759669
{ though this was only a move from 2 copies to 3 copies. ;-) }
2020-11-13 14:04:40 +01:00
Araq
19d52033f8 fixes 'nim doc' 2020-11-13 13:50:57 +01:00
Araq
cb19dc53ca better documentation 2020-11-13 13:07:48 +01:00
Araq
8778d4a6f3 attempt to make asynchttpserver better; fixes #15925; [backport:1.0] 2020-11-13 13:03:14 +01:00
Miran
8a21f94c72 refactoring: modernize rst.nim (#15953) 2020-11-13 10:25:00 +01:00
flywind
0f53b129b7 nil 2020-11-13 15:28:22 +08:00
wilypomegranate
1fdfa234d7 Don't use os for Standalone (#15944) 2020-11-13 08:15:46 +01:00
treeform
83432aecfc Add documentElement to Document. (#15943) 2020-11-13 08:12:03 +01:00
flywind
492e9afa4c fix #15941 (#15948)
* fix #15941

* add testcase

* update
2020-11-13 08:11:00 +01:00
flywind
077eba7b38 make workaround for #15934 and #15620 2020-11-12 23:24:45 +08:00
Timothee Cour
cc882917fe js -d:nodejs now supports osenv: getEnv, putEnv, envPairs, delEnv, existsEnv (v2) (#15826)
* js -d:nodejs now supports osenv: `getEnv`, `putEnv`, `envPairs`, `delEnv`, `existsEnv`

* refactor to osenv

* fix for js (without -d:nodejs) + VM

Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
2020-11-12 14:36:57 +01:00
Bung
bc007a3cd3 add parent property to window in dom.nim (#15922) 2020-11-12 12:36:42 +01:00
hlaaftana
527e792827 make var string return var char w/ BackwardsIndex (#15461)
* make var string return var char w/ BackwardsIndex

fixes #14497

* work around VM bug
* properly workaround again
2020-11-12 11:44:21 +01:00
flywind
ef2677f5f3 change some code-blocks to runnableExamples and correct some errors in docs (#15900)
* original docs are wrong
* fix pathnorm
* Update lib/pure/pathnorm.nim

Co-authored-by: Juan Carlos <juancarlospaco@gmail.com>
2020-11-12 10:47:56 +01:00
Christopher Dunn
c6ceefea6d Fix a problem for long symlinks in conda (#15908) [backport]
* d8c80ea69d (diff-e1d8e552330911f9f779f85b6f2c00a15e790dcc3fbb3b28f5da1d660a30c5b8)
2020-11-12 09:32:38 +01:00
Timothee Cour
e5db5316c2 doAssertRaises improvements; nimscript supports except Exception as e (#15765)
* doAssertRaises now correctly handles foreign exceptions; now shows which exception is raised on mismatch
* nimscript now handles `Exception as e`
* remove catch-all doAssertRaises overload from this PR

Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
2020-11-12 09:25:41 +01:00
Bung
826e62953f fix #12726 Cannot take the compile-time sizeof Atomic types (#15928)
* fix #12726 Cannot take the compile-time sizeof Atomic types

* fix for arch 32
2020-11-12 09:16:40 +01:00
ee7
42c434fa3d Docs(strutils): Fix broken links (#15912)
The `dedent` and `unindent` links were introduced by commit d67c5cb751
(#15264).
2020-11-11 10:37:14 +08:00
Miran
bbe49a14ae Correct all eggs (#15906)
* "eg" is a misspelled "egg", "e.g." is "exempli gratia"
* Also, "ie" is "i.e.".
2020-11-10 21:53:25 +01:00
flywind
b38f0403fd fix #12471 (#15901)
* fix #12471

* add testcase

* fix

* test nimdoc is tricky

* Delete t12471.nim
2020-11-10 13:15:16 +01:00
Miran
ee78d76108 rst: add support for markdown tables (#15854)
* rst: add support for markdown tables

* change template into proc

* don't create unnecessary `seq[string]`
2020-11-10 09:41:26 +01:00
Ivan Bobev
d03f24147a Add a macro returning enum items count (#15824)
Add a macro `enumLen` which is used to determine the number of items in
an enumeration type to the `typetraits.nim` module. Also, add unit tests
for it in the `ttypetraits.nim` module.

Related to nimlang/Nim#15824
2020-11-09 10:02:01 +01:00
Luca Guzzon
49f68122e6 Console apps in Windows can raise OSError (#15874)
Console apps in Windows implementation can raise OSError so I've fixed it, see below some examples for reference:
- c07807bedf/lib/pure/terminal.nim (L170)
- c07807bedf/lib/pure/terminal.nim (L178)
- c07807bedf/lib/pure/terminal.nim (L191-L192)
- c07807bedf/lib/pure/terminal.nim (L196-L197)
- ...
2020-11-08 11:51:40 +08:00
flywind
9fd67958b9 follow #11707(add pragmas examples for =>) (#15863) 2020-11-06 11:42:43 +01:00
flywind
218ff27b70 fix #15851 (#15852)
* fix #15851

* {.cast(noSideEffect).}
2020-11-06 11:40:14 +01:00
Clyybber
d1bea1f71f Tiny unittest doc fix 2020-11-05 21:02:14 +01:00
Andreas Rumpf
3aab6a409d micro improvements (#15849) 2020-11-05 14:56:44 +01:00
flywind
adde5ba6b0 document #15618 (#15810)
* document #15618

* Update lib/pure/unittest.nim

* Update lib/pure/unittest.nim

Co-authored-by: Juan Carlos <juancarlospaco@gmail.com>

* Update lib/pure/unittest.nim

Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
Co-authored-by: Juan Carlos <juancarlospaco@gmail.com>
2020-11-05 14:04:24 +01:00
flywind
c4cc907433 fix adding empty sequence to HTTP headers (#15783)
* fix adding empty sequence to HTTP headers

* add tests
2020-11-05 14:01:28 +01:00
flywind
8e1fa84b0d fix #15663 (#15839) [backport:1.4] 2020-11-05 14:00:49 +01:00
flywind
cae92f670a change non-working example to runnableExamples (#15841) 2020-11-05 13:11:22 +01:00
flywind
7d640e0943 fix #15835 (#15838)
* fix #15835

* add tests
2020-11-04 01:24:40 -05:00
flywind
b0e26d8fbf remove iup from stdlib in contrast to #15828 (#15830)
* remove iup from stdlib

* Update changelog.md
2020-11-03 20:43:51 +01:00
flywind
75dc69417a fix deprecated messages regarding high (#15832) 2020-11-03 16:31:16 +01:00
cooldome
d62f3627aa EnumUtils, speed up findStr in compiler (#15777)
* add parseEnumRange
* fix runnable example
* update changelog
* use parseEnumRange in compiler
* reorganise code
* add changelog, make single normalizer argument
2020-11-03 16:26:16 +01:00
Miran
c243639979 ioutils are moved to fusion (#15822) 2020-11-02 16:52:54 +01:00
Timothee Cour
235e4930ab simplify toHex (#15821) 2020-11-02 14:48:36 +01:00
Andreas Rumpf
dfd8a83f35 fixes #15804 (#15820)
* fixes #15804

* fix the existing test

* add the testcase for #15804

Co-authored-by: narimiran <narimiran@disroot.org>
2020-11-02 14:17:09 +01:00
flywind
eb429988cd fixes #15594 (#15819) 2020-11-02 14:16:33 +01:00
Regis Caillaud
6fa82a5b3a Handle BLOB column type in SQLite as binary data (#15681)
* 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
2020-11-02 13:02:55 +01:00
flywind
4fe56b56ce more clear (#15812) 2020-11-02 13:01:19 +01:00