From 25f3f39ca6bbc7f7195eb32a80649119b9fdd61c Mon Sep 17 00:00:00 2001 From: John Chesley Date: Mon, 1 Apr 2019 20:20:12 -0400 Subject: [PATCH] do not hoist declaration if it is exported (fixes #2347) --- src/compile/Component.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/compile/Component.ts b/src/compile/Component.ts index 21f0b6ef05..376e5f5fc1 100644 --- a/src/compile/Component.ts +++ b/src/compile/Component.ts @@ -925,7 +925,7 @@ export default class Component { const v = this.var_lookup.get(d.id.name) if (v.reassigned) return false - if (v.export_name && v.export_name !== v.name) return false + if (v.export_name) return false if (this.var_lookup.get(d.id.name).reassigned) return false; if (this.vars.find(variable => variable.name === d.id.name && variable.module)) return false;