| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
This allows spaces in imports, by using the following syntax:
* `import "directory with spaces" / subdir / file`, or
* `import "directory with spaces/subdir/file"`
|
| |
|
|
|
|
| |
refcounting works
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* kochdocs.nim: code cleanup
* docgen: nicer indentation
* parser.nim: code cleanup
* fixes #10458
* make tests green again
* make =destroy mixins
* gc:destructors: produced C code is almost working
* --gc:destructors simple program compiles (but leaks memory)
* gc:destructors make examples compile in C++ mode
* destructors: string implementation bugfixes
* strs.nim: minor code cleanup
* destructors: builtin seqs are beginning to work
* remove debugging helpers
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
* fixes #10462
* add a test
|
| |
|
|
|
|
|
|
| |
Exceptions raised inside a nkFinally/nkExcept block are not caught by
the block itself.
Fixes #3886
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
The old logic wasn't very useful because
`relPath` is almost always shorter than `absPath`,
e.g. `../../../../../` is shorter than `C:\Program Files`.
This way allows the usage of a relative path for
at most two levels deep, e.g. `../../relPath`,
otherwise the absolute path is used.
|
|
|
|
|
|
|
|
|
| |
The compiler believes these are where a macro call starts (marked with
`^`):
m "string"
^ ^
This commit addresses that.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* compiler/sem*: better lineinfo for templates
Lineinfo for templates is inconsistant across the compiler, for example:
doAssert true
^ ^
a[int](10)
^^ ^
The `^` marks where the compiler thinks the template starts.
For qualified call, we got the same situation with `proc`s before #10427:
system.once
^
Generics lineinfo within template declaration is also incorrect, for
example, this is where the compiler believes the `T` in `[T]` is:
template a[T](b: T)
^
This PR addresses all of these problems.
* nimsuggest: add tests for template highlighting
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* fix #10339 by checking for nkObjConstr
* revert check for nkObjConstr, return type from nkEmpty node
The correct type needed in `semObjConstr` to fix #10339 is indeed
available, but attached to an `nkEmpty` node. These were previously
discarded in `semTypeNode`, which is used to extract the type for the
object.
* simplify return of PType from `nkEmpty`
* also fixes #9866, add test case
|
| |
|
|
|
| |
Fixes #10333
|
| |
|
|
|
|
| |
special cases and seems to be just as fast as the old algorithm
|
| |
|
| |
|
|
|
|
| |
abstract interpretation
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously the compiler will believe these are where `newSeq` symbol
starts:
newSeq[int]()
^
system.newSeq[int]()
^
This commit moves them back to:
newSeq[int]()
^
system.newSeq[int]()
^
|
|
|
| |
Fixes #10417
|
|
|
| |
* Fix for issue #10342. better message for generic subclass instantiation errors.
|
|
|
|
|
| |
Local variables are declared before anything else.
Fixes #10352
|
|
|
|
|
|
|
|
| |
* Restrict ptr/ref to ptr/ref implicit conversion
Fixes #10409
* Make the ptr conversions explicit in db_odbc
|
| |
|
|
|
|
|
|
| |
Hopefully the type-check phase already rejected all the invalid
conversions by the time we execute the VM bytecode.
Problem reported by chrisheller on the Nim Forum
|
|
|
| |
Fixes #10376
|
| |
|
|
|
|
|
|
|
|
|
| |
The type matching is done on the `T` of the `varargs[T]` so the
conversion must be performed to `T` and not to the whole type.
This problem is only noticeable with the cpp backend since C doesn't
give a damn shit about your fucking (wrong) types.
Fixes #9845
|
|
|
|
|
| |
Drop the outer tyStatic shell then perform the check.
Fixes #7609
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* compiler/parser: preserve lineinfo for accent quoted symbols
Previously the lineinfo for symbol $$$ in this example is:
proc `$$$`
^
After this commit:
proc `$$$`
^
* compiler/semstmts: correct lineinfo for accent quoted idents
Previously nimsuggest would highlight this as:
proc `$$$`
^~~
After this commit:
proc `$$$`
^~~
* nimsuggest/tests: add a test for accent quoted proc
Disabled by default
|
| |
|
| |
|
|
|
|
|
|
| |
* fix #9629 every binary cmd line option allows on/off/empty=on
* workaround refs #10359
|
| |
|
|
|
|
|
|
| |
Failing to do so lead the codegen to emit invalid code sometimes,
especially when C++ references were involved.
Fixes #10241
|
| |
|