Skip to content

Commit 5f18548

Browse files
committed
Fixed problem where GCC < 6 wouldn't compile Crow
1 parent f52ba61 commit 5f18548

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

include/crow/json.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,16 @@
1616
#include <boost/algorithm/string/predicate.hpp>
1717
#include <boost/operators.hpp>
1818
#include <vector>
19-
#include <math.h>
19+
#include <cmath>
2020

2121
#include "crow/utility.h"
2222
#include "crow/settings.h"
2323
#include "crow/returnable.h"
2424
#include "crow/logging.h"
2525

26+
using std::isinf;
27+
using std::isnan;
28+
2629

2730
namespace crow
2831
{

include/crow/routing.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -775,7 +775,7 @@ namespace crow
775775
if (pos == req_url.size())
776776
{
777777
found_BP = std::move(*blueprints);
778-
return {node->rule_index, *blueprints, *params};
778+
return std::tuple<uint16_t, std::vector<uint16_t>, routing_params>{node->rule_index, *blueprints, *params};
779779
}
780780

781781
bool found_fragment = false;
@@ -902,7 +902,7 @@ namespace crow
902902
if (!found_fragment)
903903
found_BP = std::move(*blueprints);
904904

905-
return {found, found_BP, match_params}; //Called after all the recursions have been done
905+
return std::tuple<uint16_t, std::vector<uint16_t>, routing_params>{found, found_BP, match_params}; //Called after all the recursions have been done
906906
}
907907

908908
//This functions assumes any blueprint info passed is valid

0 commit comments

Comments
 (0)