Commit Graph

9356 Commits

Author SHA1 Message Date
Antonis Geralis
606aa45ec6 Export FileMode (#20726) 2022-11-02 10:52:15 +01:00
ringabout
59083e2e48 fixes ssl static link regression (#20722) 2022-11-01 13:34:58 +01:00
ringabout
75ece74bdd fixes #20526; use nimPreviewSlimSystem for documentation build (#20714)
* fixes #20526; use `nimPreviewSlimSystem` for `koch docs`

* fixes documentation errors

* fixes remaning issues
2022-11-01 12:53:14 +01:00
ringabout
07cf4486bc change include genode/env to an import (#20721)
* change `include genode/env` to an import 

ref 0b262e9496 (diff-8718bd20d8f61d6638d3d64b19efc31bcd40a6d5be8215b2a1f0b75ed93e8d56)

* fixes comments
2022-11-01 18:18:06 +08:00
ringabout
6166b796ba refactor os imports into corresponding small modules (#20720) 2022-11-01 10:18:04 +01:00
ringabout
d735c447d3 make system/fatal importable (#20719) 2022-11-01 07:56:32 +01:00
Juan Carlos
2f6e06d224 Improve dollar (#20672)
* Improve dollar for uri

* Refactor

* .

* .

* verde

* optimize

* https://github.com/nim-lang/Nim/pull/20672#issuecomment-1295440246 [skip ci]

* https://github.com/nim-lang/Nim/pull/20670#issuecomment-1295937393

* ci

* Update lib/pure/uri.nim

Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
2022-10-31 15:37:09 -04:00
Juan Carlos
229f146280 Improve getDataUri (#20670)
* Improve getDataUri

* Restart ci

* https://github.com/nim-lang/Nim/pull/20670#issuecomment-1295937393
2022-10-31 15:34:17 -04:00
ehmry
0b262e9496 Genode: add scheduleCallbacks to asyncdispatch (#20708)
* Genode: add native signal handler

* Genode: add scheduleCallbacks to asyncdispatch

This resolves some awkwardness where an RPC server may or may not
use callSoon while dispatching RPC but without scheduling timers
or I/O.
2022-10-31 19:24:57 +01:00
n5m
52166e3546 allow deferred close of nil stream (#20706)
* allow deferred close of nil stream

* improve example
2022-10-31 11:20:06 +01:00
ringabout
0a1f204f0f removes channels_builtin when enabling nimPreviewSlimSystem (#20713) 2022-10-31 16:56:05 +08:00
ringabout
e1ddd2d524 put std/threads under the umbrella of nimPreviewSlimSystem (#20711)
* put `std/threads` under the umbrella of `nimPreviewSlimSystem`

* add changelog

* fixes tests

* fixes tests again

* fixes tests
2022-10-31 06:36:50 +01:00
ringabout
fb2ec8d192 follow up #20668; fixes nightlies (#20701) 2022-10-31 06:33:07 +01:00
ringabout
1dab8ba334 move threads out of system (#20674)
* move syslocks first

* progress

* clean up

* go on

* clean up

* clean up

* add imports syslocks

* remove documentation

* public deallocOsPages

* fixes genode

* fixes more

* fixes boehmGC

* cover more cases

* fixes cyclic deps

* fixes genode

* cleanup

* unpublic fields

* cleanup

* clean up
2022-10-29 18:11:40 +02:00
Bung
534c97edc5 fix #16264 low(Time) OverflowDefect (#20552)
fix #16264 regression(0.18.0 => devel): import times; echo low(Time) gives OverflowDefect
2022-10-29 08:59:51 +02:00
Andrey Makarov
779b1cc5be Fix #20628 for Windows (#20667)
* Fix #20628 for Windows

* Move isRegular - !isSpecial and onlyRegular - skipSpecial

* Forgot to change it in 1 more place
2022-10-28 10:01:28 +02:00
metagn
e68a6ea759 openssl 3 support no longer opt in + some 1.0 support (#20668)
* Revert "Add OpenSSL 3 support (#19814)"

This reverts commit 2dcfd73260.

* openssl 3 support no longer opt in + some 1.0 support

* hopefully fix

* maybe fix

* final attempt

* actual fix hopefully
2022-10-27 17:24:26 +02:00
Jason Beetham
0b1989d736 Added openarray[char] overloads to std/unicode (#20648)
* Added openarray[char] overloads to std/unicode

Call substr instead of index slice inside unicode

Added substr overload for openarray for parity with string functionality

Made style checker happies and fixed overloads for substr

* Added update to changelog [skip ci]

* Inline unicode string operations

* Moved substr overload to unicode

Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
2022-10-27 14:16:41 +02:00
ringabout
c341f20476 cleanup os related documentation links (#20663)
cleanup documentation links
2022-10-27 12:16:27 +02:00
Juan M Gómez
3b973f3fc8 fixes #20654 FAMs should not be used in the C++ backend (#20655)
* fixes #20654 FAMs should not be used in the C++ backend

* updates the test so it only affects clang
2022-10-25 17:39:51 +02:00
ringabout
69eaa4f14c clean up std/os related modules (#20651)
* clean up `std/os` related modules

* use `cmpPaths`

* reset

* cleanup
2022-10-25 17:56:11 +08:00
Saint
daf35c6d1b Change both code snippets to use the same test URL (#20647) 2022-10-25 09:40:57 +02:00
Andrey Makarov
8ed2431db0 Implement Unix file regularity check (#20448) (#20628)
* Implement Unix file regularity check

* update std/dirs also
2022-10-25 07:42:47 +02:00
Jason Beetham
ea0e45e62f Added 'openArray[char]' overloads to 'std/parseutils' (#20527)
* Added 'openarray[char]' overloads to 'std/parseutils'

* Removed redundant `start` and `last` params from slice using procs

* Fixed type for parseIdent overload

* fixed one by off with 'substr'

* removed missed start parameters for procedures

* Added 'openarray[char]' overloads to 'std/parseutils'

* Removed redundant `start` and `last` params from slice using procs

* Fixed type for parseIdent overload

* fixed one by off with 'substr'

* removed missed start parameters for procedures

* Fixed VM op to work with new 'opcSlice'

* Corrected captureBetween's logic to work with openarray

* js sys's parsefloat logic now uses openarray

Co-authored-by: Clay Sweetser <Varriount@users.noreply.github.com>
2022-10-24 14:50:54 -04:00
Jake Leahy
eed1b6df20 Add better error messages to std/jsonutils (#20629)
* Add better error messages

* Add fmt on tuple msg
2022-10-24 12:57:48 -04:00
Jacek Sieka
e2f412145f fix fwrite prototype (#20644)
* fix fwrite prototype

* Update lib/std/syncio.nim

Co-authored-by: ringabout <43030857+ringabout@users.noreply.github.com>

Co-authored-by: ringabout <43030857+ringabout@users.noreply.github.com>
2022-10-24 17:25:34 +02:00
ringabout
878919a4df fixes the typical (not a == b) bug in the documentation (#20643)
* fixes the typical (not a == b) bug; uses runnableExamples

* cannot add runnableExamples
2022-10-24 15:20:57 +02:00
Jake Leahy
d261135c5c Fix tuple size check in std/jsonutils (#20637)
* Add test for tuple being invalid size

* Test tuple size before accessing fields

* Fix formatting for import

* Fix not being able to build from csources_v1

Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
2022-10-24 17:17:14 +08:00
Jake Leahy
69cb671d8d Pass json options to hooks (#20638)
* Added tests

* Fix expected string

* Allow hooks to take an optional parameter that is the current options

* Add options to hooks for other generic types

* Fix doc links
2022-10-24 08:14:17 +02:00
Tanguy
4578e773ce Remove side-effects from sysFatal with panics on (#20632) 2022-10-24 07:57:49 +02:00
ringabout
c75cfb363f improve error message when using toTask with a call with a return value (#20622) 2022-10-23 08:27:34 +02:00
ringabout
9361938ccd add std/appdirs (#20618) 2022-10-22 13:42:46 +02:00
ringabout
3c12b72168 add typesafe std/paths, std/files, std/dirs, std/symlinks (#20582)
* split std/os; add typesafe std/paths
* add more files, dirs, paths
* add documentation
* add testcase
* remove tryRemoveFile
* clean up
* Delete test.nim
* apply changes
* add `add` and fixes
2022-10-21 21:53:44 +02:00
Amjad Ben Hedhili
5b195ab0f0 Add safe parameter to base64.encodeMime (#20559)
* Improve `encodeMime` signature

* `string` to `openArray[char or byte]`
* `safe` parameter

* Fix

* Revert "Fix"

This reverts commit a394c505c2.

* Remove encodeMime's openArray overload

* Document the `safe` parameter

* Add changelog entry
2022-10-21 09:25:25 +02:00
ringabout
ff2cb113ad move procs in os to appdirs (#20605)
* move procs in os to `appdirs`

* Update lib/std/private/osappdirs.nim
2022-10-20 23:14:50 +02:00
ringabout
f6a002c8a5 [std/os] split and re-export (#20593)
* [std/os] split and export
* move to private modules
* fixes docs and tests

Co-authored-by: xflywind <43030857+xflywind@users.noreply.github.com>
2022-10-20 07:58:29 +02:00
ringabout
b07526b2c7 refactor envvars, oserrors; register vmops (#20592)
* refactor envvars, oserrors; register vmops

* remove type definitions
2022-10-18 19:44:26 +02:00
Andreas Rumpf
81087c949f fixes #20572 (#20585)
* fixes #20572

* added a test case
2022-10-17 23:48:51 +02:00
ringabout
c0824b9b80 [std/os clean up] import and export osseps (#20580)
import and export osseps
2022-10-17 20:29:00 +02:00
Juan Carlos
b7f1757952 Documentation only, dom (#20584)
Add docs to dom
2022-10-17 20:01:08 +02:00
Antonis Geralis
ed26156c99 atomicInc global alloc counters (#20571) 2022-10-16 01:07:22 +02:00
ringabout
1e15f975b8 fixes #19162; enable strictEffects for v2 (#19380)
* enable stricteffects
* add gcsafe
* fix tests
* use func
* fixes pegs tests
* explicitly mark repr related procs with noSideEffect
* add nimLegacyEffects
* change URL
* fixes docopt
* add `raises: []` to repr
* fixes weave
* fixes nimyaml
* fixes glob
* fixes parsetoml
* Apply suggestions from code review
* Update testament/important_packages.nim
* add legacy:laxEffects
2022-10-15 14:07:40 +02:00
Andreas Rumpf
07b645342a fixes #3748 (#20563)
* fixes #3748

* fix the regression

* don't use the new allocator for the SSL wrapper

* fixes regression
2022-10-14 12:00:38 +02:00
ringabout
be18f4e513 follow up #19714; add memmem optimizations for find on Linux, Macos and BSDs (#20556)
* fixes tests

* add memmem optimization for find

* fixes

* ty[o

* fixes `"abc".find("") == 0 doesn't work on macOS

Co-authored-by: xflywind <43030857+xflywind@users.noreply.github.com>
2022-10-13 23:58:59 +02:00
Andrey Makarov
19ff746916 Markdown code blocks migration part 7 (#20547) 2022-10-12 16:13:43 +02:00
ringabout
13b3ea71da oids sticks to 24 length strings; fixes breaking changes (#20546)
oids sticks 24 length strings
2022-10-12 15:15:21 +02:00
ringabout
5602183234 'lock levels' are deprecated, now a noop (#20539)
* 'lock levels' are deprecated, now a noop

* fixes tests
2022-10-11 09:17:09 +02:00
ringabout
e290b028ab Make rstgen work with gcsafe (#20534)
* Make rstgen work with gcsafe

Co-authored-by: Danil Yarantsev <tiberiumk12@gmail.com>

* add tests and fixes

* if nimHasWarningAsError

Co-authored-by: Danil Yarantsev <tiberiumk12@gmail.com>
2022-10-10 18:56:01 +02:00
Amjad Ben Hedhili
944e4cf585 Remove unused base64.encode overload (#20369)
* Remove unused `base64.encode` overload

* [skip ci] Remove commented code

* [skip ci] var -> let

* [skip ci] Remove mentions of the string overload

* Remove `SomeInteger` overload

* Fix CI

* Fix CI

* Deprecate `SomeInteger` overload

* [skip ci] Add changelog entry

* Revert "Remove `SomeInteger` overload"

This reverts commit 79a2963a21.

* Revert "[skip ci] Add changelog entry"

This reverts commit 186f17eb39.

* Revert "Revert "Remove `SomeInteger` overload""

This reverts commit 8005318ee4.

* Update lib/pure/base64.nim

Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
2022-10-09 15:54:21 -04:00
ee7
5661edd75a parseutils: skipWhile: fix parameter name in doc comment (#20523) 2022-10-09 19:32:04 +08:00