Omniscia 0xPhase Audit
Code Style
Code Style
During the manual portion of the audit, we identified 37 optimizations that can be applied to the codebase that will decrease the operational cost associated with the execution of a particular function and generally ensure that the project complies with the latest best practices and standards in Solidity.
Additionally, this section of the audit contains any opinionated adjustments we believe the code should make to make it more legible as well as truer to its purpose.
These optimizations are enumerated below:
ID | Severity | Addressed | Title |
---|---|---|---|
ACL-01C | Inefficient mapping Lookups | ||
ACL-02C | Loop Iterator Optimization | ||
ACL-03C | Multiple Top-Level Declarations | ||
ACL-04C | Redundant Repetitive Invocations of Getter Function | ||
ACB-01C | Inefficient mapping Lookups | ||
ACB-02C | Loop Iterator Optimization | ||
ACB-03C | Redundant Repetitive Invocations of Getter Function | ||
COE-01C | Variable Mutability Specifiers (Immutable) | ||
DBV-01C | Inefficient Assignments of State | ||
DBV-02C | Inefficient Iteration of Expected Results | ||
DBV-03C | Loop Iterator Optimizations | ||
DBV-04C | Redundant Instantiations of Arrays | ||
DLI-01C | Inefficient mapping Lookups | ||
DLF-01C | Loop Iterator Optimization | ||
ERP-01C | Redundant In-Memory Variable | ||
ERV-01C | Ineffectual Usage of Safe Arithmetics | ||
ERV-02C | Redundant In-Memory Variable | ||
ETN-01C | Multiple Top-Level Declarations | ||
FRI-01C | Redundant Duplicate Getter Definition | ||
ICO-01C | Multiple Top-Level Declarations | ||
ICA-01C | Multiple Top-Level Declarations | ||
IDB-01C | Multiple Top-Level Declarations | ||
IPT-01C | Multiple Top-Level Declarations | ||
ISC-01C | Multiple Top-Level Declarations | ||
ITY-01C | Multiple Top-Level Declarations | ||
IVT-01C | Multiple Top-Level Declarations | ||
MRE-01C | Repetitive Value Literals | ||
MOE-01C | Loop Iterator Optimization | ||
MLB-01C | Ineffectual Usage of Safe Arithmetics | ||
MFT-01C | Loop Iterator Optimization | ||
MFT-02C | Potentially Dangerous Multicall Paradigm | ||
SCV-01C | Inefficient Variable Usage | ||
SCV-02C | Potentially Redundant Evaluation of Time | ||
TV1-01C | Redundant Duplicate Application of Access Control | ||
VAF-01C | Ineffectual Usage of Safe Arithmetics | ||
VBE-01C | Ineffectual Usage of Safe Arithmetics | ||
VLF-01C | Suboptimal Struct Declaration Styles |