Skip to content

Commit a584df1

Browse files
committed
Support default C++98 targets (remove C++11 used elements)
1 parent d8f4aee commit a584df1

2 files changed

Lines changed: 16 additions & 12 deletions

File tree

src/minbasecli.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ MINBASECLI::MINBASECLI()
7272
{
7373
this->added_commands[i].command[0] = '\0';
7474
this->added_commands[i].description[0] = '\0';
75-
this->added_commands[i].callback = nullptr;
75+
this->added_commands[i].callback = NULL;
7676
}
7777
memset(this->rx_read, (int)('\0'), MINBASECLI_MAX_READ_SIZE - 1U);
7878
memset(this->print_array, (int)('\0'), MINBASECLI_MAX_PRINT_SIZE - 1U);

src/minbasecli.h

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@
8181

8282
/*****************************************************************************/
8383

84-
/* Constants & Defines */
84+
/* Configuration Defines */
8585

8686
// Default CLI Interface to use if not provided
8787
#if !defined(MINBASECLI_DEFAULT_IFACE)
@@ -130,6 +130,20 @@
130130

131131
/*****************************************************************************/
132132

133+
/* Constants */
134+
135+
/**
136+
* @brief Builtin command "help" text.
137+
*/
138+
static const char CMD_HELP[] = "help";
139+
140+
/**
141+
* @brief Builtin command "help" description text.
142+
*/
143+
static const char CMD_HELP_DESCRIPTION[] = "Shows current info.";
144+
145+
/*****************************************************************************/
146+
133147
/* Data Types */
134148

135149
// CLI manage result data
@@ -233,16 +247,6 @@ class MINBASECLI : public MINBASECLI_HAL
233247

234248
private:
235249

236-
/**
237-
* @brief Builtin command "help" text.
238-
*/
239-
static constexpr char CMD_HELP[] = "help";
240-
241-
/**
242-
* @brief Builtin command "help" description text.
243-
*/
244-
static constexpr char CMD_HELP_DESCRIPTION[] = "Shows current info.";
245-
246250
/**
247251
* @brief CLI initialized flag.
248252
*/

0 commit comments

Comments
 (0)