Dominik Picheta
03ddfddcae
Add test for previous commit.
2017-04-17 20:04:24 +02:00
Dominik Picheta
793d6efffb
Fixes null handling for object refs in JSON unmarshal macro.
2017-04-17 18:43:31 +02:00
Dominik Picheta
2108dcf0d5
Fix JSON macro bug with ref objects.
2017-04-17 18:01:38 +02:00
Dominik Picheta
88cb40cd31
Implement support for enum fields in JSON macro.
2017-04-09 17:22:40 +02:00
Dominik Picheta
eedc6fecd7
Document to macro in JSON and add example.
2017-04-09 12:48:07 +02:00
Dominik Picheta
a883424d0d
Implements else branch for JSON unmarshalling of object variants.
2017-04-09 11:49:50 +02:00
Dominik Picheta
658467a31f
Improve error messages and add tests for the JSON macro.
2017-04-08 22:06:57 +02:00
Dominik Picheta
cc223ff7d8
Support int, string and bool fields in unmarshal json macro.
2017-04-08 21:23:35 +02:00
Dominik Picheta
12aafb25cc
First implementation of JSON unmarshal macro.
2017-04-08 20:55:32 +02:00
Anatoly Galiulin
3374bcb373
parsecfg: handle streams and strings when saving or loading configuration ( #5554 )
2017-04-06 08:10:08 +02:00
Anatoly Galiulin
434a7c8426
Fix posix version of moveFile between different filesystems ( #5580 )
2017-03-23 23:40:03 +01:00
Ruslan Mustakov
310b73b556
Reduce the scope of stackTrace var ( #5583 )
...
Fixes #5571 .
2017-03-22 01:06:05 +01:00
Parashurama
976095c894
add bitops module for optimized bit manipulation. ( #5201 )
2017-03-14 21:32:54 +01:00
c-blake
d59441340d
Fixes incorrect fd==0 test on Unix; Conserves handles by default. ( #5512 )
...
* Fix 2 problems. First, 0 is a valid fd on Unix (easily gotten if user first
closes all fds and then starts using memfiles). Use -1 instead for an invalid
fd. Second, it is best practice to conserve open fds on Unix and file handles
on Windows. These handles are not needed unless the user wants to remap the
memory with ``mapMem`` (or a hypothetical future ``proc resize``). Adding a
new bool param ``allowRemap=false`` to ``memfiles.open`` solves this cleanly
in a "mostly" backward compatible way. This is only "mostly" because the
default ``false`` case does not keep unneeded resources allocated, but that
most sensible default means that any ``mapMem`` callers need to fix all their
open calls to have allowRemap=true, as this PR also does for tmemfiles2.nim.
* Include backwards compatibility note.
2017-03-12 20:45:10 +01:00
Florent
93305443aa
close #5472 nre tests should be run ( #5474 )
...
nre tests were just being compiled - changed so that a failure causes exit code to defer causing `tester` to report it as a failure
2017-03-04 11:13:08 +01:00
Florent
f7af16a1c9
More robust tests for #5453 ( #5469 )
2017-03-03 01:30:49 +01:00
Florent
34a3d40d18
fixes #5444 - nre.findIter keeps searching when no match is possible ( #5453 )
2017-03-02 11:48:41 +01:00
Federico Ceratto
dd4d47c671
Add gethostname to nativesockets ( #5443 )
2017-03-01 09:44:24 +01:00
Andreas Rumpf
e5341a391d
Merge pull request #5373 from nim-lang/feature/async-streams
...
Async streams and HTTP client streaming downloads support
2017-02-26 17:35:08 +01:00
Fabian Keller
f250c30b9d
Make use of used in unittest ( #5410 )
2017-02-25 21:18:16 +01:00
Araq
1961e444c3
Merge branch 'devel' into feature/async-streams
2017-02-25 11:18:48 +01:00
Anatoly Galiulin
279e4b0451
Fixes #5382
2017-02-13 13:35:40 +01:00
Dominik Picheta
f9f86899b5
Implement streamed async/sync downloadFile and deprecate old one.
2017-02-11 14:00:53 +01:00
Dominik Picheta
1b4067a81b
Implement streamed body reading in httpclient.
2017-02-11 12:43:16 +01:00
Araq
794d36cf31
fixes #5349
2017-02-08 14:33:05 +01:00
Parashurama
c57fcf42df
fix string slice & splice ( #5311 )
...
code fixes courtesy of @memophen
2017-02-01 12:13:01 +01:00
Ruslan Mustakov
35d48765fb
Use onThreadCreation to set default SSL context for each thread ( #5265 )
...
Fixes : #4998
2017-01-23 21:04:14 +01:00
Araq
cdebcf23d9
new segfaults.nim stdlib module works on Windows
2017-01-20 17:08:11 +01:00
Andreas Rumpf
7ff80cc8b2
first implementation of segfaults stdlib module
2017-01-20 12:40:54 +01:00
Parashurama
d04ca6ef23
Improve & optimize strutils 'find' procs ( #5196 )
...
* add 'last' argument to 'find' procs in strutils
* add 'rfind' proc for looking up set[char] in strutils
* use optimised C function 'memchr' when available
2017-01-11 09:48:31 +01:00
Andreas Rumpf
013e11fcc4
add copyDir stdlib test
2017-01-10 11:27:03 +01:00
Chris Heller
af63bd4e0b
Update unit test to handle AssertionError instead of ValueError for #5119
2016-12-21 19:06:11 -08:00
Chris Heller
40d034b7e3
Guard against calling split with an empty string as a separator. Fixes #5119
2016-12-21 12:06:59 -08:00
Araq
7f8a02d0c6
make tos.nim green on Windows
2016-12-13 09:01:53 +01:00
Dominik Picheta
d6ab21eed5
Merge pull request #5080 from FedericoCeratto/httpheaders
...
Add HTTP header deletion, improve tests
2016-12-01 18:01:04 +01:00
Federico Ceratto
74e442f766
Add HTTP header deletion, improve tests
2016-12-01 00:11:59 +00:00
Dmitry Polienko
6bd86f7543
Rewrite xmltools.innerText
...
Make it recursive, define for node types other than xnElement
2016-11-30 10:38:22 +07:00
Ruslan Mustakov
2c146445bc
Added deques module, deprecating queues
2016-11-24 19:11:51 +07:00
Felix Krause
434c27343e
Parse 'Z' as valid timezone if offset is expected
2016-11-14 18:46:35 +01:00
Felix Krause
aa08c32c2b
Improved -; fixed tests
...
* added prefix `-` operator for TimeInterval
* improved `-` for both TimeInterval and TimeInfo
* Fixed a DST test
2016-11-14 18:28:55 +01:00
Felix Krause
544a2cfe1a
Fixed daylight saving time
...
* When formatting timezone, substract 1 hour from timezone when isDST
* Do not depend DST in current timezone when parsing arbitrary date
because formatted timestamps are never in DST.
* On the way, removed an unnecessary line in parsing code which could
cause bugs.
* Added DST tests
2016-11-14 18:28:55 +01:00
Felix Krause
91a0674961
Fixed timezone rendering, added test
2016-11-10 19:03:46 +01:00
Andreas Rumpf
4c79583a95
Merge pull request #5002 from goldenreign/time-compare-nosideeffect
...
Add 'noSideEffect' pragma for Time type's operators. Fixes #4981
2016-11-07 16:52:34 +01:00
goldenreign
554105ff7c
Add 'noSideEffect' pragma for Time type's operators
2016-11-07 12:14:28 +07:00
Felix Krause
9d5de8021b
Use ISO 8601 format for times.$. Fixed tests.
...
* `$` now uses format() with explicit time zone.
* Fixed errors in rendering "z", "zz" and "zzz"
* Updated tests
2016-11-01 21:14:52 +01:00
Felix Krause
170745eb39
Removed tzname because it's broken
...
* No mapping between TimeInfo.tzname and TimeInfo.timezone
* tzname of time.h is not well-defined, may have almost arbitrary
length, and localization may differ
* Code used hardcoded "UTC" string
2016-11-01 20:26:50 +01:00
jlp765
55b28f86e1
add test: echo a seq with a nil value
2016-11-01 13:41:31 +10:00
Andreas Rumpf
2f725e923e
Merge pull request #4924 from nigredo-tori/fix-4917
...
Make createDir return discardable bool
2016-10-24 20:30:52 +02:00
Araq
a85e954b5d
make tgetfileinfo work on Windows
2016-10-24 20:18:49 +02:00
Araq
6d645e5240
Merge branch 'devel' of https://github.com/rudis/Nim into rudis-devel
2016-10-24 20:11:00 +02:00