Timothee Cour
0831292863
revives: Move typetraits.$ to system. Fixes #5827 ( #10071 )
...
* Move typetraits.`$` to system. Fixes #5827 .
* revive PR; adjust code to make sure everything works and add tests
* fix tests/concepts/tstackconcept.nim
* address comments
2018-12-30 01:09:47 +01:00
Araq
4ec40796e6
fixes #9868
2018-12-11 10:28:56 +01:00
alaviss
ac56d3b0ed
fixes #7365
2018-11-26 13:02:37 +01:00
cooldome
2ac7f52388
Fixes multiple bugs with sink arguments ( #9802 )
...
* fixes #9781
* fix spacing
2018-11-26 09:45:45 +01:00
cooldome
8c1083d3b7
Of operator in vm fixes [backport] ( #9717 )
...
* fixes #9701
* fixes #9702
* optimize of statement to bool
2018-11-15 13:03:42 +01:00
Andreas Rumpf
a2e6a873af
fixes #9610
2018-11-03 11:04:30 +01:00
Araq
c844a9169c
fixes #9498 , typeof is for everybody
2018-10-25 13:04:51 +02:00
Timothee Cour
745f1642d6
implement sizeof and alignof operator (manually squashed #5664 ) ( #9356 )
2018-10-14 00:52:28 +02:00
andri lim
78c0ac5407
fixes #7827 , bindSym enhancement ( #8499 )
...
* bindSym power up, working prototype
* update bindSym doc
* add bindSym test
* fix some typo
* fix bindSym doc
* get rid of specialops field from vm
* add experimental: dynamicBindSym
2018-08-02 12:56:44 +02:00
LemonBoy
3163a0f466
Do not consider enums with holes as ordinals ( #8264 )
...
Make the compiler behave consistently with respect to what's written in
the manual.
Fixes #1239
2018-07-12 18:08:45 +02:00
Andreas Rumpf
40ec7be45c
refactoring: remove idents.legacy global variable and pass the IdentCache around explicitly
2018-05-27 22:09:15 +02:00
Andreas Rumpf
a325692fb2
refactoring: fewer global variables
2018-05-27 19:19:12 +02:00
Andreas Rumpf
669a564492
remove more global variables in the Nim compiler
2018-05-27 11:10:56 +02:00
Andreas Rumpf
a4e2b0c153
platform.nim doesn't use globals anymore; prepare msgs.nim for not using globals
2018-05-18 15:18:00 +02:00
Andreas Rumpf
bf6c2c5ccf
preparations of making compiler/msgs.nim free of global variables
2018-05-17 15:21:22 +02:00
Araq
2a7fc84c86
remove ast.emptyNode global; cleanup configuration.nim
2018-05-16 03:06:07 +02:00
Araq
5526252fa0
fixes testament compilation
2018-05-14 17:45:44 +02:00
Andreas Rumpf
050789a8f4
sem pass compiles again
2018-05-12 21:30:42 +02:00
Andreas Rumpf
ce859d8c16
more modules compile again
2018-05-12 16:35:59 +02:00
Zahary Karadjov
2b8bf8fc4a
A motivating example for the new bindSym behavior.
...
The example is a proof-of-concept logging library, allowing you to define
lexically-scoped environments where certain logging attributes are applied
automatically to all logging statements.
fixes tmacro1 (use of `bindSym` inside static blocks)
2018-05-07 09:37:49 +02:00
Zahary Karadjov
bdcb729597
Better support for treating templates and macros as symbols.
...
This allows you to pass a template or a macro to another macro
which can then inspect the implementation of the former template/macro
using `getImpl`.
Since templates can be freely redefined, this allows you to treat
their symbols as compile-time variables that have lexical scope.
A motivating PoC example for a logging library taking advantage of
this will be provided in the next commit.
Implementation details:
* The name of a template or a macro will be consider a symbol if
the template/macro requires parameters
* For parameterless templates/macros, you can use `bindSym`, which
was extended to also work outside of compile-time procs.
2018-05-07 09:37:49 +02:00
Andreas Rumpf
47335aab41
introduce nkTupleConstr AST node for unary tuple construction; breaking change
2018-04-13 17:45:58 +02:00
PMunch
4f1725ad61
Add column number to instantiation info ( #7376 )
...
* Add column number to instantiation info
Instantiation info left out column number for no good reason. This adds
it in as the third element of the tuple.
* Fix test that failed and added change to changelog
An assertion test failed because it was declaring a type that was
expected to be populated by instantiationInfo with the old signature.
Also added the changes to the changelog as it is a breaking change.
2018-04-12 20:02:04 +02:00
Andreas Rumpf
e4081a7201
preparations for language extensions: 'sink' and 'lent' types
2018-01-07 23:09:26 +01:00
Andreas Rumpf
1548743856
make tests green again
2017-11-18 23:03:16 +01:00
Andreas Rumpf
30b098fcaf
wip
2017-11-02 15:39:44 +01:00
Andreas Rumpf
f1dab39086
remove old implementation of the roof operator; make tests green again; close #6292
2017-10-29 20:36:07 +01:00
Araq
b407f083ba
destructors: work in progress
2017-10-26 00:55:23 +02:00
Andreas Rumpf
e7f37d7223
added typetraits.supportsCopyMem
2017-10-17 21:59:17 +02:00
Andreas Rumpf
8d714d2b02
low/high/of are now overloadable operations
2017-08-30 23:14:33 +02:00
Zahary Karadjov
cd02561368
introduce a pre-processing pass for the concept bodies
...
fixes #4982
fixes #3805
close #3414
2017-06-20 11:29:42 +02:00
Zahary Karadjov
bc01835091
Allow tyOr,tyAnd and tyNot to be constructed in more contexts
2017-04-28 17:07:54 +03:00
Zahary Karadjov
9574d318ae
use lower-case proc names
2017-03-24 17:03:55 +02:00
Zahary Karadjov
52b241fd57
new type traits: GenericHead and StripGenericParams
2017-03-24 16:59:47 +02:00
Zahary Karadjov
644d645ea7
implement the special treatment of explicit type params in concepts
2017-03-24 16:58:15 +02:00
Andreas Rumpf
46efaf294b
big compiler refactoring; avoid globals for multi method dispatcher generation
2017-02-22 16:27:52 +01:00
Andreas Rumpf
01ae0d28d4
recursive modules are only detected to improve error messages
2016-11-24 12:27:21 +01:00
Jacek Sieka
6f7b891bdc
remove remnants of tyIter
2016-10-24 21:10:48 +08:00
Jacek Sieka
4d558e2608
Merge remote-tracking branch 'origin/devel' into compiler-cleanup
2016-08-17 18:49:36 +08:00
Matthew Baulch
674a1110f0
Require ordinal or set argument to system.ord
2016-08-11 21:13:18 +10:00
Jacek Sieka
3cd4cf4320
remove unused stuff
2016-08-09 22:54:27 +08:00
Andreas Rumpf
de6198c747
fixes #4555
2016-08-02 12:47:02 +02:00
Andreas Rumpf
db56174a19
fixes #3548
2016-07-15 00:22:14 +02:00
Andreas Rumpf
e8faa214eb
fixes #4295
2016-06-07 22:46:12 +02:00
bit
b6a11271b3
Removed error that disallows slices with negative indexes
2016-02-22 16:37:29 +02:00
Andreas Rumpf
bd8e89774e
fixes a critical bug concerning a[^1] rewritings
2015-12-14 18:40:58 +01:00
Araq
29a9166966
fixes the most pressing regressions introduced by the new handling of a[i] in the compiler
2015-09-16 15:34:54 +02:00
Araq
8ef66b973d
first attempt to fix 'a[i]' handling in generics
2015-09-12 10:55:28 +02:00
Yuriy Glukhov
a5be556a4c
Untyped pointers godegen changed. addr expression fixed.
2015-08-21 13:29:25 +03:00
Araq
ab26298a03
added system.unsafeAddr
2015-08-04 17:31:18 +02:00