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 572 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
583 return elements_accessors_[JSObject::EXTERNAL_UNSIGNED_INT_ELEMENTS]; | 583 return elements_accessors_[JSObject::EXTERNAL_UNSIGNED_INT_ELEMENTS]; |
584 case EXTERNAL_FLOAT_ARRAY_TYPE: | 584 case EXTERNAL_FLOAT_ARRAY_TYPE: |
585 return elements_accessors_[JSObject::EXTERNAL_FLOAT_ELEMENTS]; | 585 return elements_accessors_[JSObject::EXTERNAL_FLOAT_ELEMENTS]; |
586 case EXTERNAL_DOUBLE_ARRAY_TYPE: | 586 case EXTERNAL_DOUBLE_ARRAY_TYPE: |
587 return elements_accessors_[JSObject::EXTERNAL_DOUBLE_ELEMENTS]; | 587 return elements_accessors_[JSObject::EXTERNAL_DOUBLE_ELEMENTS]; |
588 case EXTERNAL_PIXEL_ARRAY_TYPE: | 588 case EXTERNAL_PIXEL_ARRAY_TYPE: |
589 return elements_accessors_[JSObject::EXTERNAL_PIXEL_ELEMENTS]; | 589 return elements_accessors_[JSObject::EXTERNAL_PIXEL_ELEMENTS]; |
590 default: | 590 default: |
591 UNREACHABLE(); | 591 UNREACHABLE(); |
592 return NULL; | 592 return NULL; |
593 break; | |
594 } | 593 } |
595 } | 594 } |
596 | 595 |
597 | 596 |
598 void ElementsAccessor::InitializeOncePerProcess() { | 597 void ElementsAccessor::InitializeOncePerProcess() { |
599 static struct ConcreteElementsAccessors { | 598 static struct ConcreteElementsAccessors { |
600 FastElementsAccessor fast_elements_handler; | 599 FastElementsAccessor fast_elements_handler; |
601 FastDoubleElementsAccessor fast_double_elements_handler; | 600 FastDoubleElementsAccessor fast_double_elements_handler; |
602 DictionaryElementsAccessor dictionary_elements_handler; | 601 DictionaryElementsAccessor dictionary_elements_handler; |
603 NonStrictArgumentsElementsAccessor non_strict_arguments_elements_handler; | 602 NonStrictArgumentsElementsAccessor non_strict_arguments_elements_handler; |
(...skipping 22 matching lines...) Expand all Loading... |
626 &element_accessors.float_elements_handler, | 625 &element_accessors.float_elements_handler, |
627 &element_accessors.double_elements_handler, | 626 &element_accessors.double_elements_handler, |
628 &element_accessors.pixel_elements_handler | 627 &element_accessors.pixel_elements_handler |
629 }; | 628 }; |
630 | 629 |
631 elements_accessors_ = accessor_array; | 630 elements_accessors_ = accessor_array; |
632 } | 631 } |
633 | 632 |
634 | 633 |
635 } } // namespace v8::internal | 634 } } // namespace v8::internal |
OLD | NEW |