MCPcopy Create free account
hub / github.com/Singular/Singular / vnew_array

Function vnew_array

kernel/oswrapper/vspace.h:552–559  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

550
551template <typename T>
552VRef<T> vnew_array(size_t n) {
553 VRef<T> result = VRef<T>::alloc(n);
554 T *ptr = result.as_ptr();
555 for (size_t i = 0; i < n; i++) {
556 new (ptr + i) T();
557 }
558 return result;
559}
560
561template <typename T>
562VRef<T> vnew_uninitialized_array(size_t n) {

Callers

nothing calls this directly

Calls 1

as_ptrMethod · 0.45

Tested by

no test coverage detected