summary refs log tree commit diff stats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Added `std/oserrors` for OS error reporting (#19390)flywind2022-01-171-0/+9
| | | | | | | | | * Added 'std/oserrors' for OS error reporting * add a simple test * New code should not support -d:useWinAnsi anymore thanks to @Araq
* Optimize lent in JS [backport:1.6] (#19393)hlaaftana2022-01-172-8/+45
| | | | | | | * Optimize lent in JS [backport:1.6] * addr on lent doesn't work anymore, don't use it * use unsafeAddr in test again for older versions
* mangle names in nimbase.h using cppDefine (#19395) [backport]flywind2022-01-171-0/+16
| | | | mangle names in nimbase.h fix comments
* add mm to compilesettings; deprecate gc (#19394)flywind2022-01-161-1/+2
|
* deprecate unsafeAddr; extend addr (#19373)flywind2022-01-1624-39/+39
| | | | | | | | | | | | | | | | | | | | | | | | | * deprecate unsafeAddr; extend addr addr is now available for all addressable locations, unsafeAddr is deprecated and become an alias for addr * follow @Vindaar's advice * change the signature of addr * unsafeAddr => addr (stdlib) * Update changelog.md * unsafeAddr => addr (tests) * Revert "unsafeAddr => addr (stdlib)" This reverts commit ab83c99c507048a8396e636bf22d55fdd84d7d1c. * doc changes; thanks to @konsumlamm Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com> Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com>
* Use openarray of bytes in md5 (#19307)hlaaftana2022-01-153-9/+16
| | | | | | | | | | * Use openarray of bytes in md5 * fix CI * cleanup * use noSideEffect for bootstrapping * fix CI again * actually fix CI by checking if it works * this is getting ridiculous * put old md5 version in compiler, remove vmop
* Fixed concept constraints for static types (#19391)Jason Beetham2022-01-151-25/+62
|
* Generic parameters now can constrain statics in type definitions (#19362)Jason Beetham2022-01-141-0/+42
| | | | | | | | | * Parameters now can constrain static in type definitions resolved regression with generic procedures * Update compiler/sigmatch.nim Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
* nrvo shouldn't touch bycopy object[backport:1.2] (#19385)flywind2022-01-142-0/+30
| | | fix nim-lang#19342
* fix stylecheck error with asyncdispatch (#19350)flywind2022-01-102-0/+34
| | | | | | | | | | | | | | | | | | | | | * stylecheck usages part two: stdlib cleanup typeinfo.nim: importCompilerProc => importcompilerproc nre.nim: newLineFlags => newlineFlags system.nim: JSRoot => JsRoot ref #19319 * prefer importCompilerProc * fix stylecheck error with asyncdispatch it is a partial regression since #12842 * add tests * don't use echo in tests
* Fix `remove` on last node of singly-linked list [backport:1.6] (#19353)gecko2022-01-101-0/+13
|
* style usages part one (openarray => openArray) (#19321)flywind2022-01-0449-76/+76
| | | | | * style usages (openArray) * revert doc changes
* Fix #19314 - fixing broken `DoublyLinkedList` after adding empty ↵rockcavera2022-01-031-0/+12
| | | | | | | `DoublyLinkedList` (#19315) [backport] * Update lists.nim * Update tlists.nim
* Add Week-Of-Year Implementation to Times Module (#17223)Carlo Capocasa2022-01-031-0/+95
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * initial * more tests * Apply suggestions from code review idiomatize Co-authored-by: Timothee Cour <timothee.cour2@gmail.com> * test iron age dates * add examples * fix typo * consistent param mention * add since pragrams * add changelog * Update lib/pure/times.nim Co-authored-by: Timothee Cour <timothee.cour2@gmail.com> * fix examples * fix negative years * add getWeeksInYear tests * add back fix dropped by rebase * week-year tuple api * add changelog * fix doc tags * add docstrings * fix typos Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com> Co-authored-by: Timothee Cour <timothee.cour2@gmail.com> Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com>
* Allow full commands and blocks in type sections (#19181)hlaaftana2022-01-025-0/+368
| | | | | | | * allow full commands and blocks in type sections * update grammar * fix changelog [skip ci] * more tests * even more tests
* Update JS and nimscript import tests (#19306)hlaaftana2022-01-012-40/+53
| | | | | * add new modules, except experimental ones * remove deprecated modules mersenne and sharedlist * better describe why some modules fail and some modules don't
* Fix #19297 - fixing broken list after adding empty list (#19299)rockcavera2021-12-301-0/+12
| | | | | | | | | * Update lists.nim * Update tlists.nim * removed check `if b.tail != nil` The tail of the list being null it is still possible to retrieve its end by going through all nodes from the head. So checking for null from `b.tail` is unnecessary. However, setting `a.tail = b.tail` only if `a.head != nil`, so you don't break a good list with an already broken one.
* Fixed object field access of static objects in generics (#19283) [backport]Jason Beetham2021-12-231-0/+8
|
* Extract runnables that specify `doccmd` (#19275) [backport:1.6]Jake Leahy2021-12-201-0/+20
|
* fix #19244 - solves the problem of the InAddr object constructor in Windows. ↵rockcavera2021-12-171-0/+6
| | | | | | | (#19259) * Update winlean.nim * Update tnet_ll.nim
* [backport:1.0] json: limit recursion depth (#19252)Miran2021-12-141-0/+32
| | | | | * json: limit recursion depth * do not run this check for JS backend
* fix: fixes bug in CVerifyPeerUseEnvVars (#19247)Nick Wilburn2021-12-141-0/+16
| | | | | | Previously CVerifyPeerUseEnvVars was not being passed into scanSslCertificates, which meant that we weren't scanning additional certificate locations given via the SSL_CERT_FILE and SSL_CERT_DIR environment variables
* fix bug #14468 zero-width split (#19248)Carlo Capocasa2021-12-131-0/+6
|
* Various std net improvements (#19132)Jaremy Creechley2021-12-121-43/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Variant of that works with raw IpAddresses. - Add doc tests for new net proc's. - Aadd recvFrom impl - Add recvFrom impl -- tweak handling data var - Update lib/pure/net.nim Co-authored-by: Dominik Picheta <dominikpicheta@googlemail.com> - cleaning up sendTo args - remove extra connect test - cleaning up sendTo args - fix inet_ntop test - fix test failing - byte len * fix test failing - byte len * debugging odd windows build failure * debugging odd windows build failure * more experiments to figure out the windows failure * try manual assigment on InAddr Co-authored-by: Jaremy Creechley <jaremy.creechley@panthalassa.com>
* fixes a possible 'javascript:' protocol exploit [backport:1.0] (#19134)Andreas Rumpf2021-12-101-4/+31
| | | | | | | | | | | | | * fixes a possible 'javascript:' protocol exploit [backport:1.0] * add tests * Update tests/stdlib/trstgen.nim * add the same logic for hyperlinks * move the logic into a proc Co-authored-by: narimiran <narimiran@disroot.org>
* nimRawSetjmp: support Windows (#19197)Ștefan Talpalaru2021-12-102-2/+134
| | | | | | | | | | | | * nimRawSetjmp: support Windows Using `_setjmp()` directly is required to avoid some rare (but very annoying) exception-related stack corruption leading to segfaults on Windows, with Mingw-w64 and SEH. More details: https://github.com/status-im/nimbus-eth2/issues/3121 Also add "nimBuiltinSetjmp" - mostly for benchmarking. * fix for Apple's Clang++
* fixes an old ARC bug: the produced copy/sink operations don't copy the ↵Andreas Rumpf2021-12-091-0/+15
| | | | hidden type field for objects with enabled inheritance; fixes #19205 [backport:1.6] (#19232)
* fixes a converter handling regression that caused private converters to leak ↵Andreas Rumpf2021-12-092-0/+13
| | | | into client modules; fixes #19213; [backport:1.6] (#19229)
* allow `HSlice` bounded by constants of distinct types (#19219) [backport:1.2]Etan Kissling2021-12-061-0/+2
| | | | | | | | | When creating heterogenous slices of distinct types, the compiler does not initialize the internal type's `size` before accessing it. This then leads to this crash message: ``` compiler/int128.nim(594, 11) `false` masking only implemented for 1, 2, 4 and 8 bytes [AssertionError] ``` This patch initializes the `size` properly, fixing the problem.
* treat do with pragmas but no parens as proc (#19191)hlaaftana2021-12-051-2/+17
| | | fixes #19188
* fixes #19159 [backport:1.6] (#19210)Andreas Rumpf2021-12-041-0/+12
|
* fixes #19198 [backport:1.6] (#19209)Andreas Rumpf2021-12-041-2/+21
| | | | | * fixes #19198 [backport:1.6] * added a test case
* fixes #19015 [backport:1.6] (#19204)Andreas Rumpf2021-12-041-0/+3
|
* accept object type node from macros (#19179)hlaaftana2021-11-241-0/+16
|
* parseExpr/parseStmt accept filename, fixes #13540 (#19182)hlaaftana2021-11-242-0/+15
|
* fix #12274 (#19180)hlaaftana2021-11-241-0/+9
|
* `caseStmtMacros` no longer experimental, experimental manual refactor (#19173)hlaaftana2021-11-231-2/+0
| | | | | | | | | | | * `caseStmtMacros` no longer experimental, experimental manual refactor * Update doc/manual.rst * apply review suggestions * apply review Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
* implement RST & Markdown quote blocks (#19147)Andrey Makarov2021-11-231-0/+361
| | | | | | | * implement RST & Markdown quote blocks * compile with nim 1.0 * Fix indentation
* Accept nnkTypeSection from typedef macro pragmas (#19168)hlaaftana2021-11-221-0/+66
|
* fix marshal bugs in VM (#19161) [backport:1.6]flywind2021-11-171-4/+8
|
* Enable customizing PageShift to set PageSize for embedded targets (#19129)Jaremy Creechley2021-11-161-2/+5
| | | | | | | | | | | | | | | | * Enable customizing PageSize (via PageShift). This enables adjusting PageSize for embedded targets without abusing cpu16. * copy nimPageXYZ settings for mmpaptest * add docs for Nim manual * add docs for Nim manual * docs tweaks Co-authored-by: Jaremy Creechley <jaremy.creechley@panthalassa.com>
* Fix punycode.decode function (#19136)Christoph Krybus2021-11-121-1/+201
| | | | | | | | | | | | | | * Refactor: rename proc to func * Fix punycode.decode function This function could only properly decode punycodes containing a single encoded unicode character. As soon as there was more than one punycode character group to decode it produced invalid output - the number of characters was correct, but their position was not. * Update tpunycode.nim Co-authored-by: Clay Sweetser <Varriount@users.noreply.github.com>
* fixes #19051 [backport:1.6] (#19133)Andreas Rumpf2021-11-121-1/+8
|
* fixes #19013 [backport:1.6] (#19111)Andreas Rumpf2021-11-091-0/+22
| | | | | * fixes #19013 [backport:1.6] * added test case
* change os.nim doc links to new style (#19102)Andrey Makarov2021-11-081-0/+6
|
* fixes another effect inference bug [backport:1.6] (#19100)Andreas Rumpf2021-11-072-0/+64
| | | | * fixes another effect inference bug [backport:1.6]
* manual: Document that comma propagates the default values of parameters (#19080)Kaushal Modi2021-11-031-0/+20
| | | | | | | | | | | | | * manual: Document that comma propagates the default values of parameters Fixes https://github.com/nim-lang/Nim/issues/15949. * Use the "bug #NNNN" comment syntax for consistency Ref: https://nim-lang.github.io/Nim/contributing.html#writing-tests-stdlib > Always refer to a GitHub issue using the following exact syntax: bug for tooling.
* manual: Document the use of `static` as a proc call (#19084)Kaushal Modi2021-11-032-0/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | * manual: Document the use of `static` as a proc call Also adds tests. Fixes https://github.com/nim-lang/Nim/issues/16987 . * Update doc/manual.rst Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com> * Use the "bug #NNNN" comment syntax for consistency Ref: https://nim-lang.github.io/Nim/contributing.html#writing-tests-stdlib > Always refer to a GitHub issue using the following exact syntax: bug for tooling. * manual: Undocument usage of foo.static foo.static and foo.static() are not expected to work. Ref: https://github.com/nim-lang/Nim/pull/19084/files#r741203578 Co-authored-by: konsumlamm <44230978+konsumlamm@users.noreply.github.com>
* Add test for issue 15435 (#19079)Kaushal Modi2021-11-031-0/+29
| | | | | | | | | * Add test for issue 15435 Closes https://github.com/nim-lang/Nim/issues/15435. * Specify bug # in comment Addresses https://github.com/nim-lang/Nim/pull/19079#discussion_r740279547
* tests: Fix warnings in tstrscans (#19082)Kaushal Modi2021-11-021-26/+34
|