基于O'Caml语言的通用编程技术
DOI:
作者:
作者单位:

作者简介:

通讯作者:

中图分类号:

基金项目:


Generic Programming Based on O'Caml Language
Author:
Affiliation:

Fund Project:

  • 摘要
  • |
  • 图/表
  • |
  • 访问统计
  • |
  • 参考文献
  • |
  • 相似文献
  • |
  • 引证文献
  • |
  • 增强出版
  • |
  • 文章评论
    摘要:

    O'Caml语言是一门优秀的函数式程序语言, 具有计算模型简单、语法语义描述清晰等特点, 而通用编程技术方法通过高度抽象算法、数据结构及其他软件组件可以避免功能相似代码的重复编写. 针对如何将通用编程技术方法和O'Caml语言相结合来提高O'Caml程序复用程度的问题, 通过对O'Caml语言语法进行扩展引入类型标记1函数, 然后运用类型结构化转换和类型映射机制, 实现通用函数, 从而达到在O'Caml语言中引入通用编程技术的目的. 实例结果表明, 在O'Caml语言中实现通用编程技术, 有效提高了编程效率和程序的通用性.

    Abstract:

    O'Caml is a popular functional programming language with a lot of advanced features, such as: simple module, clear grammar and semantci, etc. Generic programming which programs through the abstracting of algorithm, data structure and all other of the software components can avoid the repeated work of coding with similar functions. In order to combine the generic programming and O'Caml language which can improve the reuse of soft, we extend the grammar of O'Caml language to implement type-indexed function, the structure transition and isomorphism of type and generic function. The experimental result shows that the implementation of generic programming in O'Caml language has improved the efficiency and universality of programming.

    参考文献
    相似文献
    引证文献
引用本文

李阳,赵建平,张德华,程小林.基于O'Caml语言的通用编程技术.计算机系统应用,2015,24(5):106-110

复制
分享
文章指标
  • 点击次数:
  • 下载次数:
  • HTML阅读次数:
  • 引用次数:
历史
  • 收稿日期:2014-08-21
  • 最后修改日期:2014-10-08
  • 录用日期:
  • 在线发布日期: 2015-05-15
  • 出版日期:
您是第位访问者
版权所有:中国科学院软件研究所 京ICP备05046678号-3
地址:北京海淀区中关村南四街4号 中科院软件园区 7号楼305房间,邮政编码:100190
电话:010-62661041 传真: Email:csa (a) iscas.ac.cn
技术支持:北京勤云科技发展有限公司

京公网安备 11040202500063号