[queue.cons.alloc] # 23 Containers library [[containers]](./#containers) ## 23.6 Container adaptors [[container.adaptors]](container.adaptors#queue.cons.alloc) ### 23.6.3 Class template queue [[queue]](queue#cons.alloc) #### 23.6.3.3 Constructors with allocators [queue.cons.alloc] [1](#1) [#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L15776) If uses_allocator_v is false the constructors in this subclause shall not participate in overload resolution[.](#1.sentence-1) [🔗](#lib:queue,constructor) `template constexpr explicit queue(const Alloc& a); ` [2](#2) [#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L15786) *Effects*: Initializes c with a[.](#2.sentence-1) [🔗](#lib:queue,constructor_) `template constexpr queue(const container_type& cont, const Alloc& a); ` [3](#3) [#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L15797) *Effects*: Initializes c with cont as the first argument and a as the second argument[.](#3.sentence-1) [🔗](#lib:queue,constructor__) `template constexpr queue(container_type&& cont, const Alloc& a); ` [4](#4) [#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L15809) *Effects*: Initializes c with std​::​move(cont) as the first argument and a as the second argument[.](#4.sentence-1) [🔗](#lib:queue,constructor___) `template constexpr queue(const queue& q, const Alloc& a); ` [5](#5) [#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L15821) *Effects*: Initializes c with q.c as the first argument and a as the second argument[.](#5.sentence-1) [🔗](#lib:queue,constructor____) `template constexpr queue(queue&& q, const Alloc& a); ` [6](#6) [#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L15833) *Effects*: Initializes c with std​::​move(q.c) as the first argument and a as the second argument[.](#6.sentence-1) [🔗](#lib:queue,constructor_____) `template constexpr queue(InputIterator first, InputIterator last, const Alloc& alloc); ` [7](#7) [#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L15846) *Effects*: Initializes c withfirst as the first argument,last as the second argument, andalloc as the third argument[.](#7.sentence-1) [🔗](#lib:queue,constructor______) `template<[container-compatible-range](container.intro.reqmts#concept:container-compatible-range "23.2.2.1 Introduction [container.intro.reqmts]") R, class Alloc> constexpr queue(from_range_t, R&& rg, const Alloc& a); ` [8](#8) [#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L15861) *Effects*: Initializes c withranges​::​to(std​::​forward(rg), a)[.](#8.sentence-1)