PROS Issue with C++ anyone know a fix?

In file included from /Applications/ARM/arm-none-eabi/include/c++/11.2.1/bits/specfun.h:46,
from /Applications/ARM/arm-none-eabi/include/c++/11.2.1/cmath:1935,
from ./include/api.h:24,
from ./include/main.h:37,
from src/TeamNumber/auton_helper_functions.cpp:1:
/Applications/ARM/arm-none-eabi/include/c++/11.2.1/limits:1673:7: internal compiler error: Illegal instruction: 4
1673 | min() _GLIBCXX_USE_NOEXCEPT { return FLT_MIN; }
| ^~~

What is the problem? I’m guessing you’re getting an error on line 4 for misusing min? Any other details? Posting an error message with no explanation of anything whatsoever is really not helpful. Thank you for catagorizing it correctly, though.

sorry about that, it comes from the file “c_cpp_properties.json” where I recently had to download “/opt/homebrew/bin/arm-none-eabi-gcc” through home-brew on (m1 Macboook pro just for cpu info) . and this is what’s in the file:
{
“configurations”: [
{
“name”: “Mac”,
“includePath”: [
{workspaceFolder}/**" ], "defines": [], "macFrameworkPath": [], "compilerPath": "/opt/homebrew/bin/arm-none-eabi-gcc", "cStandard": "gnu17", "cppStandard": "gnu++17", "intelliSenseMode": "macos-gcc-arm", "compileCommands": "{workspaceFolder}/compile_commands.json”
}
],
“version”: 4
}
and it tells me that
In file included from /Applications/ARM/arm-none-eabi/include/c++/11.2.1/bits/specfun.h:46,
from /Applications/ARM/arm-none-eabi/include/c++/11.2.1/cmath:1935,
from ./include/api.h:24,
from ./include/main.h:37,
from src/22204V/zooms_auton_helper_functions.cpp:1:
/Applications/ARM/arm-none-eabi/include/c++/11.2.1/limits:1673:7: internal compiler error: Illegal instruction: 4
1673 | min() _GLIBCXX_USE_NOEXCEPT { return FLT_MIN; }
| ^~~
Please submit a full bug report,
with preprocessed source if appropriate.
See https://bugs.linaro.org/ for instructions.

I should also mention that to format inline code, you use ``; whatever you put in it will look like this. To format multi-line code, use ``` on their own line, on the following lines your code, and after the last line three more back ticks.

Your post would look like this

sorry about that, it comes from the file “c_cpp_properties.json” where I recently had to download “/opt/homebrew/bin/arm-none-eabi-gcc” through home-brew on (m1 Macboook pro just for cpu info) . and this is what’s in the file:

{
“configurations”: [
{
“name”: “Mac”,
“includePath”: [
“ 
workspaceFolder/∗∗"],"defines":[],"macFrameworkPath":[],"compilerPath":"/opt
 {workspaceFolder}/compile_commands.json”
}
],
“version”: 4
}

and it tells me that

In file included from /Applications/ARM/arm-none-eabi/include/c++/11.2.1/bits/specfun.h:46,
from /Applications/ARM/arm-none-eabi/include/c++/11.2.1/cmath:1935,
from ./include/api.h:24,
from ./include/main.h:37,
from src/22204V/zooms_auton_helper_functions.cpp:1:
/Applications/ARM/arm-none-eabi/include/c++/11.2.1/limits:1673:7: internal compiler error: Illegal instruction: 4
1673 | min() _GLIBCXX_USE_NOEXCEPT { return FLT_MIN; }
| ^~~
Please submit a full bug report,
with preprocessed source if appropriate.
See https://bugs.linaro.org/ for instructions.

But when I said

What I wanted to know was something like

  • What is your code?
  • What are you trying to do?
  • What part of your code has an error?

So again, please read this post on writing help-able posts and add information accordingly.

1 Like

The problem that I am facing I believe is a bug with C++ however it forbids me from utilizing pros at the moment as the files will not compile. I am trying to simply make my code(build it) and my code is giving me an error which is in the Applications/ARM/arm-none-eabi/include/c++/11.2.1/limits:1673:7. which happens to be an external file. It seems that this is a known bug and how do I work around it is my main concern?

Last August PROS would not work correctly with gcc 10.3, not sure if that got fixed, perhaps it’s not compatible with gcc 11.2. @RanchSauce any idea ?

edit: seems it’s probably not a PROS issue.
https://www.mail-archive.com/gcc-bugs@gcc.gnu.org/msg709750.html

2 Likes

Yeah, late August PROS was fixed for that so it’s most likely a GCC issue.

1 Like

any tips on what I could do about that? revert to the older version?

I could downgrade to 10.3 and see if that fixes anything

used clang instead… thx for any help guys

1 Like