Araq
24106ade8f
hotfix: discriminants can be of size 8 bytes [backport]
2018-12-05 09:43:59 +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
ab38c075f8
add: proc deepCopy*[T](y: T): T ( #9740 )
2018-11-28 08:46:22 +01:00
Andreas Rumpf
eb919c35b2
fixes #9675
2018-11-26 10:41:26 +01:00
Ștefan Talpalaru
f8fa94cb20
fix segfault when calling shallow() on an empty string ( #9782 ) [backport]
...
shallow() casts its string argument to a seq and then tries to access
its fields. Guess what happens when that string is nil, which seems to
be the representation of an empty string (both the default value and an
explicitly assigned "").
Segfault encountered when running "ntags -R ." on a large project. The relevant line:
a1c62c38e5/ntags.nim (lines-125)
2018-11-22 14:47:27 +01:00
ishowta
6ff596d4f8
Empty check in shallow [backport] ( #9676 )
2018-11-21 11:56:38 +01:00
Araq
3f6168b337
removes deprecated T/P types
2018-11-16 13:27:56 +01:00
Mamy Ratsimbazafy
b65c0c336c
Inline generic min and max - https://github.com/nim-lang/Nim/issues/9514 ( #9688 )
2018-11-14 12:37:46 +01:00
Arne Döring
6a57ec6d2e
NaN fixes for clang backend ( #9652 )
2018-11-08 20:17:37 +01:00
Andreas Rumpf
b4f16fab49
Nim devel is version 0.19.9
2018-11-03 12:45:55 +01:00
Araq
1dd1d66f16
system.nim: workaround for the fixed documentation generator
2018-10-30 21:58:59 +01:00
Araq
05964b95e4
change system.nim to adhere to the style guide
2018-10-30 15:03:28 +01:00
Araq
f6def4286c
fixes #8603
2018-10-30 11:28:45 +01:00
narimiran
80b78b50d0
more examples for mod and div, plus corrections [ci skip]
2018-10-28 22:37:58 +00:00
Mamy Ratsimbazafy
5b97762787
Openmp parallel iterator improvements ( #9493 )
...
* More flexibility in OpenMP pragma
* Use static to constrain to compile-time annotation string
* Update changelog with OpenMP change
2018-10-25 18:09:35 +02:00
Andreas Rumpf
223e92b83a
stdlib: documenation updates, the exception names have been changed
2018-10-25 07:42:45 +02:00
Araq
963292f725
added system.typeof operation; fixes #9093
2018-10-24 17:09:51 +02:00
Araq
8252c65cf2
system.nim deprecate 'getRefcount'; refs #2839 , refs #3713
2018-10-15 10:54:20 +02:00
Araq
fe091997aa
system.nim: fixes typo
2018-10-15 02:38:04 +02:00
Timothee Cour
745f1642d6
implement sizeof and alignof operator (manually squashed #5664 ) ( #9356 )
2018-10-14 00:52:28 +02:00
Timothee Cour
3e2d8c1c53
correctly render AST in doAssert/assert condition: fixes #8518 ; refs #9301 ( #9332 )
...
* fixes #8518 ; refs #9301 ; correctly render AST in doAssert condition
2018-10-14 00:17:10 +02:00
Timothee Cour
ef820769a4
deprecate accumulateResult => sequtils.toSeq ( #8666 )
2018-10-13 09:23:33 +02:00
c-blake
1b3725e395
Add toOpenArray[T](ptr UncheckedArray[T]) for clarity. ( #9316 )
...
* Add `toOpenArray[T](ptr UncheckedArray[T])` for clarity. `ptr array[0,T]`
for some unchecked type already works but A) `UncheckedArray` seems to be
the intended future way for this kind of access, and B) essentially all use
cases will have a `ptr` for that kind of array source and this call signature
lets callers drop the trailing `[]` corresponding to that `ptr` deref.
This PR relates to issue https://github.com/nim-lang/Nim/issues/9001 .
* Add a test for toOpenArray() for UncheckedArray[T]s.
2018-10-12 17:40:07 +02:00
eqperes
00c4aba828
compile date and compile time tz written in doc ( #9283 )
2018-10-11 12:15:15 +02:00
LemonBoy
0ead36dae6
Unchecked arrays now have their own type ( #9267 )
2018-10-10 21:03:18 +02:00
hlaaf
c68ea019f9
Separate high/low/len docs for each overload ( #8816 )
2018-10-09 20:15:55 +02:00
Araq
66c0f7c3fb
development version is 0.19.1
2018-10-09 10:31:27 +02:00
Andreas Rumpf
c240806756
update version to 0.19
2018-09-25 12:21:04 +02:00
Araq
548fc778c9
.error for routines now can also have a custom error message; improve error message for 'nil' strings
2018-09-25 00:28:39 +02:00
Zahary Karadjov
27734852da
Implements the equals operator for openarray
2018-09-18 18:19:54 +03:00
Araq
a34184bf88
documents system.cmp's platform specific behaviour; fixes #8930
2018-09-15 00:23:27 +02:00
Araq
5709736e82
Merge branch 'devel' into araq-better-docgen
2018-09-14 15:48:07 +02:00
Araq
4ab9953787
fixes #8961
2018-09-14 11:40:43 +02:00
Andreas Rumpf
8f046792cf
Merge pull request #8941 from timotheecour/pr_fix_8928
...
fix #8928 regression
2018-09-12 10:28:57 +02:00
LemonBoy
b195204549
Fix add(string, cstring) when the lhs is null ( #8951 )
2018-09-12 10:10:00 +02:00
Timothee Cour
b5f463c3f6
fix #8928
2018-09-11 11:36:15 -07:00
LemonBoy
9ba80d2044
JS strings have no trailing zero anymore ( #8936 )
2018-09-11 11:45:02 +02:00
LemonBoy
3f16711254
Fix insert/delete for JS ( #8915 )
...
Fixes #8914
2018-09-08 10:38:18 +02:00
Andreas Rumpf
b5730ec01f
system.nim: fix doc comment for 'once'
2018-09-07 19:21:15 +02:00
LemonBoy
af1e84f54d
Automatic deref for everything but pointers in asm/emit ( #8891 )
...
Fixes #7249
2018-09-07 01:54:59 +02:00
Araq
e0fd1cdb5f
fix items for cstring for the JS target; makes tests green again
2018-09-03 11:13:59 +02:00
Araq
7ace82440f
deprecate system.onRaise; fixes #1652
2018-09-03 09:22:19 +02:00
Araq
fa338768a3
fixes #8847
2018-09-03 08:37:32 +02:00
Andreas Rumpf
df4d5b77a1
introduce precise string '[]', '[]=' accessors; fixes #8049 ( #8817 )
2018-08-30 23:01:15 +02:00
awr1
96d44fdd0a
Deprecate xlen() for strings and seqs ( #8782 )
...
* deprecates xlen() for strings and seqs
* added docs
2018-08-26 17:15:19 +02:00
Timothee Cour
3a626179ee
doAssert, assert now print full path of failing line on error ( #8555 )
2018-08-25 21:48:37 +02:00
Araq
30597e643f
fixes merge conflict
2018-08-23 11:30:55 +02:00
awr1
bf973d29da
Fixes #8719 (onFailedAssert now works for doAssert) ( #8731 )
2018-08-23 10:20:58 +02:00
Araq
64517445ea
even more strict isNil handling for strings/seqs in order to detect bugs
2018-08-22 12:35:46 +02:00
Araq
f12a5431a1
make tests green again
2018-08-21 20:33:47 +02:00