| 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 2793 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2804 Template(); | 2804 Template(); |
| 2805 | 2805 |
| 2806 friend class ObjectTemplate; | 2806 friend class ObjectTemplate; |
| 2807 friend class FunctionTemplate; | 2807 friend class FunctionTemplate; |
| 2808 }; | 2808 }; |
| 2809 | 2809 |
| 2810 | 2810 |
| 2811 template<typename T> | 2811 template<typename T> |
| 2812 class ReturnValue { | 2812 class ReturnValue { |
| 2813 public: | 2813 public: |
| 2814 V8_INLINE(explicit ReturnValue(internal::Object** slot)); | 2814 template <class S> V8_INLINE(ReturnValue(const ReturnValue<S>& that)) |
| 2815 : value_(that.value_) { |
| 2816 TYPE_CHECK(T, S); |
| 2817 }; |
| 2815 // Handle setters | 2818 // Handle setters |
| 2816 template <typename S> V8_INLINE(void Set(const Persistent<S>& handle)); | 2819 template <typename S> V8_INLINE(void Set(const Persistent<S>& handle)); |
| 2817 template <typename S> V8_INLINE(void Set(const Handle<S> handle)); | 2820 template <typename S> V8_INLINE(void Set(const Handle<S> handle)); |
| 2818 // Fast primitive setters | 2821 // Fast primitive setters |
| 2819 V8_INLINE(void Set(bool value)); | 2822 V8_INLINE(void Set(bool value)); |
| 2820 V8_INLINE(void Set(double i)); | 2823 V8_INLINE(void Set(double i)); |
| 2821 V8_INLINE(void Set(int32_t i)); | 2824 V8_INLINE(void Set(int32_t i)); |
| 2822 V8_INLINE(void Set(uint32_t i)); | 2825 V8_INLINE(void Set(uint32_t i)); |
| 2823 // Fast JS primitive setters | 2826 // Fast JS primitive setters |
| 2824 V8_INLINE(void SetNull()); | 2827 V8_INLINE(void SetNull()); |
| 2825 V8_INLINE(void SetUndefined()); | 2828 V8_INLINE(void SetUndefined()); |
| 2826 // Convenience getter for Isolate | 2829 // Convenience getter for Isolate |
| 2827 V8_INLINE(Isolate* GetIsolate()); | 2830 V8_INLINE(Isolate* GetIsolate()); |
| 2831 |
| 2828 private: | 2832 private: |
| 2833 template<class F> friend class ReturnValue; |
| 2834 template<class F> friend class FunctionCallbackInfo; |
| 2835 template<class F> friend class PropertyCallbackInfo; |
| 2836 V8_INLINE(explicit ReturnValue(internal::Object** slot)); |
| 2829 internal::Object** value_; | 2837 internal::Object** value_; |
| 2830 }; | 2838 }; |
| 2831 | 2839 |
| 2832 | 2840 |
| 2833 /** | 2841 /** |
| 2834 * The argument information given to function call callbacks. This | 2842 * The argument information given to function call callbacks. This |
| 2835 * class provides access to information about the context of the call, | 2843 * class provides access to information about the context of the call, |
| 2836 * including the receiver, the number and values of arguments, and | 2844 * including the receiver, the number and values of arguments, and |
| 2837 * the holder of the function. | 2845 * the holder of the function. |
| 2838 */ | 2846 */ |
| (...skipping 3437 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6276 | 6284 |
| 6277 | 6285 |
| 6278 } // namespace v8 | 6286 } // namespace v8 |
| 6279 | 6287 |
| 6280 | 6288 |
| 6281 #undef V8EXPORT | 6289 #undef V8EXPORT |
| 6282 #undef TYPE_CHECK | 6290 #undef TYPE_CHECK |
| 6283 | 6291 |
| 6284 | 6292 |
| 6285 #endif // V8_H_ | 6293 #endif // V8_H_ |
| OLD | NEW |