Commit Graph

7812 Commits

Author SHA1 Message Date
Andreas Rumpf
7f377da1d2 fixes #14370 (#14371) 2020-05-16 17:03:25 +02:00
Dominik Picheta
7361e2627b Emscripten: disable epoll (#14361)
Epoll is not supported by epoll.
2020-05-16 15:50:41 +02:00
Bung
390ff428f0 add SqlPrepared api fix #13559 (#14365)
Co-authored-by: bung87 <crc32@qq.com>
2020-05-16 15:50:04 +02:00
Timothee Cour
c777f2fb60 fix some issues with --backend (#14363)
* fix some issues with --backend
* fix https://github.com/timotheecour/Nim/issues/175; improve upon #14306
2020-05-16 13:09:18 +02:00
Kaushal Modi
bf0e1c696f Remove the uses of {.procvar.} pragma (#14359)
This pragma did nothing.

Ref:
- https://github.com/nim-lang/Nim/issues/2172#issuecomment-383276469
- https://github.com/nim-lang/Nim/issues/12975
2020-05-15 23:37:24 +02:00
Bung
ce0552c100 fix #9771 (#14357)
* fix #9771
* map SQLLEN SQLULEN
* fix proc params take TSqlLen

Co-authored-by: bung87 <crc32@qq.com>
2020-05-15 21:00:06 +02:00
PMunch
13cfaf5fd5 Improve nimeval, changes some defaults (#14351)
* Improve nimeval, changes some defaults

This improves nimeval to make it easier to use NimScript as an embedded
scripting languages. It does change some of the defaults, so in case
anything used the old version and depended on the old behaviour these
would have to be changed.

* Remove dependency on nimhcr for nimscript
2020-05-15 19:32:52 +02:00
Kaushal Modi
a2a3fa1039 Fail quickly if re or nre module is attempted to be compiled with js [backport] (#14341)
Fixes https://github.com/nim-lang/Nim/issues/14338 .
2020-05-14 07:27:57 +02:00
Araq
8a339d1178 fixes #13862 2020-05-13 23:56:40 +02:00
Andreas Rumpf
79fe87500f fixes #13935 2020-05-13 22:17:38 +02:00
Araq
a3719df8b3 fixes #14331 2020-05-13 14:29:53 +02:00
Timothee Cour
041ee92bba osproc.execCmdEx now takes an optional input for stdin, env, workingDir (#14211)
* `osproc.execCmdEx` now takes an optional `input` for stdin

* execCmdEx now also takes an optional ``workingDir` and `env`
2020-05-13 13:45:36 +02:00
Araq
82f008158c cycle collector: make it threadsafe 2020-05-12 20:13:06 +02:00
Andreas Rumpf
06dfd31612 fixes #13881
* fixes #13881
* documented changed requirements for system.onThreadDestruction
* destructors.rst: update the documentation
2020-05-12 15:46:24 +02:00
Timothee Cour
b8ec07f19e properly fixes #13758 so that import std/macros stays legal (#14291)
* properly fix https://github.com/nim-lang/Nim/issues/12389
* use --lib:lib in koch.nim.cfg instead
* third time is the charm
2020-05-12 08:27:47 +02:00
Kaushal Modi
86669ef5b4 Make --backend:cpp|js work for :test: code-blocks as well (#14306)
Continues 9502e39b63

Ref:
- 9502e39b63 (commitcomment-39087584)
- https://github.com/nim-lang/Nim/pull/14278

Fixes https://github.com/nim-lang/Nim/issues/13129 .
2020-05-11 20:45:35 +02:00
slangmgh
76f7e95814 Fix #14289 (#14304) [backport] 2020-05-11 19:17:37 +02:00
Andreas Rumpf
0f344a70c9 fixes #13946 (#14302) 2020-05-11 19:12:40 +02:00
Andreas Rumpf
03c146cd93 do not track 'raise Defect' in the .raises: [] clause anymore (#14298)
* do not track 'raise Defect' in the .raises: [] clause anymore

* --panics:on maps 'raise Defect' to an unrecoverable fatal error

* make tests green again

* update the documentation too
2020-05-11 16:25:56 +02:00
Antonis
73c9d2c9d7 Fix for --styleCheck:error 2020-05-11 15:39:44 +02:00
Timothee Cour
9502e39b63 nim doc --backend:js, nim doc --doccmd:-d:foo, nim r --backend:js, --doccmd:skip + other improvements (#14278)
* `nim doc --backend:js|cpp...`
`nim doc --doccmd:'-d:foo --threads:on'`
`nim r --backend:cpp...` (implies --run --usenimcache)
* --usenimcache works with all targets
* --docCmd:skip now skips compiling snippets; 50X speedup for doc/manual.rst
2020-05-11 12:01:18 +02:00
Timothee Cour
d11cb9d495 fix a critical bug in windows.osproc leading to resource leaks and blocking IO [backport] (#14296) 2020-05-11 11:14:21 +02:00
Andy Davidoff
8018449319 simple typo in locks.nim (#14297) 2020-05-11 02:59:31 -04:00
Timothee Cour
411be506a3 --hint:processing (+friends) is now supported and means --hint:processing:on, like all other bool flags (#14271) 2020-05-08 18:54:16 +02:00
Andreas Rumpf
ce16115e79 Merge pull request #14265 from alaviss/quickfix
nativesockets: add missing inheritable pass-through
2020-05-08 17:33:38 +02:00
Clyybber
120ea906fb Fix #14270 and add testcases (#14276) 2020-05-08 15:54:34 +02:00
Leorize
73a42ce941 nativesockets: add missing inheritable pass-through 2020-05-07 14:43:53 -05:00
alaviss
1a1e9986a3 net: remove more erroneous set constructions (#14252) [backport]
Refs #13764
2020-05-07 13:37:54 +02:00
awr1
b70b8a7cdd Fix runnable examples for bitops (#14247) 2020-05-06 19:29:36 +02:00
awr1
b8e6ea7547 Added bitslice operations for bitops (#14016)
* added bit operations based on bit slices, clarified documentation, made non-mutating versions of mask ops
* Added since annotations, some runnable examples
* Added mask()/masked() functions, changed internal workings of mask ops to use new bit* funcs
* Changelog updated for new bitops improvements
* Reorganization, added runnable examples
* Documentation adjustments
* Add incltrl for since annotation
* Fix masked() impl
* Fix mask() return type
* Don't call toUnsigned on already unsigned types
* Remove improper `var T` for flipMasked()
* Fix return types for flipMasked()
* Slight syntactic cleanup for *masked ops
* Added tests for bitslice operations, new mask() operation, non-mutating mask ops
* Fix setmasked() var T issue
* More comprehensive tests
* Fix runnable example for bitsliced()
* Fix runnable example for mask()
2020-05-06 12:21:49 +02:00
Oscar Nihlgård
48e7775ad1 Make the fields of times.DateTime private (#14197)
* Make the fields of `times.DateTime` private

* PR fixes
2020-05-06 12:20:34 +02:00
Timothee Cour
c28a057a6b fix js stacktraces, unify all file,line,col formatting into a single function (#14230)
* fix https://github.com/timotheecour/Nim/issues/135 ; unify all file,line,col formatting into a single function
2020-05-05 14:56:15 +02:00
hlaaftana
6b7b5fb4fa Clarify JS cstring len (#14184) 2020-05-05 10:34:37 +02:00
cooldome
eefada8a88 fix #14217 (#14218)
* fix #14217

Co-authored-by: cooldome <ariabushenko@bk.ru>
2020-05-05 07:26:32 +02:00
Andreas Rumpf
64e839d5fd fixes #14209 [backport:1.2] (#14213)
* fixes #14209 [backport:1.2]
* improve stability
2020-05-05 00:48:13 +02:00
wltsmrz
c817e85f4c Linux updates (#14170)
* Add posix_memalign()

* Add linux-specific open() flags

O_TMPFILE: since Linux 3.11
O_PATH: since Linux 2.6.39
O_NOATIME: since Linux 2.6.8
O_DIRECT: since Linux 2.4.10

* Fix Stat type

* Fix POSIX AF_INET* const generation
2020-05-04 19:23:49 +02:00
PMunch
44f377ff5e Add procedures to read RSA keys from BIO format (#14223) 2020-05-04 19:23:11 +02:00
rockcavera
603010f8c9 Fixes net.recvFrom to work correctly with IPv6 (#14131)
* added high level sendTo and recvFrom to std/asyncnet; tests were also added.
* add .since annotation, a changelog entry and fixed to standard library style guide.
* fixes net.recvFrom to work correctly with IPv6
* raise if domain is not AF_INET or AF_INET6
* renamed template to adaptRecvFromToDomain()
2020-05-04 11:54:08 +02:00
Andreas Rumpf
a73d403901 sequtils refactoring: prefer typeof over type (#14212) 2020-05-04 11:18:29 +02:00
hlaaftana
3e060cfb0a => supports pragmas & names (+ changed behavior) (#14200)
* => supports pragmas & names (+ changed behavior)

(x, y: int) is now parsed as (x: int, y: int) instead of
(x: auto, y: int) inside => and ->.

* fix pragma check

* fixes, use since & LHS of -> supports pragmas
2020-05-03 10:22:49 +02:00
slangmgh
b56432bd8a fix #14203 (#14204) 2020-05-03 09:50:08 +02:00
slangmgh
d5c014e59b Fix #14151 (#14205) [backport] 2020-05-03 09:47:21 +02:00
slangmgh
b447ff7860 Fix #14201 (#14202) 2020-05-03 09:46:42 +02:00
hlaaftana
fbc97e712a move since from inclrtl to std/private/since (#14188)
* move since from inclrtl to std/private/since
* move since import in system below for HCR
2020-05-02 23:51:59 +02:00
Kaushal Modi
0880f118d3 Document that proc named fooTask is created for every foo task [backport] (#14187)
Ref: https://irclogs.nim-lang.org/01-05-2020.html#15:18:03
2020-05-02 17:50:27 +02:00
Miran
9c33bcac5c change 'iff' to 'if' to stop "corrections" once and for all (#14182) 2020-05-01 15:54:03 +02:00
hlaaftana
9b01c6cf48 discardable async procs are now an error (#14176)
* add discard warning in manual
2020-05-01 09:49:13 +02:00
rockcavera
33e9ac7cd3 fix sendTo and recvFrom in asyncnet (#14154)
* added high level sendTo and recvFrom to std/asyncnet; tests were also added.

* add .since annotation, a changelog entry and fixed to standard library style guide.

* Improved asserts msgs and added notes for use with UDP sockets

* pointers removed in parameters and fixes

* added .since annotation

* minor fixes
2020-04-30 22:50:37 +02:00
Andreas Rumpf
89be5be03e fixes #13698 [backport:1.2] (#14175) 2020-04-30 22:45:02 +02:00
Araq
3d2459bdc0 fixes the regression #12860 caused; hotfix 2020-04-30 20:23:53 +02:00