arrow
返回

Identifying change patterns of API misuses from code changes

delete2021-02-07
delete5
PRE
AI
W
Wenjian Liu
B
Bihuan Chen *
X
Xin Peng
Q
Qinghao Sun
DOI:10.1007/s11432-019-2745-5delete
delete原文链接
delete原文求助
delete分享
delete收藏
摘要

摘要

En 中文
Library or framework APIs are difficult to learn and use, leading to unexpected software behaviors or bugs. Hence, various API mining techniques have been introduced to mine API usage patterns about the co-occurring of API calls or pre-conditions of API calls. However, they fail to mine patterns about an API call itself (e.g., whether the arguments of the API call are correctly set and whether the API is suitably chosen over other similar APIs). To bridge this gap, we propose Cpam to identify change patterns (in the form of a pair of APIs before and after code changes) to fix API misuses, using historical code changes. Given a set of target APIs and a corpus of open-source projects, Cpam first selects the commits that potentially fix API misuses from the corpus, then extracts changes to API misuses in each selected commit, and finally identifies change patterns of API misuses. We implement Cpam for Java, and conduct large-scale evaluation, targeting Java SE APIs and using a corpus of 1162 Java projects. Our experimental results demonstrate Cpam's effectiveness and efficiency. By applying identified change patterns to bug detection, we find 44 new bugs, and 18 of them have been confirmed and fixed.
Keyword:
API misuses
API mining
AST differencing
change patterns
bug fixing
AI总结

AI总结

对已上传原文的论文进行重点信息的提取,主要内容包括:简要概述、研究摘要、背景介绍、关键亮点、图文解析、展望与总结。

期刊

Science China Information Sciences 封面图
Science China Information Sciences
IF:
7.6
论文数:
4.9K
被引数:
8.9K

机构

F
fudan university
学者数:
11.8W
论文数: 7.7W
被引数: 121
引用论文

引用论文

A Hybrid ACO+CP for Balancing Bicycle Sharing Systems
err2013-01-01
err0
PREAI
errLuca Di Gaspero; Andrea Rendl; Tommaso Urli
err分享
err收藏
Titania Nanobelts as a Scattering Layer with Cu2ZnSnS4 as a Counter Electrode for DSSC with Improved Efficiency
err2018-01-01
err0
PREAI
errSiva Sankar Nemala; Krishnaiah Mokurala; Parag Bhargava; Sudhanshu Mallick
err分享
err收藏
Supercurrent in a Double Quantum Dot
err2018-12-20
err0
errOAAI
errJ. C. Estrada Saldaña; A. Vekris; G. Steffensen; R. Žitko; P. Krogstrup; J. Paaske; K. Grove-Rasmussen; J. Nygård
err分享
err收藏
err
IF0
err
err0
PREAI
err
err分享
err收藏
Psychometric properties of the Chinese version of the Infertility Self-Efficacy Scale
err2016-09-01
err0
errOAAI
errBing Fu; Pingping Yan; Hang Yin; Shujuan Zhu; Qing Liu; Yulan Liu; Chanyuan Dai; Guanxiu Tang; Chunli Yan; Jun Lei
err分享
err收藏
err
IF0
err
err0
PREAI
err
err分享
err收藏
A Socially Responsible Islamic Finance
err
IF0
err2017-01-01
err0
PREAI
errUmar F. Moghul
err分享
err收藏
学者 查看更多内容