/in/foo.cc: In function 'void calheight(char*, int*, int)':
/in/foo.cc:37:22: error: reference to 'rank' is ambiguous
for(i=1; i<=n; i++) rank[sa[i]]=i;
^~~~
/in/foo.cc:7:5: note: candidates are: int rank [200005]
int rank[maxn],height[maxn],sa[maxn];
^~~~
In file included from /usr/include/c++/6/bits/move.h:57:0,
from /usr/include/c++/6/bits/stl_pair.h:59,
from /usr/include/c++/6/utility:70,
from /usr/include/c++/6/algorithm:60,
from /in/foo.cc:2:
/usr/include/c++/6/type_traits:1482:12: note: template<class> struct std::rank
struct rank
^~~~
/in/foo.cc:38:23: error: reference to 'rank' is ambiguous
for(i=0; i<n; height[rank[i++]]=k)
^~~~
/in/foo.cc:7:5: note: candidates are: int rank [200005]
int rank[maxn],height[maxn],sa[maxn];
^~~~
In file included from /usr/include/c++/6/bits/move.h:57:0,
from /usr/include/c++/6/bits/stl_pair.h:59,
from /usr/include/c++/6/utility:70,
from /usr/include/c++/6/algorithm:60,
from /in/foo.cc:2:
/usr/include/c++/6/type_traits:1482:12: note: template<class> struct std::rank
struct rank
^~~~
/in/foo.cc:39:20: error: reference to 'rank' is ambiguous
for(k?k--:0,j=sa[rank[i]-1]; r[i+k]==r[j+k]; k++);
^~~~
/in/foo.cc:7:5: note: candidates are: int rank [200005]
int rank[maxn],height[maxn],sa[maxn];
^~~~
In file included from /usr/include/c++/6/bits/move.h:57:0,
from /usr/include/c++/6/bits/stl_pair.h:59,
from /usr/include/c++/6/utility:70,
from /usr/include/c++/6/algorithm:60,
from /in/foo.cc:2:
/usr/include/c++/6/type_traits:1482:12: note: template<class> struct std::rank
struct rank
^~~~