Skip to main content

Advertisement

SpringerLink
Log in
Menu
Find a journal Publish with us Track your research
Search
Cart
Book cover

European Symposium on Programming

ESOP 2007: Programming Languages and Systems pp 110–124Cite as

  1. Home
  2. Programming Languages and Systems
  3. Conference paper
Anti-pattern Matching

Anti-pattern Matching

  • Claude Kirchner1,
  • Radu Kopetz1 &
  • Pierre-Etienne Moreau1 
  • Conference paper
  • 1130 Accesses

  • 8 Citations

Part of the Lecture Notes in Computer Science book series (LNTCS,volume 4421)

Abstract

It is quite appealing to base the description of pattern-based searches on positive as well as negative conditions. We would like for example to specify that we search for white cars that are not station wagons.

To this end, we define the notion of anti-patterns and their semantics along with some of their properties. We then extend the classical notion of matching between patterns and ground terms to matching between anti-patterns and ground terms. We provide a rule-based algorithm that finds the solutions to such problems and prove its correctness and completeness. Anti-pattern matching is by nature different from disunification and quite interestingly the anti-pattern matching problem is unitary. Therefore the concept is appropriate to ground a powerful extension to pattern-based programming languages and we show how this is used to extend the expressiveness and usability of the Tom language.

Keywords

  • Normal Form
  • Pattern Match
  • Free Variable
  • Function Symbol
  • Equational Problem

These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

UMR 7503 CNRS-INPL-INRIA-Nancy2-UHP.

Chapter PDF

Download to read the full chapter text

References

  1. Aiken, A., Kozen, D., Wimmers, E.: Decidability of systems of set constraints with negative constraints. Information and Computation 122(1), 30–44 (1995)

    CrossRef  MATH  MathSciNet  Google Scholar 

  2. Aiken, A., Wimmers, E.L.: Solving systems of set constraints (extended abstract). In: LICS, pp. 329–340. IEEE Computer Society Press, Los Alamitos (1992)

    Google Scholar 

  3. Ait-Kaci, H., Podelski, A., Smolka, G.: A feature constraint system for logic programming with entailment. Theoretical Computer Science 122(1–2), 263–283 (1994)

    CrossRef  MATH  MathSciNet  Google Scholar 

  4. Baader, F., et al.: On the expressivity of feature logics with negation, functional uncertainty, and sort equations. Journal of Logic, Language and Information 2, 1–18 (1993)

    CrossRef  MATH  MathSciNet  Google Scholar 

  5. Baader, F., Nipkow, T.: Term Rewriting and all That. Cambridge University Press, Cambridge (1998)

    Google Scholar 

  6. Backofen, R., Smolka, G.: A complete and recursive feature theory. Theoretical Computer Science 146(1–2), 243–268 (1995)

    CrossRef  MATH  MathSciNet  Google Scholar 

  7. Charatonik, W., Pacholski, L.: Negative set constraints with equality. In: LICS, pp. 128–136. IEEE Computer Society Press, Los Alamitos (1994)

    Google Scholar 

  8. Clark, K.L.: Negation as Failure. In: Gallaire, H., Minker, J., Nicolas, J. (eds.) Logic and databases, pp. 293–322. Plenum Press, New York (1978)

    Google Scholar 

  9. Comon, H.: Unification et disunification. Théories et applications. Thèse de Doctorat d’Université, Institut Polytechnique de Grenoble (France) (1988)

    Google Scholar 

  10. Comon, H.: Disunification: a survey. In: Lassez, J.-L., Plotkin, G. (eds.) Computational Logic. Essays in honor of Alan Robinson, pp. 322–359. MIT Press, Cambridge (1991)

    Google Scholar 

  11. Comon, H., Lescanne, P.: Equational problems and disunification. In: Kirchner, C. (ed.) Unification, pp. 297–352. Academic Press, London (1990)

    Google Scholar 

  12. Foster, J.S.: CLP(SC): Implementation and efficiency considerations. In: Proceedings Workshop on Set Constraints, held in Conjunction with CP’96, Boston, Massachusetts (1996)

    Google Scholar 

  13. Huet, G.: Résolution d’equations dans les langages d’ordre 1, 2, ..., ω. Thèse de Doctorat d’Etat, Université de Paris 7 (France) (1976)

    Google Scholar 

  14. Kirchner, C., Kirchner, H.: Rewriting, solving, proving (1999), A preliminary version of a book available at http://www.loria.fr/~ckirchne/rsp.ps.gz

  15. Kirchner, C., Moreau, P.-E., Reilles, A.: Formal validation of pattern matching code. In: Barahona, P., Felty, A. (eds.) Proceedings of the 7th ACM SIGPLAN PPDP, July 2005, pp. 187–197. ACM Press, New York (2005)

    Google Scholar 

  16. Lassez, J.-L., Marriott, K.: Explicit representation of terms defined by counter examples. Journal of Automated Reasoning 3(3), 301–317 (1987)

    CrossRef  MATH  MathSciNet  Google Scholar 

  17. Liquori, L.: iRho: the software [system description]. In: DCM: International Workshop on Development in Computational Models. Electr. Notes Theor. Comput. Sci, vol. 135(3), pp. 85–94 (2006)

    Google Scholar 

  18. Momigliano, A.: Elimination of negation in a logical framework. In: Clote, P.G., Schwichtenberg, H. (eds.) CSL 2000. LNCS, vol. 1862, pp. 411–426. Springer, Heidelberg (2000)

    CrossRef  Google Scholar 

  19. Moreau, P.-E., Ringeissen, C., Vittek, M.: A Pattern Matching Compiler for Multiple Target Languages. In: Hedin, G. (ed.) CC 2003 and ETAPS 2003. LNCS, vol. 2622, pp. 61–76. Springer, Heidelberg (2003)

    Google Scholar 

  20. Müller, M., Niehren, J., Podelski, A.: Inclusion constraints over non-empty sets of trees. In: Bidoit, M., Dauchet, M. (eds.) CAAP 1997, FASE 1997, and TAPSOFT 1997. LNCS, vol. 1214, pp. 217–231. Springer, Heidelberg (1997)

    Google Scholar 

Download references

Author information

Authors and Affiliations

  1. INRIA & LORIA, Nancy, France

    Claude Kirchner, Radu Kopetz & Pierre-Etienne Moreau

Authors
  1. Claude Kirchner
    View author publications

    You can also search for this author in PubMed Google Scholar

  2. Radu Kopetz
    View author publications

    You can also search for this author in PubMed Google Scholar

  3. Pierre-Etienne Moreau
    View author publications

    You can also search for this author in PubMed Google Scholar

Editor information

Rocco De Nicola

Rights and permissions

Reprints and Permissions

Copyright information

© 2007 Springer Berlin Heidelberg

About this paper

Cite this paper

Kirchner, C., Kopetz, R., Moreau, PE. (2007). Anti-pattern Matching. In: De Nicola, R. (eds) Programming Languages and Systems. ESOP 2007. Lecture Notes in Computer Science, vol 4421. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-71316-6_9

Download citation

  • .RIS
  • .ENW
  • .BIB
  • DOI: https://doi.org/10.1007/978-3-540-71316-6_9

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-71314-2

  • Online ISBN: 978-3-540-71316-6

  • eBook Packages: Computer ScienceComputer Science (R0)

Share this paper

Anyone you share the following link with will be able to read this content:

Sorry, a shareable link is not currently available for this article.

Provided by the Springer Nature SharedIt content-sharing initiative

Publish with us

Policies and ethics

search

Navigation

  • Find a journal
  • Publish with us
  • Track your research

Discover content

  • Journals A-Z
  • Books A-Z

Publish with us

  • Publish your research
  • Open access publishing

Products and services

  • Our products
  • Librarians
  • Societies
  • Partners and advertisers

Our imprints

  • Springer
  • Nature Portfolio
  • BMC
  • Palgrave Macmillan
  • Apress
  • Your US state privacy rights
  • Accessibility statement
  • Terms and conditions
  • Privacy policy
  • Help and support
  • Cancel contracts here

167.114.118.210

Not affiliated

Springer Nature

© 2023 Springer Nature