From 7c2c2a3114bdd4db60ab96f5a7a3f43e01582abc Mon Sep 17 00:00:00 2001 From: Martin Carlberg Date: Mon, 12 Aug 2013 09:40:20 +0200 Subject: [PATCH] Fixed: Allow protocols in interface declaration --- Objective-J/acorn.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/Objective-J/acorn.js b/Objective-J/acorn.js index 6bf3a54a8..9724bf05d 100644 --- a/Objective-J/acorn.js +++ b/Objective-J/acorn.js @@ -2116,6 +2116,19 @@ var preIfLevel = 0; node.categoryname = parseIdent(true); expect(_parenR, "Expected closing ')' after category name"); } + if (tokVal === '<') { + next(); + var protocols = [], + first = true; + node.protocols = protocols; + while (tokVal !== '>') { + if (!first) + expect(_comma, "Expected ',' between protocol names"); + else first = false; + protocols.push(parseIdent(true)); + } + next(); + } if (eat(_braceL)) { node.ivardeclarations = []; for (;;) {