| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 519 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 530 | 530 |
| 531 | 531 |
| 532 Extension::Extension(const char* name, | 532 Extension::Extension(const char* name, |
| 533 const char* source, | 533 const char* source, |
| 534 int dep_count, | 534 int dep_count, |
| 535 const char** deps, | 535 const char** deps, |
| 536 int source_length) | 536 int source_length) |
| 537 : name_(name), | 537 : name_(name), |
| 538 source_length_(source_length >= 0 ? | 538 source_length_(source_length >= 0 ? |
| 539 source_length : | 539 source_length : |
| 540 (source ? static_cast<int>(strlen(source)) : 0)), | 540 static_cast<int>(strlen(source))), |
| 541 source_(source, source_length_), | 541 source_(source, source_length_), |
| 542 dep_count_(dep_count), | 542 dep_count_(dep_count), |
| 543 deps_(deps), | 543 deps_(deps), |
| 544 auto_enable_(false) { } | 544 auto_enable_(false) { |
| 545 CHECK(source); |
| 546 } |
| 545 | 547 |
| 546 | 548 |
| 547 v8::Handle<Primitive> Undefined() { | 549 v8::Handle<Primitive> Undefined() { |
| 548 i::Isolate* isolate = i::Isolate::Current(); | 550 i::Isolate* isolate = i::Isolate::Current(); |
| 549 if (!EnsureInitializedForIsolate(isolate, "v8::Undefined()")) { | 551 if (!EnsureInitializedForIsolate(isolate, "v8::Undefined()")) { |
| 550 return v8::Handle<v8::Primitive>(); | 552 return v8::Handle<v8::Primitive>(); |
| 551 } | 553 } |
| 552 return v8::Handle<Primitive>(ToApi<Primitive>( | 554 return v8::Handle<Primitive>(ToApi<Primitive>( |
| 553 isolate->factory()->undefined_value())); | 555 isolate->factory()->undefined_value())); |
| 554 } | 556 } |
| (...skipping 5970 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6525 | 6527 |
| 6526 v->VisitPointers(blocks_.first(), first_block_limit_); | 6528 v->VisitPointers(blocks_.first(), first_block_limit_); |
| 6527 | 6529 |
| 6528 for (int i = 1; i < blocks_.length(); i++) { | 6530 for (int i = 1; i < blocks_.length(); i++) { |
| 6529 v->VisitPointers(blocks_[i], &blocks_[i][kHandleBlockSize]); | 6531 v->VisitPointers(blocks_[i], &blocks_[i][kHandleBlockSize]); |
| 6530 } | 6532 } |
| 6531 } | 6533 } |
| 6532 | 6534 |
| 6533 | 6535 |
| 6534 } } // namespace v8::internal | 6536 } } // namespace v8::internal |
| OLD | NEW |