decompiler  1.0.0
Static Public Member Functions | Public Attributes | List of all members
BlockSwitch::CaseOrder Struct Reference

A class for annotating and sorting the individual cases of the switch. More...

Static Public Member Functions

static bool compare (const CaseOrder &a, const CaseOrder &b)
 Compare two cases. More...
 

Public Attributes

FlowBlockblock
 The structured case block.
 
const FlowBlockbasicblock
 The first basic-block to execute within the case block.
 
uintb label
 The label for this case, as an untyped constant.
 
int4 depth
 How deep in a fall-thru chain we are.
 
int4 chain
 Who we immediately chain to, expressed as caseblocks index, -1 for no chaining.
 
int4 outindex
 Index coming out of switch to this case.
 
uint4 gototype
 (If non-zero) What type of unstructured case is this?
 
bool isexit
 Does this case flow to the exit block.
 
bool isdefault
 True if this is formal default case for the switch.
 

Detailed Description

A class for annotating and sorting the individual cases of the switch.

Member Function Documentation

◆ compare()

bool BlockSwitch::CaseOrder::compare ( const CaseOrder a,
const CaseOrder b 
)
inlinestatic

Compare two cases.

Cases are compared by their label

Parameters
ais the first case to compare
bis the second
Returns
true if the first comes before the second

References depth, and label.

Referenced by BlockSwitch::orderSwitchCases().


The documentation for this struct was generated from the following file: