Arshad Sofware Reengineering
Arshad Sofware Reengineering
Arshad Sofware Reengineering
ID 12234
Name Arshad Khan
Subject Software Reengineering
Submitted to Mam Zartashia Najaf
Introduction:
The process of examining the source code of a software application or program without actually
executing it. The goal of source code analysis is to identify potential issues, vulnerabilities, and
defects in the codebase, as well as to ensure that the code adheres to coding standards and best
practices. This analysis is typically performed by automated tools or manual review by software
developers.
Choosing Project:
For this analysis, we chose the open-source Flutter project calculator from GitHub.
Link:https://github.com/Mukhiddin3888/sqlliteflutterapp/tree/main
1. flutter analyze:
Purpose: This tool performs static analysis on the Flutter project, identifying potential
issues such as type errors, unused imports, and other code quality concerns.
Integration:
Included as part of the Flutter SDK.
Run using the command flutter analyze in the project directory.
Results:
Identified and documented issues related to type safety and unused variables.
1. flutter analyze:
Run the flutter analyze command in the terminal.
Reviewed the generated report for potential issues.
Documented identified issues and their impact on code quality.
Run Analysis: Executed the source code analysis tools and documented the following:
flutter analyze:
○ Output of static analysis, including warnings and potential errors.
Screen shots:
Errors Detected:
○ Local variable:
The variable named 'database' is declared but not used in the code.
Result:
● If the variable is not intended for use, you may consider removing it. If it's meant to be used
later in your code, make sure to utilize it to avoid unnecessary declarations.
● Consider using const with the constructor call if applicable. This can improve performance
by using compile-time constants.
Conclusion:
This solution document outlines the process of integrating and utilizing source code analysis tools
in Flutter development. The selected tools, flutter analyze proved effective in identifying and
addressing issues related to code quality and consistency. The experience gained through this
analysis underscores the importance of incorporating source code analysis tools into the
development workflow for better code maintainability and overall project success.