IBM
Contents Index Previous Next



Including PR Files


The Analyzer allows the user to divide the SDL description into a number of separate PR files. (The macro expansion can, however, only handle one file at a time.) It may, for example, be convenient to have the system level data type definitions in a separate file. A separate file is included by adding an include directive to the SDL description.

Syntax of #INCLUDE Directives

The include directive is #INCLUDE followed by the name of the file which should be surrounded by single quotation marks. The directive should be placed in an SDL comment, directly after the comment start ("/*"), at the place where the file should be included.

Example 347 : #INCLUDE in Analyzer

System Example;
/*#INCLUDE 'DataDefs.pr' */
/*#INCLUDE 'BlockA.pr' */
EndSystem Example;

Search Order for Included PR Files

The Analyzer will search for included SDL/PR files in the following order:

  1. Any directory specified with Include-Directory command
  2. Source directory
  3. The current default directory
  4. The directory designated by the environment variable HOME.
  5. The directory designated by $telelogic/sdt/include/ADT (on UNIX), or <installation directory>\sdt\include\adt (in Windows)
    (This directory contains a number of useful abstract data types in SDL/PR that are included in the release. See The ADT Library for more information.)

http://www.ibm.com/rational
Contents Index Previous Next