Record Detail

Compile Error

In file included from /in/Compile/check.cpp:7:
/in/sokoban.hpp:12:9: error: keyword is hidden by macro definition [-Werror,-Wkeyword-macro]
#define unsigned long long ull;
        ^
/in/sokoban.hpp:64:32: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
            char cell = layout[static_cast<int>(i)][static_cast<int>(j)];
                        ~~~~~~ ^~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:64:53: error: implicit conversion changes signedness: 'int' to 'std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
            char cell = layout[static_cast<int>(i)][static_cast<int>(j)];
                        ~~~~~~                      ^~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:65:17: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
            map[static_cast<int>(i)][static_cast<int>(j)] = cell;
            ~~~ ^~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:65:38: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
            map[static_cast<int>(i)][static_cast<int>(j)] = cell;
            ~~~                      ^~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:93:12: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
    if(map[static_cast<int>(pos.row)][static_cast<int>(pos.col)] == '#'){
       ~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:93:39: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
    if(map[static_cast<int>(pos.row)][static_cast<int>(pos.col)] == '#'){
       ~~~                            ^~~~~~~~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:89:94: error: unused parameter 'boxes' [-Werror,-Wunused-parameter]
bool isValidMove(const GridPos& pos, const vector<vector<char>>& map, const vector<GridPos>& boxes) {
                                                                                             ^
/in/sokoban.hpp:102:35: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
    bool horizontalBlocked = (map[static_cast<int>(row - 1)][static_cast<int>(col)] == '#' && map[static_cast<int>(row + 1)][static_cast<int>(col)] == '#');
                              ~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:102:62: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
    bool horizontalBlocked = (map[static_cast<int>(row - 1)][static_cast<int>(col)] == '#' && map[static_cast<int>(row + 1)][static_cast<int>(col)] == '#');
                              ~~~                            ^~~~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:102:99: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
    bool horizontalBlocked = (map[static_cast<int>(row - 1)][static_cast<int>(col)] == '#' && map[static_cast<int>(row + 1)][static_cast<int>(col)] == '#');
                                                                                              ~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:102:126: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
    bool horizontalBlocked = (map[static_cast<int>(row - 1)][static_cast<int>(col)] == '#' && map[static_cast<int>(row + 1)][static_cast<int>(col)] == '#');
                                                                                              ~~~                            ^~~~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:103:33: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
    bool verticalBlocked = (map[static_cast<int>(row)][static_cast<int>(col - 1)] == '#' && map[static_cast<int>(row)][static_cast<int>(col + 1)] == '#');
                            ~~~ ^~~~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:103:56: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
    bool verticalBlocked = (map[static_cast<int>(row)][static_cast<int>(col - 1)] == '#' && map[static_cast<int>(row)][static_cast<int>(col + 1)] == '#');
                            ~~~                        ^~~~~~~~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:103:97: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
    bool verticalBlocked = (map[static_cast<int>(row)][static_cast<int>(col - 1)] == '#' && map[static_cast<int>(row)][static_cast<int>(col + 1)] == '#');
                                                                                            ~~~ ^~~~~~~~~~~~~~~~~~~~~
/in/sokoban.hpp:103:120: error: implicit conversion changes signedness: 'int' to 'std::vector::size_type' (aka 'unsigned long') [-Werror,-Wsign-conversion]
    bool verticalBlocked = (map[static_cast<int>(row)][static_cast<int>(col - 1)] == '#' && map[static_cast<int>(row)][static_cast<int>(col + 1)] == '#');
                                                                                            ~~~                        ^~~~~~~~~~~~~~~~~~~~~~~~~
16 errors generated.
/in/Compile/Makefile:16: recipe for target 'main' failed
make: *** [main] Error 1

Information

Submit By
Type
Submission
Homework
Project3
Language
C++
Submit At
2024-11-26 20:06:30
Judged At
2024-11-26 20:06:30
Judged By
Score
0
Total Time
0ms
Peak Memory
0 Bytes