From 9853c9d78debaf7c502bbcee0cb080922f6c2ab0 Mon Sep 17 00:00:00 2001 From: Sebastian McKenzie Date: Sat, 10 Jan 2015 22:42:35 +1100 Subject: [PATCH] add empty statement case to toBlock --- lib/6to5/types/index.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/6to5/types/index.js b/lib/6to5/types/index.js index c132e8860a..3e21e4d7c8 100644 --- a/lib/6to5/types/index.js +++ b/lib/6to5/types/index.js @@ -320,6 +320,10 @@ t.toBlock = function (node, parent) { return node; } + if (t.isEmptyStatement(node)) { + node = []; + } + if (!Array.isArray(node)) { if (!t.isStatement(node)) { if (t.isFunction(parent)) {