summary refs log tree commit diff stats
path: root/compiler/transf.nim
Commit message (Collapse)AuthorAgeFilesLines
* document compiler procs regarding `&` (#20257)ringabout2022-08-221-0/+5
|
* move assertions out of system (#19599)flywind2022-03-231-0/+3
|
* Fixed distinct composite type class proc borrowing (#18904)Jason Beetham2021-10-261-0/+8
| | | | | | | * Fixed composite type class proc borrowing * Moved borrow search into transf * added borrow check to symbol flag
* fixes #12642 (#18811)Andreas Rumpf2021-09-061-2/+3
| | | | | | | | | | | | | | | | | | | * fixes #12642 * update important packages; refs #18804 * fixes #18805; refs #18806 * fixes a regression * Update testament/categories.nim Co-authored-by: flywind <xzsflywind@gmail.com> * progress * progress Co-authored-by: flywind <xzsflywind@gmail.com>
* fixes #14165, fixes #18739, fix the second example of #6269 (#18812)Andreas Rumpf2021-09-061-4/+7
|
* remove unnecessary if statement (#18792)flywind2021-09-031-6/+6
|
* fix #9778 (pairs iterator calling a helper proc with tuple return type will ↵flywind2021-09-021-11/+44
| | | | | | | | | | | cut the iterator yield into half) (#18767) * test someSymFromImportTable * Update compiler/lookups.nim * test nkTupleConstr * use isConstExpr * add tests * add comments and todo * use todo
* cString => cSourceString; tyCString => tyCstring so that error msgs show ↵Timothee Cour2021-04-171-2/+2
| | | | cstring, not cString (#17744)
* IC: bugfix (#17533)Andreas Rumpf2021-03-271-4/+2
| | | | * cleanups * IC: bugfix
* fixes #11225; generic sandwich problems; [backport:1.2] (#17255)Andreas Rumpf2021-03-091-1/+1
| | | | | * fixes #11225; generic sandwich problems; [backport:1.2] * progress * delegating these symbols must be done via 'bind'
* IC: next steps (#16729)Andreas Rumpf2021-01-231-1/+3
| | | | | | | | | | | * IC: dead code elimination pass * preparations for a different codegen strategy * added documentation to the newly written code * IC: backend code * IC: backend adjustments * optimized the compiler a bit * IC: yet another massive refactoring * fixes regressions * cleanups
* Fix 16722 (#16730)cooldome2021-01-151-0/+2
| | | | | | | * fix #16722 * fix spacing * spacing
* IC: next steps (#16705)Andreas Rumpf2021-01-141-2/+2
| | | | | | | | | | | * code cleanups * refactorings for IC * more refactorings for IC * IC: attach the 'nil' type to its module * IC: refactorings and improvements * IC: progress * IC: more serialization fixes * IC: embarrassing omission * code cleanups
* IC: next steps (#16550)Andreas Rumpf2021-01-071-7/+8
| | | | | | | | | | | | | | | | | | * cleanups * ast.nim: cleanups * IC: no more sym.tab field, stored externally in the module graph * nimble compiles again * rodfiles: store bitwidth of integers and the endianness in the cookie because we serialize 'int' directly * rodfiles: added compilerproc and export sections * rodfiles: added all the missing sections * rodfiles: track the missing information * IC: architecture for lazy loading of proc bodies * make tests green again * completed the lazy loading of proc bodies * symbol lookup integration, part 1 * symbol lookup integration, part 2 * symbol lookup integration, part 3 * make tcompilerapi work again * rodfiles: fixed config change handling
* big steps torwards an efficient, simple IC implementation (#16543)Andreas Rumpf2021-01-021-3/+3
| | | | | | | | | | | | | | | | | | | * reworked ID handling * the packed AST now has its own ID mechanism * basic serialization code works * extract rodfiles to its own module * rodfiles: store and compare configs * rodfiles: store dependencies * store config at the end * precise dependency tracking * dependency tracking for rodfiles * completed loading of PSym, PType, etc * removed dead code * bugfix: do not realloc seqs when taking addr into an element * make IC opt-in for now * makes tcompilerapi green again * final cleanups Co-authored-by: Andy Davidoff <github@andy.disruptek.com>
* fixes #16069; [backport:1.2] [backport:1.4] (#16115)Andreas Rumpf2020-11-241-0/+5
| | | | | * fixes #16069; refs https://github.com/nim-lang/RFCs/issues/257 [backport:1.2] [backport:1.4] * make tests green again
* explicit ID generation for easier IC (#15559)Andreas Rumpf2020-10-251-30/+32
| | | | | | | | | | | | | | | | | * refactoring: idents don't need inheritance * refactoring: adding an IdGenerator (part 1) * refactoring: adding an IdGenerator (part 2) * refactoring: adding an IdGenerator (part 3) * refactoring: adding an IdGenerator (part 4) * refactoring: adding an IdGenerator (part 5) * refactoring: adding an IdGenerator (part 5) * IdGenerator must be a ref type; hello world works again * make bootstrapping work again * progress: add back the 'exactReplica' ideas * added back the missing exactReplica hacks * make tcompilerapi work again * make important packages green * attempt to fix the build for 32 bit machines (probably need a better solution here)
* implements https://github.com/nim-lang/RFCs/issues/258 (#15503)Andreas Rumpf2020-10-061-0/+1
| | | | | | | | | * implements https://github.com/nim-lang/RFCs/issues/258 * don't be too strict with custom pragma blocks * cast pragmas: documentation * added most missing inference query procs to effecttraits.nim
* implements https://github.com/nim-lang/RFCs/issues/257 (#15466)Andreas Rumpf2020-10-021-7/+0
|
* borrow checking (#15282)Andreas Rumpf2020-09-091-0/+4
| | | | | | | | | | | * refactoring: move procs to typeallowed.nim * frontend preparations for first class openArray support * prepare the code generator for first class openArray * code generation for first class openArray; WIP * code generation for open arrays, progress * added isViewType proc * preparations for borrow checking * added borrow checking to the front end
* Expand hoisted default params in sem (#15270)Clyybber2020-09-051-47/+0
| | | | | | | | | * Expand hoisted default params in sem Introduce ast.newTree{I,IT} Add test for default params in procs * Cleanup * Simplify hoist transformation and expand test
* Use typeflag insteadClyybber2020-08-101-1/+1
|
* Make explicit {.nimcall.} a seperate calling conventionClyybber2020-08-081-1/+1
|
* fixes #15071 [backport] (#15131)Andreas Rumpf2020-07-311-3/+3
|
* arc: cursors for simple for loop variables (#15008)Andreas Rumpf2020-07-171-2/+22
| | | | | * arc: cursors for simple for loop variables * merged devel
* An optimizer for ARC (#14962)Andreas Rumpf2020-07-151-1/+1
| | | | | | | | | | | | | | | | | | | | * WIP: an optimizer for ARC * do not optimize away destructors in 'finally' if unstructured control flow is involved * optimized the optimizer * minor code cleanup * first steps to .cursor inference * cursor inference: big steps to a working solution * baby steps * better .cursor inference * new feature: expandArc for easy inspection of the AST after ARC transformations * added topt_cursor test * adapt tests * cleanups, make tests green * optimize common traversal patterns * moved test case * fixes .cursor inference so that npeg compiles once again * cursor inference: more bugfixes Co-authored-by: Clyybber <darkmine956@gmail.com>
* init checks and 'out' parameters (#14521)Andreas Rumpf2020-06-231-5/+5
| | | | | | | | | | | * I don't care about observable stores * enforce explicit initializations * cleaner code for the stdlib * stdlib: use explicit initializations * make tests green * algorithm.nim: set result explicitly * remove out parameters and bring the PR into a mergable state * updated the changelog
* `nim doc --backend:js`, `nim doc --doccmd:-d:foo`, `nim r --backend:js`, ↵Timothee Cour2020-05-111-2/+2
| | | | | | | | | | `--doccmd:skip` + other improvements (#14278) * `nim doc --backend:js|cpp...` `nim doc --doccmd:'-d:foo --threads:on'` `nim r --backend:cpp...` (implies --run --usenimcache) * --usenimcache works with all targets * --docCmd:skip now skips compiling snippets; 50X speedup for doc/manual.rst
* fix #13739 (#13742)Arne Döring2020-04-071-5/+4
|
* fixes #13744 (#13749)cooldome2020-03-251-1/+1
| | | | | | | * fixes #13744 * improve style Co-authored-by: cooldome <ariabushenko@gmail.ru>
* Revert "fix #13417 (#13712)" (#13728)Andreas Rumpf2020-03-231-10/+11
| | | This reverts commit a5f02cac85281fc2804e910f330f0c11d3c4f77b.
* fix #13417 (#13712)Arne Döring2020-03-221-11/+10
| | | | | * fix #13417 * add test
* fixes #12747 [backport] (#13651)cooldome2020-03-161-3/+12
| | | | | | | * fixes #12747 * fix tests * improve code style Co-authored-by: cooldome <ariabushenko@bk.ru>
* fixes #13596 (#13612)Andreas Rumpf2020-03-091-0/+13
|
* Cosmetic compiler cleanup (#12718)Clyybber2019-11-281-277/+254
| | | | | | | | | | | | | | | | | | * Cleanup compiler code base * Unify add calls * Unify len invocations * Unify range operators * Fix oversight * Remove {.procvar.} pragma * initCandidate -> newCandidate where reasonable * Unify safeLen calls
* ARC: solves phase ordering problems (#12654)Andreas Rumpf2019-11-141-21/+8
|
* --gc:destructors improvements (#12626)Andreas Rumpf2019-11-091-2/+1
| | | | | | * do not cache the noDestructors transformation * liftdestructor: improvements * undo bugfix
* some progress on bug #12443Andreas Rumpf2019-10-271-1/+1
|
* refactoring: --newruntime consists of 3 different switchesAraq2019-10-201-1/+1
|
* Refactor injectdestructors (#12295)Clyybber2019-10-011-1/+0
| | | One improvement over #devel is visible in the transformation of getEnv. With this approach we move to result whenever possible.
* Fix spellings (#12277) [backport]Federico Ceratto2019-09-271-2/+2
|
* Small ast.nim cleanup (#12156)Clyybber2019-09-091-22/+22
| | | | | * Remove sonsLen * Use Indexable
* Merge branch 'devel' into uint-range-checksAraq2019-09-021-2/+1
|\
| * Support iterators returning lent T (#11938)cooldome2019-08-311-2/+1
| | | | | | | | | | | | | | * lent iterators * rebase tests * update changelog * fix comments, more tests
* | minor stuffArne Döring2019-08-271-1/+1
|/
* removed unused imports [refactoring]Andreas Rumpf2019-08-081-1/+1
|
* int128 on firstOrd, lastOrd and lengthOrd (#11701)Arne Döring2019-08-071-2/+2
| | | | * fixes #11847
* [refactoring] remove unused imports in the compiler and in some stdlib modulesAraq2019-07-181-2/+2
|
* fixes #11683Araq2019-07-101-5/+6
|
* fixes #8316 (#11673)Andreas Rumpf2019-07-061-7/+15
|