I found this seems to happen whenever a hyphen is in the file name.
'let A =1 in A' | Out-File My-File.pq
pqnet.exe My-File.pq
#Token Equal expected. Start position: (4, 10). End position (4,11).
The start/end position numbers in the error message depend on the position of the hyphen in the name. pqnet.exe 'My-File.pq' doesn't help.