Fix error source location access for struct refactor.