| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 2096 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2107 | 2107 |
| 2108 // Create exit block. | 2108 // Create exit block. |
| 2109 Block* inner_finally = new(zone()) Block(NULL, 1, false); | 2109 Block* inner_finally = new(zone()) Block(NULL, 1, false); |
| 2110 inner_finally->AddStatement(new(zone()) WithExitStatement()); | 2110 inner_finally->AddStatement(new(zone()) WithExitStatement()); |
| 2111 | 2111 |
| 2112 // Create a try/finally statement. | 2112 // Create a try/finally statement. |
| 2113 TryFinallyStatement* inner_try_finally = | 2113 TryFinallyStatement* inner_try_finally = |
| 2114 new(zone()) TryFinallyStatement(inner_body, inner_finally); | 2114 new(zone()) TryFinallyStatement(inner_body, inner_finally); |
| 2115 inner_try_finally->set_escaping_targets(inner_collector.targets()); | 2115 inner_try_finally->set_escaping_targets(inner_collector.targets()); |
| 2116 | 2116 |
| 2117 catch_block = new (zone()) Block(NULL, 1, false); | 2117 catch_block = new(zone()) Block(NULL, 1, false); |
| 2118 catch_block->AddStatement(inner_try_finally); | 2118 catch_block->AddStatement(inner_try_finally); |
| 2119 } else { | 2119 } else { |
| 2120 Expect(Token::LBRACE, CHECK_OK); | 2120 Expect(Token::LBRACE, CHECK_OK); |
| 2121 } | 2121 } |
| 2122 | 2122 |
| 2123 tok = peek(); | 2123 tok = peek(); |
| 2124 } | 2124 } |
| 2125 | 2125 |
| 2126 Block* finally_block = NULL; | 2126 Block* finally_block = NULL; |
| 2127 if (tok == Token::FINALLY || catch_block == NULL) { | 2127 if (tok == Token::FINALLY || catch_block == NULL) { |
| (...skipping 2862 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4990 info->is_global(), | 4990 info->is_global(), |
| 4991 info->StrictMode()); | 4991 info->StrictMode()); |
| 4992 } | 4992 } |
| 4993 } | 4993 } |
| 4994 | 4994 |
| 4995 info->SetFunction(result); | 4995 info->SetFunction(result); |
| 4996 return (result != NULL); | 4996 return (result != NULL); |
| 4997 } | 4997 } |
| 4998 | 4998 |
| 4999 } } // namespace v8::internal | 4999 } } // namespace v8::internal |
| OLD | NEW |