Record Detail

Compile Error

In file included from /in/Compile/check.cpp:7:
/in/sokoban.hpp:38:16: error: implicit conversion changes signedness: 'int' to 'size_t' (aka 'unsigned long') [-Werror,-Wsign-conversion]
        return hash;
        ~~~~~~ ^~~~
/in/sokoban.hpp:350:22: error: implicit conversion loses integer precision: 'size_t' (aka 'unsigned long') to 'std::unordered_map<int, int, std::hash<int>, std::equal_to<int>, std::allocator<std::pair<const int, int> > >::key_type' (aka 'int') [-Werror,-Wshorten-64-to-32]
    store_gcost[init.getHash()] = 0;
    ~~~~~~~~~~~ ~~~~~^~~~~~~~~
/in/sokoban.hpp:358:25: error: implicit conversion loses integer precision: 'size_t' (aka 'unsigned long') to 'std::unordered_map<int, int, std::hash<int>, std::equal_to<int>, std::allocator<std::pair<const int, int> > >::key_type' (aka 'int') [-Werror,-Wshorten-64-to-32]
        if (store_gcost[current] < now.g_cost){
            ~~~~~~~~~~~ ^~~~~~~
/in/sokoban.hpp:397:37: error: implicit conversion loses integer precision: 'size_t' (aka 'unsigned long') to 'int' [-Werror,-Wshorten-64-to-32]
                int nextHash = next.getHash();
                    ~~~~~~~~   ~~~~~^~~~~~~~~
4 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-24 12:58:36
Judged At
2024-11-24 12:58:36
Judged By
Score
0
Total Time
0ms
Peak Memory
0 Bytes