Fix some clang tidy things
This commit is contained in:
parent
fe03c440fb
commit
fd6e33711b
3 changed files with 8 additions and 8 deletions
|
@ -1,8 +1,8 @@
|
|||
#include "lcd.hpp"
|
||||
|
||||
lcd_grid lcd(std::string s1,
|
||||
std::string s2,
|
||||
std::string s3) {
|
||||
lcd_grid lcd(const std::string & s1,
|
||||
const std::string & s2,
|
||||
const std::string & s3) {
|
||||
lcd_grid result;
|
||||
result.push_back(s1);
|
||||
result.push_back(s2);
|
||||
|
|
|
@ -7,6 +7,6 @@ typedef std::vector<std::string> lcd_grid;
|
|||
|
||||
lcd_grid lcd(int value);
|
||||
|
||||
lcd_grid lcd(std::string s1,
|
||||
std::string s2,
|
||||
std::string s3);
|
||||
lcd_grid lcd(const std::string & s1,
|
||||
const std::string & s2,
|
||||
const std::string & s3);
|
||||
|
|
|
@ -3,14 +3,14 @@
|
|||
#include "lcd.hpp"
|
||||
#include <iostream>
|
||||
|
||||
std::string to_string(lcd_grid grid) {
|
||||
std::string to_string(const lcd_grid & grid) {
|
||||
std::stringstream output;
|
||||
for (const auto & str: grid)
|
||||
output << str;
|
||||
return output.str();
|
||||
}
|
||||
|
||||
void lcd_spec(int value, lcd_grid grid) {
|
||||
void lcd_spec(int value, const lcd_grid & grid) {
|
||||
std::string expected = to_string(grid),
|
||||
actual = to_string(lcd(value));
|
||||
if (expected != actual) {
|
||||
|
|
Loading…
Reference in a new issue