講演抄録/キーワード |
講演名 |
2018-01-25 14:20
定理証明技術を用いたソースコードの補完手法の提案 ○小池遼平(早大)・小野康一(日本IBM)・深澤良彰(早大) KBSE2017-33 |
抄録 |
(和) |
ソフトウェア開発を効率的に行うための技術の1つにコード補完がある.コード補完とは記述中のソースコードの不足部分を自動的に補完する技術であり,ユーザは提示された補完候補のうちの1つを選択することで効率よくコーディングを行うことができる.しかし既存の手法では,正しくないコードの候補も含めて提示されるため,ユーザが誤ったコードを選択する可能性が発生する.この場合,ユーザはコード全体に修正を加えるか,補完された部分を再び候補の中から選択し直すという手間を強いられることになる.そこで本研究では定理証明技術を組み込んだコード補完手法を提案する.提案する手法では実装途中のソースコードに加え,実装途中のコードに与えられた事前条件/事後条件を考慮したコード検索を行い,定理証明を用いた検証により候補の絞り込みを行う.これにより,与えられた仕様を充足するコードに限定して推薦を行うことができるため,スムーズなコーディングを行えるとともに誤ったコードを選択するリスクを軽減することができる. |
(英) |
Code completion is one of the techniques for making software development efficient. Code completion can complete the missing part of the source code automatically, so users can implement by selecting one of the recommended candidates. However, when users work on environment with existing code completion techniques, they might select incorrect candidates, since the recommendation would include incorrect codes. In this case, they have to modify the code or to select another one from the candidates. In this paper, we propose a new code completion method incorporating theorem proving technique. In this method, code search is performed in consideration of pre-condition / post-condition given as the specification of the code, and the theorem proving is used to narrow down the candidates by verifying the specification. By using this method, users can get the correct code that satisfies a given specification, so users can develop software smoothly and reduce the risk of selecting incorrect codes. |
キーワード |
(和) |
コード補完 / コード断片 / JMLアノテーション / 定理証明 / / / / |
(英) |
code completion / code snippet / JML annotation / automated theorem proving / / / / |
文献情報 |
信学技報, vol. 117, no. 414, KBSE2017-33, pp. 7-11, 2018年1月. |
資料番号 |
KBSE2017-33 |
発行日 |
2018-01-18 (KBSE) |
ISSN |
Print edition: ISSN 0913-5685 Online edition: ISSN 2432-6380 |
著作権に ついて |
技術研究報告に掲載された論文の著作権は電子情報通信学会に帰属します.(許諾番号:10GA0019/12GB0052/13GB0056/17GB0034/18GB0034) |
PDFダウンロード |
KBSE2017-33 |