skip to main content
10.1145/2786805.2807560acmconferencesArticle/Chapter ViewAbstractPublication PagesfseConference Proceedingsconference-collections
abstract

Spotting familiar code snippet structures for program comprehension

Published: 30 August 2015 Publication History

Abstract

Developers deal with the persistent problem of understanding non-trivial code snippets. To understand the given implementation, its issues, and available choices, developers will benefit from reading relevant discussions and descriptions over the web. However, there is no easy way to know the relevant natural language terms so as to reach to such descriptions from a code snippet, especially if the documentation is inadequate and if the vocabulary used in the code is not helpful for web search. We propose an approach to solve this problem using a repository of topics and associated structurally variant snippets collected from a discussion forum. In this on-going work, we take Java methods from the code samples of three Java books, match them with the repository, and associate the topics with 76.9% precision and 66.7% recall.

References

[1]
How to implement Chebyshev Type 2 LPF in Java? http://StackOverflow.com/questions/16879642/ how-to-implement-chebyshev-type-2-lpf-in-java.
[2]
B. Ashok, J. Joy, H. Liang, S. K. Rajamani, G. Srinivasa, and V. Vangala. Debugadvisor: A recommender system for debugging. In Proceedings of the the 7th Joint Meeting of the European Software Engineering Conference and the ACM SIGSOFT Symposium on The Foundations of Software Engineering, ESEC/FSE ’09, pages 373–382, New York, NY, USA, 2009. ACM.
[3]
S. K. Bajracharya, J. Ossher, and C. V. Lopes. Leveraging usage similarity for effective retrieval of examples in code repositories. In Proceedings of the Eighteenth ACM SIGSOFT International Symposium on Foundations of Software Engineering, FSE ’10, pages 157–166, 2010.
[4]
L. R. Biggers, C. Bocovich, R. Capshaw, B. P. Eddy, L. H. Etzkorn, and N. A. Kraft. Configuring latent dirichlet allocation based feature location. Empirical Softw. Engg., 19(3):465–500, June 2014.
[5]
J. Bloch. Effective Java, Second Edition.
[6]
B. Dit, M. Revelle, M. Gethers, and D. Poshyvanyk. Feature location in source code: a taxonomy and survey. Journal of Software: Evolution and Process, 25(1):53–95, 2013.
[7]
A. Feuer, S. Savev, and J. A. Aslam. Implementing and evaluating phrasal query suggestions for proximity search. Inf. Syst., 34(8):711–723, Dec. 2009.
[8]
S. Haiduc, J. Aponte, and A. Marcus. Supporting program comprehension with source code summarization. In Proceedings of the 32Nd ACM/IEEE International Conference on Software Engineering - Volume 2, ICSE ’10, pages 223–226, 2010.
[9]
S. Lahiri, C. Hawblitzel, M. Kawaguchi, and H. Rebelo. Symdiff: A language-agnostic semantic diff tool for imperative programs. In Computer Aided Verification (CAV ’12) (Tool description). Springer, July 2012.
[10]
A. Lucia, M. Penta, R. Oliveto, A. Panichella, and S. Panichella. Labeling source code with information retrieval methods: An empirical study. Empirical Softw. Engg., 19(5):1383–1420, Oct. 2014.
[11]
C. D. Manning, P. Raghavan, and H. Schütze. Introduction to Information Retrieval. Cambridge University Press, 2008.
[12]
H. Schildt. Java: A Beginner’s Guide, Sixth Edition. http://www.mhprofessional.com/product.php? isbn=0071809252.
[13]
K. Sierra and B. Bates. Head First Java, Second Edition. http://www.headfirstlabs.com/books/hfjava/.
[14]
V. Vinayakarao, R. Purandare, and A. V. Nori. Structurally heterogeneous source code examples from unstructured knowledge sources. In Proceedings of the 2015 Workshop on Partial Evaluation and Program Manipulation, PEPM ’15, pages 21–26, 2015.

Cited By

View all
  • (2023)Big Code Search: A BibliographyACM Computing Surveys10.1145/360490556:1(1-49)Online publication date: 26-Aug-2023
  • (2017)Modeling Source Code to Support Retrieval-Based ApplicationsProceedings of the Tenth ACM International Conference on Web Search and Data Mining10.1145/3018661.3022749(833-833)Online publication date: 2-Feb-2017
  • (2016)Query Expansion Based on Crowd Knowledge for Code SearchIEEE Transactions on Services Computing10.1109/TSC.2016.25601659:5(771-783)Online publication date: 1-Sep-2016

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Conferences
ESEC/FSE 2015: Proceedings of the 2015 10th Joint Meeting on Foundations of Software Engineering
August 2015
1068 pages
ISBN:9781450336758
DOI:10.1145/2786805
Permission to make digital or hard copies of part or all of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for third-party components of this work must be honored. For all other uses, contact the Owner/Author.

Sponsors

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 30 August 2015

Check for updates

Author Tags

  1. Structure Matching
  2. Variant Repository

Qualifiers

  • Abstract

Conference

ESEC/FSE'15
Sponsor:

Acceptance Rates

Overall Acceptance Rate 112 of 543 submissions, 21%

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)2
  • Downloads (Last 6 weeks)0
Reflects downloads up to 20 Jan 2025

Other Metrics

Citations

Cited By

View all
  • (2023)Big Code Search: A BibliographyACM Computing Surveys10.1145/360490556:1(1-49)Online publication date: 26-Aug-2023
  • (2017)Modeling Source Code to Support Retrieval-Based ApplicationsProceedings of the Tenth ACM International Conference on Web Search and Data Mining10.1145/3018661.3022749(833-833)Online publication date: 2-Feb-2017
  • (2016)Query Expansion Based on Crowd Knowledge for Code SearchIEEE Transactions on Services Computing10.1109/TSC.2016.25601659:5(771-783)Online publication date: 1-Sep-2016

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media