| Item type |
Trans(1) |
| 公開日 |
2025-03-18 |
| タイトル |
|
|
言語 |
ja |
|
タイトル |
型クラスの導入による文脈自由文法の構文要素間の関係の記述 |
| タイトル |
|
|
言語 |
en |
|
タイトル |
Describing Relationships Among Syntax Elements in Context-Free Grammar through Introduction of Type Classes |
| 言語 |
|
|
言語 |
jpn |
| キーワード |
|
|
主題Scheme |
Other |
|
主題 |
[発表概要, Unrefereed Presentatin Abstract] |
| 資源タイプ |
|
|
資源タイプ識別子 |
http://purl.org/coar/resource_type/c_6501 |
|
資源タイプ |
journal article |
| 著者所属 |
|
|
|
筑波大学大学院理工情報生命学術院システム情報工学研究群情報理工学位プログラム |
| 著者所属 |
|
|
|
筑波大学図書館情報メディア系 |
| 著者所属 |
|
|
|
筑波大学システム情報系 |
| 著者所属(英) |
|
|
|
en |
|
|
Graduate School of Science and Technology, Degree Programs in Systems and Information Engineering, Master's Program in Computer Science, University of Tsukuba |
| 著者所属(英) |
|
|
|
en |
|
|
Institute of Library, Information and Media Science, University of Tsukuba |
| 著者所属(英) |
|
|
|
en |
|
|
Institute of Systems and Information Engineering, University of Tsukuba |
| 著者名 |
中神,悠太
中井,央
三宮,秀次
|
| 著者名(英) |
Yuta Nakagami
Hisashi Nakai
Shuji Sannomiya
|
| 論文抄録 |
|
|
内容記述タイプ |
Other |
|
内容記述 |
プログラミング言語の文法として文脈自由文法(CFG:Context-Free Grammar)がよく用いられる.プログラミング言語の文法は通常,何らかの構造的性質を有する.開発現場では,この性質を利用して,文法を記述する際に既存文法から一部を利用することがよくある.このとき,規則の一部を開発中の文法に取り入れるためには不整合を解消するための変更が必要となることがある.また,言語の進化にともなう構文の変化に応じて,文法規則の増減や調整も必要となる.開発者は文法中に潜在する構文要素間の関係を意識しながら文法の開発や修正を行う必要があり,これが文法の開発を難しくしている.さらに,意味解析処理を考慮してそのための構造を持たせることもあり,文法の設計がより複雑化することが多い.CFGではここであげたような複雑さを十分にとらえられない.我々は,CFGの構成要素である非終端記号に対して型クラスを基本とする型システムを導入したTypedCFGを提案する.TypedCFGでは,要素間の関係を表現する記述法を導入することで,要素間の依存関係や制約を非終端記号に対して明示的に与えられる.従来のCFGでの文法開発では規則間に潜在する関係を自ら補完していたが,それを明示することで効率的に文法を開発・修正できる.本研究では,提案する記法の考案やこれによるパーサジェネレータの実装を行った.さらに,型情報を用いて意味解析における各種制約を表現する手法について検討し,いくつかの例について実装を行った. |
| 論文抄録(英) |
|
|
内容記述タイプ |
Other |
|
内容記述 |
Context-Free Grammar (CFG) is commonly used as the syntax for programming languages. Typically, programming language grammars exhibit some structural properties. In development, it is common to utilize parts of existing grammars when describing new ones, leveraging these properties. However, in- corporating rules from existing grammars into a developing grammar often requires adjustments to resolve inconsistencies. Furthermore, as languages evolve, syntax changes necessitate adjustments in grammar rules. Developers must be mindful of relationships among potential syntactic elements within the grammar, which complicates grammar development. Moreover, designing grammars can become even more complex when considering semantic analysis requirements, potentially requiring specific structural attributes. CFG fails to adequately capture complexities such as those mentioned above. We propose Typed CFG, which introduces a type system based on type classes for non-terminal symbols, components of CFG. Typed CFG employs a notation to explicitly specify dependencies and constraints among elements, addressing these issues. While traditional CFG development often involves developers sup- plementing implicit relationships between rules, Typed CFG facilitates efficient grammar development and modification by making these relationships explicit. In this study, we devised the proposed notation and implemented a parser generator based on it. Addition- ally, we explored techniques using type information to represent various constraints in semantic analysis, implementing several examples accordingly. |
| 書誌レコードID |
|
|
収録物識別子タイプ |
NCID |
|
収録物識別子 |
AA11464814 |
| 書誌情報 |
情報処理学会論文誌プログラミング(PRO)
巻 18,
号 1,
p. 15-15,
発行日 2025-03-18
|
| ISSN |
|
|
収録物識別子タイプ |
ISSN |
|
収録物識別子 |
1882-7802 |
| 出版者 |
|
|
言語 |
ja |
|
出版者 |
情報処理学会 |