Permalink
Browse files

some fixes from Rainer to allow grammar extraction

  • Loading branch information...
1 parent e4104ad commit ae532130f0374079c93a2c8f0609f04705dd8f82 Trass3r committed Apr 4, 2011
Showing with 2 additions and 22 deletions.
  1. +0 −20 attribute.dd
  2. +0 −2 expression.dd
  3. +2 −0 template.dd
View
@@ -276,10 +276,6 @@ $(GNAME ProtectionAttribute):
<h2>$(LNAME2 const, Const Attribute)</h2>
-$(GRAMMAR
-$(B const)
-)
-
$(P The $(B const) attribute declares constants that can be
evaluated at compile time. For example:
)
@@ -391,10 +387,6 @@ void main()
<h2>$(LNAME2 override, Override Attribute)</h2>
-$(GRAMMAR
-$(B override)
-)
-
$(P The $(B override) attribute applies to virtual functions.
It means that the function must override a function with the
same name and parameters in a base class. The override attribute
@@ -422,10 +414,6 @@ class Foo2 : Foo
<h2>Static Attribute</h2>
-$(GRAMMAR
-$(B static)
-)
-
$(P The $(B static) attribute applies to functions and data.
It means that the declaration does not apply to a particular
instance of an object, but to the type of the object. In
@@ -471,10 +459,6 @@ private int y = 4; // y is local to module foo
<h2>$(LNAME2 auto, Auto Attribute)</h2>
-$(GRAMMAR
-$(B auto)
-)
-
$(P The $(B auto) attribute is used when there are no other attributes
and type inference is desired.
)
@@ -485,10 +469,6 @@ auto i = 6.8; // declare i as a double
<h2>$(LNAME2 scope, Scope Attribute)</h2>
-$(GRAMMAR
-$(B scope)
-)
-
$(P
The $(B scope) attribute is used for local variables and for class
declarations. For class declarations, the $(B scope) attribute creates
View
@@ -656,15 +656,13 @@ $(GNAME CatExpression):
<h2>Mul Expressions</h2>
-$(V1
$(GRAMMAR
$(GNAME MulExpression):
$(GLINK UnaryExpression)
$(I MulExpression) $(B *) $(GLINK UnaryExpression)
$(I MulExpression) $(B /) $(GLINK UnaryExpression)
$(I MulExpression) $(B %) $(GLINK UnaryExpression)
)
-)
$(P The operands must be arithmetic types. They undergo integral
promotions, and then are brought to a common type using the
View
@@ -1001,11 +1001,13 @@ $(V2
<h2>Template Constraints</h2>
---
+$(GRAMMAR
$(GNAME Constraint):
$(B if) $(B $(LPAREN)) $(I ConstraintExpression) $(B $(RPAREN))
$(I ConstraintExpression):
$(I $(GLINK2 expression, Expression))
+)
---
$(P $(I Constraint)s are used to impose additional constraints

0 comments on commit ae53213

Please sign in to comment.