diff --git a/lib/parse.js b/lib/parse.js index f2c2c48..445ad04 100644 --- a/lib/parse.js +++ b/lib/parse.js @@ -79,7 +79,12 @@ var flatteners = { 'instance': function (result) { result.scope = 'instance'; }, - // 'interface' + 'interface': function (result, tag) { + result.interface = true; + if (tag.description) { + result.name = tag.description; + } + }, 'kind': function (result, tag) { result.kind = tag.kind; }, diff --git a/test/lib/parse.js b/test/lib/parse.js index 24bd32d..e36fd53 100644 --- a/test/lib/parse.js +++ b/test/lib/parse.js @@ -254,6 +254,18 @@ test('parse - @instance', function (t) { t.end(); }); +test('parse - @interface', function (t) { + t.deepEqual(evaluate(function () { + /** @interface */ + })[0].interface, true, 'anonymous'); + + t.deepEqual(evaluate(function () { + /** @interface Foo */ + })[0].name, 'Foo', 'named'); + + t.end(); +}); + test('parse - @kind', function (t) { t.equal(evaluate(function () { /** @kind class */