2

Closed

Declare does not work for enums

description

declare enum foo {
    bar,
}
will generate code (which ambients should not perhaps)
var foo;
(function (foo) {
    foo[foo["bar"] = 0] = "bar";
})(foo || (foo = {}));
Closed Nov 19, 2013 at 9:27 PM by RyanCavanaugh
Thanks for reporting this! The issue has been fixed and can be tried out in the upcoming 0.9.5 release. We also have a beta available (https://typescript.codeplex.com/wikipage?title=TypeScript%200.9.5%20beta) if you'd like to try it out.

comments

danquirk wrote Sep 18, 2013 at 11:42 PM

Thanks for the report, you're right, we actually just noticed this the other day but it is not yet fixed. Marked as active.