Static Slicing for Python First-Class Objects

Zhaogui Xu, Ju Qian, Lin Chen, Zhifei Chen, Baowen Xu
{"title":"Static Slicing for Python First-Class Objects","authors":"Zhaogui Xu, Ju Qian, Lin Chen, Zhifei Chen, Baowen Xu","doi":"10.1109/QSIC.2013.50","DOIUrl":null,"url":null,"abstract":"Program slicing is an important program analysis technique and now has been used in many fields of software engineering. However, most existing program slicing methods focus on static programming languages such as C/C++ and Java, and methods on dynamic languages like Python are rarely seen. Python, a typical dynamic object-oriented language, has been more and more widely used now. In Python, everything is a first-class object, including functions, classes, methods, and modules. Existing slicing methods cannot handle the issue of these first-class objects. Therefore, this paper proposes a static slicing method for Python first-class objects. By adding all the definitions of first-class objects into the dependence model and uniformly constructing the program dependence graphs for all the functions, classes, methods, and modules, this method can effectively solve the slicing problems caused by arbitrary definitions and uses of first-class objects in Python.","PeriodicalId":404921,"journal":{"name":"2013 13th International Conference on Quality Software","volume":"234 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2013-07-29","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"12","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"2013 13th International Conference on Quality Software","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1109/QSIC.2013.50","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 12

Abstract

Program slicing is an important program analysis technique and now has been used in many fields of software engineering. However, most existing program slicing methods focus on static programming languages such as C/C++ and Java, and methods on dynamic languages like Python are rarely seen. Python, a typical dynamic object-oriented language, has been more and more widely used now. In Python, everything is a first-class object, including functions, classes, methods, and modules. Existing slicing methods cannot handle the issue of these first-class objects. Therefore, this paper proposes a static slicing method for Python first-class objects. By adding all the definitions of first-class objects into the dependence model and uniformly constructing the program dependence graphs for all the functions, classes, methods, and modules, this method can effectively solve the slicing problems caused by arbitrary definitions and uses of first-class objects in Python.
Python一级对象的静态切片
程序切片是一种重要的程序分析技术,目前已应用于软件工程的许多领域。然而,大多数现有的程序切片方法都集中在C/ c++和Java等静态编程语言上,而Python等动态语言上的方法很少见到。Python是一种典型的动态面向对象语言,目前已得到越来越广泛的应用。在Python中,一切都是一等对象,包括函数、类、方法和模块。现有的切片方法无法处理这些一等对象的问题。因此,本文提出了一种针对Python第一类对象的静态切片方法。该方法通过将所有一级对象的定义加入到依赖模型中,统一构造所有函数、类、方法和模块的程序依赖图,可以有效解决Python中由于任意定义和使用一级对象而导致的切片问题。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 求助全文
来源期刊
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术官方微信