Commit 6d0d0f6
feat(joystick/vector): Update to return
* feat(joystick/vector): Update to return `const ref` where possible
* Update `espp::Vector2d` and `espp::Joystick` to return const references where possible
Reduces the amount of unnecessary copies in application code
Build and run `math/example` and `joystick/example`
* add missing const ref to vector
* Update components/joystick/include/joystick.hpp
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* fix comments
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>const ref where possible (#416)1 parent 14b5bf0 commit 6d0d0f6
File tree
3 files changed
+8
-6
lines changed- components
- joystick
- include
- src
- math/include
3 files changed
+8
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
202 | 202 | | |
203 | 203 | | |
204 | 204 | | |
| 205 | + | |
205 | 206 | | |
206 | | - | |
| 207 | + | |
207 | 208 | | |
208 | 209 | | |
209 | 210 | | |
| |||
212 | 213 | | |
213 | 214 | | |
214 | 215 | | |
| 216 | + | |
215 | 217 | | |
216 | | - | |
| 218 | + | |
217 | 219 | | |
218 | 220 | | |
219 | 221 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
74 | 74 | | |
75 | 75 | | |
76 | 76 | | |
77 | | - | |
| 77 | + | |
78 | 78 | | |
79 | | - | |
| 79 | + | |
80 | 80 | | |
81 | 81 | | |
82 | 82 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
76 | 76 | | |
77 | 77 | | |
78 | 78 | | |
79 | | - | |
| 79 | + | |
80 | 80 | | |
81 | 81 | | |
82 | 82 | | |
| |||
88 | 88 | | |
89 | 89 | | |
90 | 90 | | |
91 | | - | |
| 91 | + | |
92 | 92 | | |
93 | 93 | | |
94 | 94 | | |
| |||
0 commit comments