Do a BackFlip for ais523!
JavaScript (ES6), 158 bytes

f=(a,x=0,y=0,d=3)=&gt;a[x]&amp;&amp;(c=a[x][y])?(a[x][y]=c=='.'?c:c=='/'?(d^=3,'\\'):c=='\\'?(d^=1,'/'):'v&gt;^&lt;'[d][d='^&lt;v&gt;'.search(c),0],f(a,d&lt;3?x+d-1:x,d?y+d-2:y,d)+1):1


Developed independently from @tsh's answer although strikingly similar.

The mapping of directions ^&lt;v&gt; to integers 0-3 is governed by the fact that .search('^') returns 0 since ^ is a regexp metacharacter.