[nem-en] Where field initialization expressions copy constructor
of type?
Kamil Skalski
kamil.skalski at gmail.com
Mon Nov 6 15:14:23 CET 2006
It is done in StaticInitalizer macro:
http://nemerle.org/svn/nemerle/trunk/macros/Internals.n
If you are looking for a bug http://nemerle.org/bugs/view.php?id=778
it might be a little bit hard to fix - in particular the problem is in
order of executing macros (bug
http://nemerle.org/bugs/view.php?id=199) - I'm still planning to add
"before" attribute to macros, like
[Before (Nemerle.Core.Record)]
macro MyPreRecord (...) {
}
which would ensure that if both Record and MyPreRecord macros are
present (and they have the same state target), then MyPreRecord will
be executed before Record.
I think that making Record run before StaticInitializer should fix
that problems - because StaticInitializer will add initalization of
fields to all ctors generated by Record macro.
On 11/6/06, vc <vc at rsdn.ru> wrote:
> Hi,
>
> Where (in compiler code) field initialization expressions copy
> constructor of type?
>
> For example, in code:
> public class TestClass
> {
> static some_stack: Stack[string] = Stack();
> }
>
> expression "Stack()" copy to ctor of TestClass. I need finde where is
> done.
>
>
> _______________________________________________
> https://nemerle.org/mailman/listinfo/devel-en
>
--
Kamil Skalski
http://nazgul.omega.pl
More information about the devel-en
mailing list