aboutsummaryrefslogtreecommitdiff
path: root/src/parser/grammar/types.rs
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2018-02-10 09:35:40 +0000
committerAleksey Kladov <[email protected]>2018-02-10 09:35:40 +0000
commit2ef16a4121ad497e7fb290445ffe644b6b8ceae6 (patch)
treec9e86b4c2e02c19433f7c6cf8f73578602fb9d26 /src/parser/grammar/types.rs
parent419b9b7e5efd895249934551cb2588b27a956f58 (diff)
G: type item
Diffstat (limited to 'src/parser/grammar/types.rs')
-rw-r--r--src/parser/grammar/types.rs11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/parser/grammar/types.rs b/src/parser/grammar/types.rs
index 1a3d44a0a..c798edd08 100644
--- a/src/parser/grammar/types.rs
+++ b/src/parser/grammar/types.rs
@@ -1,5 +1,14 @@
1use super::*; 1use super::*;
2 2
3pub(super) fn type_ref(p: &mut Parser) { 3pub(super) fn type_ref(p: &mut Parser) {
4 p.expect(IDENT); 4 match p.current() {
5 IDENT => p.bump(),
6 L_PAREN => {
7 p.bump();
8 p.expect(R_PAREN);
9 }
10 _ => {
11 p.error("expected type");
12 }
13 }
5} 14}