Nim icon indicating copy to clipboard operation
Nim copied to clipboard

Nim is a statically typed compiled systems programming language. It combines successful concepts from mature languages like Python, Ada and Modula. Its design focuses on efficiency, expressiveness, an...

Results 629 Nim issues
Sort by recently updated
recently updated
newest added

Compiling derived `var` object on `C++` backend results in compilation error. No problems on `C` backend. ### Example ```nim type Base* = ref object of RootObj method printSpace(c: var Base):...

C++ codegen
Regression

### What happened? Probably this is already reported, but couldnt find it anywhere. When using auto, and it seems sugar uses it, the compiler allows you to write incorrect code....

accepts invalid

```nim template test_template(args:varargs[typedesc])= echo typeof(args[1000]) proc test_proc(args:varargs[typedesc])= echo typeof(args[1000]) test_template(string) # it's ok, but 'echo typeof(args[0] | args[1] | args[1000])' all work test_proc(string) # Error: internal error: getTypeDescAux(tyNone) test_template(string,int) #...

typedesc[T]
Crash
varargs

If you have a const string it will not short-circuit and will not compile: ### Example ```nim const s1 = "" if s1.len == 0 or s1[0] == '/': echo...

fixes https://github.com/nim-lang/Nim/issues/19967 - [x] add a testcase for emums

TODO: followup needed
Ready for review

### Example `module1`/`defs.nim`: ```nim type MyObj* = object field1*: int ``` `module2`/`defs.nim`: ```nim type MyObj* = object field2*: int ``` `main.nim`: ```nim import module1/defs as md1 import module2/defs as md2...

Regression

fixes https://github.com/nim-lang/Nim/issues/10542 ref https://github.com/nim-lang/RFCs/issues/471

Requires Araq

- Added `envvars.getEnv` overload that stores the value in argument.

closes #9331, fixes #20114, fixes #19766 Stores full definition AST for consts (continuing #9582). Also moves extractPragma to ast for later convenience. Also had to fix `noRewrite` (#16620, probably not...

refs #8759 This is just to test the suite/packages with this change, not adding a test for #8759