Andreas Rumpf
6c1c8f51b3
IC: green tests ( #17311 )
...
* IC: renamed to_packed_ast module to ic module
* IC: don't store the --forceBuild flag, makes it easier to test
* IC: enable hello world test
* Codegen: refactorings for IC; changed the name mangling algorithm
* fixed the HCR regressions
* life is too short for HCR
* tconvexhull is now allowed to use deepCopy
* IC exposed a stdlib bug, required a refactoring
* codegen: code cleanups
* IC: even if a module is outdated, its dependencies might come from disk
* IC: progress
* IC: better name mangling, module IDs are not stable
* IC: another refactoring helping with --ic:on --gc:arc
* disable arraymancer on Windows for the time being
* disable arraymancer altogether
* IC: make basic test work with 'nim cpp'
* IC: progress on --ic:on --gc:arc
* wip; name mangling for type info
2021-03-19 16:53:38 +01:00
flywind
83e002a318
follow up #17391 add testcase ( #17404 )
...
* Revert "make system random work in VM"
* fix #17380
* attempt to fix bug
* fix
* better
* fix
* a bit
* fix the leaks
* revert
* fix
* better
* follow up #17391
* fix
* Update tchannels.nim
* Update tests/stdlib/tchannels.nim
* Update tchannels.nim
2021-03-19 14:48:31 +08:00
Timothee Cour
9d4d27a3ce
adjust spellSuggestSecretSauce logic to avoid too many matches for small symbols ( #17410 )
2021-03-18 13:26:45 +01:00
Timothee Cour
2356d0603f
followup #17398 : getTempDir, getConfigDir now do not have trailing DirSep ( #17402 )
...
* followup #17398 : `getTempDir`, `getConfigDir` now do not have trailing DirSep
* fix test
2021-03-18 13:25:56 +01:00
Andrey Makarov
4bfc5a9551
Rst test check messages ( fix #17280 ) ( #17338 )
2021-03-17 20:13:04 +01:00
Saem Ghani
72b89eff82
semLambda removed, semProcAux reworked ( #17379 )
...
* simplified proc-like name ident to symbol code
* wip - reworking generic param sem
* wip - closer to removing nkEmpty generic params
* it's hacky but tests pass
* slowly tweaking semProcAux to take on semLambda
* fix pragma superset check proto vs current
* Set the symbol owner earlier
* partial progress reworking proto
found bug where default values between forward and impl lead to overload
resolution issues.
* simplified pragma handling and callConv checks
Co-authored-by: Clyybber <Clyybber@users.noreply.github.com >
* partially working
* cgexprs issue
* It works!
* comment clean-up
* clean-up asserts, comments, and other bits
* add isGenericParams, inline isGeneric queries
* seeing if this is sufficiently consistent
* can use this approach or continue it in a further PR
* commentary about nullary generics and clean-ups
* fixed a mistake in PNode isGenericRoutine
* Some small cleanups
* Small cleanup
* for func lambdas ensure we use lambda pragmas
* add some basic compileTime func tests
* [ci skip] remove comments
Co-authored-by: Clyybber <Clyybber@users.noreply.github.com >
Co-authored-by: Clyybber <darkmine956@gmail.com >
2021-03-17 19:51:50 +01:00
Andrey Makarov
144e338abb
allow short-style rst references with symbols ( #17372 )
2021-03-17 18:08:13 +01:00
flywind
e9b5543bd5
[std/channels]fix recv leaks(Part One) ( #17394 )
2021-03-17 10:08:54 +01:00
Timothee Cour
4d3f3513e2
followup #16067 --spellSuggest ( #17401 )
...
* followup #16067 --spellSuggest
* enable --spellSuggest by default
* fixup
2021-03-17 07:40:29 +01:00
Timothee Cour
895a40d1ac
fix #17383 : json.%,to and jsonutils.formJson,toJson now works with uint|uint64 ( #17389 ) [backport:1.2]
...
* fix #17383 : json.%,to and jsonutils.formJson,toJson now works with uint|uint64
* fixup
* fix for js
2021-03-16 21:44:54 +01:00
Timothee Cour
48eab5370a
fix #2844 #3911 ; add --spellsuggest to suggest symbols in scope with similar spellings on undefined symbol error ( #16067 )
...
* add --spellsuggest to suggest symbols in scope with similar spellings on undefined symbol errors
* implement --spellsuggest with 0 arguments
2021-03-16 10:41:30 +01:00
Miran
40a5d6537a
fix #17385 , len must be declared before items ( #17386 )
2021-03-15 10:45:10 -07:00
flywind
84cf3e5fca
Revert "make system random work in VM" ( #17378 )
2021-03-15 10:21:25 +01:00
flywind
a0b8a3d920
New channels implementation for ORC ( #17305 )
...
* Update lib/std/channels.nim
* Rename tchannel_pthread.nim to tchannels_pthread.nim
* Rename tchannel_simple.nim to tchannels_simple.nim
Co-authored-by: Mamy Ratsimbazafy <mamy_github@numforge.co >
2021-03-12 13:33:47 +01:00
Andrey Makarov
d97bf4f1c8
fix RST parsing when no indent after enum.item ( fix #17249 ) ( #17257 )
2021-03-12 08:33:21 +01:00
Clyybber
4545995e2d
Revert "Revert "close #16607 add testcase ( #17317 )" ( #17336 )" ( #17347 )
...
This reverts commit 3ce27511ad .
2021-03-12 00:21:31 +01:00
Miran
e922d73dd6
refs #4347 , add ZZZ and ZZZZ patterns for timezone offsets without colons ( #17318 )
2021-03-11 16:32:50 +01:00
Clyybber
3cbc80045d
Fix #14325 ( #17308 )
...
* Fix #14325
* Refactor and fix
2021-03-11 14:03:25 +01:00
Clyybber
3ce27511ad
Revert "close #16607 add testcase ( #17317 )" ( #17336 )
...
This reverts commit 1655103d83 .
2021-03-11 20:43:45 +08:00
Timothee Cour
789cc49b60
disable most flaky test in CI (refs #16338 ) ( #17113 )
2021-03-10 19:08:27 -08:00
Timothee Cour
eb07a5a75b
add typetraits.OrdinalEnum, enumutils.symbolName ( #17281 )
2021-03-10 08:08:24 -08:00
flywind
58e88dbf12
close #9440 add testcase ( #17316 )
2021-03-09 22:50:17 -08:00
flywind
1655103d83
close #16607 add testcase ( #17317 )
2021-03-09 22:16:34 -08:00
Andreas Rumpf
2f213db7ee
fixes #11225 ; generic sandwich problems; [backport:1.2] ( #17255 )
...
* fixes #11225 ; generic sandwich problems; [backport:1.2]
* progress
* delegating these symbols must be done via 'bind'
2021-03-09 20:19:24 +01:00
flywind
cc37fee0ab
fix #17275 ( #17276 )
2021-03-09 12:22:26 +01:00
Timothee Cour
d161d27cdd
fix #13491 #17279 runnableExamples now don't get lost in translation ( #17282 )
...
* fix #13491 runnableExamples rendering
* fix a runnableExamples thanks to this bugfix
2021-03-09 07:09:24 +01:00
flywind
761ec2ccc8
improve test coverage for isolation ( #17297 )
...
* improve test coverage for isolation
* a bit better
2021-03-08 22:21:57 +08:00
flywind
dd8383b10a
add testcase for #12005 ( #17278 )
...
* remove unnecessary when statement
* remove outdated codes
* reuse jsffi
* move js json coverage
* close #12005 add testcase
* Update tests/stdlib/tthreadpool.nim
* Update tests/stdlib/tthreadpool.nim
* Update tests/stdlib/tthreadpool.nim
Co-authored-by: Timothee Cour <timothee.cour2@gmail.com >
Co-authored-by: Timothee Cour <timothee.cour2@gmail.com >
2021-03-08 14:37:52 +01:00
Timothee Cour
93cb5d6896
add setutils.[]= ( #17272 )
...
* add setutils.[]=
* address comments
* proc => func (for other symbols too)
2021-03-08 10:39:39 +01:00
Roman Inflianskas
31424b3808
stdlib/os: add isAdmin ( #17012 )
...
* stdlib/os: add isAdmin
* uint8 -> cuchar, assert isAdmin on Azure
Co-authored-by: Timothee Cour <timothee.cour2@gmail.com >
* Update lib/pure/os.nim docs
Co-authored-by: Timothee Cour <timothee.cour2@gmail.com >
* Address comments on #17012
* Raise on errors in #17012
* Check the result of FreeSid in #17012
* Change case in #17012
* Fix memory leak in #17012
* Address comments in #17012
Co-authored-by: Timothee Cour <timothee.cour2@gmail.com >
Co-authored-by: Timothee Cour <timothee.cour2@gmail.com >
2021-03-07 22:40:16 +01:00
flywind
d1e093207a
fix #17267 ( #17273 )
...
* remove unnecessary when statement
* remove outdated codes
* reuse jsffi
* move js json coverage
* fix #17267
* address comments
* Update compiler/main.nim
* Update tests/threads/tjsthreads.nim
2021-03-07 12:13:41 +01:00
flywind
0e3ea16554
use lowercase --define switches ( #17283 )
2021-03-07 12:08:41 +01:00
Clyybber
38d82795da
Fix #16437 ( #17277 )
...
* Fix #16437
* Fix
* Small cleanup
2021-03-06 22:35:02 +01:00
flywind
171b03c386
fix #17264 [backport:1.4] ( #17266 )
...
* fix #17264
* fix vm
* fix js and add tests
2021-03-05 14:39:46 +01:00
konsumlamm
2e8325a19c
Remove support for named procs with sugar.=> ( #17220 )
...
* Add docs & tests for named procs with sugar.=>
* Remove support for named procs in sugar.=>
* Resolve conflict
* Fix test
2021-03-05 12:08:03 +01:00
flywind
cda443ee68
follow up #17165 ( #17262 )
2021-03-04 22:41:20 -08:00
flywind
81889fb84c
reuse jsffi in json module ( #17165 )
...
* remove unnecessary when statement
* remove outdated codes
* reuse jsffi
* move js json coverage
2021-03-04 19:37:12 +01:00
flywind
e1cc3b83fb
deprecate newruntime ( #17245 )
...
* deprecate newruntime
* tests
* Update compiler/commands.nim
2021-03-04 19:33:16 +01:00
Timothee Cour
a66637bda4
followup #16871 asyncjs.then: allow pipelining procs returning futures ( #17189 )
...
* followup #16871 asyncjs.then: allow pipelining procs returning futures
* rename test files where they belong
* fix tests
* tests for then with `onReject` callback
* rename test file containing fail to avoid messing with grep
* address comments
* cleanup
* un-disable 1 test
2021-03-04 14:00:04 +01:00
Jason Beetham
c180de60a8
Added math.clamp for slice clamping ( #17246 )
...
* Added math.clamp for slice clamping
* Added inline to math.clamp
* Cleaned up math.clamp + test
2021-03-03 23:54:23 +00:00
flywind
6391f6e861
fix #16384 and #17144 ( #17126 ) [backport]
2021-03-03 11:58:50 +01:00
Juan Carlos
4982d1c662
https://github.com/nim-lang/Nim/pull/15826/files#r585368355 ( #17233 )
2021-03-03 11:58:05 +01:00
flywind
ec068a2687
fix #17177 ( #17243 )
...
* remove unnecessary when statement
* remove outdated codes
* fix #17177
* add testcase
2021-03-03 11:57:34 +01:00
Andrey Makarov
02f4464058
RST heading improvements ( fix #17091 ) ( #17195 )
2021-03-02 16:41:10 +01:00
Timothee Cour
f1bf672ffc
re-enable disabled tests after #17173 ( #17228 )
2021-03-02 12:53:05 +01:00
flywind
5628cd5de1
attempt to fix #16374 ( #17232 )
...
* remove unnecessary when statement
* remove outdated codes
* attempt to fix #16374
* fix
2021-03-02 19:41:55 +08:00
Saem Ghani
ab780f66ef
fixes #17198 , DFA failure on large case stmts ( #17210 )
...
This alters the DFA control flow graph generation for case statments.
Gotos are now generated as a chained link, this ensures that evaluation
of variant branches collapses as early as possible, without hitting the
2k call limit.
2021-03-02 10:32:43 +01:00
flywind
eabb9b79b2
close #5342 add testcase ( #17230 )
...
* remove unnecessary when statement
* remove outdated codes
* close #5342 add testcase
* update the example
2021-03-02 10:24:45 +01:00
Timothee Cour
6c5872c169
--nilseqs is now a deprecated noop (#17211 )
...
* --nilseqs is now a deprecated noop
* fix tests; fix: future => sugar
2021-03-01 20:59:43 +01:00
Andreas Rumpf
bb0c19f42c
fixes #17173 ( #17213 )
...
* fixes #17173
* add testcase (#17214 )
* Apply suggestions from code review
* fix for newruntime
* Apply suggestions from code review
* Update lib/system.nim
* Update lib/system.nim
* Update lib/system.nim
Co-authored-by: Danil Yarantsev <tiberiumk12@gmail.com >
Co-authored-by: flywind <xzsflywind@gmail.com >
Co-authored-by: Danil Yarantsev <tiberiumk12@gmail.com >
2021-03-01 20:58:12 +01:00