Commit Graph

7973 Commits

Author SHA1 Message Date
Hugo Granström
32ac1b7c9d fix #15033 (#15034) 2020-07-22 10:30:46 +02:00
Mildred Ki'Lya
503c5e0520 smtp: Fix STARTTLS, request HELO once TLS is established (#15032) 2020-07-22 00:30:33 -04:00
Miran
5fafa2fd5c fix several newline problems (#15028) [backend]
* prevent newlines where they shouldn't be
* 'contentLength' shouldn't be negative
2020-07-21 22:49:08 +02:00
genotrance
450a3e3179 Fix #2408 - add -d:globalSymbols (#14904) 2020-07-21 19:14:36 +02:00
Bung
64d629c617 Shadow Dom apis (#14979)
* shadow dom api

* fix typos

* host to Element type

* fix code style

* move elementsFromPoint to dom_extensions.nim
2020-07-21 19:11:12 +02:00
Andreas Rumpf
70acba7f0d readLine: Unicode support for Windows console (#14782)
* readLine: Unicode support for Windows console

When input is read from the Windows console, input encoding is UTF16. This is translated internally to UTF8.

* readLine: Remove recursive imports

* readLine: Fix issues with --gc:arc

**--gc:arc** defines **nimv2**. This changes the definition of **WideCStringObj**.
Also an empty string should be returned in case of EOF.
2020-07-20 14:39:27 +02:00
Andreas Rumpf
71dd5f85b9 'isolate' builtin; refs https://github.com/nim-lang/RFCs/issues/244 (#15011) 2020-07-20 07:50:19 +02:00
alaviss
bb1adf6a70 io: fix SetHandleInformation signature to match Windows' (#15017)
* io: fix SetHandleInformation signature to match Windows'

Fixes #14980

* rename Handle -> IoHandle because system.nim is a mess
2020-07-20 00:17:33 -04:00
Dominik Picheta
1e3a0ef1e1 [Backport] Fixes callbacks being dropped on Linux/macOS/BSD. (#15012)
Fixes #15003.

This is a serious bug which occurs when data cannot be read/sent
immediately and there are a bunch of other read/write events
pending. What happens is that the new events are dropped which
results in the case of the reported bug resulted in some data not
being sent (!).
2020-07-19 08:41:36 +02:00
Araq
ffe7b3a9bf threadpool.nim: minor code style changes 2020-07-18 21:40:57 +02:00
Andy Davidoff
ae358a0c7a fix docs for nativesocket read/write selects (#15010)
The sockets which *cannot* be _[read from or written to]_ will also be removed from ``readfds``.
2020-07-18 16:39:41 +02:00
Timothee Cour
169ca37d26 enable,document,test getImplTransformed, very useful for understanding how nim transforms code (#14924)
* enable,document,test getImplTransformed, very useful for understanding how nim transforms code
2020-07-18 10:49:36 +02:00
Tomohiro
c983466c15 Fix #14906 (#14949)
* Fix #14906 by wrapping outputStream with PipeOutStream

* Fix compile error when ./build_all.sh

* Use PipeOutStream on posix

* Fix compile error when build_all.sh

* Use ptr UncheckedArray

* Replace copyRefObj

* Remove tmp buffer from posPeekData

* Add more tests for outputStream

* Add comments about PipeOutStream.buffer

* Fix bug in posReadLine

* Move implementation of newPipeOutStream to streamwrapper module
2020-07-18 10:41:33 +02:00
cooldome
edbbbdf1a8 fix odbc regressions (#15009) [backport]
* fix odbc regressions

* make only necessary changes
2020-07-18 10:21:09 +02:00
Miran
c62513049c fix #14082, don't crash on incorrectly formatted input (#14977) [backport]
* fix #14082, don't crash on incorrectly formatted input

* address code review

* remove duplication
2020-07-17 10:59:53 +02:00
flywind
9fb7467fda fix #15006 (#15007) 2020-07-17 10:53:26 +02:00
Clyybber
282128ab66 Fix #14994 (#14996)
* Fix #14994

* Revert misplaced "optimization"

* Typo
2020-07-15 23:33:58 +02:00
Andreas Rumpf
c5358b0d4b An optimizer for ARC (#14962)
* WIP: an optimizer for ARC
* do not optimize away destructors in 'finally' if unstructured control flow is involved
* optimized the optimizer
* minor code cleanup
* first steps to .cursor inference
* cursor inference: big steps to a working solution
* baby steps
* better .cursor inference
* new feature: expandArc for easy inspection of the AST after ARC transformations
* added topt_cursor test
* adapt tests
* cleanups, make tests green
* optimize common traversal patterns
* moved test case
* fixes .cursor inference so that npeg compiles once again
* cursor inference: more bugfixes

Co-authored-by: Clyybber <darkmine956@gmail.com>
2020-07-15 23:00:06 +02:00
Clyybber
813dd1b670 repr_v2 improvements (#14992)
* Support proc in arc repr

* Typo

* Improve repr for strings and chars
2020-07-15 22:04:15 +02:00
flywind
c5f64f101b fix #13086 (#14987)
* fix #6608

* minor

* fix

* clean tests

* make testamnet happy

* again

* minor

* fix #13086
2020-07-15 03:46:17 -04:00
Juan Carlos
9465b5db44 Clean up macros (#14959) 2020-07-14 16:44:56 +02:00
Bung
f999f916f3 add missing props,procs (#14978) 2020-07-14 13:53:41 +02:00
Hendrik
9ed0dbfa6e fix index error (#14974)
Co-authored-by: Hendrik Albers <mail@hendrik.dev>
2020-07-14 13:15:22 +02:00
Timothee Cour
e07d661d16 fix #14475; unittest.require now works with nim c; require and check now works with -d:nodejs (#14676)
* fix #14475; make unittest work with -d:nodejs

* fixup

* fixup

* disable inim, delaunay which failed after unittest.require got fixed

* re-enable tests that have been fixed
2020-07-14 13:14:32 +02:00
Miran
f4f21c89e5 asyncftpclient.nim - don't assume a sufficiend line length (#14973) 2020-07-14 02:18:02 -04:00
Andreas Rumpf
6cc0061a72 optimize the new nimPrepareStrMutationV2 with inlining (#14969) 2020-07-12 16:50:56 +02:00
flywind
9ec9a31f46 Fix #12759 (#14967)
* add testcase for #5926

* fix #12759
2020-07-12 03:31:03 -04:00
Clyybber
4a1128d16c Move wasMoved out of =destroy 2020-07-10 13:36:02 +02:00
treeform
399b2e3134 Add missing dom.nim things (#14944) 2020-07-09 09:18:27 +02:00
flywind
3db6d9ea0c add docs and more tests for debug format strings (#14861)
* add debug format string

* remove try except

* add changelog

* add docs and more tests

* Update lib/pure/strformat.nim

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

* minor

Co-authored-by: Juan Carlos <juancarlospaco@gmail.com>
2020-07-08 22:21:30 +02:00
Miran
3de5296337 remove a condition that table size must be passed as power of 2 (#14926)
* remove a condition that table size must be passed as power of 2
* remove power-of-2 condition from sets and sharedtables
* remove power-of-2 condition from deques
* use 'correctSize' for both branches
* prettify changelog.md and fix typos
* add a changelog entry
* fix double-call of 'right-size'
* fix the same thing in sets.nim
* introduce a new internal proc `slotsNeeded`

Deprecate the public proc `rightSize`, which is not needed anymore.
Now it is an identity function, allowing the old code to work
correctly and without extra allocations.
2020-07-08 15:01:47 +02:00
Andreas Rumpf
87f6a9592c fixes #14402 (#14908)
* fixes #14402

* added a test case
2020-07-08 08:21:55 +02:00
narimiran
e82a14b273 fix mistake in times.nim docs 2020-07-07 22:57:06 +02:00
Dominik Picheta
25ceacbe4f Revert commit 3e843ab335. Closes #14930. 2020-07-07 19:18:02 +01:00
ee7
a754160d65 tables.nim: Add named fields in smallest and largest (#14919)
The `smallest` and `largest` procs for `CountTable` returned a tuple
with named fields, but the same procs for `CountTableRef` returned an
anonymous tuple.

This commit makes those `CountTableRef` procs more consistent, and adds
a test.

Fixes: #14918
2020-07-06 14:02:03 +02:00
Araq
6f962a4b36 fixes #14830 2020-07-06 13:41:56 +02:00
narimiran
46aacf917f Fix style inconsistencies due to the previous commit 2020-07-06 11:24:43 +02:00
narimiran
ebaf603c84 revert 0944b0f4 2020-07-06 10:55:51 +02:00
Juan Carlos
21b3ca636f Fix logging tiny bug (#14910)
* Fix logging tiny bug

* Update changelog.md

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

* Update changelog.md

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

* Update changelog.md

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

* https://github.com/nim-lang/Nim/pull/14910#discussion_r450012032

Co-authored-by: Danil Yarantsev <tiberiumk12@gmail.com>
2020-07-06 04:00:25 -04:00
Timothee Cour
695154970d deprecate existsDir; use dirExists instead (#14884) 2020-07-03 23:04:23 +02:00
Juan Carlos
4f6acf24ff Add jsre (#14870) 2020-07-03 20:13:10 +02:00
Timothee Cour
dc5a40f3f3 {.deprecated: [existsFile: fileExists].} (#14735)
* {.deprecated: [existsFile: fileExists].}

* s/existsFile/fileExists/ except under deps

* workaround pending #14819

* fix test
2020-07-02 16:19:13 +02:00
Juan Carlos
d590611fc5 Clean out sharedlists (#14857) 2020-07-02 08:40:58 +02:00
Juan Carlos
cbcaf2bbc4 Clean out strutils (#14859)
Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
2020-07-01 23:16:50 +02:00
Timothee Cour
2867a33ebc fix #14846; add macros.extractDocCommentsAndRunnables (#14849)
* fix #14846; add macros.extractDocCommentsAndRunnables

* fixup

* update tests

* address comment
2020-07-01 09:26:23 +02:00
Juan Carlos
05384efec5 Clean out sharedtables (#14858)
Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
2020-06-30 19:09:13 +02:00
Juan Carlos
a519f3b038 Removed asyncdispatch.newAsyncNativeSocket, was deprecated since 0.18 (#14854)
Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
2020-06-30 16:29:53 +02:00
alaviss
56b3d422b0 typetraits: features and fixes (#14791)
* typetraits: add support for nnkTypeOfExpr

* typetraits: don't wrap typedesc symbols in StaticParam

* typetraits: add nested generics support to genericParams

* typetraits: make genericParams understand array[I, T] whackiness

Also moved tests to ttypetraits

* typetraits: clarify comment on genericParams
2020-06-30 15:25:53 +02:00
Ray Imber
36fa79a524 Fix asyncdispatch drain behavior (#14820) (#14838)
* Fix asyncdispatch drain behavior (#14820)

* Changed test to use asyncCheck instead of discard after code review (#14820)

* Added some debug statements to help understand what is happening in Azure.

* Removed debug statements and increased timeouts by 1 order of magnitude to account for slow Azure VMs

Co-authored-by: Ray Imber <ray@crankuptheamps.com>
2020-06-30 15:23:53 +02:00
flywind
8be54b8fa7 add debug fmt string like python's (#14808)
* add debug format string

* remove try except

* add changelog
2020-06-30 15:21:37 +02:00