Mercurial > projects > dstress
view compile/c/const_44_C.d @ 1414:aaf99ec76365
Re: Compile time function execution...
torhu <fake@address.dude>
2007-02-15
http://www.digitalmars.com/webnews/newsgroups.php?search_txt=&group=digitalmars.D&article_id=48845
author | thomask |
---|---|
date | Sun, 11 Mar 2007 11:06:16 +0000 |
parents | |
children |
line wrap: on
line source
// $HeadURL$ // $Date$ // $Author$ // @author@ torhu <fake@address.dude> // @date@ 2007-02-15 // @uri@ http://www.digitalmars.com/webnews/newsgroups.php?search_txt=&group=digitalmars.D&article_id=48845 // @desc@ Re: Compile time function execution... module dstress.compile.c.const_44_C; double square(idouble x){ return x * x; } const double foo = square(5.0i); static assert(25 == foo);