Open System Portability Checker Update (Nov 94)

Version 3.1 is released:

Header File Usage

During the lifetime of a software project many header files are created and modified. Once included within a source file a given header tends to stay included. The cost of finding out which headers are actually needed can be very high.

OSPC now analyses the use of identifiers, contained within headers, to find out which are referenced by the source file that includes them. Those included headers that do not contain identifiers referenced from the C source code are flagged as not needed. The #include statement can then be removed. The advantages of removing #includes of redundant headers are improvements in compilation rate; smaller make files; and less extraneous information to worry about during reviews.

User headers that have been included more than once are also flagged.

OSPC will also flag externally visible identifiers that are not declared within any included header file. Such identifiers should probably be made static or declared in a header.

Code Layout

Good code layout helps to make it easier to follow what is going on. Logic errors are sometimes introduced into working programs by changes involving the rearrangement of blocks of code. Checking that code has a consistent layout is a useful way of uncovering this type of error.

It is not intended that OSPC be used to enforce a particular style of code layout. Rather it is assumed that code is consistently laid out. If a statement is found to be indented more, or less than those that surround it, a warning is given.

Separate checks are made against case labels, the tokens { and } used to create compound blocks and individual statements within particular blocks. It is also possible to configure the number of spaces that are considered to be equivalent to the horizontal tab character.

Embedded SQL

OSPC now supports some of the constructs being proposed in the revision of the ISO/IEC 9075:1992 standard, SQL/3. The current draft of this document is 50% larger than the existing standard which was itself 100% larger than SQL/1.

The main feature in the latest release is support for triggers. A construct already supported by a number of vendors in current versions of theirs product.

Additional coding standard checks have also been added to the use of SELECT and VIEW statements. Also a SQL specific configuration file can be edited, by the user, to tailor the system calls and keywords accepted by OSPC.

Support for the ODBC API has been added to the list of supported standards available through the platform profile machinery.

Sybase Conference

The Sybase UK User Group are holding a conference and their AGM during 7-8 December at the Sheraton Skyline Hotel, Heathrow. Knowledge Software have a stand at the conference and will be demonstrating the latest version of OSPC.

Please drop by and say hello.

Anybody interested in attending the conference should contact David Martin of Database Solutions on 081-953-2519.

Tokyo meeting of WG14

The ISO committee responsible for C, SC22/WG14, held a meeting during July in Tokyo. A new 'spirit of C' was agreed upon. This spirit will be used to guide the revision of the standard. The items given in the rationale of the original C standard as the spirit have been kept. There were a number of additions.

In order to handle the additional workload of revising the standard WG14 has increased the number of days it meets. Future meetings, starting in Dallas, Texas in December will last five days. It is hoped that the UK will be able to host a WG14 meeting during 1996.

The current UK position is that C is a different language from C++ and has uses in systems where low memory usage is a premium, or where high performance is needed. At least one person on the US committee would like to add classes to C; learning from the 'mistakes' made with classes in C++.

If anybody is interested in taking part in the C standardisation process they should contact the new UK C panel convenor, Neil Martin on (01908) 640778. Meetings are held four times a year at the new BSI headquarters in Chiswick, to the west of London.

NT Support

OSPC has now been ported to NT (on the Digital Alpha platform). As part of the porting process, information on NT was collected and added to the list of platforms supported by the Platform Profile machinery.

Contact Details

Tel : (01252)-520667 Internet:

© Copyright 1995. Knowledge Software Ltd. All rights reserved;