@@ -46,12 +46,12 @@ class CharSetConverterImplBase {
4646 // / - std::errc::invalid_argument: The input contains an incomplete
4747 // / multibyte sequence.
4848 // /
49+ // / If the destination charset is a stateful character set, the shift state
50+ // / will be set to the initial state.
51+ // /
4952 // / In case of an error, the result string contains the successfully converted
5053 // / part of the input string.
5154 // /
52- // / If the destination charset is a stateful character set, the shift state
53- // / will be set to the initial state.
54-
5555 virtual std::error_code convert (StringRef Source,
5656 SmallVectorImpl<char > &Result) const = 0;
5757};
@@ -70,16 +70,15 @@ enum class id {
7070
7171// / Utility class to convert between different character set encodings.
7272class CharSetConverter {
73- // details::CharSetConverterImplBase *Converter;
7473 std::unique_ptr<details::CharSetConverterImplBase> Converter;
7574
7675 CharSetConverter (std::unique_ptr<details::CharSetConverterImplBase> Converter)
7776 : Converter(std::move(Converter)) {}
7877
7978public:
8079 // / Creates a CharSetConverter instance.
81- // / \param[in] CSFrom name of the source character encoding
82- // / \param[in] CSTo name of the target character encoding
80+ // / \param[in] CSFrom the source character encoding
81+ // / \param[in] CSTo the target character encoding
8382 // / \return a CharSetConverter instance
8483 static CharSetConverter create (text_encoding::id CSFrom,
8584 text_encoding::id CSTo);
@@ -95,9 +94,8 @@ class CharSetConverter {
9594 CharSetConverter (const CharSetConverter &) = delete ;
9695 CharSetConverter &operator =(const CharSetConverter &) = delete ;
9796
98- CharSetConverter (CharSetConverter &&Other) {
99- Converter = std::move (Other.Converter );
100- }
97+ CharSetConverter (CharSetConverter &&Other)
98+ : Converter(std::move(Other.Converter)) {}
10199
102100 CharSetConverter &operator =(CharSetConverter &&Other) {
103101 if (this != &Other)
0 commit comments