-
Notifications
You must be signed in to change notification settings - Fork 14
/
grammar.html
82 lines (70 loc) · 2.33 KB
/
grammar.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
<!-- Copyright 2014 Google Inc. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!-- BNF Grammar block
Use this tag to declare a fragment of a grammar specification.
This sets the block within an indented region of text and changes
the default font-style to use italic.
Note that the spacing for the grammar is taken from the LaTeX
version of the draft standard (or as well as I can interpret
the spacing in LaTeX - a .9\textwidth minipage with tabs every
.6 inches).
-->
<polymer-element name="bnf-grammar" noscript>
<template>
<style>
:host { display: block; font-style:italic; margin-left:.35in; };
</style>
<content></content>
</template>
</polymer-element>
<!-- BNF rule
Defines a BNF production.
-->
<polymer-element name="bnf-rule" noscript>
<template>
<style>
:host { display: block; margin-left: .6in; }
</style>
<content></content>:
</template>
</polymer-element>
<!-- BNF rule alternative.
Indents the alternative beneath the rule name and applies
a line break.
-->
<polymer-element name="bnf-alt" noscript>
<template>
<style>
:host { display: block; margin-left:1.2in; }
</style>
<content></content>
</template>
</polymer-element>
<!-- BNF terminal
A terminal element in a BNF specification.
-->
<polymer-element name="bnf-terminal" noscript>
<template><style>
:host { font-style: normal; }
</style><code><content></content></code></template>
</polymer-element>
<!-- BNF optional element -->
<polymer-element name="bnf-opt" noscript>
<template><content></content><sub>opt</sub></template>
</polymer-element>
<!-- Grammar terms
A grammar term refers to a BNF production in the grammar.
TODO: Link grammar terms to their definitions?
-->
<polymer-element name="cxx-grammarterm" noscript>
<template><i><content></content></i></template>
</polymer-element>