Araq
6e584c42c2
vm2: new representation of registers
2014-02-21 17:23:37 +01:00
Zahary Karadjov
3f71b7f1f6
implements #766 ;
...
expressions such as Type.field are now recognised by the compiler.
This also fixes a bug, preventing the user-defined to check for the presence of
regular fields in addition to procs
2014-01-24 23:52:52 +02:00
Araq
73c6efdf66
'nil' as a statement is deprecated, use an empty 'discard' instead
2014-01-19 16:54:59 +01:00
Zahary Karadjov
afddae5aaf
Merge branch 'upstream' into devel
...
Conflicts:
compiler/ccgutils.nim
compiler/msgs.nim
compiler/sem.nim
compiler/semexprs.nim
compiler/seminst.nim
compiler/semmagic.nim
compiler/semstmts.nim
compiler/semtypes.nim
compiler/semtypinst.nim
compiler/sigmatch.nim
compiler/types.nim
compiler/vmgen.nim
lib/core/macros.nim
lib/system.nim
tests/reject/tenummix.nim
web/news.txt
2013-12-29 17:21:00 +02:00
Zahary Karadjov
66a2556525
make more tests green
2013-12-29 00:00:37 +02:00
Araq
92b8fac94a
case consistency part 4
2013-12-27 23:10:36 +01:00
Zahary Karadjov
027f30610e
static params: expr[T] is now static[T]
...
This introduces tyStatic and successfully bootstraps and handles
few simple test cases. Static params within macros are no longer
treated as PNimrodNodes - they are now equivalent to constants
of the designated type.
2013-12-19 01:06:38 +02:00
Araq
29357ab556
more tests are green
2013-12-08 01:47:07 +01:00
Araq
8710118b2c
Merge branch 'master' of github.com:Araq/Nimrod
2013-08-30 12:44:27 +02:00
Araq
7056ceda67
float64 is now an alias to 'float'; fixes #545
2013-08-30 12:24:54 +02:00
Zahary Karadjov
fee2a7ecfa
Experimental support for delayed instantiation of generics
...
This postpones the semantic pass over the generic's body until
the generic is instantiated. There are several pros and cons for
this method and the capabilities that it enables may still be possible
in the old framework if we teach it a few new trick. Such an attempt
will follow in the next commits.
pros:
1) It allows macros to be expanded during generic instantiation that
will provide the body of the generic. See ``tmacrogenerics``.
2) The instantiation code is dramatically simplified. Dealing with unknown
types in the generic's body pre-pass requires a lot of hacky code and error
silencing in semTypeNode. See ``tgenericshardcases``.
cons:
1) There is a performance penalty of roughly 5% when bootstrapping.
2) Certain errors that used to be detected in the previous pre-pass won't
be detected with the new scheme until instantiation.
2013-08-23 01:10:20 +03:00
Araq
aefa0da8a6
new VM: implemented constructors and jump optimizer
2013-08-07 01:40:08 +02:00
Araq
2c3d1fa954
bugfix: gensym
2013-07-25 21:25:40 +02:00
Araq
b1d4dfa6b1
fixes #544
2013-07-24 22:32:09 +02:00
Araq
38ed2373ab
fixes #432 , fixes #427
2013-05-19 02:49:10 +02:00
Araq
2afadc5c9c
first steps to the expr/stmt unification
2013-04-30 02:38:49 +02:00
Araq
3cb3813eed
fixes #287 ; bugfix: subrange checking is performed again
2013-04-12 16:24:58 +02:00
Grzegorz Adam Hankiewicz
72a3e21f28
Removes executable bit for text files.
2013-03-16 23:53:07 +01:00
Araq
78b27ed7fa
bugfix: 'indexOf' for tuple fields works
2013-03-11 08:42:35 +01:00
Araq
225d657019
first steps to implement object construction expressions
2013-03-07 01:52:17 +01:00
Araq
5b0d8246f7
make some tests green
2013-03-03 12:05:03 +01:00
Zahary Karadjov
9c8bc3a244
the is operator now works with type classes and type variables
...
bugfixes:
the DLL tests were failing on Mac OS X, due to an incorrect DynlibFormat
2012-10-03 01:59:49 +03:00
Araq
af7c92c003
term rewriting macros fully implemented; still buggy
2012-09-03 00:55:44 +02:00
Araq
51de278bd4
next steps for tyVarargs/tyOpenArray split
2012-08-14 08:44:26 +02:00
Araq
43f057c5aa
got rid of some mAddU64 etc. magics
2012-07-20 07:52:04 +02:00
Araq
832da8a303
equality and hashing for closures
2012-07-17 17:26:02 +02:00
Araq
b4084df434
improved unsigned support
2012-07-14 14:03:13 +02:00
Araq
4966212141
more fixes for new integer promotion rules; fixes #152 ; fixes #157 ; fixes #156 ; fixes #155
2012-07-09 21:11:11 +02:00
Araq
121d4e0fc2
'addSon' for types deprecated for 'int literal type' analysis
2012-07-09 08:09:00 +02:00
Araq
4fbba0a65a
changed integer promotion rules; breaks bootstrapping and lots of code
2012-07-08 21:03:47 +02:00
Araq
36247e0947
added devel/logging; weakrefs test; next steps for proper unsigned support
2012-07-05 00:03:33 +02:00
Araq
2900ceae35
changed integer promotion rules; added math.fmod
2012-06-28 08:33:25 +02:00
Zahary Karadjov
e2d38a57ec
better support for unsigned integers.
2012-06-11 21:38:01 +03:00
Zahary Karadjov
a1da1f987b
Added system.staticExec proc for executing external command at compile-time
2012-06-02 19:51:49 +03:00
Zahary Karadjov
efb53233cb
the foundations of a type traits module; better error messages for expr, typedesc and typeclasses params
2012-04-06 13:46:31 +03:00
Araq
ccd58fba2c
bugfix: semfold supports merging of '&'
2012-02-19 21:01:04 +01:00
Araq
4f1b89c30c
year 2012 for most copyright headers
2012-01-02 23:07:35 +01:00
Araq
2962ca7890
alias analysis as required for the code gen and the HLO
2011-12-08 23:21:08 +01:00
Araq
70cf34cbdc
'assert' is now implemented without compiler magic
2011-12-04 20:14:50 +01:00
Araq
840979b45c
Merge branch 'master' of github.com:Araq/Nimrod
2011-11-26 10:49:48 +01:00
Araq
02e8e9c3ea
fixed bug that kept tls emulation from working
2011-11-25 17:26:11 +01:00
Zahary Karadjov
c617479c68
New algorithm for locating and loading nimrod config files.
...
Some new options added to the compiler (see news.txt for details)
2011-11-25 17:29:55 +02:00
Araq
72651de710
bugfix: 'when' sections in generic objects now work, so TThread[void] compiles
2011-11-20 16:13:03 +01:00
Araq
299390a585
constant folding for cnst[i] and cnst.attr
2011-10-29 23:54:50 +02:00
Zahary Karadjov
e3deb5b502
Cleaned up the circular dependecies and remaining issues
...
Changed: The []= operator for strings and sequences is now capable of splicing
2011-10-07 17:10:04 +03:00
Zahary Karadjov
eaeed1f846
getAst works correctly with existing AST values as template/macro arguments
2011-10-07 17:05:54 +03:00
Araq
42516c0086
code generator supports constant sequences; more consistent compile time evaluation
2011-10-07 09:02:08 +02:00
Zahary Karadjov
dbcca9b3b9
Moved the parseAST magics to evals.nim
...
Added string interpolation helper routines in parserutils
Added a proof-of-concept string interpolation user-land macros (currently, only as a test case):
the interpolated expression could either be transformed to
concat("literal string ", $(interpolated), " end") or
"literal string $1 end" % [$(interpolated)]
Added a very initial definition of Optional[T] generic type
A new overload of ParseIdent was added in hope to get around the fact that the
old one doesn't work correctly in macros, but the problem persists.
2011-09-20 14:13:45 +03:00
Araq
b0742c5b27
finally got rid of nkPassAsOpenArray
2011-08-16 08:56:53 +02:00
Araq
05cffb9370
'is' operator for generic code
2011-07-31 00:55:30 +02:00