/ Vijos /

记录详情

Compile Error

/in/foo.cc: In function 'void help()':
/in/foo.cc:31:2: error: reference to 'move' is ambiguous
  move=s;
  ^~~~
/in/foo.cc:13:34: note: candidates are: int move
 int nd[5][7],X[10],Y[10],Dir[10],move,flag;
                                  ^~~~
In file included from /usr/include/c++/7/bits/char_traits.h:39:0,
                 from /usr/include/c++/7/ios:40,
                 from /usr/include/c++/7/ostream:38,
                 from /usr/include/c++/7/iostream:39,
                 from /in/foo.cc:1:
/usr/include/c++/7/bits/stl_algobase.h:479:5: note:                 template<class _II, class _OI> _OI std::move(_II, _II, _OI)
     move(_II __first, _II __last, _OI __result)
     ^~~~
In file included from /usr/include/c++/7/bits/nested_exception.h:40:0,
                 from /usr/include/c++/7/exception:143,
                 from /usr/include/c++/7/ios:39,
                 from /usr/include/c++/7/ostream:38,
                 from /usr/include/c++/7/iostream:39,
                 from /in/foo.cc:1:
/usr/include/c++/7/bits/move.h:98:5: note:                 template<class _Tp> constexpr typename std::remove_reference< <template-parameter-1-1> >::type&& std::move(_Tp&&)
     move(_Tp&& __t) noexcept
     ^~~~
/in/foo.cc:38:37: error: reference to 'move' is ambiguous
    if(i<4&&nd[i][j]!=nd[i+1][j])dfs(move,i,j,1);
                                     ^~~~
/in/foo.cc:13:34: note: candidates are: int move
 int nd[5][7],X[10],Y[10],Dir[10],move,flag;
                                  ^~~~
In file included from /usr/include/c++/7/bits/char_traits.h:39:0,
                 from /usr/include/c++/7/ios:40,
                 from /usr/include/c++/7/ostream:38,
                 from /usr/include/c++/7/iostream:39,
                 from /in/foo.cc:1:
/usr/include/c++/7/bits/stl_algobase.h:479:5: note:                 template<class _II, class _OI> _OI std::move(_II, _II, _OI)
     move(_II __first, _II __last, _OI __result)
     ^~~~
In file included from /usr/include/c++/7/bits/nested_exception.h:40:0,
                 from /usr/include/c++/7/exception:143,
                 from /usr/include/c++/7/ios:39,
                 from /usr/include/c++/7/ostream:38,
                 from /usr/include/c++/7/iostream:39,
                 from /in/foo.cc:1:
/usr/include/c++/7/bits/move.h:98:5: note:                 template<class _Tp> constexpr typename std::remove_reference< <template-parameter-1-1> >::type&& std::move(_Tp&&)
     move(_Tp&& __t) noexcept
     ^~~~
/in/foo.cc:39:28: error: reference to 'move' is ambiguous
    if(i>0&&!nd[i-1][j])dfs(move,i,j,-1);
                            ^~~~
/in/foo.cc:13:34: note: candidates are: int move
 int nd[5][7],X[10],Y[10],Dir[10],move,flag;
                                  ^~~~
In file included from /usr/include/c++/7/bits/char_traits.h:39:0,
                 from /usr/include/c++/7/ios:40,
                 from /usr/include/c++/7/ostream:38,
                 from /usr/include/c++/7/iostream:39,
                 from /in/foo.cc:1:
/usr/include/c++/7/bits/stl_algobase.h:479:5: note:                 template<class _II, class _OI> _OI std::move(_II, _II, _OI)
     move(_II __first, _II __last, _OI __result)
     ^~~~
In file included from /usr/include/c++/7/bits/nested_exception.h:40:0,
                 from /usr/include/c++/7/exception:143,
                 from /usr/include/c++/7/ios:39,
                 from /usr/include/c++/7/ostream:38,
                 from /usr/include/c++/7/iostream:39,
                 from /in/foo.cc:1:
/usr/include/c++/7/bits/move.h:98:5: note:                 template<class _Tp> constexpr typename std::remove_reference< <template-parameter-1-1> >::type&& std::move(_Tp&&)
     move(_Tp&& __t) noexcept
     ^~~~
/in/foo.cc: In function 'void dfs(int, int, int, int)':
/in/foo.cc:155:6: warning: operation on 'move' may be undefined [-Wsequence-point]
    X[++move]=Y[move]=Dir[move]=0;
      ^~~~~~
/in/foo.cc:166:4: warning: operation on 'move' may be undefined [-Wsequence-point]
  X[++move]=Y[move]=Dir[move]=0;
    ^~~~~~

信息

递交者
类型
递交
题目
P1738 Mayan游戏
语言
C++
递交时间
2018-11-26 23:47:01
评测时间
2018-11-26 23:47:01
评测机
分数
0
总耗时
274ms
峰值内存
30.07 MiB