facebookarchive / prepack

A JavaScript bundle optimizer.
http://prepack.io
Other
14.21k stars 424 forks source link

Return correct recovery code for FatalError #2548

Closed sb98052 closed 6 years ago

sb98052 commented 6 years ago

In support of #2547. Sometimes, it is more desirable (less costly, better for debugging) to flag a warning for a possibly anomalous condition, than to assume that it is anomalous and enforce it as an error. This change exposes warnings that a user upgrades to errors, so that they can then be enforced as such.

sb98052 commented 6 years ago

Ok, I'm going to abandon most of this - but keep a small nit I fixed in the process. I'll solve the problem this was to address differently.