Practical type checking of functions defined on context-free languages

被引:2
|
作者
Chen, HM [1 ]
Dong, YM [1 ]
机构
[1] Chinese Acad Sci, Inst Software, Comp Sci Lab, Beijing 100080, Peoples R China
基金
中国国家自然科学基金;
关键词
type checking; context-free language; algorithm;
D O I
10.1007/BF02973447
中图分类号
TP3 [计算技术、计算机技术];
学科分类号
0812 ;
摘要
A type checking method for the functional language LFC is presented. A distinct feature of LFC is that it uses Context-Free (CF) languages as data types to represent compound data structures. This makes LFC a dynamically typed language. To improve efficiency, a practical type checking method is presented, which consists of both static and dynamic type checking. Although the inclusion relation of CF languages is not decidable, a special subset of the relation is decidable, i.e., the sentential form relation, which can be statically checked. Moreover, most of the expressions in actual LFC programs appear to satisfy this relation according to the statistic data of experiments. So, despite that the static type checking is not complete, it undertakes most of the type checking task. Consequently the run-time efficiency is effectively improved. Another feature of the type checking is that it converts the expressions with implicit structures to structured representation. Structure reconstruction technique is presented.
引用
收藏
页码:840 / 847
页数:8
相关论文
共 50 条
  • [1] Practical type checking of functions defined on Context-Free languages
    Hai-Ming Chen
    Yun-Mei Dong
    Journal of Computer Science and Technology, 2004, 19 : 840 - 847
  • [2] Towards practical computable functions on context-free languages
    Chen, Haiming
    Dong, Yunmei
    THEORY AND APPLICATIONS OF MODELS OF COMPUTATION, PROCEEDINGS, 2006, 3959 : 555 - 565
  • [3] Pattern matching compilation of functions defined in context-free languages
    Haiming Chen
    Yunmei Dong
    Journal of Computer Science and Technology, 2001, 16 : 159 - 167
  • [4] Pattern matching compilation of functions defined in context-free languages
    Chen, HM
    Dong, YM
    JOURNAL OF COMPUTER SCIENCE AND TECHNOLOGY, 2001, 16 (02) : 159 - 167
  • [5] Model-Checking Structured Context-Free Languages
    Chiari, Michele
    Mandrioli, Dino
    Pradella, Matteo
    COMPUTER AIDED VERIFICATION, PT II, CAV 2021, 2021, 12760 : 387 - 410
  • [6] Practical experiments with regular approximation of context-free languages
    Nederhof, MJ
    COMPUTATIONAL LINGUISTICS, 2000, 26 (01) : 17 - 44
  • [7] ON CONTEXT-FREE LANGUAGES
    PARIKH, RJ
    JOURNAL OF THE ACM, 1966, 13 (04) : 570 - +
  • [8] Efficient parallel and incremental parsing of practical context-free languages
    Bernardy, Jean-Philippe
    Claessen, Koen
    JOURNAL OF FUNCTIONAL PROGRAMMING, 2015, 25
  • [9] NATURAL LANGUAGES AND CONTEXT-FREE LANGUAGES
    PULLUM, GK
    GAZDAR, G
    LINGUISTICS AND PHILOSOPHY, 1982, 4 (04) : 471 - 504
  • [10] On differentiation functions, structure functions, and related languages of context-free grammars
    Dassow, J
    Mitrana, V
    Paun, G
    Stiebe, R
    RAIRO-THEORETICAL INFORMATICS AND APPLICATIONS, 2004, 38 (03): : 257 - 267