Searching source code
Abstract
Searching source code includes receiving a search string, a feature type and details of source code to be searched. The source code is parsed to generate an abstract syntax tree. The abstract syntax tree is indexed using a search structure defining all source code features for which searching is enabled. The search string is searched for the search string of the feature type in the indexed abstract syntax tree using a results structure defining the search outputs to be retrieved. A structured search result based on the output of the searching is provided. The structured search result is stored in the storage device.
Interactive Citation Constellation Global Citation Ranking
Interactive SVG Citation Constellation renders in Rust/WebAssembly. Prior art cited: 28 · Forward citations: 2.
Claims (1 — 1 Independent, 0 Dependent)
- Claim 1Independent Claim
A method for controlling a storage device for searching source code stored in the storage device, the method comprising: receiving a search string, a feature type and details of source code to be searched; parsing the source code to be searched to generate an abstract syntax tree; indexing the abstract syntax tree using a search structure defining all source code features for which searching is enabled, wherein the source code features for which searching is enabled are defined during an initialization process that includes generating a parser based on a grammar of a programming language of th
Technical Overview & Description
Full multi-page specification text is archived at the issuing office. Read complete official specification ↗
Cited By — Indexed Forward Citations (2 of 2 total)
| Patent | Title | Year | Citations |
|---|---|---|---|
| US 11,003,426 B1 | Identification of code for parsing given expressions | 2021 | 8 |
| US 11,481,212 B2 | Automatic identification of reference data | 2022 | 0 |
References Cited — Backward Prior Art (28)
Non-Patent Literature (5)
- Chilowicz et al., Syntax tree fingerprinting for source code similarity detection, published by IEEE, 2009, pp. 243-247.
- Hsu et al., "A Multi-block Scheme for Searching Source Codes," IEEE, 2010, pp. 608-613.
- Keivanloo et al., "Semantic Webbased Source Code Search", 6th International Workshop on Semantic Web Enabled Software Engineering (SWESE 2010), San Francisco, USA., p. 1-16.
- Kuhn et al., Abstract Syntax Tree, Published 2006: [retrieved on Mar. 7, 2015], Retrieved from Internet ; pp. 1-8.
- Kuhn et al., Abstract Syntax Tree, Published 2006: [retrieved on Mar. 7, 2015], Retrieved from Internet <http://www.eclipse.org/articles/Article-JavaCodeManipulation-AST>; pp. 1-8.