JPH0689170A - Source program analysis method for case system - Google Patents

Source program analysis method for case system

Info

Publication number
JPH0689170A
JPH0689170A JP4240216A JP24021692A JPH0689170A JP H0689170 A JPH0689170 A JP H0689170A JP 4240216 A JP4240216 A JP 4240216A JP 24021692 A JP24021692 A JP 24021692A JP H0689170 A JPH0689170 A JP H0689170A
Authority
JP
Japan
Prior art keywords
specification information
information
primary
database
source program
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
JP4240216A
Other languages
Japanese (ja)
Inventor
Junichi Shibuya
純一 澁谷
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NEC Solution Innovators Ltd
Original Assignee
NEC Solution Innovators Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NEC Solution Innovators Ltd filed Critical NEC Solution Innovators Ltd
Priority to JP4240216A priority Critical patent/JPH0689170A/en
Publication of JPH0689170A publication Critical patent/JPH0689170A/en
Withdrawn legal-status Critical Current

Links

Abstract

PURPOSE:To develop and maintain software by managing the analysis result of a source program including selective indication description as one specification information on a data base in the CASE system and presenting specification information for application of a specific selection condition to a user at the time of editing of specification information. CONSTITUTION:A primary analysis means 11 preserves primary specification information 32, which is obtained by analyzing a source progrm 21 including selective compile description without obtaining a selection condition, in a data base 31. When specification information for application of a specific selection condition is edited, an editing means 12 analyzes primary specification information 32 on the specific selection condition by a secondary analysis means 13 to obtain secondary specification information 41 and takes this information as the editing object. A specification information update means 14 reflects update contents of edited secondary specification information 41 on primary specification information in the data base 31.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は、情報処理装置に対する
ソフトウェアの開発および保守作業を支援するCASE
システムにおける原始プログラム解析方式に関し、特
に、原始プログラムから仕様情報を抽出するためのCA
SEシステムにおける原始プログラム解析方式に関す
る。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to CASE for supporting software development and maintenance work for information processing devices.
Regarding a source program analysis method in a system, in particular CA for extracting specification information from a source program
The present invention relates to a primitive program analysis method in an SE system.

【0002】[0002]

【従来の技術】従来のCASEシステムにおける原始プ
ログラム解析方式は、原始プログラムを解析して仕様情
報を抽出するCASEシステムの解析機構で、前記プロ
グラム中に選択コンパイル記述を含む場合には、解析に
際して選択条件を利用者に与えさせて解析を行い、解析
の結果得られた仕様情報をデータベースに保存して仕様
情報の編集の対象としたり、選択条件の指定なしに解析
を行い、得られた仕様情報をデータベースに保存して仕
様情報の編集の対象としたりしていた。
2. Description of the Related Art A source program analysis method in a conventional CASE system is an analysis mechanism of a CASE system that analyzes a source program and extracts specification information. If the program includes a selective compilation description, it is selected in analysis. Analysis is performed by giving conditions to the user, and the specification information obtained as a result of the analysis is saved in a database for editing the specification information, or analysis is performed without specifying selection conditions and the obtained specification information is obtained. Was saved in the database and used as the target for editing the specification information.

【0003】[0003]

【発明が解決しようとする課題】しかしながら、上述し
た従来のCASEシステムにおける原始プログラム解析
方式は、選択条件を指定して解析した結果得られた仕様
情報を保存して、編集の対象とした場合には、同一の原
始プログラムに対して複数の仕様情報がデータベース上
に保存され、編集の対象となるので、同一の原始プログ
ラムに対する複数の仕様情報中には、選択条件に依存し
ない共通の仕様情報が重複して存在するために、個々の
仕様情報の中の共通部分の内容に対する等価性の保証が
利用者に委ねられ、しばしば等価性が損なわれたり、利
用者にとっても共通部分の等価性の保証が煩わしいもの
であるという欠点を有していた。
However, in the above-mentioned source program analysis method in the conventional CASE system, when the specification information obtained as a result of the analysis by designating the selection conditions is saved and is to be edited. Since multiple specification information for the same source program is saved in the database and is subject to editing, common specification information that does not depend on selection conditions is included in multiple specification information for the same source program. Since they are duplicated, it is left to the user to guarantee the equivalence of the contents of the common parts in the individual specification information, and the equivalence is often impaired, and the equivalence guarantee of the common parts is also made to the user. Had the drawback of being annoying.

【0004】また、従来のCASEシステムにおける原
始プログラム解析方式は、選択条件を指定しないで解析
して得られた仕様情報を保存して編集の対象とした場合
には、仕様情報として原始プログラムの解読を支援する
には不十分な情報しか得られていないことが多く、十分
な支援機能を実現出来ていないのが実状であった。
Further, in the original program analysis method in the conventional CASE system, when the specification information obtained by the analysis without selecting the selection condition is stored and edited, the original program is decoded as the specification information. In many cases, insufficient information was available to support people, and the reality was that they could not realize sufficient support functions.

【0005】本発明の目的は、選択条件を指定せずに解
析して得られた仕様情報をデータベースに保存すること
により、データベースに重複した情報を保持せず、編集
時に選択条件を指定した解析を行うことにより、原始プ
ログラムの解読を支援するのに十分な仕様情報による編
集を可能とし、更新された仕様情報中の選択条件に依存
する部分と依存しない部分とを考慮してデータベース上
の仕様情報を更新することにより、従来の欠点を解決す
るCASEシステムにおける原始プログラム解析方式を
提供することにある。
An object of the present invention is to save specification information obtained by analysis without designating selection conditions in a database so that duplicate information is not retained in the database and analysis is performed by designating selection conditions during editing. By doing so, it is possible to edit with the specification information sufficient to support the decoding of the source program, and the specifications on the database considering the part that depends on the selection condition and the part that does not depend on the selection condition in the updated specification information. An object of the present invention is to provide a source program analysis method in a CASE system that solves the conventional drawbacks by updating information.

【0006】[0006]

【課題を解決するための手段】本発明のCASEシステ
ムにおける原始プログラム解析方式は、ソフトウェアの
設計情報をデータベース上に保持して、ソフトウェアの
開発および保守の作業を支援するために、原始プログラ
ムを解析してソフトウェアの仕様情報をデータベースに
登録し、設定書等の上位仕様の構築を支援するリバース
エンジニアリング機能を持つCASEシステムにおける
原始プログラム解析方式において、選択コンパイル記述
(C言語の#ifdef等)を含む原始プログラムの選
択条件を得ること無しに解析し、選択条件が与えられる
ことによって解析が可能になる部分の解析を行わず、未
解析のまま仕様情報としてデータベースに保存し、解析
可能な部分を解析することによって得られた仕様情報と
併せて一次仕様情報としてデータベースに保存する一次
解析手段と、データベースに登録された仕様情報を参照
しながら原始プログラムの解読を行い、上位仕様を付加
して仕様情報の更新を可能とする編集手段と、前記編集
手段から起動され、データベースに保存されている一次
仕様情報および選択条件を入力し、前記一次解析手段が
解析出来なかった選択条件に依存する部分の解析を行
い、完成された仕様情報である二次仕様情報を生成して
前記編集手段に返却する二次解析手段と、前記編集手段
によって起動され、前記二次解析手段によって完成さ
れ、前記編集手段によって更新された二次仕様情報を入
力し、前記編集手段によって更新された部分を選択条件
に依存しない部分および依存する部分に分類し、一次仕
様情報の該当する部分との対応関係に従って一次仕様情
報を更新する仕様情報更新手段とを備えて構成されてい
る。
A source program analysis method in a CASE system of the present invention analyzes a source program in order to hold software design information in a database and support software development and maintenance work. In the source program analysis method in the CASE system having the reverse engineering function that supports the construction of the upper specification such as the setting document by registering the software specification information in the database, the selection compilation description (#ifdef etc. in C language) is included. Analyze without obtaining the selection conditions of the source program, do not analyze the part that can be analyzed by giving the selection conditions, save as unanalyzed in the database as specification information and analyze the analyzable parts Together with the specification information obtained by As a primary analysis means for storing in the database, an editing means for decoding the source program while referring to the specification information registered in the database, and adding the upper specification to update the specification information, and the editing means Secondary specification information, which is completed specification information, is entered by inputting the primary specification information and selection conditions that are started and stored in the database, and analyze the part that depends on the selection conditions that the primary analysis means could not analyze. Secondary analysis means for generating and returning to the editing means, and inputting the secondary specification information started by the editing means, completed by the secondary analyzing means, and updated by the editing means, The part updated by is classified into the part that does not depend on the selection condition and the part that depends on it, and according to the correspondence relationship with the corresponding part of the primary specification information. It is constituted by a specification information updating means for updating the primary specification information Te.

【0007】[0007]

【実施例】以下に、本発明の実施例について図面を参照
して説明する。図1は、本発明のCASEシステムにお
ける原始プログラム解析方式の一実施例を示すブロック
図である。図1に示すように、本実施例のCASEシス
テムにおける原始プログラム解析方式は、一次解析手段
11、編集手段12、二次解析手段13、仕様情報更新
手段14によって構成され、原始プログラム21、デー
タベース31、一次仕様情報32、二次仕様情報41、
選択条件51を収容している。図1中の実線矢印は起動
関係を示し、破線矢印は参照設定関係を示している。
Embodiments of the present invention will be described below with reference to the drawings. FIG. 1 is a block diagram showing an embodiment of a source program analysis method in the CASE system of the present invention. As shown in FIG. 1, the source program analysis method in the CASE system of the present embodiment is composed of a primary analysis means 11, an editing means 12, a secondary analysis means 13, and a specification information updating means 14, a source program 21, a database 31. , Primary specification information 32, secondary specification information 41,
It contains the selection condition 51. The solid line arrow in FIG. 1 indicates the starting relationship, and the broken line arrow indicates the reference setting relationship.

【0008】図2は、一次仕様情報32の一例を示す図
である。図2に示すように、一次仕様情報32は、プロ
グラムの処理内容に関する情報を保持するテキスト情報
32−1、データの定義に関する定義情報を保持するデ
ータ定義情報32−2、マクロの定義に関する定義情報
を保持するマクロ定義情報32−3によって構成されて
いる。
FIG. 2 is a diagram showing an example of the primary specification information 32. As shown in FIG. 2, the primary specification information 32 includes text information 32-1 holding information about processing contents of a program, data definition information 32-2 holding definition information about definition of data, definition information about definition of macro. Is defined by macro definition information 32-3.

【0009】テキスト情報32−1は、プログラムが遂
行する処理を構成する単位処理に関する情報を保持する
テキスト32−1−1,〜32−1−iの集合である。
各テキスト32−1−1,〜32−1−iは、当該のテ
キストの種別、当該のテキストを一意に識別するための
テキストid、単位処理の内容に関する情報を保持する
処理内容情報によって構成される。なお、処理内容情報
は、選択条件に依存する項目に関して未完成である。
The text information 32-1 is a set of texts 32-1-1, 32-1-i holding information about unit processes constituting processes executed by the program.
Each of the texts 32-1-1 to 32-1-i is composed of a type of the text, a text id for uniquely identifying the text, and processing content information holding information about the content of unit processing. It Note that the processing content information is incomplete for items that depend on the selection conditions.

【0010】また、データ定義情報32−2は、データ
定義に関する情報を保持する定義情報32−2−1,〜
32−2−jの集合である。各定義情報32−2−1,
〜32−2−jは、定義情報を一意に識別するための定
義idと、データの名前,型,構造等を保持する定義内
容情報とによって構成される。
The data definition information 32-2 holds definition information 32-2-1, ...
It is a set of 32-2-j. Each definition information 32-2-1
.. 32-2-j is composed of a definition id for uniquely identifying the definition information and definition content information for holding the name, type, structure, etc. of the data.

【0011】さらに、マクロ定義情報32−3は、マク
ロ定義に関する情報を保持する定義情報32−3−1,
〜32−3−kの集合である。各定義情報32−3−
1,〜32−3−kは、定義情報を一意に識別するため
の定義idと、マクロの名前やマクロ展開規則等を保持
する定義内容情報とによって構成される。
Further, the macro definition information 32-3 is the definition information 32-3-1 for holding information on the macro definition,
~ 32-3-k is a set. Each definition information 32-3-
Each of 1 to 32-3-k is composed of a definition id for uniquely identifying the definition information and definition content information holding a macro name, a macro expansion rule, and the like.

【0012】図3は、二次仕様情報1の構成の一例を示
す図である。図3に示すように、二次仕様情報41は、
一次仕様情報32と同様の情報であるテキスト情報41
−1、データ定義情報41−2、マクロ定義情報41−
3によって構成される。二次仕様情報41の一次仕様情
報32との相違点は、特定の選択条件を与えられた場合
の一次仕様情報32のサブセットであること、テキスト
情報41−1の中のテキストの処理内容情報が完成状態
のものが含まれることである。
FIG. 3 is a diagram showing an example of the structure of the secondary specification information 1. As shown in FIG. 3, the secondary specification information 41 is
Text information 41 that is the same information as the primary specification information 32
-1, data definition information 41-2, macro definition information 41-
It is composed of three. The difference from the primary specification information 32 of the secondary specification information 41 is that it is a subset of the primary specification information 32 when a specific selection condition is given, and the text processing content information in the text information 41-1 is That is to include the completed one.

【0013】本実施例では、原始プログラム21は、C
言語て記述されているものとしている。まず、一次解析
手段11は、C言語の選択コンパイル記述機能を遂行す
る選択指示文(ここでは、#ifdef文,#else
文,#endif文のみとする)を含む原始プログラム
21を入力して解析し、一次仕様情報32をデータベー
ス31に出力する。一次解析手段11は、最初に、原始
プログラム21の各行を解析して、トークンにより内部
表現に変換する。
In this embodiment, the source program 21 is C
It is supposed to be described as a language. First, the primary analysis means 11 selects a selection instruction statement (here, #ifdef statement, #else) for performing the C language selective compilation description function.
Statements, and #endif statements only) are input and analyzed, and the primary specification information 32 is output to the database 31. The primary analysis means 11 first analyzes each line of the source program 21 and converts it into an internal representation with a token.

【0014】次に、トークン列を解析して、#ifde
f文,#else文,#endif文を検出し、#if
def文と#else文,#else文と#endif
文,#else文がない場合の#ifdef文と#en
dif文の間(以降に、「選択指示文の間」と称す)に
出現する行とそうでない行とを認識する。続いて、選択
指示文以外の行のトークン列を解析して、C言語の文を
認識する。その結果、得られた各文を構成するトークン
列および選択指示文を構成するトークン列からテキスト
情報32−1の中にテキスト32−1−1からテキスト
32−1−iを生成する。
Next, the token string is analyzed and #ifde
f sentence, #else sentence, #endif sentence are detected, and #if
def statement and #else statement, #else statement and #endif
Statement, #ifdef statement and #en when there is no #else statement
The lines appearing between the dif sentences (hereinafter, referred to as “between selection instruction sentences”) and the lines not appearing are recognized. Then, the token string of the line other than the selection instruction sentence is analyzed to recognize the C language sentence. As a result, the texts 32-1-1 to 32-1-i are generated in the text information 32-1 from the obtained token string forming each sentence and the token string forming the selection instruction sentence.

【0015】各テキスト32−1−1,32−1−iに
は、テキストを一意に識別するテキストidが付与さ
れ、選択指示文を構成するトークン列に対するテキスト
の種別には値1を、選択指示文以外の文で選択指示文の
間に出現する文を構成するトークン列に対応するテキス
トの種別には値2を、選択指示文の間に出現しない文を
構成するトークン列に対応するテキストの種別には値3
を、文として認識出来なかったトークン列に対するテキ
ストの種別には値4をそれぞれ設定する。
A text id that uniquely identifies the text is added to each of the texts 32-1-1 and 32-1-i, and the value 1 is selected as the text type for the token string forming the selection directive. A value other than 2 for the type of text corresponding to a token string that forms a sentence that appears between selection directives other than a directive text, and a text that corresponds to a token string that forms a sentence that does not appear between selection directives 3 for the type of
Is set to the type of text for the token string that could not be recognized as a sentence.

【0016】文がデータ定義の文であれば、さらに解析
してデータの定義内容情報を収集して、データ定義情報
32−2の中に定義情報32−2−1から定義情報32
−2−iを生成し、テキスト情報32−1の中の当該の
テキストの処理内容情報には、対応するデータ定義情報
32−2の中の要素の定義idを保持する。
If the sentence is a data definition sentence, it is further analyzed to collect data definition contents information, and the definition information 32-2-1 to the definition information 32 are included in the data definition information 32-2.
-2-i is generated, and the processing content information of the text in the text information 32-1 holds the definition id of the element in the corresponding data definition information 32-2.

【0017】文がマクロ定義の文であれば、さらに解析
してマクロの定義内容情報を収集してマクロ定義情報3
2−3の中に定義情報32−3−1から定義情報32−
3−kを生成し、テキスト情報32−1の中の当該のテ
キストの処理内容情報には、対応するマクロ定義情報3
2−3の中の要素の定義idを保持する。
If the statement is a macro definition statement, it is further analyzed to collect macro definition content information and macro definition information 3
2-3, definition information 32-3-1 to definition information 32-
3-k is generated, and the corresponding macro definition information 3 is included in the processing content information of the text in the text information 32-1.
Holds the definition id of the element in 2-3.

【0018】それ以外の文に対するテキストの処理内容
情報は、文を構成するトークン列を保持する。選択条件
が与えられていないために、このトークン列中のデータ
参照およびマクロ参照を表す名標は、対応するデータ定
義情報32−2の中の定義情報32−2−1,〜32−
2−jやマクロ定義情報32−3の中の定義情報32−
3−1,〜32−3−kとの対応関係は未解決のままと
なる。
The text processing content information for the other sentences holds a token string constituting the sentence. Since no selection condition is given, the names representing the data reference and macro reference in this token string are defined by the definition information 32-2-1, 32-32 in the corresponding data definition information 32-2.
2-j and definition information 32-in the macro definition information 32-3
The correspondence with 3-1 to 32-3-k remains unsolved.

【0019】そして、編集手段12は、データベース3
1に保存されている一次仕様情報32に特定の選択条件
を与えた際に有効となる仕様情報に対して、利用者が参
照,更新,仕様情報に対する説明の付加等を行う手段を
提供して、原始プログラム21から抽出された原始プロ
グラムレベルの仕様情報から詳細設計仕様レベルの仕様
情報を構築するための支援を行う。
Then, the editing means 12 uses the database 3
1 provides a means for the user to refer to, update, and add a description to the specification information that becomes effective when a specific selection condition is given to the primary specification information 32 stored in 1. , Support for constructing detailed design specification level specification information from source program level specification information extracted from the source program 21.

【0020】また、編集手段12は、特定の選択条件を
与えた際の原始プログラム21の処理内容を示すチャー
ト、原始プログラム21の中で定義されているデータ、
マクロの定義情報とデータ、マクロのチャート上での参
照関係を知るために、二次解析手段13を起動して二次
仕様情報41を得る。
Further, the editing means 12 is a chart showing the processing contents of the source program 21 when a specific selection condition is given, data defined in the source program 21,
In order to know the definition information and data of the macro, and the reference relationship of the macro on the chart, the secondary analysis means 13 is activated to obtain the secondary specification information 41.

【0021】さらに、編集手段12は、二次解析手段1
3から得られた二次仕様情報41をもとに使用者の指示
に従って、チャートの参照,更新、処理に対する説明の
付加、データやマクロの定義情報の参照,更新、それら
の説明の付加、チャート上でのデータやマクロの参照位
置の検索等の操作を行い、必要に応じて二次仕様情報4
1を更新する。
Further, the editing means 12 is the secondary analysis means 1
According to the user's instruction based on the secondary specification information 41 obtained from No. 3, reference and update of charts, addition of explanation for processing, reference and update of definition information of data and macro, addition of those explanations, chart Perform operations such as searching the above data and macro reference positions, and if necessary, specify secondary specification information 4
Update 1.

【0022】チャート上で文が追加された場合には、二
次仕様情報41の中のテキスト情報41−1に種別の値
が5のテキストを追加する。チャート上で既存の文が更
新された場合には、二次仕様情報41の中のテキスト情
報41−1内の対応するテキスト41−1−1,〜41
−1−xの種別を値5に変更し、処理内容情報を変更さ
れたチャート上の文をトークン化しただけの未完成状態
に変更する。
When a sentence is added on the chart, the text having the type value of 5 is added to the text information 41-1 in the secondary specification information 41. When an existing sentence is updated on the chart, the corresponding texts 41-1-1 to 41-41 in the text information 41-1 in the secondary specification information 41 are displayed.
The type of -1-x is changed to the value 5, and the processing content information is changed to an incomplete state in which the sentence on the changed chart is tokenized.

【0023】チャート上の文が削除された場合には、二
次仕様情報41の中のテキスト情報41−1の対応する
テキスト41−1−1,〜41−1−xの何れかを削除
する。チャート上の1つ以上の文がグループ化されてグ
ループに対する説明が付加された場合には、二次仕様情
報41の中のテキスト情報41−1のグループ化された
1つ以上の文に対するテキストの直前に種別の値が6の
テキストを追加する。
When the sentence on the chart is deleted, any of the corresponding texts 41-1-1 and 41-1-x of the text information 41-1 in the secondary specification information 41 is deleted. . When one or more sentences on the chart are grouped and a description for the group is added, the text information for the one or more grouped sentences of the text information 41-1 in the secondary specification information 41 is displayed. Immediately before, a text whose type value is 6 is added.

【0024】データやマクロの定義情報に説明が付加さ
れた場合には、対応するデータ定義情報41−2やマク
ロ定義情報41−3の中の定義情報41−2−1,〜4
1−2−y,41−3−1,〜41−3−zの定義内容
情報に説明を付加し、定義内容が更新された場合には、
更新内容を解釈して定義内容情報を更新する。
When an explanation is added to the definition information of data or macro, the definition information 41-2-1 to 4 in the corresponding data definition information 41-2 and macro definition information 41-3.
When the description is added to the definition content information of 1-2-y, 41-3-1 and 41-3-z and the definition content is updated,
Interpret the update contents and update the definition contents information.

【0025】データやマクロの定義の追加および削除
は、チャート上で行うものとし、その解釈と定義情報の
追加および削除は、仕様情報更新手段14によって行わ
れる。なお、編集手段12は、利用者の更新や説明の付
加等によって生じた二次仕様情報41の変更内容を一次
仕様情報32に反映してデータベース31に保存するた
めに、仕様情報変更手段14を起動する。
Data and macro definitions are added and deleted on the chart, and the interpretation and definition information are added and deleted by the specification information updating means 14. In addition, the editing means 12 controls the specification information changing means 14 in order to reflect the changed contents of the secondary specification information 41 caused by the update of the user, the addition of the explanation, etc. in the primary specification information 32 and to save it in the database 31. to start.

【0026】次に、二次解析手段13は、編集手段12
から起動され、選択条件51およびデータベース31か
らの一次仕様情報32を入力し、選択条件51が指定さ
れた時に有効となる仕様情報を一次仕様情報から抽出し
て二次仕様情報41を生成する。二次解析手段13は、
一次仕様情報32のテキスト情報32−1の中の選択指
示文に対するテキストを選択条件51によって評価し
て、選択されるテキストを決定する。
Next, the secondary analysis means 13 is the editing means 12
When the selection condition 51 and the primary specification information 32 from the database 31 are input, the specification information that becomes valid when the selection condition 51 is specified is extracted from the primary specification information to generate the secondary specification information 41. The secondary analysis means 13
The text corresponding to the selection directive in the text information 32-1 of the primary specification information 32 is evaluated by the selection condition 51, and the selected text is determined.

【0027】選択されたテキストの処理内容情報を解析
して、一次解析手段11では完成できなかった情報を完
成して、テキスト情報41−1として二次仕様情報41
の中に出力する。選択されたテキストの解析には、種別
の値が4のテキスト、すなわち、文として認識出来なか
ったテキストの再解析および種別の値が2,3のテキス
トの処理内容情報の中のデータ参照やマクロ参照を表す
名標と対応するデータ定義情報32−2やマクロ定義情
報32−3の中の定義情報の決定がある。
The processing content information of the selected text is analyzed to complete the information that could not be completed by the primary analysis means 11, and the secondary specification information 41 as text information 41-1.
Output in. For the analysis of the selected text, re-analysis of the text whose type value is 4, that is, the text that could not be recognized as a sentence, and data reference or macro in the processing content information of the text whose type value is 2 or 3 The definition information in the data definition information 32-2 and the macro definition information 32-3 corresponding to the name mark indicating the reference is determined.

【0028】文として認識出来なかったテキストの再解
析を行うのは、選択指示文によって一つの文が分断され
たために文として認識出来なかったものが、選択条件5
1が与えられて有効となるテキストが選択されたことに
よって文として認識出来るようになるためである。ま
た、参照された名標と対応する定義情報の決定が本手段
で行われるのは、選択条件51が与えられることによっ
て有効となる定義情報が選択され、参照された名標に対
応する定義情報を一意に決定することが可能となるため
である。
The text that could not be recognized as a sentence is re-analyzed by selecting the condition 5 which cannot be recognized as a sentence because one sentence is divided by the selection instruction sentence.
This is because when 1 is given and a valid text is selected, it can be recognized as a sentence. Further, the definition information corresponding to the referenced name tag is determined by this means because the definition information that is valid by the selection condition 51 is selected and the definition information corresponding to the referenced name tag is selected. This is because it is possible to uniquely determine

【0029】そこで、二次解析手段13は、データ定義
情報32−2やマクロ定義情報32−3の中の定義情報
32−1−1,〜32−2−j,32−3−1,〜32
−3−kから、選択条件51が与えられた場合に有効と
なる定義情報を選択して、データ定義情報41−2やマ
クロ定義情報41−3として、二次仕様情報41の中に
出力する。有効となる定義情報は、テキスト情報32−
1から選択されたテキストのデータ定義やマクロ定義に
対応するテキストの処理内容情報の中に設定されている
定義情報idによって決定される。
Therefore, the secondary analysis means 13 defines information 32-1-1, ~ 32-2-j, 32-3-1, ~ in the data definition information 32-2 and macro definition information 32-3. 32
From -3-k, the definition information that becomes effective when the selection condition 51 is given is selected and output as the data definition information 41-2 and the macro definition information 41-3 in the secondary specification information 41. . The valid definition information is the text information 32-
It is determined by the definition information id set in the text processing content information corresponding to the data definition or macro definition of the text selected from 1.

【0030】さらに、仕様情報更新手段14は、編集手
段12によって更新された二次仕様情報41とデータベ
ース31の中の一次仕様情報32とを入力して、二次仕
様情報41の中の追加,変更,削除された情報を、対応
する一次仕様情報32の中の情報に反映する。テキスト
情報32−1の更新は、テキスト情報41−1とテキス
ト情報32−1を各テキストのテキストidで対応をと
ることによって行われる。その際に、テキスト情報41
−1の中の各テキストの処理内容情報で完成状態のもの
は、未完成状態に戻される。
Further, the specification information updating means 14 inputs the secondary specification information 41 updated by the editing means 12 and the primary specification information 32 in the database 31 to add the secondary specification information 41, The changed and deleted information is reflected in the information in the corresponding primary specification information 32. The text information 32-1 is updated by associating the text information 41-1 and the text information 32-1 with the text id of each text. At that time, the text information 41
The processing content information of each text in -1 in the completed state is returned to the incomplete state.

【0031】データ定義情報32−2やマクロ定義情報
32−3の更新は、データ定義情報32−2とデータ定
義情報41−2、マクロ定義情報32−3とマクロ定義
情報41−3を各定義情報の定義idで対応をとること
によって行われる。そして、テキスト情報41−1の中
のデータ定義やマクロ定義に関する文の追加,変更,削
除に対しては、対応するデータ定義情報32−2やマク
ロ定義情報32−3の追加,変更,削除も行われる。
To update the data definition information 32-2 and the macro definition information 32-3, the data definition information 32-2 and the data definition information 41-2, the macro definition information 32-3 and the macro definition information 41-3 are defined. This is done by taking correspondence with the definition id of the information. Then, with respect to the addition, change, or deletion of the sentence relating to the data definition or macro definition in the text information 41-1, addition, change, or deletion of the corresponding data definition information 32-2 or macro definition information 32-3 is also performed. Done.

【0032】また、仕様情報更新手段14は、一次仕様
情報32の更新の際に、選択条件に依存しない部分の更
新結果を二次仕様情報41を作成する際に使用された選
択条件ごとに保存し、選択条件に依存しない部分に対し
て、選択条件ごとに別の意味付けを行うことも可能とし
ている。
Further, the specification information updating means 14 saves the update result of the part that does not depend on the selection condition when updating the primary specification information 32 for each selection condition used when creating the secondary specification information 41. However, it is also possible to give different meanings to each part that does not depend on the selection condition.

【0033】[0033]

【発明の効果】以上説明したように、本発明のCASE
システムにおける原始プログラム解析方式は、選択条件
を指定せずに解析して得られた仕様情報をデータベース
に保存することにより、データベースに重複した情報を
保持せず、編集時に選択条件を指定した解析を行うこと
により、原始プログラムの解読を支援するのに十分な仕
様情報による編集を可能とし、更新された仕様情報の中
の選択条件に依存する部分と依存しない部分とを考慮し
て、データベース上の仕様情報を更新することが可能と
なるという効果を有している。
As described above, the CASE of the present invention
The source program analysis method in the system saves the duplicated information in the database by saving the specification information obtained by the analysis without specifying the selection condition in the database. By doing so, it is possible to edit with the specification information sufficient to support the decoding of the source program, and consider the part of the updated specification information that depends on the selection conditions and the part that does not depend on the selection conditions. It has an effect that the specification information can be updated.

【図面の簡単な説明】[Brief description of drawings]

【図1】本発明のCASEシステムにおける原始プログ
ラム解析方式の一実施例を示すブロック図である。
FIG. 1 is a block diagram showing an embodiment of a source program analysis method in a CASE system of the present invention.

【図2】一次仕様情報32の構成の一例を示す図であ
る。
FIG. 2 is a diagram showing an example of a configuration of primary specification information 32.

【図3】二次仕様情報41の構成の一例を示す図であ
る。
FIG. 3 is a diagram showing an example of a configuration of secondary specification information 41.

【符号の説明】[Explanation of symbols]

11 一次解析手段 12 編集手段 13 二次解析手段 14 仕様情報更新手段 21 原始プログラム 31 データベース 32 一次仕様情報 41 二次仕様情報 51 選択条件 11 primary analysis means 12 editing means 13 secondary analysis means 14 specification information updating means 21 source program 31 database 32 primary specification information 41 secondary specification information 51 selection conditions

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】 ソフトウェアの設計情報をデータベース
上に保持して、ソフトウェアの開発および保守の作業を
支援するために、原始プログラムを解析してソフトウェ
アの仕様情報をデータベースに登録し、設定書等の上位
仕様の構築を支援するリバースエンジニアリング機能を
持つCASEシステムにおける原始プログラム解析方式
において、 選択コンパイル記述(C言語の#ifdef等)を含む
原始プログラムの選択条件を得ること無しに解析し、選
択条件が与えられることによって解析が可能になる部分
の解析を行わず、未解析のまま仕様情報としてデータベ
ースに保存し、解析可能な部分を解析することによって
得られた仕様情報と併せて一次仕様情報としてデータベ
ースに保存する一次解析手段と、 データベースに登録された仕様情報を参照しながら原始
プログラムの解読を行い、上位仕様を付加して仕様情報
の更新を可能とする編集手段と、 前記編集手段から起動され、データベースに保存されて
いる一次仕様情報および選択条件を入力し、前記一次解
析手段が解析出来なかった選択条件に依存する部分の解
析を行い、完成された仕様情報である二次仕様情報を生
成して前記編集手段に返却する二次解析手段と、 前記編集手段によって起動され、前記二次解析手段によ
って完成され、前記編集手段によって更新された二次仕
様情報を入力し、前記編集手段によって更新された部分
を選択条件に依存しない部分および依存する部分に分類
し、一次仕様情報の該当する部分との対応関係に従って
一次仕様情報を更新する仕様情報更新手段とを備えるこ
とを特徴とするCASEシステムにおける原始プログラ
ム解析方式。
1. In order to maintain software design information in a database and to support software development and maintenance work, a source program is analyzed, software specification information is registered in the database, and a setting sheet, etc. In the source program analysis method in the CASE system having the reverse engineering function that supports the construction of the high-level specification, the source program including the selective compilation description (#ifdef in C language) is analyzed without obtaining the source selection conditions, The part that can be analyzed by being given is not analyzed, it is saved in the database as specification information as it is unanalyzed, and the database as primary specification information together with the specification information obtained by analyzing the analyzable part The primary analysis method to be stored in the Editing the original program while referring to the information, and adding the upper specification to update the specification information, editing means, and the primary specification information and selection conditions that are started from the editing means and stored in the database. Secondary analysis means for inputting, analyzing the part depending on the selection condition that the primary analysis means could not analyze, generating secondary specification information which is completed specification information and returning it to the editing means, The secondary specification information which is started by the editing means, completed by the secondary analysis means, and updated by the editing means is input, and the portion updated by the editing means does not depend on the selection condition and depends on the selection condition. And a specification information updating unit for updating the primary specification information according to the correspondence relationship with the corresponding part of the primary specification information. Primitive program analysis method in SE system.
JP4240216A 1992-09-09 1992-09-09 Source program analysis method for case system Withdrawn JPH0689170A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP4240216A JPH0689170A (en) 1992-09-09 1992-09-09 Source program analysis method for case system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP4240216A JPH0689170A (en) 1992-09-09 1992-09-09 Source program analysis method for case system

Publications (1)

Publication Number Publication Date
JPH0689170A true JPH0689170A (en) 1994-03-29

Family

ID=17056181

Family Applications (1)

Application Number Title Priority Date Filing Date
JP4240216A Withdrawn JPH0689170A (en) 1992-09-09 1992-09-09 Source program analysis method for case system

Country Status (1)

Country Link
JP (1) JPH0689170A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013114575A (en) * 2011-11-30 2013-06-10 Nec Corp Information processing apparatus, information processing method and information processing program

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013114575A (en) * 2011-11-30 2013-06-10 Nec Corp Information processing apparatus, information processing method and information processing program

Similar Documents

Publication Publication Date Title
JPH08190587A (en) Simulation system for application process
JP3181994B2 (en) How to automatically create job flow specifications
AU4098700A (en) Circuit arrangement for measuring the resistances of a pressure-sensitive resistance mat
JPH07200358A (en) Automatic test method of software application
JP4826120B2 (en) Business specification creation support system and method
US5907851A (en) Editing nested documents by appointing a portion for insertion with an alternative substitute
JPH06259420A (en) Sentence editing support device
JPH0540616A (en) Method for generating program specifications
US20050039108A1 (en) Fast tag entry in a multimodal markup language editor
JPH0689170A (en) Source program analysis method for case system
JPH1153391A (en) Database access method
CA2359079A1 (en) Program reproducing method and device, and medium on which a program for program reproduction recording
JPH07146785A (en) Method for automatically generating program and device therefor
KR100323971B1 (en) How to automatically manage document completion and schedule in the project schedule management system
JPH09101880A (en) Program analyzer
JP2000181691A (en) Program structure analysis system
JPH056291A (en) Method for preparing and managing test resources
JPH0830448A (en) Program specification consistency inspecting device
JPH11353162A (en) Program correction result comparing method
JPH10133866A (en) Method for shift conversion processing
JPH11161666A (en) Method and device for document data retrieval and document editing device
JP2003177923A (en) Reserved word converting method for porting support system
JP2946509B2 (en) Control method of interactive manual
JPH03262036A (en) Graphic program pattern generating system
JP2003016034A (en) Creating method for electronic manual

Legal Events

Date Code Title Description
A300 Application deemed to be withdrawn because no request for examination was validly filed

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 19991130