Commit Graph

17607 Commits

Author SHA1 Message Date
Andreas Rumpf
86a7054c88 Merge branch 'devel' into araq-devel 2018-07-04 19:25:53 +02:00
genotrance
c7cc934632 Test case for #5626 (#8204) 2018-07-03 22:47:50 -04:00
LemonBoy
ab47a870bc Error out if vararg match isn't an exact one (#8186)
Fixes #8172
2018-07-03 15:10:12 +02:00
Timothee Cour
426e5c2d1f simplify typetraits.nim test (#8193) 2018-07-03 12:19:46 +02:00
Vindaar
681d8e0749 Deprecate 'c', 'C' prefix for octal literals, fixes #8082 (#8178)
* deprecate `0c`, `0C` prefix for octal literals

Deprecates the previously allowed syntax of `0c` and `0C` as a prefix for
octal literals to bring the literals in line with the behavior of
`parseOct` from parseutils.

* add `msgKind` arg to `lexMessageLitNum` for deprecation messages

* change literal tests to check all valid integer literals

Also adds the `tinvaligintegerlit3` test to test for the (still)
invalid `0O` prefix.
2018-07-03 01:56:36 +02:00
genotrance
70cf286a22 Test case for #6281 (#8190) 2018-07-02 22:53:00 +02:00
Dominik Picheta
d1f983b37c Merge pull request #8187 from zargot/bugfix/asyncftpclient
asyncftpclient: add missing file.close to retrFile
2018-07-02 17:37:39 +01:00
zargot
e63369f2b9 asyncftpclient: add missing file.close to retrFile 2018-07-02 18:07:24 +02:00
Tomohiro
c79f488027 Fix os.unixToNativePath proc returns wrong result(#8179) (#8181)
* Fix os.unixToNativePath proc returns wrong result(#8179)

* Add tests for unixToNativePath
2018-07-02 17:14:26 +02:00
LemonBoy
2c98b4943e Fix crash with static and anonymous procs (#8171)
Fixes #6077
2018-07-02 00:49:03 +02:00
Tomohiro
a2b2bc1a36 Fixed #8173 (#8175) 2018-07-02 00:46:56 +02:00
Andreas Rumpf
e455023902 Merge branch 'devel' into araq-devel 2018-07-01 16:24:56 +02:00
LemonBoy
dbbe311e18 Minor changes to discardable handling (#8155) 2018-07-01 15:27:14 +02:00
Andreas Rumpf
67c7e49e2a gc_common: minor reformating 2018-07-01 15:10:18 +02:00
Oscar Nihlgård
b61e69202b Unexport times.stringifyUnit (#8168) 2018-07-01 12:54:13 +02:00
Timothee Cour
fbd9f9da95 execCmdEx stderr redirection (#8162) 2018-07-01 04:38:15 -04:00
LemonBoy
584d778318 Fix use of custom pragmas in generic procs (#8165)
Fixes #7626
2018-07-01 08:06:58 +02:00
LemonBoy
eec239e851 Fix constant folding of len() with concept type (#8143)
Fixes #7952
2018-06-30 13:43:55 +02:00
Oscar Nihlgård
7ae9c4358e Fix vm regression (#8163) 2018-06-30 13:38:52 +02:00
Oscar Nihlgård
d146045ed5 Fixes #6689 (#8135) 2018-06-30 09:16:46 +02:00
LemonBoy
0a14b3d198 Check the RHS when building a set (#8159)
Fixes #2669
2018-06-30 09:16:14 +02:00
Vindaar
898a4bc4fa fix #8129 by calling semExpr in semIs if node is strLit (#8130)
* call `semExpr` in `semIs` if node is `strLit`, fixes #8129

In case the second son of the node in `semIs` is of kind `strLit`, we
now call `semExpr` to set the `typ` field of that node.

Also removes the `t2 != tyTypeDesc` check in `isOpImpl`, since the
kind of `n[2]` is already assertet with the `internalAssert`.

* reintroduce check for `t2.kind != tyTypeDesc` to fix test case

The `internalAssert` in the `isOpImpl` doesn't check
`n.sons[2].typ.kind` as I previously read, but rather
`n.sons[2].kind`. Therefore the check for `tyTypeDesc` here is
useful. Otherwise the last test case in `isopr.nim` fails.

Also removes the flag `efDetermineType` from the call to `semExpr`.
2018-06-29 16:34:47 +02:00
Oscar Nihlgård
ae69e571e1 VM regression fixes (#8146) 2018-06-29 16:00:53 +02:00
LemonBoy
64c84a7d11 Fix codegen for mInSet magic and empty sets (#8140)
Fixes #8041
2018-06-29 15:10:51 +02:00
Oscar Nihlgård
7674df0dff Fixes #8100 (#8101) 2018-06-29 14:53:09 +02:00
Andreas Rumpf
b5a96d28c7 codgen refactoring: prepare for alternative string/seq implementations 2018-06-29 11:34:39 +02:00
Andreas Rumpf
a9e96888d0 system.nim: cleanup the formatting 2018-06-29 11:21:57 +02:00
Timothee Cour
4deda6b732 Update nre.nim (#8147) 2018-06-29 02:13:49 -04:00
cooldome
541c2a3fec one more attempt 2018-06-28 09:21:09 +01:00
Andreas Rumpf
c7298561c1 system.nim: remove deprecated symbols 2018-06-28 07:42:46 +02:00
Vindaar
cc7479b70f improve error message if literal ends with an underscore (#8114) 2018-06-28 00:33:15 +02:00
LemonBoy
cecce80d42 Fix template codegen with static parameters (#8110)
* Fix template codegen with static parameters

Fixes #7477

* Move the test case to tstaticimportcpp
2018-06-27 22:46:46 +02:00
Yuriy Glukhov
e66b7f3909 Clarify the docs for tables.del (#8134) 2018-06-27 22:25:22 +02:00
hlaaf
9ed671b2fe Replace NotString with typeclass in jsffi (#8128) 2018-06-27 21:43:45 +02:00
LemonBoy
52fc16d5d2 Return an error symbol as macro output if needed (#8116)
Return an error symbol if the macro output has no type and a typedesc
is expected.

Fixes #7454
2018-06-27 21:43:07 +02:00
LemonBoy
7f148838a4 Reject ptr/ref void types (#8127)
Do this during the semantic pass to avoid tripping the following passes.

Fixes #6454
2018-06-27 21:41:40 +02:00
Kaushal Modi
5ac74da926 Clarify use of special : for passing a block of stmts to template (#8133)
Fixes https://github.com/nim-lang/Nim/issues/8131.
2018-06-27 21:37:31 +02:00
LemonBoy
722abbe9c9 Reject enums with holes when computedGoto is used (#8132)
Fixes #7699
2018-06-27 21:36:52 +02:00
LemonBoy
bb23d903b6 Don't consider concept types as non-complex during codegen (#8119)
Fixes #7125
2018-06-27 17:21:53 +02:00
Hiroki Noda
a85493610c Lexer: do not accept some invalid integer literals (#8089)
* Lexer: do not accept some invalid integer literals

* Use Natural instead of uint, and result variable
2018-06-27 17:07:26 +02:00
Joey
559a7615ad Nintendo switch support (#8069)
* Add config section for Nintendo Switch
* Add compiler configuration for Nintendo Switch and it's CPU
* Add specific lib code for Nintendo Switch
* Add GC support for Nintendo Switch
* Update changelog for Nintendo Switch
* Update changelog with more info about fixed paths
* Cleaned up GC memory management a bit
* Relocate docs for Switch
* Rename aarch64NoneElfGcc to nintendoSwitchGCC
* Remove armv8a57
* Fix installer.ini
* Reuse code in linux and amd64
* Add posix defs for nintendo switch
* Add more defined sections for nintendo switch
* Remove old comment
* Add what's not supported for Nintendo Switch docs
* Make nintendoswitch == posix
* Remove DEVKITPRO references from nim.cfg
* Make PR extccomp changes
* Remove Result type alias
* Add separate switch consts file
* Update docs for nintendo switch
* Fix travis errors with undefined consts and add correct wait.h procs
2018-06-27 12:35:09 +02:00
Daniil Yarancev
b74b16ffde Add missing backtick to the changelog.md 2018-06-27 12:54:28 +03:00
cooldome
c20d1ac1c0 Fix failing test 2018-06-26 23:50:06 +01:00
cooldome
34170db963 Merge branch 'devel' into Fixes-7845 2018-06-26 23:33:34 +01:00
Araq
19ea3a70d2 compiler/types.nim: make low/high know about 'sink' parameters; cleans up #7736 2018-06-27 00:21:31 +02:00
Andreas Rumpf
d8f7174dda Merge pull request #7736 from cooldome/range_float_type
Language feature: range float types
2018-06-27 00:08:21 +02:00
Andreas Rumpf
edc3806aa2 Merge pull request #8120 from krux02/basic-debugging
make basic debugging possible
2018-06-26 23:58:07 +02:00
Andreas Rumpf
7cec5d1cfb Merge pull request #7681 from nim-lang/typedesc-reforms
Typedesc reforms
2018-06-26 23:53:30 +02:00
Andreas Rumpf
ccb1514837 Merge pull request #8108 from LemonBoy/fix-5958
Make `static` blocks introduce their own scope
2018-06-26 23:16:40 +02:00
Andreas Rumpf
bf5de98c6a Merge pull request #7800 from GULPF/vm-nil-fix
VM fix for nil assignment
2018-06-26 23:15:26 +02:00