Commit graph

436 commits

Author SHA1 Message Date
Zahary Karadjov
d9d82fb0af syntax compatibility between do blocks and stmt blocks
See the section `do notation` in the manual for more info.

* nkMacroStmt has been removed
   Macro statements are now mapped to regular nkCall nodes.
   The support for additional clauses (such as else, except, of, etc)
   have been restored - they will now appear as additional arguments
   for the nkCall node (as nkElse, nkExcept, etc nodes)

* fixed some regressions in the `is` operator and semCompiles
2012-10-04 15:37:26 +03:00
Zahary Karadjov
2e5265bef5 experimental support for querying the type of expressions within macros
normalised the line endings of macros.nim (minor edits otherwise)
2012-10-03 01:59:50 +03: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
Zahary Karadjov
770d4a997e implemented case expressions 2012-10-03 01:59:49 +03:00
Zahary Karadjov
92f70b08f9 table constructors now mimic more closely the syntax of case... of...
see the safePrintF example in the manual as a motivation
2012-10-03 01:59:49 +03:00
Zahary Karadjov
7e44015491 implemented return type inference
Other fixes:
* bind once is now the default for type classes as documented in the manual
* fixes an issue in template overloading (erroneous  ambiguity when different typedesc params were used)
2012-10-03 01:59:49 +03:00
Zahary Karadjov
2aabae702d fixes ttypeselectors 2012-09-28 14:30:48 +03:00
Zahary Karadjov
badb6c0f66 improved support for typedesc values
* can be stored in constants and variables (including in containers like sequences)
* can be passed to and returned from macros
2012-09-25 02:03:15 +03:00
Araq
83b90b941b bugfix: proc bodies as expr 2012-09-23 09:02:11 +02:00
Araq
759b3201ad proc bodies can be expressions with a type 2012-09-22 22:43:36 +02:00
Araq
043921c7a7 fixes #194 2012-09-20 23:44:52 +02:00
Araq
cb6ad8cb74 bugfix: 'nimrod i' works again 2012-09-18 20:59:14 +02:00
Araq
a71c5f98ea made tests green again 2012-09-18 00:36:48 +02:00
Araq
391fb89a3e some support for passing blocks to overloaded templates/macros 2012-09-17 20:30:15 +02:00
Araq
d336cb4957 bugfix: echo vs debugEcho 2012-09-13 17:33:20 +02:00
Araq
23c3af80f6 semExpr/semStmt merged 2012-09-13 08:33:55 +02:00
Araq
8178cd4fab made some tests green 2012-09-12 08:43:24 +02:00
Araq
64c638a9dc first steps for overloading support of passing blocks; bugfix: test results of 'compile' are not overwritten 2012-09-11 08:09:34 +02:00
Araq
b64eeeb430 term rewriting improvements 2012-09-08 15:43:21 +02:00
Araq
af7c92c003 term rewriting macros fully implemented; still buggy 2012-09-03 00:55:44 +02:00
Araq
1786e30991 first steps towards term rewriting macros 2012-08-30 10:55:40 +02:00
Araq
b4844a189d parameter passing works the same for macros and templates; use callsite magic to access the invokation AST 2012-08-28 22:15:29 +02:00
Araq
b5b5e6e76d distinguish properly between nkOpen and nkClosedSymChoice 2012-08-26 02:47:17 +02:00
Araq
9a7f0cd851 bindSym suffices; no 'bind' for macros anymore 2012-08-25 01:34:50 +02:00
Araq
da190876de next steps to hygienic templates 2012-08-20 08:44:17 +02:00
Araq
5e15dec175 first steps to make templates hygienic 2012-08-20 01:13:13 +02:00
Araq
51de278bd4 next steps for tyVarargs/tyOpenArray split 2012-08-14 08:44:26 +02:00
Araq
5e570bae47 more bugfixes for closures 2012-08-14 07:53:16 +02:00
Araq
991b3096e8 made tests green again 2012-08-14 00:09:06 +02:00
Araq
244c14db0b top level closures should work; transf is not a pass anymore; next steps for first class iterator support 2012-08-13 17:07:49 +02:00
Araq
19bc408ec6 idetools: '--def' now works in 'x.f' 2012-08-05 16:05:17 +02:00
Araq
c7158af752 idetools: 'usages' and 'def' should work now; documented js backend 2012-08-05 12:33:23 +02:00
Araq
a7a2f464a2 idetools: don't suggest module names or not visible object fields 2012-08-03 22:57:26 +02:00
Araq
79aaf213d6 idetools improvements 2012-08-03 17:33:44 +02:00
Araq
674c05f426 made compiler more robust for idetools; implemented idetools.usages 2012-07-30 23:07:19 +02:00
Araq
976c39cdc9 more improvements for idetools 2012-07-30 01:24:54 +02:00
Araq
b595fc8347 better error handling for better idetools support 2012-07-29 23:08:28 +02:00
Araq
8c62903429 better overloading capabilities for 'shallowCopy'; little bugfix for 'system.compiles' 2012-07-29 10:30:35 +02:00
Araq
087b8621d3 improvements for idetools; system.compiles improved 2012-07-29 02:45:50 +02:00
Araq
b9afdffb3e fixes #178 2012-07-28 16:37:31 +02:00
Araq
538b06a123 implements #173 2012-07-28 14:16:08 +02:00
Araq
20b6dc3829 next steps for closure consistency; fixes #176 2012-07-25 21:59:31 +02:00
Araq
8413772063 optimizations for system.compiles 2012-07-20 16:23:07 +02:00
Araq
1c6f14deee added system.compiles 2012-07-20 08:49:42 +02:00
Araq
832da8a303 equality and hashing for closures 2012-07-17 17:26:02 +02:00
Araq
483f28d1cf fixes #147 2012-07-10 22:17:47 +02:00
Araq
95faae2c0a some more bugfixes for the integer promotion rules 2012-07-10 01:12:03 +02:00
Araq
049de0ef66 'addSon' for types deprecated for 'int literal type' analysis (3) 2012-07-09 20:04:19 +02:00
Araq
82b5e430cf 'addSon' for types deprecated for 'int literal type' analysis (2) 2012-07-09 08:22:55 +02:00
Araq
4fbba0a65a changed integer promotion rules; breaks bootstrapping and lots of code 2012-07-08 21:03:47 +02:00