aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeil MacIntosh <neilmac@microsoft.com>2016-09-12 19:06:45 -0700
committerNeil MacIntosh <neilmac@microsoft.com>2016-09-12 19:06:45 -0700
commitbc70a93bba6c6f63486df55295145d043604a228 (patch)
tree49eaa4b10d928ee4145904d64a20345cab1d9c1d
parent3b2419532e8cdf78a4ba585f4dd15b9e08a4a48f (diff)
downloadplatform_external_Microsoft-GSL-bc70a93bba6c6f63486df55295145d043604a228.tar.gz
platform_external_Microsoft-GSL-bc70a93bba6c6f63486df55295145d043604a228.tar.bz2
platform_external_Microsoft-GSL-bc70a93bba6c6f63486df55295145d043604a228.zip
Removed unnecessary reinterpret_cast<> from span implementation.
-rw-r--r--gsl/span4
1 files changed, 2 insertions, 2 deletions
diff --git a/gsl/span b/gsl/span
index cce8253..d2e16dc 100644
--- a/gsl/span
+++ b/gsl/span
@@ -420,7 +420,7 @@ public:
details::is_allowed_extent_conversion<OtherExtent, Extent>::value &&
details::is_allowed_element_type_conversion<OtherElementType, element_type>::value>>
constexpr span(const span<OtherElementType, OtherExtent>& other)
- : storage_(reinterpret_cast<pointer>(other.data()),
+ : storage_(static_cast<pointer>(other.data()),
details::extent_type<OtherExtent>(other.size()))
{
}
@@ -431,7 +431,7 @@ public:
details::is_allowed_extent_conversion<OtherExtent, Extent>::value &&
details::is_allowed_element_type_conversion<OtherElementType, element_type>::value>>
constexpr span(span<OtherElementType, OtherExtent>&& other)
- : storage_(reinterpret_cast<pointer>(other.data()),
+ : storage_(static_cast<pointer>(other.data()),
details::extent_type<OtherExtent>(other.size()))
{
}