Saem Ghani
2aba116bbc
when statements branches exit early ( #17143 )
...
When statement branches exit early outside of nimvm. In nimvm it seems that all
sides of the branches must be evaluated as the code gen happens at a later
stage, this remains intact.
2021-02-22 12:27:23 +01:00
Andrey Makarov
fab1618eb4
make rst.nim use object variant ( #17138 )
...
* make rst.nim use object variant
* add workaround
* fix mistake
2021-02-22 11:00:31 +01:00
flywind
32bf10126c
fix #17118 ( #17119 ) [backport:1.2]
...
* fix js unsigned integer
* Use `std` prefix for standard library modules
* fix #17118
2021-02-22 09:14:18 +01:00
Clyybber
6b7a6f8c54
Split last read and first write analysis ( #17137 )
...
* Split last read and first write analysis
This improves performance by 10% for some
cases.
* Remove outdated comments
2021-02-21 16:20:05 +01:00
Andrey Makarov
d1fec552d0
stricter checks for RST headlines ( #17089 )
2021-02-20 18:01:45 +01:00
Andreas Rumpf
4395a26764
fixes #17085 [backport:1.2] ( #17101 )
2021-02-19 12:30:39 +01:00
Andreas Rumpf
8fd1ed6dfe
fixes #17060 ( #17083 )
2021-02-18 12:15:21 +01:00
flywind
8873ec6084
fix #17076 ( #17081 )
2021-02-18 06:59:58 +01:00
Timothee Cour
31bb67a309
add -d:nimStrictMode in CI to keep code from regressing; fixes ConvFromXtoItselfNotNeeded, UnusedImport notes ( #16764 )
2021-02-17 19:30:09 +01:00
flywind
8d63f7b483
clean up old codes ( #17071 )
2021-02-17 19:26:08 +01:00
flywind
874ccc8493
[minor] clean extccomp ( #17069 )
2021-02-17 15:48:17 +01:00
Clyybber
aa3af9e053
ARC Analysis in one pass v3 ( #17068 )
...
* Analyse last reads all at once
* Integrate firstWrite analysis
* Small cleanup
* Use sets instead of seqs
* Remove instrTargets
* Reap the benefits
* Implement error diagnostics
* Operate on DFA index for lastRead analysis
* Use mgetOrPut
* Cache alias results
This improves performance by a lot, since many
CFG locations map to a single PNode
* Improve performance
* Improve performance
* Cleanup
* Fix #17025
* Grammar
* Expand testcase
2021-02-17 14:17:35 +01:00
flywind
4f118721be
make system random work in VM ( #17059 )
...
* make system random work in VM
2021-02-17 11:52:46 +01:00
Andreas Rumpf
f32ffb6ed8
fixes #17033 [backport:1.4] ( #17061 )
...
* fixes #17033 [backport:1.4]
* make test robust against stdlib gensym things
* cleanup assertions.nim to make topt_no_cursor easier to get right
2021-02-17 11:00:03 +01:00
Timothee Cour
b9994925f5
remove all uses of condsyms symbols defined prior to bootstrap nim 0.20.0 ( #16918 )
...
* nimNoArrayToCstringConversion deadcode
* nimbabel deadcode
* nimHasalignOf deadcode
* nimvarargstyped deadcode
* nimhygiene deadcode
* nimNewTypedesc deadcode
* nimlocks deadcode
* nimHasCppDefine deadcode
* nimHasRunnableExamples deadcode
* nimHasNilChecks deadcode
* nimSymKind deadcode
* minor macros refactoring
* nimVmEqIdent deadcode
* nimNoNil deadcode
* nimNoZeroTerminator deadcode
* nimHasSymOwnerInMacro deadcode
* nimVmExportFixed deadcode
* nimNewRuntime deadcode
* nimAshr deadcode
* nimUncheckedArrayTyp deadcode
* nimHasTypeof deadcode
* nimErrorProcCanHaveBody deadcode
* nimHasHotCodeReloading deadcode
* nimHasSignatureHashInMacro deadcode
* nimHasDefault deadcode
* nimMacrosSizealignof deadcode
2021-02-17 09:32:36 +01:00
Timothee Cour
b187caeb87
document since ( #17048 )
...
* document `since`
* address comment
2021-02-16 20:20:01 +01:00
Clyybber
70b9e9962f
Revert "ARC: Analysis in one pass v2 ( #17000 )" ( #17046 )
...
This reverts commit 216be4060a .
2021-02-15 18:31:15 +01:00
flywind
339ebe958d
JS: fix div uint64 no truncation ( #16899 )
2021-02-15 14:22:46 +01:00
Andrey Makarov
35bd39a9d0
RST: implement footnotes and citations ( #16960 )
...
* RST: implement footnotes and citations
* manual fixup of nimdoc.out.css
* remove unused code
* shorter printing code
* Update lib/packages/docutils/rst.nim
Co-authored-by: Andreas Rumpf <rumpf_a@web.de >
2021-02-15 14:12:40 +01:00
flywind
240879bf3d
array literals uses typed arrays; fix a jsgen bug ( #16850 )
...
* array litterals uses typed arrays
* Update compiler/jsgen.nim
Co-authored-by: Timothee Cour <timothee.cour2@gmail.com >
Co-authored-by: Andreas Rumpf <rumpf_a@web.de >
2021-02-15 11:28:11 +01:00
Saem Ghani
260a5dacb7
fixed dot operator recursive loop & macro suggest ( #16922 )
...
* basic stability improvements; refs nimsuggest
* fixed dot operator recursive loop & macro suggest
* hacky fix for run away dot operator sem check
Committing this mostly to make the issue more clear. Perhaps get better
feedback.
* semExprWithType seems like a better place to check
* fixed error messages const case expressions
* Clean-up test
* stopped the dot operator madness
No longer get infinite recursion when seming broken code with a dot
operator macro like in jsffi.
Co-authored-by: Araq <rumpf_a@web.de >
2021-02-15 09:51:05 +01:00
Timothee Cour
4326f743d0
compilesettings: add libpath ( #16997 )
...
* compilesettings: add libpath
* add test
* changelog
* fixup
Co-authored-by: Andreas Rumpf <rumpf_a@web.de >
2021-02-12 23:50:41 +01:00
Timothee Cour
e40ff24c23
typeToString: type float => typedesc[float] ( #17011 )
...
* typeToString: type float => typedesc[float]
* fixup
* fix tests
2021-02-12 17:10:20 +01:00
Danil Yarantsev
66bf9b18b0
Display user hints/warnings from foreign packages ( #17024 )
2021-02-12 14:03:42 +01:00
hlaaftana
81533a0014
[backport:1.4] JS cstring null fixes ( #16979 )
...
* [backport:1.4] JS cstring null fixes
* fix JS move string
* make it look cleaner
2021-02-11 17:04:32 +01:00
Andreas Rumpf
f3c39bf2d9
fixes a bug that keeps Nimbus from compiling with --gc:orc ( #17005 )
...
* fixes a bug that keeps Nimbus from compiling with --gc:orc
* better fix
2021-02-11 11:55:57 +01:00
Timothee Cour
b7dd8e7dff
unbundle fusion ( #16925 )
...
* unbundle fusion
* changelog
* address comment: `./koch fusion` calls nimble install fusion (at a fixed hash)
2021-02-11 07:24:53 +01:00
flywind
9bd4f503f4
[JS] Ref #15952 make toOpenArray works better ( #17001 )
...
* ref 15952 toOpenArray works in JS
* fix
2021-02-10 18:49:44 +01:00
Clyybber
216be4060a
ARC: Analysis in one pass v2 ( #17000 )
...
* Analyse last reads all at once
* Integrate firstWrite analysis
* Small cleanup
* Use sets instead of seqs
* Remove instrTargets
* Reap the benefits
* Implement error diagnostics
* Operate on DFA index for lastRead analysis
* Use mgetOrPut
* Cache alias results
This improves performance by a lot, since many
CFG locations map to a single PNode
* Improve performance
* Improve performance
* Cleanup
2021-02-10 15:03:57 +01:00
Clyybber
9edf719e1e
Revert "ARC Analysis in one pass ( #16849 )" ( #16984 )
...
This reverts commit ab740cb5b9 .
2021-02-09 15:50:52 +01:00
hlaaftana
49b64e8dc7
Remove declPragmas from lambdas [backport:1.0] ( #16966 )
...
* Remove declPragmas from lambdas [backport:1.0]
* add test for exportc
* fix test
* fix align, nodecl -> noinit
2021-02-09 14:23:06 +01:00
Clyybber
ab740cb5b9
ARC Analysis in one pass ( #16849 )
...
* Analyse last reads all at once
* Integrate firstWrite analysis
* Small cleanup
* Use sets instead of seqs
* Remove instrTargets
* Reap the benefits
* Implement error diagnostics
* Operate on DFA index for lastRead analysis
* Use mgetOrPut
2021-02-09 14:20:58 +01:00
Timothee Cour
ba64d0c8ab
fix #16947 : --app:staticlib -o:lib now first removes lib ( #16948 )
2021-02-08 22:26:09 +01:00
hlaaftana
6a7baff97d
rename case statement macro from match to case ( #16923 )
...
* rename case statement macro from match to `case`
* fix test
2021-02-08 19:35:06 +01:00
Timothee Cour
6f6370367b
fix #16949 --app:staticlib works on openbsd; --app:staticlib tested in CI ( #16950 )
2021-02-08 09:47:05 +01:00
flywind
d447c0fe3f
use typeof instead type ( #16962 )
2021-02-08 09:46:07 +01:00
n5m
c548f97241
quote nim command on compile ( #16954 )
2021-02-07 00:31:58 +01:00
flywind
bb85bc7ebc
remove a temporary variable in int128.nim ( #16935 )
2021-02-04 17:41:23 +01:00
Andreas Rumpf
fb80d2ff85
IC: bugfixes (WIP) ( #16836 )
...
* minor improvements
* IC: added the required logic for compilerProcs
* LazySym ftw
* we need this testing logic
* reimplement the old way we use for module package creation
* fixes a regression; don't pick module names if you can avoid it
2021-02-02 19:24:55 +01:00
hlaaftana
def1f99289
add finally as post expr block [backport:1.4] ( #16896 )
2021-02-01 20:14:20 +01:00
Andreas Rumpf
91ace2188a
fixes #16897 [backport:1.2] ( #16900 )
2021-02-01 16:56:02 +01:00
flywind
de4f2604c2
fix #16822 ( #16884 )
...
* see whether it breaks
* fix #16884
* correct
* fix #14574
2021-02-01 13:31:04 +01:00
flywind
74f8a8e38a
let's assume littleEndian in JS backend ( #16886 )
...
* let's assume littleEndian in JS and VM backend
* Update compiler/platform.nim
2021-02-01 13:11:35 +01:00
Timothee Cour
1a74576854
distinctBase now is identity instead of error for non distinct types ( #16891 )
2021-02-01 13:10:52 +01:00
konsumlamm
eef2948ec2
Fix #12595 ( #16874 )
2021-01-31 01:00:18 +01:00
Saem Ghani
1097cc4173
nimsuggest prioritize non-deprecated suggestions ( #16816 )
...
* penalizes the quality score of deprecated symbols
* uses quality more pervasively in order to reflect deprecation impact
* impacts both sug and con
additional notes:
* linux i386 CI was failing
* this is because the suggested results differ slightly in their sort
* 64 bit tables.getOrDefault:441 was returned, while 32 bit returned 422
* for now simply removing the last line is good enough
2021-01-29 15:15:35 +01:00
flywind
f09d97d6d3
close #16844 ( #16852 )
...
* close #16844
* better
* comment
* Update compiler/renderer.nim
2021-01-29 14:31:41 +01:00
Timothee Cour
6e267d28b3
remove conditionals on nimHasUserErrors, nimNoNilSeqs2, nimNoNilSeqs ( #16861 )
...
* cleanup docs for type(nil) | type(nil); simplify nimHasUserErrors
* simplify nimNoNilSeqs2
* simplify nimNoNilSeqs
* fixup
2021-01-29 14:30:24 +01:00
Timothee Cour
b0f38a63c4
fix #16815 round(x,places) works again in vm ( #16825 )
...
* fix #16815 round+places works again in vm
* improve tests; fix for linux 32bit
* fix test for windows
2021-01-28 10:40:18 +01:00
Timothee Cour
e112974920
fix #16752 : threadvar now works with importcpp types; osx now uses native TLS (--tlsEmulation:off), which can be orders of magnitude faster ( #16750 )
...
* osx now uses native TLS, which can be orders of magnitude faster
* add {.cppNonPod.}
* improve test
* changelog, docs, disable part of windows test
2021-01-27 22:35:43 +01:00