Merge pull request #967 from syranide/noie8catch

Remove unnecessary catch-clauses for try-finally
This commit is contained in:
Paul O’Shannessy
2014-02-04 10:11:06 -08:00
4 changed files with 0 additions and 15 deletions
-5
View File
@@ -1001,8 +1001,6 @@ var ReactCompositeComponentMixin = {
this._currentContext = nextFullContext;
this.context = nextContext;
}
} catch (e) {
throw e;
} finally {
this._compositeLifeCycleState = null;
}
@@ -1164,9 +1162,6 @@ var ReactCompositeComponentMixin = {
ReactCurrentOwner.current = this;
try {
renderedComponent = this.render();
} catch (error) {
// IE8 requires `catch` in order to use `finally`.
throw error;
} finally {
ReactContext.current = previousContext;
ReactCurrentOwner.current = null;
-3
View File
@@ -56,9 +56,6 @@ var ReactContext = {
ReactContext.current = merge(previousContext, newContext);
try {
result = scopedCallback();
} catch (error) {
// IE8 requires `catch` in order to use `finally`.
throw error;
} finally {
ReactContext.current = previousContext;
}
-3
View File
@@ -79,9 +79,6 @@ function flushBatchedUpdates() {
// Run these in separate functions so the JIT can optimize
try {
runBatchedUpdates();
} catch (e) {
// IE 8 requires catch to use finally.
throw e;
} finally {
clearDirtyComponents();
}
@@ -737,8 +737,6 @@ describe('ReactCompositeComponent', function() {
);
NamedComponent(); // Shut up lint
} catch (e) {
throw e;
} finally {
console.warn = warn;
}
@@ -780,8 +778,6 @@ describe('ReactCompositeComponent', function() {
'createClass(...): `childContextTypes` is now a static property and ' +
'should be defined inside "statics".'
);
} catch (e) {
throw e;
} finally {
console.warn = warn;
}