Skip to content

Commit 6a01a50

Browse files
committed
Merge #13180: Fix re-declared scoped enum as unscoped (Causes issues with some compilers)
43f3dec Remove enum specifier (to avoid re-declare scoped enum as unscoped) (donaloconnor) Pull request description: MSVC fails to compile with the changes made in #10742 The problem is enum types were changed to scoped (`enum class`) but in some places `enum` as an unscoped is used. This is a very simple fix and I've tested it. Edit: Had to remove enum altogether - `enum class` doesn't compile on clang. Tree-SHA512: 13e21666243585a133c74c81249a1fa4098d6b7aa3cda06be871fa017c0ad9bb7b0725f801160b9d31678448d668718197941fd84702ebdef15128c27d92cd70
2 parents a174702 + 43f3dec commit 6a01a50

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/rest.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ enum class RetFormat {
3333
};
3434

3535
static const struct {
36-
enum RetFormat rf;
36+
RetFormat rf;
3737
const char* name;
3838
} rf_names[] = {
3939
{RetFormat::UNDEF, ""},
@@ -68,7 +68,7 @@ static bool RESTERR(HTTPRequest* req, enum HTTPStatusCode status, std::string me
6868
return false;
6969
}
7070

71-
static enum RetFormat ParseDataFormat(std::string& param, const std::string& strReq)
71+
static RetFormat ParseDataFormat(std::string& param, const std::string& strReq)
7272
{
7373
const std::string::size_type pos = strReq.rfind('.');
7474
if (pos == std::string::npos)

0 commit comments

Comments
 (0)