Filters








141,874 Hits in 5.2 sec

Combinators for parsing expressions

Steve Hill
1996 Journal of functional programming  
In particular, it describes a set of combinators for parsing expressions described by ambiguous grammars with precedence and associativity rules.  ...  The expression combinators are general, and may be constructed from any suitable set of top-down combinators.  ...  The source for the combinators and cparen tool are available via anonymous ftp from ftp.ukc.ac.uk in the directory /pub/sah.  ... 
doi:10.1017/s0956796800001799 fatcat:mu7ziogpyjaard6dep4io3gkuu

Efficient parsing with parser combinators

Jan Kurš, Jan Vraný, Mohammad Ghafari, Mircea Lungu, Oscar Nierstrasz
2018 Science of Computer Programming  
For each combinator, we analyze the language parsed by the combinator and choose the most efficient parsing strategy.  ...  By adapting a parsing strategy for different parser combinators we achieve performance comparable to that of hand-written or optimized parsers while preserving the advantages of parsers combinators.  ...  Acknowledgments We gratefully acknowledge the financial support of the Swiss National Science Foundation for the project "Agile Software Analysis" (SNSF project No. 200020-162352, Jan 1, 2016 -Dec. 30,  ... 
doi:10.1016/j.scico.2017.12.001 fatcat:3ixjvs2mxnawbd2b5o5jt7vnym

Yacc is dead [article]

Matthew Might, David Darais
2010 arXiv   pre-print
Preliminary experiments with S-Expressions parsed millions of tokens per second, which suggests this technique is efficient enough for use in practice.  ...  The second approach is based on a generalization of the derivative to parser combinators.  ...  For example, for the simple expression language, where A = {+, *, (, ), 0, 1}, the meaning of an input expression w ∈ A * is contained within τ N (w): τ N = τ ′ N ∪ τ ′ N · + · τ N → λ(n 1 , +, n 2 ).n  ... 
arXiv:1010.5023v1 fatcat:lznh3iovyba4nmgjhyottxmv7q

Expressing disambiguation filters as combinators

José Nuno Macedo, João Saraiva
2020 Proceedings of the 35th Annual ACM Symposium on Applied Computing  
We propose a different approach for disambiguation. A set of disambiguation filters (expressed as combinators) are provided, and disambiguation can be achieved by composing combinators.  ...  New combinators can be created and, by having the disambiguation step separated from the parsing step, disambiguation rules can be changed without modifying the parser.  ...  Because we express disambiguation rules as combinators, new rules can be easily defined by combining existing ones.  ... 
doi:10.1145/3341105.3374123 dblp:conf/sac/MacedoS20 fatcat:hkkpk2pgyzdopmakwz4ez6r7qm

Research Report: The Parsley Data Format Definition Language

Prashanth Mundkur, Linda Briesemeister, Natarajan Shankar, Prashant Anantharaman, Sameed Ali, Zephyr Lucas, Sean Smith
2020 2020 IEEE Security and Privacy Workshops (SPW)  
Any program that reads formatted input relies on parsing software to check the input for validity and transform it into a representation suitable for further processing.  ...  Parsley is a declarative data format definition language that combines grammars and constraints in a modular way. We show how it can be used to capture data formats such as MAVLink, PDF and ELF.  ...  Any opinions, findings and conclusions or recommendations expressed in this material are those of the author(s) and do not necessarily reflect the views of the Defense Advanced Research Projects Agency  ... 
doi:10.1109/spw50608.2020.00064 fatcat:htzbbb66lvhb7nya3x4iwgffia

A Practical Parser with Combined Parsing Techniques

Donghui Wang
2015 International Journal of Software Engineering & Applications  
This paper describes how the parser was enhanced to handle extra syntax for sophisticated mathematical and logical expressions.  ...  efficient two-level parsing approach.  ...  Bethke, RTI International, for their assistance with this paper. Without their tremendous help, I would not have been able to finish the paper.  ... 
doi:10.5121/ijsea.2015.6401 fatcat:v2spmqvhordffbp4agjlmvvbii

Exception Handling for Error Reporting in Parsing Expression Grammars [chapter]

André Murbach Maidl, Fabio Mascarenhas, Roberto Ierusalimschy
2013 Lecture Notes in Computer Science  
Parsing Expression Grammars (PEGs) are a new formalism to describe a top-down parser of a language.  ...  Moreover, our approach is an extension to the PEGs formalism that is expressive enough to implement some previous work on parser combinators.  ...  Parsing Expression Grammars (PEGs) [4] are a new formalism for describing the syntax of programming languages.  ... 
doi:10.1007/978-3-642-40922-6_1 fatcat:ovaa6lbw3bevtb4jehtxlwv57q

Implementation of C Library for Constructing Packrat Parser with Statically Allocated Memory

Yuta Sugimoto, Atusi Maeda
2018 Journal of Information Processing  
Syntax rules are just expressed by plain C macros. The runtime routine does not dynamically allocate memory regions for memoization.  ...  Packrat parsing is a recursive descent parsing method with backtracking and memoization.  ...  Acknowledgments The authors would like to thank Professor Shigeru Chiba, University of Tokyo, for his constructive comments to the draft of the paper.  ... 
doi:10.2197/ipsjjip.26.335 fatcat:aeyvm2up65duhlqgylro2ifvyi

Error Reporting in Parsing Expression Grammars [article]

André Murbach Maidl, Sérgio Medeiros, Fabio Mascarenhas, Roberto Ierusalimschy
2016 arXiv   pre-print
Labeled failures give a way to annotate grammars for better error reporting, to express some of the error reporting strategies used by deterministic parser combinators, and to encode predictive top-down  ...  Parsing Expression Grammars (PEGs) describe top-down parsers.  ...  Parsing Expression Grammars (PEGs) [2] are a formalism for describing the syntax of programming languages.  ... 
arXiv:1405.6646v3 fatcat:3evyhemwkzepddke3avvylgqq4

Packrat Parsing: Simple, Powerful, Lazy, Linear Time [article]

Bryan Ford
2006 arXiv   pre-print
Packrat parsing is a novel technique for implementing parsers in a lazy functional programming language.  ...  A packrat parser provides the power and flexibility of top-down parsing with backtracking and unlimited lookahead, but nevertheless guarantees linear parse time.  ...  Acknowledgments I wish to thank my advisor Frans Kaashoek, my colleagues Chuck Blake and Russ Cox, and the anonymous reviewers for many helpful comments and suggestions.  ... 
arXiv:cs/0603077v1 fatcat:flk3jeqayfeixcr6eb7nomwcui

Higher-order functions for parsing

Graham Hutton
1992 Journal of functional programming  
In particular, a combining form for handling the 'offside rule' is given.  ...  AbstractIncombinator parsing, the text of parsers resembles BNF notation. We present the basic method, and a number of extensions.  ...  Acknowledgements Thanks to Paul Hudak and John Launchbury for their comments and suggestions.  ... 
doi:10.1017/s0956796800000411 fatcat:hshuzikf4zhz5odeosszloedbu

Packrat parsing:

Bryan Ford
2002 Proceedings of the seventh ACM SIGPLAN international conference on Functional programming - ICFP '02  
Packrat parsing is a novel technique for implementing parsers in a lazy functional programming language.  ...  A packrat parser provides the power and flexibility of top-down parsing with backtracking and unlimited lookahead, but nevertheless guarantees linear parse time.  ...  Acknowledgments I wish to thank my advisor Frans Kaashoek, my colleagues Chuck Blake and Russ Cox, and the anonymous reviewers for many helpful comments and suggestions.  ... 
doi:10.1145/581478.581483 dblp:conf/icfp/Ford02 fatcat:ocrwbtlsyjfzbiqqoji3lf5mxm

Packrat parsing:

Bryan Ford
2002 SIGPLAN notices  
Packrat parsing is a novel technique for implementing parsers in a lazy functional programming language.  ...  A packrat parser provides the power and flexibility of top-down parsing with backtracking and unlimited lookahead, but nevertheless guarantees linear parse time.  ...  Acknowledgments I wish to thank my advisor Frans Kaashoek, my colleagues Chuck Blake and Russ Cox, and the anonymous reviewers for many helpful comments and suggestions.  ... 
doi:10.1145/583852.581483 fatcat:xs2pkw6x6fg53hmmolxnmpocau

LL(1) Parsing with Derivatives and Zippers [article]

Romain Edelmann, Jad Hamza, Viktor Kunčak
2019 arXiv   pre-print
Next, we present a novel linear-time parsing with derivatives algorithm for LL(1) expressions operating on a zipper-inspired data structure.  ...  In this paper, we present an efficient, functional, and formally verified parsing algorithm for LL(1) context-free expressions based on the concept of derivatives of formal languages.  ...  Combinators (SPC) for parsing JSON.  ... 
arXiv:1911.12737v1 fatcat:upsdnfcnm5dkvgpy5xozyjnmiu

Honu

Jon Rafkind, Matthew Flatt
2012 Proceedings of the 11th International Conference on Generative Programming and Component Engineering - GPCE '12  
A key element of Honu's design is an enforestation parsing step, which converts a flat stream of tokens into an S-expressionlike tree, in addition to the initial "read" phase of parsing and interleaved  ...  We present the design of Honu, explain its parsing and macro-extension algorithm, and show example syntactic extensions.  ...  Acknowledgments: Thanks to Ryan Culpepper and Kevin Atkinson for feedback on the design and presentation of Honu.  ... 
doi:10.1145/2371401.2371420 dblp:conf/gpce/RafkindF12 fatcat:sbkmdzvzxjfg7oefff63wkkemu
« Previous Showing results 1 — 15 out of 141,874 results