Error in math.h file while Autosar code generation

조회 수: 7 (최근 30일)
Namrata Biranje
Namrata Biranje 2020년 3월 9일
답변: Shivam Lahoti 2024년 11월 12일 9:36
Hello,
I am not understanding why I am getting the following MISRA error while compiing my .c file:
..\ansi\math.h 142 Error 10: Expecting ';'
..\ansi\math.h 142 Error 10: Expecting '{'
..\ansi\math.h 465 Error 129: declaration expected, identifier '__Ldouble_int_u' ignored
..\ansi\math.h 465 Error 19: Useless Declaration
..\ansi\math.h 489 Error 10: Expecting ';'
..\ansi\math.h 489 Error 10: Expecting '{'
..\ansi\math.h 773 Error 10: Expecting ';'
..\ansi\math.h 773 Error 10: Expecting '{'
Please help.
  댓글 수: 2
Karthik C
Karthik C 2020년 4월 12일
which compiler you're using?
Namrata Biranje
Namrata Biranje 2020년 4월 16일
Hello Karthik C, Thanks for the response. I am not changing the compiler. I am using default compiler.

댓글을 달려면 로그인하십시오.

답변 (1개)

Shivam Lahoti
Shivam Lahoti 2024년 11월 12일 9:36
Hi Namrata,
I understand that you are encountering MISRA errors related to syntax issues while compiling your .c file, specifically pointing to the "math.h" header file.
These errors may indicate syntax issues, such as missing semicolons or braces, or a corrupted "math.h" file. Ensure that the header file is unaltered, and check your code for any preprocessor directives or conditional compilation issues that might be affecting the file's inclusion.
I hope this will help you resolve the issue.
Regards,
Shivam

카테고리

Help CenterFile Exchange에서 AUTOSAR Blockset에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by