Span: Fix static assert message in default constructor.

pull/7828/head
Vincent Coubard 2018-08-22 13:31:26 +01:00
parent 26b546bab3
commit f6dd5eaa31
1 changed files with 4 additions and 1 deletions

View File

@ -98,7 +98,10 @@ struct Span {
* Extent != 0 .
*/
Span() : _data(NULL) {
MBED_STATIC_ASSERT(Extent == 0, "Invalid extent for a Span");
MBED_STATIC_ASSERT(
Extent == 0,
"Cannot default construct a static-extent Span (unless Extent is 0)"
);
}
/**