digitalmars.D.bugs - [Issue 1476] New: allow to use intrinsic math functions (e.g. trigonometry) in CTFEs
- d-bugmail puremagic.com (21/21) Sep 05 2007 http://d.puremagic.com/issues/show_bug.cgi?id=1476
- d-bugmail puremagic.com (10/10) Sep 05 2007 http://d.puremagic.com/issues/show_bug.cgi?id=1476
http://d.puremagic.com/issues/show_bug.cgi?id=1476 Summary: allow to use intrinsic math functions (e.g. trigonometry) in CTFEs Product: D Version: 1.021 Platform: PC OS/Version: Windows Status: NEW Severity: enhancement Priority: P3 Component: DMD AssignedTo: bugzilla digitalmars.com ReportedBy: thecybershadow gmail.com The compiler already supports some math functions, like the trigonometric ones, as intrinsics, since it inlines them even when -inline is not specified. It would greatly add to CTFEs if it were possible to call such functions in compile-time functions. For example, Pi could be calculated at compile-time using: const double PI = atan(1)*4; Sine tables could also be pre-calculated at compile time, etcetera. --
Sep 05 2007
http://d.puremagic.com/issues/show_bug.cgi?id=1476 thecybershadow gmail.com changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |DUPLICATE ------- Comment #1 from thecybershadow gmail.com 2007-09-05 15:06 ------- gah... hand jerked while clicking "Submit" *** This bug has been marked as a duplicate of 1475 *** --
Sep 05 2007