Record Detail

Compile Error

/in/mySqrt.c: In function 'mySqrt':
/in/mySqrt.c:5:5: error: dereferencing type-punned pointer will break strict-aliasing rules [-Werror=strict-aliasing]
     int i = *(int*)&x;
     ^~~
/in/mySqrt.c:7:5: error: dereferencing type-punned pointer will break strict-aliasing rules [-Werror=strict-aliasing]
     x = *(float*)&i;
     ^
cc1: all warnings being treated as errors

Information

Submit By
Type
Submission
Homework
Midterm Exam 2
Language
C
Submit At
2022-07-07 15:20:45
Judged At
2022-07-08 16:06:00
Judged By
Score
0
Total Time
0ms
Peak Memory
0 Bytes