| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
| |
Done:
- [x] Implement conversions to openArray/varargs.
- [x] Implement index/range checking.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Theoretical Benefits / Plans:
- Typed assembler-like language.
- Allows for a CPS transformation.
- Can replace the existing C backend by a new C backend.
- Can replace the VM.
- Can do more effective "not nil" checking and static array bounds
checking.
- Can be used instead of the DFA.
- Easily translatable to LLVM.
- Reasonably easy to produce native code from.
- Tiny memory consumption. No pointers, no cry.
**In very early stages of development.**
Todo:
- [x] Map Nim types to IR types.
- [ ] Map Nim AST to IR instructions:
- [x] Map bitsets to bitops.
- [ ] Implement string cases.
- [ ] Implement range and index checks.
- [x] Implement `default(T)` builtin.
- [x] Implement multi string concat.
- [ ] Write some analysis passes.
- [ ] Write a backend.
- [x] Integrate into the compilation pipeline.
|
| |
|
|
|
|
|
|
|
| |
fixes #22669 constructor pragma doesnt init Nim default fields
---------
Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
|
|
|
|
|
|
|
| |
It's used in `newSeqUninitialized`.
---------
Co-authored-by: ringabout <43030857+ringabout@users.noreply.github.com>
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
* unpublic the sons field of PType
* tiny fixes
* fixes an omittance
* fixes IC
* fixes
|
|
|
|
|
|
|
| |
* fixes move sideeffects issues [backport]
* fix openarray
* fixes openarray
|
|
|
| |
getTemp and friends now return `TLoc`
|
|
|
| |
`initLocExpr` and friends now return TLoc
|
| |
|
|
|
|
|
| |
* clean up gc:arc/orc in docs
* in error messages
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* wip; use strictdefs for compiler
* checkpoint
* complete the chores
* more fixes
* first phase cleanup
* Update compiler/bitsets.nim
* cleanup
|
|
|
|
|
|
|
| |
(#22376)
Revert "fix #22173 `sink` paramers not moved into closure (refc) (#22359)"
This reverts commit b40da812f7aa590ed16df54a492684c228320549.
|
|
|
|
|
| |
* use genRefAssign when assign to sink string
* add test case
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* implement `ensureMove`
* use an additional flag
* improve some logics
* progress: fixes discard ensureMove
* forbids nested expressions
* improve error messages
* checkpoint
* fixes cursor
* ADD MORE TESTS
* fixes cursorinference again
* tiny cleanup
* improve error messages
* fixes docs
* implement comments add more tests
* fixes js
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* alternative to #22219; adds a pointer wrapper for T destructor
* clean up and add comments
* Update compiler/ccgtypes.nim
* tidy up
* fixes comments
* fixes cpp
* fixes cpp
|
|
|
|
|
|
|
| |
* zero initialization union casts
* cleans up and adds a test case for #19101
* uses nimZeroMem
|
|
|
|
|
|
|
| |
(#22113)
* fixes #16331; aliasing of tuple construction within a single assignment, great coding style
* added test case
|
|
|
| |
fixes explicit deref
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* make `move` use `=wasMoved` internally
* fixes tests
* fixes spawn finally
* fixes views
* rename to internalMove
* add a test case
|
|
|
|
|
|
| |
* fixes tests again
* remove helper functions
* fixes closures, owned refs
* final cleanup
|
|
|
|
|
| |
(#21954)
fixes fieldDefect loses enum type info in ORC
|
|
|
|
|
| |
* fix #15428
* add test
|
|
|
|
|
|
|
| |
to get an array's length (#21925)
* fix #10964
* add test
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* bring #21802 back; fixes #21753 [backport]
* adds tests and multiple fixes
* add test cases
* refactor and remove startId
* fixes custom hooks and adds tests
* handle tyUncheckedArray better
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* import `=dup` hook eliminating `wasMoved` and `=copy` pairs
* add dup
* add a test for dup
* fixes documentation
* fixes signature
* resolve comments
* fixes tests
* fixes tests
* clean up
|
|
|
| |
resync fork
|
|
|
|
|
| |
* hacky attempt to reconcile default explicit constructors with enforcement of brace initialization, instead of memsetting imported objects to 0
* improve C/C++ debug output readability (1/N)
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
properly (#21688)
* fixes #21540; deref block at transf phase to make injectdestructors function properly
* add a test case
* add one more test
* fixes the type of block
* transform block
|
|
|
| |
fixes #21632; enforce deref for `wasMoved`
|
|
|
| |
remove seq[T] setLen UB
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(#21274) [backport:1.6]
* fixes #20139; hash types based on its path relative its project
* add a test case
* fixes procs
* better implementation and test case
---------
Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
|
|
|
|
|
| |
(#21459)
fixes #20422; emit nimPrepareStrMutationV2 for toOpenArray to keep the abstraction of mutable strings which have immutable string literals
|
| |
|
|
|
| |
fix #15117
|
| |
|
|
|
|
|
|
|
| |
(#21010)
* fix #20997 calling system.card[T](x: set[T]) with T of int8 or uint8 uses mismatched C array sizes
* fullfil set variant
|
|
|
|
|
| |
* fix #21045 getTime with vmopsDanger is broken; alternative to #21054
* typo
|
|
|
|
|
| |
* bounchecks for len(toOpenArray())
* add a testcase
|
|
|
|
|
|
|
| |
* Revert "fixes #20699; generate an empty struct for void type (#20790)"
This reverts commit 8fcb9380f076e55bde29e365d395bd0603fc6229.
* better fix [backport]
|