Commit Graph

286 Commits

Author SHA1 Message Date
RSDuck
3402926372 hasCustomPragma/getCustomPragmaVal: small fix (#7650)
* fix hasCustomPragma/getCustomPragmaVal for types without pragma

* fix pragma on pointer test

* removed trailing spaces
2018-04-19 11:07:45 +02:00
Dmitry Atamanov
412cd61dab Fixes #7595 (#7623)
* Fixes #7595

* Add brackets

* Fix for treeRepr and lispRepr too
2018-04-16 19:37:08 +02:00
Timothee Cour
04df7f147c update macros.nim: followup on pull #7598 (#7619)
@Araq @krux02 
https://github.com/nim-lang/Nim/pull/7598 seemed inaccurate eg for NLineInfo there's `mNLineInfo` but no opcNLineInfo
2018-04-16 09:08:52 +02:00
Arne Döring
ed5b7cbac0 move eqIdent to vm.nim (#7585)
* Strutils comment changes.

* fix typo
2018-04-15 23:38:43 +02:00
jcosborn
2478be3f21 add example to docs for getTypeInst and getTypeImpl (#7206)
* add example to docs for getTypeInst and getTypeImpl

* made examples use runnableExamples

* changed assert to doAssert
2018-04-15 13:51:16 +02:00
RSDuck
3d1d163eff fixes #7451 (#7575) 2018-04-14 08:33:36 +02:00
Andreas Rumpf
47335aab41 introduce nkTupleConstr AST node for unary tuple construction; breaking change 2018-04-13 17:45:58 +02:00
Arne Döring
55fe3d87a7 added comment to macros (#7598)
* added comment to macros

* Update macros.nim
2018-04-13 14:05:07 +02:00
Andreas Rumpf
19a1cc914f deprecate macros.callsite; fixes #7369 2018-04-12 20:09:44 +02:00
genotrance
c3cc52087f Added a few useful os calls to VM (#7440) 2018-04-12 13:59:14 +02:00
Arne Döring
6baca58693 Get symbol kind (#7491) 2018-04-11 16:48:01 +02:00
Arne Döring
5d46e1eaa2 Fixes #7473 (#7475)
* removed code duplication
* changelog entry, adopt tests for changes
2018-04-04 15:37:07 +02:00
Andreas Rumpf
d837362216 C codegen: preparations for different seq and string implementations 2018-04-03 10:25:20 +02:00
PMunch
a9f21cffdf Add CommentStmt to astGenRepr (#7313)
* Added codeRepr and dumpCode to the macros module.

This allows those writing macros to write examples, get the code to generate the AST for that example, and then modify that code to be dynamic with the macro function.
2018-03-16 15:57:40 +01:00
cooldome
2c9e56a783 Implement custom annotations (#6987) 2018-01-09 15:25:22 +01:00
Dmitry Atamanov
b31151f68e New runtime: fix allocator inheritable (#7046) 2018-01-09 11:22:29 +01:00
Dmitry Atamanov
fd1883f90a Fixes for new runtime (#7037) 2018-01-08 21:26:03 +01:00
Andreas Rumpf
2e635ab28c new runtime: added typelayouts.nim 2018-01-04 15:59:03 +01:00
Andreas Rumpf
80fef7c818 allocators.nim: minor typo 2018-01-04 14:16:33 +01:00
Araq
ee67a67ac4 first steps in adding template/macro calls to stack traces 2017-12-21 10:03:33 +01:00
Araq
255902f9a5 added macros.unpackVarargs 2017-11-30 15:24:30 +01:00
Araq
1bbab827c4 Merge branch 'devel' of github.com:nim-lang/Nim into devel 2017-11-21 01:42:58 +01:00
Araq
fba5f5acd6 added a version of macros.expectLen that takes min/max values 2017-11-21 01:42:53 +01:00
Andreas Rumpf
5ccf69ffa3 cleaned up macros.nim 2017-11-19 13:23:04 +01:00
Andreas Rumpf
4f9e8cf313 macros.nim: deprecated ! operator 2017-11-19 13:23:04 +01:00
WhiteDuke
963184fea6 'newEnum' proc added to macros.nim (#6000) 2017-11-19 00:38:44 +01:00
Andreas Rumpf
908a25a2ca replaced asArray with a much more powerful mapLiterals macro 2017-11-18 14:18:00 +01:00
Lynn C. Rees
0ab373115c Trim remaining expr/stmt from stdlib (#6742) 2017-11-15 17:34:48 +01:00
Andreas Rumpf
d52a1061b3 work in progress: new implementation for 'a[^1]' 2017-10-29 19:46:17 +01:00
Andreas Rumpf
6a3288a60e more replacements for the deprecated '<' 2017-10-29 08:55:30 +01:00
Araq
0be71677d9 macros.nim: added missing pairs iterator 2017-10-25 17:37:03 +02:00
Andreas Rumpf
d3dc753732 make the tester compile again 2017-09-25 14:52:52 +02:00
Andreas Rumpf
f7f3a25be8 first steps of making 'opt' a first class type for Nim 2017-09-25 13:19:36 +02:00
Andreas Rumpf
e879da5791 some work to make 'opt' a first class type 2017-09-24 11:21:52 +02:00
Andreas Rumpf
1a61c4d46d first implementation of the 'func' keyword 2017-09-23 23:22:53 +02:00
Andreas Rumpf
2b592a6425 in prepration for the upcoming different integer inference rules 2017-09-16 10:29:29 +02:00
Araq
7132b04f44 equality check on NimSym has now support in the VM; refs #6139 2017-09-03 01:15:40 +02:00
Andreas Rumpf
57f0936f2a macros module: 'name' proc skips the export marker 2017-08-29 00:33:46 +02:00
Yuriy Glukhov
8481e9ff14 Fixed NimTypeKind enum, added missing values. (#6157) 2017-07-30 11:10:07 +02:00
PMunch
e00953cbc0 Added codeRepr and dumpCode to the macros module. (#5778) 2017-07-26 00:37:37 +02:00
Arne Döring
000b8afd26 Remove expr/stmt (#5857) 2017-07-25 09:28:23 +02:00
Yuriy Glukhov
1f13e94dd0 Disable stacktrace in locks (#6128) 2017-07-21 17:20:46 +02:00
Arne Döring
52f092d02b Lineinfo change (#6084) 2017-07-17 08:12:15 +02:00
andri lim
2ecdf582a8 fixes #6049 add mixin release, acquire to withLock (#6113) 2017-07-16 16:54:09 +02:00
Arne Döring
52cab78ae5 newLit emty seq fix (#6091)
* the type of the empty seq is still the correct type
* updated test
2017-07-13 17:07:33 +02:00
Arne Döring
eb8e267ff6 improved comment satement support in macros (#5904) 2017-06-02 01:22:21 +02:00
Arne Döring
32143d3c7a more and improved newLit procs in macros module 2017-05-23 19:37:51 +02:00
Dominik Picheta
b2e649c093 Fixes regression introduced by #5739. Improves newNimNode proc. 2017-05-17 20:05:21 +01:00
Andreas Rumpf
22789a0bfc fixes #5419 2017-02-24 00:32:14 +01:00
Jeff Ciesielski
7f30d04d6a Fix compilation for 16 bit targets (#5286) 2017-01-26 07:05:03 +01:00