www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 2653] New: ConditionalStatement not referenced in rest of grammar

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2653

           Summary: ConditionalStatement not referenced in rest of grammar
           Product: D
           Version: 2.023
          Platform: PC
               URL: http://www.digitalmars.com/d/2.0/version.html
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: www.digitalmars.com
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: jlquinn optonline.net


Reading the text, I think the intent was to have the following

ConditionalDeclaration:
    Condition CCDeclarationBlock
    Condition CCDeclarationBlock else CCDeclarationBlock
    Condition : Declarations
    ConditionalStatement


-- 
Feb 09 2009
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2653





------- Comment #1 from jlquinn optonline.net  2009-02-09 08:48 -------
Looking into this further, dmd doesn't seem to distinguish between using
CCDeclarationBlock or NoScopeNonEmptyStatement.  The compiler's approach seems
reasonable to me. In that case, the grammar here should just be:

ConditionalDeclaration:
    Condition NoScopeNonEmptyStatement
    Condition NoScopeNonEmptyStatement else NoScopeNonEmptyStatement
    Condition : Declarations


-- 
Feb 09 2009
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2653


Walter Bright <bugzilla digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |bugzilla digitalmars.com
         Resolution|                            |INVALID


--- Comment #2 from Walter Bright <bugzilla digitalmars.com> 2012-01-23
00:17:50 PST ---
If a conditional is used in module scope, it cannot contain statements. Hence,
the existing grammar is correct.

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