Showing 8,683 of 8,684 total issues
Method To1bpp
has a Cognitive Complexity of 21 (exceeds 20 allowed). Consider refactoring. Open
public static byte[] To1bpp(string filename){
byte[] data = System.IO.File.ReadAllBytes(filename);
int raw_loc = BitmapConverter.GetInt(data,0xa,0xd);
int width = BitmapConverter.GetInt(data,0x12,0x15);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method Read
has a Cognitive Complexity of 21 (exceeds 20 allowed). Consider refactoring. Open
override public void Read()
{
string buffer = "";
System.Console.WriteLine("SPH_Magellan_Locking is deprecated; use SPH_Magellan_Scale or SPH_Magellan_Classic");
if (this.verbose_mode > 0)
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method Read
has a Cognitive Complexity of 21 (exceeds 20 allowed). Consider refactoring. Open
override public void Read()
{
string buffer = "";
if (this.verbose_mode > 0)
System.Console.WriteLine("Reading serial data");
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"