Skip to content

Commit

Permalink
Allow ArrayTrait to access non-const T* through RawArray<T>
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewkww committed Mar 3, 2016
1 parent 026edeb commit 3353e81
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions types.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ struct ArrayTrait<RawArray<T> >
static const bool canGetData = true;
static const T* data(const ArrayType &array)
{ return array.data(); }
static T* data(ArrayType &array)
{ return array.data(); }

static size_t size(const ArrayType &array)
{ return array.size(); }
Expand Down

0 comments on commit 3353e81

Please sign in to comment.