[Issue 3921] New: Compile time evaluation requirements not well-specified

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed Mar 10 04:44:21 PST 2010


http://d.puremagic.com/issues/show_bug.cgi?id=3921

           Summary: Compile time evaluation requirements not
                    well-specified
           Product: D
           Version: 2.041
          Platform: All
               URL: file:///home/jlquinn/dmd2/html/d/function.html
        OS/Version: All
            Status: NEW
          Keywords: spec
          Severity: major
          Priority: P2
         Component: www.digitalmars.com
        AssignedTo: nobody at puremagic.com
        ReportedBy: jlquinn at optonline.net


--- Comment #0 from Jerry Quinn <jlquinn at optonline.net> 2010-03-10 04:44:19 PST ---
The language of the spec does not clearly state what a compile must be able to
evaluate at compile time.  Through example, clearly constant folding must be
done, to support mixins as shown in various examples, but the full rules of
what the D language requires to be done at compile time is not given.

Similarly, CTFE states that the compiler can execute functions at compile time
if they meet certain constraints.  However, it doesn't clearly state whether
the D language requires that these functions be executed at compile time.

Other writing I've seen suggests that CTFE is an optimization, not a language
requirement.  What exactly is required of any D compiler?

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list