mirror of
https://github.com/HowardHinnant/date.git
synced 2024-12-27 16:41:04 +08:00
Merge pull request #43 from tomy2105/master
Fixes for move constructors and assignment operators added for VS2013
This commit is contained in:
commit
f3ce2210e6
24
tz.h
24
tz.h
@ -208,7 +208,7 @@ public:
|
||||
Zone(Zone&& src)
|
||||
:
|
||||
name_(std::move(src.name_)),
|
||||
zonelets_(std::move(zonelets_))
|
||||
zonelets_(std::move(src.zonelets_))
|
||||
{}
|
||||
|
||||
Zone& operator=(Zone&& src)
|
||||
@ -582,26 +582,28 @@ struct TZ_DB
|
||||
#else // defined(_MSC_VER) || (_MSC_VER >= 1900)
|
||||
TZ_DB(TZ_DB&& src)
|
||||
:
|
||||
version(std::move(src.version)),
|
||||
zones(std::move(src.zones)),
|
||||
links(std::move(links)),
|
||||
leaps(std::move(leaps)),
|
||||
rules(std::move(rules))
|
||||
links(std::move(src.links)),
|
||||
leaps(std::move(src.leaps)),
|
||||
rules(std::move(src.rules))
|
||||
#if TIMEZONE_MAPPING
|
||||
,
|
||||
mappings(std::move(mappings)),
|
||||
native_zones(std::move(native_zones))
|
||||
mappings(std::move(src.mappings)),
|
||||
native_zones(std::move(src.native_zones))
|
||||
#endif
|
||||
{}
|
||||
|
||||
TZ_DB& operator=(TZ_DB&& src)
|
||||
{
|
||||
version = std::move(src.version);
|
||||
zones = std::move(src.zones);
|
||||
links = std::move(links);
|
||||
leaps = std::move(leaps);
|
||||
rules = std::move(rules);
|
||||
links = std::move(src.links);
|
||||
leaps = std::move(src.leaps);
|
||||
rules = std::move(src.rules);
|
||||
#if TIMEZONE_MAPPING
|
||||
mappings = std::move(mappings);
|
||||
native_zones = std::move(native_zones);
|
||||
mappings = std::move(src.mappings);
|
||||
native_zones = std::move(src.native_zones);
|
||||
#endif
|
||||
return *this;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user