The SDK provided by the solution provider compiles and runs normally using GCC on the X86 platform.
However, when using miPSEL -Linux-GCC cross-compilation, the error is reported from the first line of the code, as shown in the figure below:
Error: stray ‘239 \’ in the program
Error: stray ‘387 \’ in the program
The reason:
Placing boms in UTF-8 files is largely Microsoft’s custom (by the way, it’s also Microsoft’s custom to call a SMALL sequence UTF-16 with A BOM “Unicode” without specifying it). BOM (Byte Order Mark) is prepared for UTF-16 and UTF-32 and is used to mark byte order. Microsoft USES BOM in UTF-8 because it makes a clear distinction between encoding like UTF-8 and ASCII, but such files can cause problems in operating systems other than Windows.
No BOM is required in UTF-8, although the Unicode standard allows the use of Boms in UTF-8. So UTF-8 without BOM is the standard form.
Solutions:
Use VI to open the code and set the NoBomb item.
: set nobomb
Save and exit.
Or, add Settings to the system’s VIM configuration file and reopen ViM:
vim ~/.vimrc
However, when using miPSEL -Linux-GCC cross-compilation, the error is reported from the first line of the code, as shown in the figure below:
Error: stray ‘239 \’ in the program
Error: stray ‘387 \’ in the program
The reason:
Placing boms in UTF-8 files is largely Microsoft’s custom (by the way, it’s also Microsoft’s custom to call a SMALL sequence UTF-16 with A BOM “Unicode” without specifying it). BOM (Byte Order Mark) is prepared for UTF-16 and UTF-32 and is used to mark byte order. Microsoft USES BOM in UTF-8 because it makes a clear distinction between encoding like UTF-8 and ASCII, but such files can cause problems in operating systems other than Windows.
No BOM is required in UTF-8, although the Unicode standard allows the use of Boms in UTF-8. So UTF-8 without BOM is the standard form.
Solutions:
Use VI to open the code and set the NoBomb item.
: set nobomb
Save and exit.
Or, add Settings to the system’s VIM configuration file and reopen ViM:
vim ~/.vimrc
Read More:
- Solution to stray’\357′ in program when gcc is compiled
- error: stray ‘\240’ in program
- error: How to solve stray ‘\342’ in program
- error: stray ‘\302’ in program
- error: stray ‘\357’ in program
- C language error: stray ‘\ 240’ in program|
- A solution to the problem of “straight ‘\ 357’ in program” when compiling GCC
- Python program uses OS. System () method to call exe program, resulting in no response of main program process
- Visual studio 2017, OpenGL program running prompt glut32.dll missing solution
- Solution of vs program flashback problem
- Error: the solution of “241” and “343” in program
- The solution of flashing back after the end of console program running
- The perfect solution of VS2010 console program running in a flash
- Solution to prompt run time error “438” when a VB program is opened
- Solution to the flash of visual studio 2017 running program
- Solution to the flash of visual studio console program output window
- Solution of no response of progress bar in MFC program
- Vscode running C program error luanch:program does not exsist
- Cannot run program “git.exe”: CreateProcess error=2 the correct solution
- The solution of windows not flashing back when visual studio console program is running