[#BloombergLP-bslalg-ScalarPrimitives-copyConstruct-09] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslalg.adoc[bslalg]::xref:BloombergLP/bslalg/ScalarPrimitives.adoc[ScalarPrimitives]::copyConstruct :relfileprefix: ../../../ :mrdocs: `copyConstruct` overloads == Synopses Declared in `<bslalg_scalarprimitives.h>` Build an object of the parameterized `TARGET_TYPE` from the specified `original` object of the same `TARGET_TYPE` in the uninitialized memory at the specified `address`, as if by using the copy constructor of `TARGET_TYPE`. If the specified `allocator` is based on `bslma::Allocator` and `TARGET_TYPE` takes an allocator constructor argument, then `allocator` is passed to the copy constructor. If the constructor throws, the `address` is left in an uninitialized state. Note that bit‐wise copy will be used if `TARGET_TYPE` has the bit‐wise copyable trait. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class TARGET_TYPE> static void xref:BloombergLP/bslalg/ScalarPrimitives/copyConstruct-02.adoc[copyConstruct]( TARGET_TYPE* address, TARGET_TYPE const& original, xref:BloombergLP/bslma/Allocator.adoc[bslma::Allocator]* allocator); ---- [.small]#xref:BloombergLP/bslalg/ScalarPrimitives/copyConstruct-02.adoc[_» more..._]# Same as the preceding overload, ignoring `allocator`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class TARGET_TYPE> static void xref:BloombergLP/bslalg/ScalarPrimitives/copyConstruct-01.adoc[copyConstruct]( TARGET_TYPE* address, TARGET_TYPE const& original, void* allocator); ---- [.small]#xref:BloombergLP/bslalg/ScalarPrimitives/copyConstruct-01.adoc[_» more..._]# [.small]#Created with https://www.mrdocs.com[MrDocs]#