Tajmahal#19
Conversation
| #include<bits/stdc++.h> | ||
| //} | ||
| //{ Loops | ||
| #define forab(i,a,b) for (__typeof(b) i = (a); i <= (b); ++i) |
There was a problem hiding this comment.
| #define forab(i,a,b) for (__typeof(b) i = (a); i <= (b); ++i) | |
| #define forab(i,a,b) for (__typeof(b) (i) = (a); (i) <= (b); ++(i)) |
This comment was generated with the following checker: ClangTidy
| #define forab(i,a,b) for (__typeof(b) i = (a); i <= (b); ++i) | ||
| #define rep(i,n) forab (i, 0, (n) - 1) | ||
| #define For(i,n) forab (i, 1, n) | ||
| #define rofba(i,a,b) for (__typeof(b) i = (b); i >= (a); --i) |
There was a problem hiding this comment.
| #define rofba(i,a,b) for (__typeof(b) i = (b); i >= (a); --i) | |
| #define rofba(i,a,b) for (__typeof(b) (i) = (b); (i) >= (a); --(i)) |
This comment was generated with the following checker: ClangTidy
| #define rofba(i,a,b) for (__typeof(b) i = (b); i >= (a); --i) | ||
| #define per(i,n) rofba (i, 0, (n) - 1) | ||
| #define rof(i,n) rofba (i, 1, n) | ||
| #define forstl(i,s) for (__typeof ((s).end ()) i = (s).begin (); i != (s).end (); ++i) |
There was a problem hiding this comment.
| #define forstl(i,s) for (__typeof ((s).end ()) i = (s).begin (); i != (s).end (); ++i) | |
| #define forstl(i,s) for (__typeof ((s).end ()) (i) = (s).begin (); (i) != (s).end (); ++(i)) |
This comment was generated with the following checker: ClangTidy
| #define abs(x) (((x) < 0) ? - (x) : (x)) | ||
| #define zero(x) (abs (x) < EPS) | ||
| #define equal(a,b) (zero ((a) - (b))) | ||
| #define PI 2*acos (0.0) |
There was a problem hiding this comment.
| #define PI 2*acos (0.0) | |
| #define PI (2*acos (0.0)) |
This comment was generated with the following checker: ClangTidy
| #define equal(a,b) (zero ((a) - (b))) | ||
| #define PI 2*acos (0.0) | ||
| //} | ||
| typedef long long int64; |
There was a problem hiding this comment.
| typedef long long int64; | |
| using int64 = long long; |
This comment was generated with the following checker: ClangTidy
| #define PI 2*acos (0.0) | ||
| //} | ||
| typedef long long int64; | ||
| typedef unsigned long long int64u; |
There was a problem hiding this comment.
| typedef unsigned long long int64u; | |
| using int64u = unsigned long long; |
This comment was generated with the following checker: ClangTidy
| typedef long long int64; | ||
| typedef unsigned long long int64u; | ||
| #define memo(a,v) memset(a,v,sizeof(a)) | ||
| #define all(a) a.begin(),a.end() |
There was a problem hiding this comment.
| #define all(a) a.begin(),a.end() | |
| #define all(a) a.begin(),(a).end() |
This comment was generated with the following checker: ClangTidy
| }; | ||
| } | ||
|
|
||
| Image* loadBMP(const char* filename) { |
There was a problem hiding this comment.
The function is too long
loadBMP( const char * filename) now spans 55 lines.
Corresponding modifications started here.
Keep your functions' length within 50 lines to improve readability.
This comment was generated with the following checker: long_method
| }; | ||
| } | ||
|
|
||
| Image* loadBMP(const char* filename) { |
There was a problem hiding this comment.
The function is too complicated
loadBMP( const char * filename) now has cyclomatic complexity of 15.
Corresponding modifications started here.
Split your routines to keep cyclomatic complexity below 10 to improve their maintainability.
This comment was generated with the following checker: high_cyclomatic_complexity
| }; | ||
| } | ||
|
|
||
| Image* loadBMP(const char* filename) { |
There was a problem hiding this comment.
The function is too long
loadBMP( const char * filename) now spans 55 lines.
Corresponding modifications started here.
Keep your functions' length within 50 lines to improve readability.
This comment was generated with the following checker: long_method
| }; | ||
| } | ||
|
|
||
| Image* loadBMP(const char* filename) { |
There was a problem hiding this comment.
The function is too complicated
loadBMP( const char * filename) now has cyclomatic complexity of 15.
Corresponding modifications started here.
Split your routines to keep cyclomatic complexity below 10 to improve their maintainability.
This comment was generated with the following checker: high_cyclomatic_complexity
Source code for this PR was taken from following repository: https://github.com/math10/Computer-Graphics-lab