Gå til søgefeltetSpring over til navigationSpring til hovedindhold

Typed and unambiguous pattern matching on strings using regular expressions

  • Aarhus Universitet
Publikation:
Konference artikel i Proceeding eller bog/rapport kapitel
Konferencebidrag i proceedings
Forskning
Peer-review

Open Access

Resume

We show how to achieve typed and unambiguous declarative
pattern matching on strings using regular expressions
extended with a simple recording operator.

We give a characterization of ambiguity of regular expressions
that leads to a sound and complete static analysis. The
analysis is capable of pinpointing all ambiguities in terms of
the structure of the regular expression and report shortest
ambiguous strings. We also show how pattern matching can
be integrated into statically typed programming languages
for deconstructing strings and reproducing typed and structured
values.

We validate our approach by giving a full implementation
of the approach presented in this paper. The resulting tool,
reg-exp-rec, adds typed and unambiguous pattern matching
to Java in a stand-alone and non-intrusive manner. We
evaluate the approach using several realistic examples.

Publikation information

Produktionstype

Publikation:
Konference artikel i Proceeding eller bog/rapport kapitel
Konferencebidrag i proceedings
Forskning
Peer-review

Originalsprog

Engelsk

Sider fra-til (Antal sider)

Sider 243-254 (12 sider)

Publikationsmilepæle

  • Udgivet - 2010

Publikationsstatus

Udgivet - 2010

Forlag

Association for Computing Machinery, USA
978-1-4503-0132-9

Publikations IDer

  • Scopus: 77956259528

Titel på værtspublikation

Proceedings of the 12th international ACM SIGPLAN symposium on Principles and practice of declarative programming

Metrikker

PlumX

Hentninger
10
Antal citationer
11

Relateret event

Titel

International Conference on Principles and Practice of Declarative Programming (PPDP 2010)

Begivenhedstype

Konference

Grad af anerkendelse

International begivenhed

Dato

26/07/2010 - 28/07/2010

Lokation

HagenbergØstrig