summary refs log tree commit diff stats
Commit message (Collapse)AuthorAgeFilesLines
* replaces `doAssert false` with `raiseAssert` for unreachable branches, which ↵ringabout2023-08-1021-42/+34
| | | | | works better with strictdefs (#22436) replaces `doAssert false` with `raiseAssert`, which works better with strictdefs
* `getTemp` and friends now return `TLoc` as requested (#22440)ringabout2023-08-106-77/+60
| | | getTemp and friends now return `TLoc`
* adds support for functor in member (#22433)Juan M Gómez2023-08-102-1/+17
| | | | | * adds support for functor in member * improves functor test
* fixes a typo (#22437)ringabout2023-08-101-1/+1
|
* fix #19304 Borrowing std/times.format causes Error: illformed AST (#20659)Bung2023-08-105-29/+80
| | | | | | | | | * fix #19304 Borrowing std/times.format causes Error: illformed AST * follow suggestions * mitigate for #4121 * improve error message
* `initLocExpr` and friends now return `TLoc` (#22434)ringabout2023-08-104-341/+234
| | | `initLocExpr` and friends now return TLoc
* Fix #21760 (#22422)SirOlaf2023-08-102-2/+10
| | | | | | | | | | | * Remove call-specific replaceTypeVarsN * Run for all call kinds and ignore typedesc * Testcase --------- Co-authored-by: SirOlaf <>
* modernize sempass2; `initEffects` now returns `TEffects` (#22435)ringabout2023-08-101-21/+13
|
* makes asmnostackframe work with cpp member #22411 (#22429)Juan M Gómez2023-08-092-3/+41
|
* simplify isAtom condition (#22430)ringabout2023-08-092-8/+2
|
* Fix #5780 (#22428)Bung2023-08-092-1/+4
| | | * fix #5780
* fixes cascades of out parameters, which produces wrong ProveInit warnings ↵ringabout2023-08-092-4/+24
| | | | (#22413)
* fix #12938 index type of array in type section without static (#20529)Bung2023-08-094-21/+52
| | | | | | | | | | | | | * fix #12938 nim compiler assertion fail when literal integer is passed as template argument for array size * use new flag tfImplicitStatic * fix * fix #14193 * correct tfUnresolved add condition * clean test
* fixes #22419; async/closure environment does not align local variables (#22425)ringabout2023-08-092-0/+19
| | | | | | | | | | | | | | | | | * fixes #22419; async/closure environment does not align local variables * Apply suggestions from code review * Update tests/align/talign.nim Co-authored-by: Jacek Sieka <arnetheduck@gmail.com> * apply code review * update tests --------- Co-authored-by: Jacek Sieka <arnetheduck@gmail.com>
* fix #20891 Illegal capture error of env its self (#22414)Bung2023-08-093-3/+41
| | | | | * fix #20891 Illegal capture error of env its self * fix innerClosure too earlier, make condition shorter
* make the name of procs consistent with the name forwards (#22424)ringabout2023-08-091-1/+1
| | | | | | | | | | | It seems that `--stylecheck:error` acts up when the name forwards is involved. ```nim proc thisOne*(x: var int) proc thisone(x: var int) = x = 1 ``` It cannot understand this at all.
* refactors initSrcGen and initTokRender into returning objects (#22421)ringabout2023-08-092-61/+36
|
* modernize jsgen; clean up some leftovers (#22423)ringabout2023-08-091-16/+13
|
* block ambiguous type conversion dotcalls in generics (#22375)metagn2023-08-095-0/+57
| | | fixes #22373
* modernize lineinfos; it seems that array access hinders strict def analysis ↵ringabout2023-08-091-7/+7
| | | | | | | | | | | | | | | | | | like field access (#22420) modernize lineinfos; array access hinders strict def analysis like field access A bug ? ```nim proc computeNotesVerbosity(): array[0..3, TNoteKinds] = result[3] = {low(TNoteKind)..high(TNoteKind)} - {warnObservableStores, warnResultUsed, warnAnyEnumConv, warnBareExcept} result[2] = result[3] - {hintStackTrace, hintExtendedContext, hintDeclaredLoc, hintProcessingStmt} result[1] = result[2] - {warnProveField, warnProveIndex, warnGcUnsafe, hintPath, hintDependency, hintCodeBegin, hintCodeEnd, hintSource, hintGlobalVar, hintGCStats, hintMsgOrigin, hintPerformance} result[0] = result[1] - {hintSuccessX, hintSuccess, hintConf, hintProcessing, hintPattern, hintExecuting, hintLinking, hintCC} ```
* modernize compiler/reorder, which exposes yet another strictdefs bug (#22415)ringabout2023-08-081-13/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ```nim {.experimental: "strictdefs".} type NodeKind = enum nkImportStmt nkStmtList nkNone PNode = ref object kind: NodeKind proc hasImportStmt(n: PNode): bool = # Checks if the node is an import statement or # i it contains one case n.kind of nkImportStmt: return true of nkStmtList: if false: return true else: result = false var n = PNode() echo hasImportStmt(n) ``` It compiles without warnings, but shouldn't. As a contrast, ```nim {.experimental: "strictdefs".} type NodeKind = enum nkImportStmt nkStmtList nkNone PNode = ref object kind: NodeKind proc hasImportStmt(n: PNode): bool = # Checks if the node is an import statement or # i it contains one case n.kind of nkImportStmt: result = true of nkStmtList: if false: return true else: result = false var n = PNode() echo hasImportStmt(n) ``` This gives a proper warning.
* clean up `gc:arc` or `gc:orc` in docs and in error messages (#22408)ringabout2023-08-086-14/+14
| | | | | * clean up gc:arc/orc in docs * in error messages
* fixes LineTooLong hints on old compilers (#22412)ringabout2023-08-083-0/+6
| | | | | * fixes LineTooLong hints on old compilers * fixes config/nim.cfg
* modernize compiler/filter_tmpl.nim (#22407)ringabout2023-08-081-11/+9
|
* fix #18823 Passing Natural to bitops.BitsRange[T] parameter in generi… ↵Bung2023-08-084-10/+23
| | | | | (#20683) * fix #18823 Passing Natural to bitops.BitsRange[T] parameter in generic proc is compile error
* fixes #22387; Undefined behavior when with hash(...) (#22404)ringabout2023-08-081-6/+14
| | | | | | | * fixes #22387; Undefined behavior when with hash(...) * fixes vm * fixes nimscript
* fix #22287 nimlf_ undefined error (#22382)Bung2023-08-081-0/+1
|
* tiny change on action.nim (#22405)ringabout2023-08-081-1/+1
|
* use out parameters for getTemp (#22399)ringabout2023-08-076-43/+39
|
* [C++] Member pragma RFC (https://github.com/nim-lang/RFCs/issues/530) (#22272)Juan M Gómez2023-08-077-23/+85
| | | | | | | | | | * [C++] Member pragma RFC #530 rebase devel * changes the test so `echo` is not used before Nim is init * rebase devel * fixes Error: use explicit initialization of X for clarity [Uninit]
* nimIoselector option (#22395)Bung2023-08-071-1/+12
| | | | | | | | | * selectors.nim: Add define to select event loop implementation * rename to nimIoselector --------- Co-authored-by: Jan Pobrislo <ccx@webprojekty.cz>
* Delete parse directory, which was pushed wrongly before [backport] (#22401)ringabout2023-08-071-3/+0
| | | Delete parse directory
* a bit modern code for depends (#22400)ringabout2023-08-071-6/+1
| | | | | * a bit modern code for depends * simplify
* unify starting blank lines in the experimental manual (#22396)ringabout2023-08-061-23/+0
| | | unify starting blank lines in the experimental manal
* use strictdefs for compiler (#22365)ringabout2023-08-06114-501/+1223
| | | | | | | | | | | | | | | * wip; use strictdefs for compiler * checkpoint * complete the chores * more fixes * first phase cleanup * Update compiler/bitsets.nim * cleanup
* Fix some jsgen bugs (#22330)konsumlamm2023-08-063-21/+72
| | | | | Fix `succ`, `pred` Fix `genRangeChck` for unsigned ints Fix typo in `dec`
* Let inferGenericTypes continue if a param is already bound (#22384)SirOlaf2023-08-062-4/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Play with typeRel * Temp solution: Fixup call's param types * Test result type with two generic params * Asserts * Tiny cleanup * Skip sink * Ignore proc * Use changeType * Remove conversion * Remove last bits of conversion * Flag --------- Co-authored-by: SirOlaf <>
* Stick search result (#22394)Bung2023-08-062-2/+14
| | | | | | | | | * nimdoc: stick search result inside browser viewport * fix nimdoc.out.css --------- Co-authored-by: Locria Cyber <74560659+locriacyber@users.noreply.github.com>
* fix set op related to {sfGlobal, sfPure} (#22393)Bung2023-08-062-2/+2
|
* fix #15005; [ARC] Global variable declared in a block is destroyed too… ↵Bung2023-08-062-1/+20
| | | | | (#22388) * fix #15005 [ARC] Global variable declared in a block is destroyed too early
* add test for #3907 (#21069)Bung2023-08-061-0/+10
| | | * add test for #3907
* introduces online bisecting (#22390)ringabout2023-08-061-1/+2
| | | | | * introduces online bisecting * Update .github/ISSUE_TEMPLATE/bug_report.yml
* fix server caching issue causing Theme failures (#22378)Daniel Belmes2023-08-064-8/+12
| | | | | | | | | * fix server caching issue causing Theme failures * Fix tester to ignore version cache param * fix case of people using -d:nimTestsNimdocFixup * rsttester needed the same fix
* Prevent early destruction of gFuns, fixes AddressSanitizer: ↵norrath-hero-cn2023-08-051-1/+1
| | | | | heap-use-after-free (#22386) Prevent destruction of gFuns before callClosures
* destructors: better docs [backport:2.0] (#22391)Andreas Rumpf2023-08-051-28/+57
|
* Revert adding generic `V: Ordinal` parameter to `succ`, `pred`, `inc`, `dec` ↵konsumlamm2023-08-065-17/+17
| | | | | | | (#22328) * Use `int` in `digitsutils`, `dragonbox`, `schubfach` * Fix error message
* compiler/llstream: modern code for llstream (#22385)Andreas Rumpf2023-08-041-17/+6
|
* Fix searchExtPos so that it returns -1 when the path is not a file ext (#22245)Tomohiro2023-08-042-4/+49
| | | | | | | * Fix searchExtPos so that it returns -1 when the path is not a file ext * fix comparision expression * Remove splitDrive from searchExtPos
* fixes AddressSanitizer: global-buffer-overflow in getAppFilename on windows ↵norrath-hero-cn2023-08-041-2/+2
| | | | | 10 (#22380) fixes AddressSanitizer: global-buffer-overflow
* fix #20883 Unspecified generic on default value segfaults the compiler (#21172)Bung2023-08-043-0/+20
| | | | | | | | | * fix #20883 Unspecified generic on default value segfaults the compiler * fallback to isGeneric * change to closer error * Update t20883.nim