| 2431 | |
| 2432 | template <typename T> |
| 2433 | static std::unique_ptr<T> cloneUnique(const std::unique_ptr<T> &p) { |
| 2434 | std::unique_ptr<T> r; |
| 2435 | if (p) { |
| 2436 | r = std::unique_ptr<T>(new T(*p)); |
| 2437 | } |
| 2438 | return r; |
| 2439 | } |
| 2440 | |
| 2441 | // This is a walkaround to avoid the static initialization of Value::null. |
| 2442 | // kNull must be word-aligned to avoid crashing on ARM. We use an alignment of |
no outgoing calls
no test coverage detected