| 54 | { |
| 55 | template <typename T> |
| 56 | static std::unique_ptr<T> cloneUnique(const std::unique_ptr<T>& p) { |
| 57 | std::unique_ptr<T> r; |
| 58 | if (p) { |
| 59 | r = std::unique_ptr<T>(new T(*p)); |
| 60 | } |
| 61 | return r; |
| 62 | } |
| 63 | |
| 64 | // This is a walkaround to avoid the static initialization of Value::null. |
| 65 | // kNull must be word-aligned to avoid crashing on ARM. We use an alignment of |