PASCAL ANALYZER


Pascal Analyzer, or PAL for short, parses Delphi or Borland Pascal source code. It builds large internal tables of identifiers, and collects other information such as calls between subprograms. When the parsing is completed, extensive reports are produced. These reports contain a great deal of important information about the source code. This information will help you understand your source code better, and assist you in producing code of higher quality and reliability.

For a real world example of what PAL can do with your source code, visit TurboControl and download sample PAL reports for the Async Professional toolkit from TurboPower.

View a screenshot of the main screen in Pascal Analyzer.
For a full reference, view the documentation PDF or the online documentation. There is also a list of changes, or just read about the new features in version 7.

Pascal Analyzer provides a full collection of useful informative reports to both control and document the source code. These 51 reports are divided into five groups:

General Reports

 Status Report
PAL always generates this report, regardless of any setting. It presents important facts about the current analysis, e.g. selected compiler directives and searched folders.
Read more...

 Strong Warnings Report
This report generates warnings that help you identify especially severe errors. Those are errors that can cause runtime failures ("showstoppers"), or erroneous results in your application.
Read more...

 Warnings Report
This report consists of several lists with different types of warnings. The warnings point to possible anomalies and errors in the code.
Read more...

 Optimization Report
This report pinpoints elements of the code that you can improve, resulting in better performance.
Read more...

 Memory Report
This report helps you find locations in your code with possible memory leaks.
Read more...

 Code Reduction Report
This report pinpoints locations in your code where unnecessary code could be deleted, resulting in a smaller amount of code to maintain and search for errors.
Read more...

 Convention Compliance Report
This report contains several lists of identifiers that do not comply with the conventions for naming of identifiers.
Read more...

 Inconsistent Case Report
This report that lists all identifiers with inconsistent case. If for instance, the identifier tblEmployee is declared, and it is written as tblemployee in other locations, those places in the code are listed.
Read more...

 Prefix Report
This report contains a list with variables that have a different prefix than the defined ones. For instance you can decide that all TLabel variables must start with the letters 'lbl'. Labels that don't will then be listed by this report.
Read more...

 NextGen Readiness Report
This report measures how well your code is prepared for the new NextGen compiler.
Read more...



Metrics Reports

 Totals Report
This report provides a table that summarizes the number of files, procedures, functions, types etc, in the analyzed source code. It also shows how many of each category that are global, interfaced and unused.
Read more...

 Module Totals Report
This report produces similar results as the Totals Report, but divided for each module (unit).
Read more...

 Complexity Report
The Complexity Report lists for each unit and subprogram some important metrics.

Total Lines
Lines of Code (LOC)
Comment Lines
Comments/Total Lines
Decision Points (DP)
Decision Points/Lines of Code (DP/LOC)
Characters/Lines of Code

These metrics can help you evaluate source code in terms of understandability, complexity, and reusability. You can also locate complex subprograms that should be split up.

PAL also creates a list of all identifiers with names that are longer than 15 (default) characters.
Read more...

 Object-oriented Metrics Report
This report calculates six different metrics according to Chidamber and Kemerer's metrics suite for object-oriented design. These metrics are calculated for each class. With the help of these metrics you can get a better understanding of your classes.
Read more...



Reference Reports

 Modules Report
All modules are listed, indicating whether the corresponding source file was found or not. For the modules found, PAL reports the following data:

Lines
Size
Date
Time
Path

Read more...

 Identifiers Report
This report writes a table listing all the identifiers in the program indicating their type and location. Use this as an index for your source code, and to locate a specific identifier.
Read more...

 Duplicate Identifiers Report
This report produces a list of all identifiers that share the same name. Even if it is legal to duplicate identifier names, it may sometimes be confusing, and lead to bugs that are hard to find.
Read more...

 Similarity Report
This report produces listings of identifiers that have similar names.
Read more...

 Literal Strings Report
This report creates a list of all literal strings, both those declared as constants and those that are immersed in the code. You may use this report to locate and document all strings, for instance when translating your program to another language.
Read more...

 Subprogram Index Report
This report produces an index of all subprograms. Procedures, functions, constructors, destructors, and methods are reported. The indentation at the beginning of each line indicates which routines are nested within each another. This report helps you quickly locate any subprogram in your source code.
Read more...

 Bindings Report
This report produces a list of all subprograms (functions/procedures) in your source code. For each subprogram it documents all outside subprograms, variables etc that are referenced (used) by the subprogram. This gives a measure of how dependent a subprogram is of other code. Subprograms that have few bindings are more generic and stand-alone.
Read more...

 Third-party Dependencies Report
This report shows the dependency on third-party code. It shows which folders, units and identifiers that are referenced from code in the main file folder. It is often desirable to keep the dependency on third-party code as low as possible.
Read more...

 Most Called Report
This report lists, in descending order, the subprograms that are most often called.
Read more...

 Call Tree Report
Source code consists of calls from subprograms to other subprograms. From these subprograms, other subprograms are called. These calls form call trees.
Read more...

 Reverse Call Tree Report
This report produces an outline of the call structure of your program, like the Call Tree Report. But it does so in reverse order. This means it starts with the subprograms that are only called, and that not call any other subprograms. This report can help you get a better understanding of how your low-level routines are used.
Read more...

 Call Index Report
This report is similar to the Call Tree Report. For every subprogram, it lists which other subprograms that are called. In addition, it lists all calls from other subprograms to the particular subprogram.
Read more...

 Exception Report
This report shows an exception call tree, and produces a list of raised exceptions.
Read more...

 Brief Cross-reference Report
This report lists for each identifier, all locations where it is referenced and set.
Read more...

 Cross-reference Report
This report lists for each identifier, all locations where it is referenced and set. The layout is more spacious than in the Brief Cross-reference Report, but the content is equivalent.
Read more...

 Directives Report
This report displays information about various directives (like "deprecated").
Read more...

 To-Do Report
This report displays information about To-Do items that are entered in the source code or by the IDE.
Read more...

 Module Call Tree Report
This report shows a call tree for modules. It shows how modules "use" each other by inclusion in the uses lists in the interface and implementation sections.
Read more...

 Conditional Symbols Report
This report lists locations where a $DEFINE/$UNDEF or $IFDEF/$IFNDEF directive is unnecessarily repeated.
Read more...

 Used Outside Report
For each unit, every identifier is listed that is referenced from another units. This gives a measurement of how general the unit is.
Read more...

 Uses Report
This report lists all units that PAL finds. For each unit, the uses statements are analyzed. The units specified in these clauses are reported, indicating whether they are actually used.
Read more...



Class Reports

 Class Index Report
This report presents important facts about each class in the class hierarchy.
Read more...

 Class Summary Report
This report gives for each class a table of the methods, how many are static, inherited etc.
Read more...

 Class Hierarchy Report
This report creates a hierarchical list of all classes. Use this list to get an understanding of the class hierarchy in the source code.
Read more...

 Class Field Access Report
This is a list of all class fields that are accessed directly from the outside. This means that they are not accessed by means of a property. OOP purists consider this bad practice, and you should avoid this.
Read more...



Controls Reports

 Control Index Report
This is a list of all controls that are included in form files (DFM-files). You may use this report as an index to the controls.
Read more...

 Control Alignment Report
This report gives a list of the alignment of the controls. You may use this report to detect cases of incorrect alignment between controls.
Read more...

 Control Size Report
This report gives a list of the controls and their sizes. You may use this report to detect unwanted size differences.
Read more...

 Control Tab Order Report
This report lists all controls that possibly have an incorrect tab order. Normal tab order is considered as left to right, up down.
Read more...

 Control Warnings Report
This report presents several lists, helping you spot possible errors in your form files.
Read more...

 Property Value Report
This report shows values for selected properties in your Delphi forms. For instance, it can show every value of the Caption property for all controls of type TButton. You can use this report to document your property settings, or to spot bad values.
Read more...

 Missing Property Report
This report is similar to the Property Value Report. You specify one or more types and properties that you want to monitor with this report, for example the class type TLabel and its Caption property. This report will then present a list of all occurencies in DFM-files, where a TLabel exists, but where the Caption property has not been set.
Read more...

  Form Report
This report shows important properties for your Delphi forms.
Read more...

  Events Report
This report documents how events are linked to controls. You can use it to get an overview of events in your application.
Read more...