Mercurial > octave
changeset 31935:3e01ed656bc5
maint: Replace variable length array (C99 feature) with std::vector (C++ feature).
* oct-stream.cc: Add "#include <vector>".
* oct-stream.cc (textscan::do_scan): Declare variable "merge_with_prev" to be
of type "std::vector<bool>".
author | Rik <rik@octave.org> |
---|---|
date | Sat, 25 Mar 2023 17:37:15 -0700 |
parents | c56866c949f0 |
children | 9d5ccdbae3ad |
files | libinterp/corefcn/oct-stream.cc |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/libinterp/corefcn/oct-stream.cc Sat Mar 25 14:22:17 2023 -0700 +++ b/libinterp/corefcn/oct-stream.cc Sat Mar 25 17:37:15 2023 -0700 @@ -39,6 +39,7 @@ #include <iostream> #include <sstream> #include <string> +#include <vector> #include "Array.h" #include "Cell.h" @@ -2651,7 +2652,7 @@ // after reading in data. // If the format was "", that conversion may already have happened, // so force all to be merged (as all are %f). - bool merge_with_prev[fmt_list.numel ()]; + std::vector<bool> merge_with_prev (fmt_list.numel ()); int conv = 0; if (m_collect_output) {