Skip to content

Commit 80e1e16

Browse files
committed
Fixes from compiling with gcc 12
1 parent cdd648f commit 80e1e16

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

libraries/pico_vector/pretty_poly.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
#include <new>
77
#include <filesystem>
88
#include <fstream>
9+
#include <functional>
910

1011
#include "pretty_poly_types.hpp"
1112

libraries/pico_vector/pretty_poly_types.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#pragma once
22
#include <cstdint>
33
#include <math.h>
4+
#include <vector>
45

56
#ifdef PP_DEBUG
67
#define debug(...) printf(__VA_ARGS__)
@@ -138,7 +139,7 @@ namespace pretty_poly {
138139
unsigned count;
139140

140141
contour_t() {}
141-
contour_t(std::vector<point_t<T>> v) : points(v.data()), count(v.size()) {};
142+
contour_t(const std::vector<point_t<T>>& v) : points(v.data()), count(v.size()) {};
142143
contour_t(point_t<T> *points, unsigned count) : points(points), count(count) {};
143144

144145
// TODO: Make this work, it's so much nicer to use auto point : contour

0 commit comments

Comments
 (0)