Mercurial > projects > dstress
changeset 945:08dc6d2df0a4
Tiago Gasiba <tiago.gasiba@gmail.com>
2005-10-28
news:djtk1c$22gs$1@digitaldaemon.com
author | thomask |
---|---|
date | Sun, 02 Apr 2006 14:25:50 +0000 |
parents | eb7e3f644b18 |
children | 18bc025c4445 |
files | run/m/memory_management_04.d |
diffstat | 1 files changed, 27 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/run/m/memory_management_04.d Sun Apr 02 14:25:50 2006 +0000 @@ -0,0 +1,27 @@ +// $HeadURL$ +// $Date$ +// $Author$ + +// @author@ Tiago Gasiba <tiago.gasiba@gmail.com> +// @date@ 2005-10-28 +// @uri@ news:djtk1c$22gs$1@digitaldaemon.com + +module dstress.run.m.memory_management_04; + +class C{ + double[] x; + + void func(){ + x.length=0; + x.length=100; + } +} + +int main(){ + C o = new C; + + for(size_t i=0; i<2000; i++){ + o.func(); + } + return 0; +}