Skip to content
This repository was archived by the owner on Oct 28, 2021. It is now read-only.

Commit 008c2ae

Browse files
committed
v1.1.4
1 parent 47f772e commit 008c2ae

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Clara v1.1.3
1+
# Clara v1.1.4
22
[![Build Status](https://travis-ci.org/catchorg/Clara.svg?branch=master)](https://travis-ci.org/catchorg/Clara)
33
[![Build status](https://ci.appveyor.com/api/projects/status/github/catchorg/Clara?brach=master&svg=true)](https://ci.appveyor.com/project/catchorg/clara)
44
[![codecov](https://codecov.io/gh/catchorg/Clara/branch/master/graph/badge.svg)](https://codecov.io/gh/catchorg/Clara)

include/clara.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
//
66
// See https://github.com/philsquared/Clara for more details
77

8-
// Clara v1.1.3
8+
// Clara v1.1.4
99

1010
#ifndef CLARA_HPP_INCLUDED
1111
#define CLARA_HPP_INCLUDED

single_include/clara.hpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
//
66
// See https://github.com/philsquared/Clara for more details
77

8-
// Clara v1.1.3
8+
// Clara v1.1.4
99

1010
#ifndef CLARA_HPP_INCLUDED
1111
#define CLARA_HPP_INCLUDED
@@ -21,6 +21,7 @@
2121
#ifndef CLARA_CONFIG_OPTIONAL_TYPE
2222
#ifdef __has_include
2323
#if __has_include(<optional>) && __cplusplus >= 201703L
24+
#include <optional>
2425
#define CLARA_CONFIG_OPTIONAL_TYPE std::optional
2526
#endif
2627
#endif
@@ -665,11 +666,11 @@ namespace detail {
665666
}
666667
#ifdef CLARA_CONFIG_OPTIONAL_TYPE
667668
template<typename T>
668-
inline auto convertInto( std::string const &source, std::optional<T>& target ) -> ParserResult {
669+
inline auto convertInto( std::string const &source, CLARA_CONFIG_OPTIONAL_TYPE<T>& target ) -> ParserResult {
669670
T temp;
670671
auto result = convertInto( source, temp );
671672
if( result )
672-
target = temp;
673+
target = std::move(temp);
673674
return result;
674675
}
675676
#endif // CLARA_CONFIG_OPTIONAL_TYPE

0 commit comments

Comments
 (0)