J4 ›› 2012, Vol. 39 ›› Issue (6): 70-77.doi: 10.3969/j.issn.1001-2400.2012.06.012

• 研究论文 • 上一篇    下一篇

程序流程图到代码的自动生成算法

王黎明;王帼钕;周明媛;褚艳利;陈科;陈平   

  1. (西安电子科技大学 软件工程研究所,陕西 西安  710071)
  • 收稿日期:2011-07-26 出版日期:2012-12-20 发布日期:2013-01-17
  • 通讯作者: 王黎明
  • 作者简介:王黎明(1982-),男,讲师,西安电子科技大学博士研究生,E-mail: wanglm@mail.xidian.edu.cn.
  • 基金资助:

    国家自然科学基金资助项目(60903198)

Research on and implementation of the algorithm from the program flowchart to the code

WANG Liming;WANG Guonü;ZHOU Mingyuan;CHU Yanli;CHEN Ke;CHEN Ping   

  1. (Research Inst. of Software Engineering, Xidian Univ., Xi'an  710071, China)
  • Received:2011-07-26 Online:2012-12-20 Published:2013-01-17
  • Contact: WANG Liming

摘要:

提出了一种从标准程序流程图到结构化代码生成的新算法.该算法通过对程序流程图结构的分析与识别、循环结构的线性化以及对分支结构域的确定等过程,能够生成符合程序流程图语义的结构化C代码(包括continue/break/return);同时,能够识别出非结构化的程序流程图.

关键词: 可视化编程, 程序流程图, 模型驱动, 代码生成

Abstract:

A new method for generating the structural code from the standard program flowcharts is presented. By analyzing the flowchart, linearizing the cycle structure and delimiting the branch structure, the structual C code agreeing with the semanteme of the flowchart is generated. At the same time, the unstructural flowchart is recognized.

Key words: visual programming, flowcharting, model-based, code generation

中图分类号: 

  • tp331
Baidu
map