Commit Graph

6563 Commits

Author SHA1 Message Date
Araq
ac8274c60f fix merge conflict 2018-12-12 17:51:33 +01:00
Araq
eb8383cb28 move diff.nim to experimental 2018-12-12 17:48:30 +01:00
Andreas Rumpf
9f453592a4 Merge pull request #9552 from recloser/strmisc-doc
Add runnableExamples for strmisc procs and a better doc for expandTabs
2018-12-12 16:32:09 +01:00
Andreas Rumpf
a1bf9fd2b6 Merge branch 'devel' into sorted_deduplicate 2018-12-12 16:29:46 +01:00
Araq
f080a15da1 diff.nim: massive code cleanups 2018-12-12 16:17:35 +01:00
Araq
9ce21bb8de Merge branch 'std-diff' of https://github.com/krux02/Nim into krux02-std-diff 2018-12-12 15:43:03 +01:00
Araq
f828e5da49 clean up the implementation of the new memfiles.resize 2018-12-12 12:10:17 +01:00
Araq
77a884f178 export every field of MemFile for more low level trickery; refs #9922 2018-12-12 12:03:57 +01:00
Andreas Rumpf
cddc4be209 Merge pull request #9922 from c-blake/devel
Let handles be seen outside of `memfiles` module so that "updating"
2018-12-12 12:00:12 +01:00
Flaviu Tamas
c0a47f7e22 Rework nil/option for nre in light of ""==nil
Fixes #9243
2018-12-11 22:15:57 +00:00
Flaviu Tamas
22b3e9df27 Revert 7f49364fd0 for nre 2018-12-11 22:15:02 +00:00
Andreas Rumpf
5dc83d0c8f cleanup of excpt.nim 2018-12-11 23:04:49 +01:00
Andreas Rumpf
239846a528 Merge pull request #9805 from pacien/181126-list-append
add SinglyLinkedList.append procs
2018-12-11 22:18:40 +01:00
Andreas Rumpf
e3d91a5b74 Merge pull request #9923 from stefantalpalaru/calldepth
replace misleading "stack overflow" message when reaching Nim's call depth limit
2018-12-11 22:07:44 +01:00
Andreas Rumpf
bb1ce398af Merge pull request #9881 from timotheecour/pr_ref_9880
refs #9880 show index and bound in lots of `index out of bounds` errors
2018-12-11 21:49:08 +01:00
Araq
3b783f7e13 Testament: refactoring; makes the test joiner green 2018-12-11 21:23:23 +01:00
Arne Döring
199018ef2e test can fail because of invalid spec 2018-12-11 21:23:20 +01:00
Charles Blake
b92594572e For now just implement resize per https://github.com/nim-lang/Nim/pull/9922
discussion (with special mremap usage on Linux, but ordinary munmap, mmap on
other POSIX).  Someone needs to do the when windows branch.
2018-12-11 14:57:28 -05:00
Charles Blake
369ac2dd2d Address dom96/Araq opinions in https://github.com/nim-lang/Nim/pull/9922
Updating accessors are also provided since the idea of this change is to
allow "updating" operations external to the module which are by their very
nature closely tied to module internals (as well as to OS interface details).
2018-12-11 10:27:27 -05:00
Andreas Rumpf
3177aee75f Merge pull request #9910 from nc-x/fix-semicolon
Fixes #9907
2018-12-11 12:26:23 +01:00
Neelesh Chandola
5aba5875da Address Comments 2018-12-11 10:44:43 +05:30
Ștefan Talpalaru
497e8c41e8 replace misleading "stack overflow" message on call depth limit
The new error message looks like this:
"Error: call depth limit reached in a debug build (2000 function calls).
You can change it with -d:nimCallDepthLimit=<int> or switch to a release
build with -d:release."
2018-12-10 19:35:37 +01:00
Charles Blake
740c5b13ea Let handles be seen outside of memfiles module so that "updating"
operations (like eg., resizing a file and re-mapping) do not need
to worry about race conditions of re-opened paths, renamed parent
directories and that sort of thing.  Operating directly on already
open handles is both safer and more efficient than relying upon the
stability of filesystem paths.
2018-12-10 11:40:08 -05:00
Timothee Cour
f3ecc15a94 refs #9880 show index and bound in lots of index out of bounds errors 2018-12-09 16:50:45 -08:00
Andreas Rumpf
981dcc6b9a Merge pull request #9890 from nim-lang/remove-asynccommon
Merge async common into asyncdispatch.
2018-12-09 13:00:10 +01:00
Neelesh Chandola
abdfbd07a5 Fixes #9907 2018-12-09 10:35:30 +05:30
Oscar Nihlgård
0a749f1a37 Make options.UnpackError inherit from system.Defect 2018-12-08 10:04:53 +01:00
Dominik Picheta
775bfb3e8d Merge async common into asyncdispatch. 2018-12-07 22:47:10 +00:00
Arne Döring
43ea41bdf4 added lib/std/diff.nim 2018-12-07 16:21:50 +01:00
data-man
a38f353597 Add the parameter isSorted for the sequtils.deduplicate 2018-12-07 02:17:40 +05:00
Andreas Rumpf
160a034643 Merge pull request #9803 from GULPF/walkdirrec-relative
Add `relative` parameter to walkDirRec
2018-12-06 09:29:35 +01:00
Timothee Cour
14223c4b7f Update parseutils.nim 2018-12-05 11:27:22 -08:00
Araq
24106ade8f hotfix: discriminants can be of size 8 bytes [backport] 2018-12-05 09:43:59 +01:00
Andreas Rumpf
d215296497 Merge pull request #9846 from timotheecour/pr_getpid
add os.getCurrentProcessId()
2018-12-05 08:12:17 +01:00
Andreas Rumpf
88dcad7c01 Merge pull request #9862 from zevv/posix-cmsg
Added CMSG_SPACE and CMSG_LEN macros to posix.nim
2018-12-05 08:11:27 +01:00
Araq
633832d0de times.nim: Minor formatting change in the example code 2018-12-04 22:41:06 +01:00
Ico Doornekamp
c37fdbf843 Added CMSG_SPACE and CMSG_LEN macros to posix.nim 2018-12-04 21:17:22 +01:00
rec
e3e5ae287f Fix fat pointers, object copying, magic double evals on JS (#9411) [backport]
* Add a test for issue #9389

* Fixes #9389.

* Make object contructors copy objects properly by checking whether the expressions passed to them don't need to be copied.
* Make mArrToSeq implementation actually check if a copy needs to be made.

* Avoid unnecessary copy in mChr impl

* Assume set constructor elements need no copy

* Add a test for issue #9410

* Add a test

* fix passing fat pointers (#9410)

* Enhance tests

* More tests and fixes

* Add more (failing) tests [ci skip]

* Added equality operator for fat pointers, more tests and fixes

* Fix printing uninitialized strings

* Fix mInc, mDec double eval, add more tests

* Tests

* Refactored, fixed multiple evals, revamped the tests, added missing ops

* Fix ups

* Fix #9643 and #9644

* add pointer normalization
2018-12-04 12:04:27 +01:00
Timothee Cour
e4850b7f1c address comments 2018-12-04 02:51:27 -08:00
Timothee Cour
c0a91970f2 fixup 2018-12-04 00:45:58 -08:00
Timothee Cour
53147cc546 fixup 2018-12-03 14:25:04 -08:00
Timothee Cour
af7d758cfc address comments 2018-12-03 14:03:06 -08:00
Timothee Cour
0caab530fb fixup 2018-12-03 12:51:28 -08:00
Timothee Cour
e7ab4817e2 fixup 2018-12-03 12:46:32 -08:00
Timothee Cour
b93fbcf09a add osproc.processID() 2018-12-03 12:04:46 -08:00
Andreas Rumpf
350396e1ca gc:destructors: more progress 2018-11-29 20:10:52 +01:00
Andreas Rumpf
7d82df20be gc:destructors further progress 2018-11-29 01:13:32 +01:00
Timothee Cour
ab38c075f8 add: proc deepCopy*[T](y: T): T (#9740) 2018-11-28 08:46:22 +01:00
pacien
4e483bb01a add SinglyLinkedList.append procs 2018-11-27 10:34:34 +01:00
Andreas Rumpf
8990764709 some progress on --gc:destructors 2018-11-27 00:36:29 +01:00