Skip to content

Commit e71c69e

Browse files
author
Colin Robertson
authored
Merge pull request MicrosoftDocs#1808 from Panky-codes/vector-emplace-correction
Corrected the func definition for vector emplace
2 parents 2517b94 + 7d2c61d commit e71c69e

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

docs/standard-library/vector-class.md

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -794,18 +794,19 @@ The number '30' is in c1 collection 3 times.
794794
Inserts an element constructed in place into the vector at a specified position.
795795

796796
```cpp
797+
template <class... Types>
797798
iterator emplace(
798-
const_iterator _Where,
799-
Type&& val);
799+
const_iterator position,
800+
Types&&... args);
800801
```
801802
802803
### Parameters
803804
804-
*_Where*\
805+
*position*\
805806
The position in the [vector](../standard-library/vector-class.md) where the first element is inserted.
806807
807-
*val*\
808-
The value of the element being inserted into the `vector`.
808+
*args*\
809+
Constructor arguments. The function infers which constructor overload to invoke based on the arguments provided.
809810
810811
### Return Value
811812
@@ -863,12 +864,12 @@ Adds an element constructed in place to the end of the vector.
863864

864865
```cpp
865866
template <class... Types>
866-
void emplace_back(Types&&... _Args);
867+
void emplace_back(Types&&... args);
867868
```
868869
869870
### Parameters
870871
871-
*_Args*\
872+
*args*\
872873
Constructor arguments. The function infers which constructor overload to invoke based on the arguments provided.
873874
874875
### Example

0 commit comments

Comments
 (0)