JPS59125447A - Executing method of programming language - Google Patents

Executing method of programming language

Info

Publication number
JPS59125447A
JPS59125447A JP37183A JP37183A JPS59125447A JP S59125447 A JPS59125447 A JP S59125447A JP 37183 A JP37183 A JP 37183A JP 37183 A JP37183 A JP 37183A JP S59125447 A JPS59125447 A JP S59125447A
Authority
JP
Japan
Prior art keywords
data
modifier
predicate
basic
buffer
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.)
Pending
Application number
JP37183A
Other languages
Japanese (ja)
Inventor
Atsushi Sugano
淳 菅野
Kenichi Ueda
謙一 上田
Kunio Honda
本田 邦夫
Yoshiki Okamura
岡村 嘉己
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.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial Co 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 Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP37183A priority Critical patent/JPS59125447A/en
Publication of JPS59125447A publication Critical patent/JPS59125447A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/40Transformation of program code
    • G06F8/41Compilation

Abstract

PURPOSE:To allow anybody in a family to generate a program easily by converting document data into an executable interpreter language. CONSTITUTION:Blank data is detected rom the right end of a document data storage buffer 2 and codes up to the blank data are read out as basic predicate data. Then, whether coincident basic predicate data is registered in a basic predicate table 3 or not is judged, and when not, a converter 4 is informed that the data is erroneous data. Then, a code indicating a syntax error is generated in an interpreter data storage buffer 5. When the data is registered in the table 3, on the other hand, modifier data is read out of a modifier table 6 corresponding to the basic predicate data and whether there is corresponding modifier data in a buffer 2 or not is judged. When there is the modifier data in the buffer 2, a unit data extactor 7 extracts left and right term data of the modifier data from the buffer 2.

Description

【発明の詳細な説明】 産業上の利用分野 本発明は、パーソナルコンピュータ等の市;子計算機で
各種の情報処理を行なわせるプログラム言語の実行方法
に関する。
DETAILED DESCRIPTION OF THE INVENTION Field of the Invention The present invention relates to a method for executing a programming language that causes a slave computer such as a personal computer to perform various information processing.

従来例の構成とその問題点 近年の半導体技術の進歩に伴い、パーソナルコンピュー
タの性能は大幅に向上しており、各種データのかな、漢
字まじりの日本語による表現が可能となっている。
Conventional configurations and their problems With recent advances in semiconductor technology, the performance of personal computers has improved significantly, and it has become possible to express various types of data in Japanese, including kana and kanji.

更に最近になって、この日本語による情報処理をプログ
ラミングの分野にまで応用しようとする動きがでてきて
いる。
Furthermore, recently there has been a movement to apply this Japanese information processing to the field of programming.

これまで開発されてきたプログラミング言語には、RA
SIC,FORTRAN、C0BOL等があるが、これ
らは英語の構文が基礎となっているため、日本人にとっ
てなじみにくく、また日本語用に開発されたプログラミ
ング言語もいくつかあるが、これらはC0BOL言語を
基礎としていてC0BOLの文法に縛られており、日本
人の誰もが家庭内で利用できるような自然言語に近い日
本語表記g語ではなかった。
Programming languages that have been developed so far include RA
There are SIC, FORTRAN, C0BOL, etc., but these are based on English syntax, so they are difficult for Japanese people to understand.Also, there are some programming languages developed for Japanese, but these are based on the C0BOL language. It is based on C0BOL grammar, and is not a Japanese written g-word that is close to the natural language that every Japanese person can use at home.

すなわち、従来のプログラミング言語の実行方法によれ
ば、日本人にとってはなじみにくい言語や文法に基いて
プログラムを作成しなければならず、誰もが簡便に作成
できるプログラムによる実行は困難であった。また、−
どのような事は、日本人だけでなく、中国人、ロシア人
などについても同様の問題である。
That is, according to the conventional method of executing a programming language, a program must be created based on a language and grammar that are not familiar to Japanese people, and it is difficult to execute a program that can be easily created by anyone. Also, -
This is not only a problem for Japanese people, but also for Chinese, Russians, etc.

発明の目的 本発明は上記の問題点に鑑みてなされたもので、自然言
語に近い日本語表記等のプログラミング言語でも情報処
理が可能な、家庭内の誰もが容易にプログラムを作成す
ることのできるプロゲラミンク暦語の実行方法を提供す
ることを目的とする。
Purpose of the Invention The present invention has been made in view of the above-mentioned problems, and provides a system that allows anyone at home to easily create programs that can process information using a programming language similar to natural language, such as Japanese notation. The purpose is to provide a method for executing Progeramink Calendar.

発明の構成 本発明は上記目的を達成するだめ、文章データ中の述語
データを抽出し、抽出した述語データに対応する単位デ
ータを修飾語データに基いて抽出し、抽出した述語デー
タ、修飾語データ、単位データに基いて文章データを実
行可能なインタープリタ言語に変換するものである。
Structure of the Invention In order to achieve the above object, the present invention extracts predicate data from text data, extracts unit data corresponding to the extracted predicate data based on modifier data, and extracts the extracted predicate data and modifier data. , which converts text data into an executable interpreted language based on unit data.

実施例の説明 以下に図面を用いて実施例を説明する。Description of examples Examples will be described below with reference to the drawings.

第1図は本発明のプログラミング言語の実行方法の一実
施例を示すフローチャートである。
FIG. 1 is a flowchart showing an embodiment of a method for executing a programming language according to the present invention.

日本語表記のプログラムは、句点(−0」で区切られた
文章データ単位に取り出され、処理される。
A program written in Japanese is extracted and processed in units of sentence data separated by periods (-0).

始めに文章データから右端の項データが基本述語データ
として取り出される。
First, the rightmost term data is extracted from the sentence data as basic predicate data.

次にこの基本述語データが基本述語チーフルに有るか判
断され、無い場合は構文誤りとして処理される。基本述
語テーブルに有る基本述語データは、この基本述語デー
タに対応した修飾語データを持つかどうか判断され、文
章データ中に該当する修飾語データを持たない場合は構
文誤りとして処理される。
Next, it is determined whether this basic predicate data exists in the basic predicate chifur, and if it does not exist, it is treated as a syntax error. The basic predicate data in the basic predicate table is judged whether it has modifier data corresponding to this basic predicate data, and if the text data does not have the corresponding modifier data, it is treated as a syntax error.

該当する修飾語データが有る場合は、文章データからこ
の修飾語データの左右の項データが中位データとして取
り出され、基本述語データに応じて変換され、実行可能
なインターフ”リタ言語が作成される。作成されたイン
タープリタ言’ nnは電子計薄機(OP U)により
、遂次解釈され実行がイ1なわれる。
If there is corresponding modifier data, the term data on the left and right sides of this modifier data are extracted from the text data as intermediate data, converted according to the basic predicate data, and an executable interfilter language is created. The created interpreter word 'nn is successively interpreted and executed by an electronic measuring unit (OPU).

第2図に同実施例を行なう構成図を示す。第2図におい
て、1は端末機であり、端末機1から入力された文章デ
ータは、文章データ格納バッファ2に格納される。
FIG. 2 shows a block diagram for carrying out the same embodiment. In FIG. 2, 1 is a terminal, and text data input from the terminal 1 is stored in a text data storage buffer 2.

次に文章データ格納バッファ2の右端からブランクデー
タを検出し、ブランクデータまでのコードが基本述語デ
ータとして取シ出され、基本述語テーブル3に一致する
基本述語データが登録されているか判断され、登録され
ていない場合は、変換器4に謂シデータである事を通知
し、インタープリタデータ格納バッファ5には、構文誤
りを表示゛するコードが生成される。
Next, blank data is detected from the right end of the text data storage buffer 2, the code up to the blank data is extracted as basic predicate data, it is determined whether basic predicate data that matches the basic predicate data is registered in the basic predicate table 3, and the code is registered. If not, the converter 4 is notified that the data is incorrect, and a code is generated in the interpreter data storage buffer 5 that indicates a syntax error.

基本述語テープ/L’3に登録されている場合は、その
基本述語データに対応する修飾語テープ/L/6よシ修
飾語データが取り出され、文章データ格納バッファ2中
に、該当する修飾語データが有るか判断され、無い場合
は、基本述語テープ)v参照の場合と同様に、構文誤り
を表示するコードがインタープリタデータ格納バッファ
6に生成される。
If the basic predicate data is registered in the basic predicate tape/L'3, the modifier data corresponding to the basic predicate data is extracted from the modifier tape/L/6, and the corresponding modifier data is stored in the sentence data storage buffer 2. It is determined whether there is data, and if there is no data, a code indicating a syntax error is generated in the interpreter data storage buffer 6, as in the case of basic predicate tape)v reference.

文章データ格納バッファ2中に該当する修飾語データが
イする場合は、単位データ抽出器7によシ、文章データ
格納バッファ2から、その修飾語データの左右の項デー
タが取り出され、単位データとして変換器4に転送され
る。
When the corresponding modifier data is found in the sentence data storage buffer 2, the unit data extractor 7 extracts the left and right term data of the modifier data from the sentence data storage buffer 2 and stores them as unit data. It is transferred to converter 4.

変換器4では、4i(木述dt1データに対応した修飾
語デーク、単位データに結いてコード変換がイ1なわれ
、実行可能なインタープリタデータが生成され、インタ
ープリタデータ格納バッファらに転送される。インター
プリタデータ格納バッファ5の内容はCPU8で解釈、
実イ了される。
In the converter 4, code conversion is performed on 4i (modifier data corresponding to the tree dt1 data and unit data), and executable interpreter data is generated and transferred to the interpreter data storage buffer. The contents of the interpreter data storage buffer 5 are interpreted by the CPU 8,
It is actually completed.

次に第1図、第2図に基づいて、実際の文章データを用
いて説明する。始めに端末機1より、次の文章データが
入力される。「面積は〔縦*横〕である。Jこの文章デ
ータは、文章データ格納バッファ2に格納され、基本述
語データの1である」が取り出される。
Next, an explanation will be given using actual text data based on FIGS. 1 and 2. First, the following text data is input from the terminal 1. ``The area is [length*width].JThis sentence data is stored in the sentence data storage buffer 2, and is 1 of the basic predicate data'' is extracted.

次に、この基本述語データに対応する修飾6Aデータの
「は」が修飾語テープ/L/6から取り出され、この修
飾語データを元にして、文はデータ格納バッファ2から
単位データの「面let J及び]〔縦*横〕」が取り
出され、変換器4に送られる。
Next, the modifier 6A data "wa" corresponding to this basic predicate data is retrieved from the modifier tape/L/6, and based on this modifier data, the sentence is written from the data storage buffer 2 to the unit data "wa". let J and ][length*width]" are taken out and sent to the converter 4.

変換器4では、この2つの学位データを用いて、0PU
Bで実行可能なインタープリフ言、?!41面積=〔縦
幸横〕、」が作成され、インタープリタデ−タ格納バッ
ファ5に蓄えられる。
Converter 4 uses these two degree data to convert 0PU
Interpret expressions that can be executed in B? ! 41 area=[vertical, horizontal and vertical]" is created and stored in the interpreter data storage buffer 5.

同様に1縦は100である。」、「横は60である。」
、及び「面積を計算する。」 という3つの文章データ
は同様の手順で各々[縦=1oc5.J[横=60,1
.[結果二〈面積〉、」という3種類のインタープリタ
言語に変換され、インタープーリタデータ格納バッファ
5に蓄えられる。
Similarly, one vertical line is 100. ”, “The width is 60.”
, and ``Calculate the area.'' The three text data items are each [vertical=1oc5. J [horizontal = 60,1
.. [Result 2 <Area>,'' is converted into three types of interpreter languages and stored in the interpreter data storage buffer 5.

このインター1リタデータ格納バツフア5の内容はCP
U8により遂次解釈実行されて、「結果=50oO1」
という実行結果が得られる。
The contents of this Inter 1 data storage buffer 5 are CP
Interpretation is executed successively by U8, and “Result = 50oO1”
The execution result is obtained.

ところで、上記実施例において、基本述語テープ/V3
と修飾語テーブル6とは、1つの記憶装置内に、基本述
語データと修飾語データとをそれぞれ対応させてコード
で記憶させておくことにより構成できる。また、変換器
4は、文章データを構成する基本述語データおよび修飾
語データに対応したインタープリフデータが記憶された
記憶装置で構成できる。単位データ抽出器7は、修飾語
データのコードの左右の項データのコードを抽出するコ
ード抽出器で構成できる。
By the way, in the above embodiment, the basic predicate tape/V3
The modifier table 6 can be constructed by storing basic predicate data and modifier data in correspondence with each other in a code in one storage device. Further, the converter 4 can be configured with a storage device that stores interpref data corresponding to basic predicate data and modifier data that constitute the text data. The unit data extractor 7 can be configured as a code extractor that extracts the codes of the term data on the left and right sides of the code of the modifier data.

基本述語データおよび修飾語データは上記実施例の他に
、第1表に示すものなどが設定できる。
In addition to the above embodiments, the basic predicate data and modifier data can be set as shown in Table 1.

第′1表 ゛また、これらの基本述語データおよび修飾語データを
用い、第2表に示す日本語プログラムなどを作成するこ
とができる。なお、第2表においてA、  B、  N
、  P、  Qは単位データを示す。
Table '1' Furthermore, using these basic predicate data and modifier data, the Japanese programs shown in Table 2 can be created. In addition, in Table 2, A, B, N
, P, and Q indicate unit data.

第2表 第1表、第2表で示した基本述語、修飾語、プログラム
の基本形表現は、本発明の実施例であって、その他種々
のものが考えられる。
Table 2 The basic predicates, modifiers, and basic form expressions of programs shown in Tables 1 and 2 are examples of the present invention, and various other expressions are possible.

また、実施例では、日本語表記について述べたが、その
他の言語、例えば中国語、ロシア語など種々の言語の表
記に対しても応用できる。
Further, in the embodiment, Japanese notation has been described, but the present invention can also be applied to notation in various other languages such as Chinese and Russian.

発明の詳細 な説明したように本発明は、文章データ中の述語データ
を抽出し、抽出した述語データに対応する単位データを
修飾語データに基いて抽出し、抽出した述語データ、修
飾語データ、単位データに基いて文章データを実行可能
なインタープリタ言語からなる文章に変換するものであ
るだめ、自然言語に近い日本語表記などでもってプログ
ラムを作成し、情報処理を実行することができるだめ、
読みやすく文法は簡明で容易に修得可能であり、大型計
算機のみ奢らずパーソナルコンピュータにも応用でき、
家庭内においても誰もが簡便にプログラムを作成するこ
とができる。
Detailed Description of the Invention As described above, the present invention extracts predicate data from text data, extracts unit data corresponding to the extracted predicate data based on modifier data, and extracts the extracted predicate data, modifier data, It is necessary to convert text data into texts in an executable interpreted language based on unit data, and it is necessary to create programs in Japanese notation that is close to natural language and perform information processing.
It is easy to read, the grammar is simple and easy to learn, and it can be applied not only to large computers but also to personal computers.
Anyone can easily create a program even at home.

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

第1図は本発明のプログラミング言語の実行方法の一実
施例を示すフローチャー1・、第2図は同実施例を行な
う構成図である。 1・・・・・・端末機、2・・・・・文章データ格納バ
ッフ1.3・・・・・・基本述語テーブル、4・・・・
・・変換器、6・・・・・・インタープリタデータ格納
バッファ、6・・・・・・修飾語テーブル、7・・・・
・CP U。 代理人の氏名 弁理士 中 尾 敏 男 ほか1名第 
13 第2図 !
FIG. 1 is a flowchart 1 showing an embodiment of the programming language execution method of the present invention, and FIG. 2 is a block diagram for carrying out the same embodiment. 1...Terminal, 2...Text data storage buffer 1.3...Basic predicate table, 4...
Converter, 6... Interpreter data storage buffer, 6... Modifier table, 7...
・CPU. Name of agent: Patent attorney Toshio Nakao and 1 other person
13 Figure 2!

Claims (1)

【特許請求の範囲】[Claims] 単位データと述語データと修飾語データとが配列された
文章データ中の前記述語データを抽出する手順と、抽出
した前記述語データに対応する前記単位データを前記修
飾語データに基いて抽出する手順と、抽出した前記単位
データ、前記述語データ、前記修飾語データに基いて前
記文章データを実行可能なインタープリタ言語に変換す
る手順とを備えたプログラミング言語の実行方法。
A procedure for extracting predescriptive word data from sentence data in which unit data, predicate data, and modifier data are arranged, and extracting the unit data corresponding to the extracted predescriptive word data based on the modifier data. A method of executing a programming language, comprising: a step of converting the text data into an executable interpreted language based on the extracted unit data, predescriptive word data, and modifier data.
JP37183A 1983-01-05 1983-01-05 Executing method of programming language Pending JPS59125447A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP37183A JPS59125447A (en) 1983-01-05 1983-01-05 Executing method of programming language

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP37183A JPS59125447A (en) 1983-01-05 1983-01-05 Executing method of programming language

Publications (1)

Publication Number Publication Date
JPS59125447A true JPS59125447A (en) 1984-07-19

Family

ID=11471930

Family Applications (1)

Application Number Title Priority Date Filing Date
JP37183A Pending JPS59125447A (en) 1983-01-05 1983-01-05 Executing method of programming language

Country Status (1)

Country Link
JP (1) JPS59125447A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS61262883A (en) * 1985-05-16 1986-11-20 Fujitsu Ltd Japanese syntax analyzing system

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5650443A (en) * 1979-09-29 1981-05-07 Canon Inc Electronic computer
JPS5680748A (en) * 1979-12-06 1981-07-02 Fujitsu Ltd Data processor programmable in ideographic language

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5650443A (en) * 1979-09-29 1981-05-07 Canon Inc Electronic computer
JPS5680748A (en) * 1979-12-06 1981-07-02 Fujitsu Ltd Data processor programmable in ideographic language

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS61262883A (en) * 1985-05-16 1986-11-20 Fujitsu Ltd Japanese syntax analyzing system

Similar Documents

Publication Publication Date Title
US6321372B1 (en) Executable for requesting a linguistic service
US5895446A (en) Pattern-based translation method and system
US6182029B1 (en) System and method for language extraction and encoding utilizing the parsing of text data in accordance with domain parameters
JP2003030185A (en) Automatic extraction of transfer mapping from bilingual corpora
JP2003050797A (en) Scaleable machine translation system
JPS61255469A (en) Language generating device
JPH0252292B2 (en)
JPH0344764A (en) Mechanical translation device
JPS59125447A (en) Executing method of programming language
JPH04128926A (en) Program comment translating system
JP2002014990A (en) Question answering system, question answering processing method, transformation rule automatic acquisition processing method and recording medium for these system and method programs
Zhang et al. Implementing Natural Language Processes to Natural Language Programming
JPH0256691B2 (en)
JP2727987B2 (en) Data type inspection device
JPH0340067A (en) Sentence retrieving system
JP2650099B2 (en) Document extraction device
JPH04273534A (en) Precompile system
JPH01112367A (en) Machine translator
JPH02208775A (en) Machine translation system
JPS63136263A (en) Mechanical translating device
JPH04257077A (en) Picture processor
JPS60243765A (en) Information input system
JPH0431966A (en) Translation supporting device
JPH0616269B2 (en) Execution processor for programming language
JPS6315335A (en) Expanding system for end user language for data base to natural language