{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,10,1]],"date-time":"2026-10-01T07:38:10Z","timestamp":1790840290751,"version":"4.1.0"},"reference-count":51,"publisher":"Association for Computing Machinery (ACM)","issue":"POPL","license":[{"start":{"date-parts":[[2021,1,4]],"date-time":"2021-01-04T00:00:00Z","timestamp":1609718400000},"content-version":"vor","delay-in-days":0,"URL":"https:\/\/creativecommons.org\/licenses\/by\/4.0\/"}],"content-domain":{"domain":["dl.acm.org"],"crossmark-restriction":true},"short-container-title":["Proc. ACM Program. Lang."],"published-print":{"date-parts":[[2021,1,4]]},"abstract":"<jats:p>Dependently typed programming languages and proof assistants such as Agda and Coq rely on computation to automatically simplify expressions during type checking. To overcome the lack of certain programming primitives or logical principles in those systems, it is common to appeal to axioms to postulate their existence. However, one can only postulate the bare existence of an axiom, not its computational behaviour. Instead, users are forced to postulate equality proofs and appeal to them explicitly to simplify expressions, making axioms dramatically more complicated to work with than built-in primitives. On the other hand, the equality reflection rule from extensional type theory solves these problems by collapsing computation and equality, at the cost of having no practical type checking algorithm. This paper introduces Rewriting Type Theory (RTT), a type theory where it is possible to add computational assumptions in the form of rewrite rules. Rewrite rules go beyond the computational capabilities of intensional type theory, but in contrast to extensional type theory, they are applied automatically so type checking does not require input from the user. To ensure type soundness of RTT\u2014as well as effective type checking\u2014we provide a framework where confluence of user-defined rewrite rules can be checked modularly and automatically, and where adding new rewrite rules is guaranteed to preserve subject reduction. The properties of RTT have been formally verified using the MetaCoq framework and an implementation of rewrite rules is already available in the Agda proof assistant.<\/jats:p>","DOI":"10.1145\/3434341","type":"journal-article","created":{"date-parts":[[2021,1,4]],"date-time":"2021-01-04T12:34:24Z","timestamp":1609763664000},"page":"1-29","update-policy":"https:\/\/doi.org\/10.1145\/crossmark-policy","source":"Crossref","is-referenced-by-count":17,"title":["The taming of the rew: a type theory with computational assumptions"],"prefix":"10.1145","volume":"5","author":[{"given":"Jesper","family":"Cockx","sequence":"first","affiliation":[{"name":"Delft University of Technology, Netherlands"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"given":"Nicolas","family":"Tabareau","sequence":"additional","affiliation":[{"name":"Inria, France"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"given":"Th\u00e9o","family":"Winterhalter","sequence":"additional","affiliation":[{"name":"Inria, France \/ LS2N, France"}],"role":[{"vocabulary":"crossref","role":"author"}]}],"member":"320","published-online":{"date-parts":[[2021,1,4]]},"reference":[{"key":"e_1_2_1_1_1","doi-asserted-by":"publisher","DOI":"10.1145\/3158111"},{"key":"e_1_2_1_2_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-642-21691-6_5"},{"key":"e_1_2_1_3_1","unstructured":"Agda Development Team. 2020. Agda 2.6.1 documentation. http:\/\/agda.readthedocs. io\/en\/v2.6.1\/"},{"key":"e_1_2_1_4_1","doi-asserted-by":"publisher","DOI":"10.1145\/2502409.2502411"},{"key":"e_1_2_1_5_1","doi-asserted-by":"publisher","DOI":"10.4230\/LIPIcs.RTA"},{"key":"e_1_2_1_6_1","doi-asserted-by":"publisher","DOI":"10.4204\/EPTCS.186.8"},{"key":"e_1_2_1_7_1","doi-asserted-by":"publisher","DOI":"10.1017\/S095679689700289X"},{"key":"e_1_2_1_8_1","doi-asserted-by":"publisher","DOI":"10.1016\/B978-0-444-87508-2"},{"key":"e_1_2_1_9_1","doi-asserted-by":"publisher","DOI":"10.1109\/LICS"},{"key":"e_1_2_1_10_1","doi-asserted-by":"publisher","DOI":"10.4230\/LIPIcs.TYPES"},{"key":"e_1_2_1_11_1","first-page":"24","volume-title":"15th International Conference, RTA 2004, Aachen, Germany, June 3-5, 2004, Proceedings (Lecture Notes in Computer Science), Vincent van Oostrom (Ed.)","volume":"3091","author":"Blanqui Fr\u00e9d\u00e9ric","year":"2004","unstructured":"Fr\u00e9d\u00e9ric Blanqui. 2004. A Type-Based Termination Criterion for Dependently-Typed Higher-Order Rewrite Systems. In Rewriting Techniques and Applications, 15th International Conference, RTA 2004, Aachen, Germany, June 3-5, 2004, Proceedings (Lecture Notes in Computer Science), Vincent van Oostrom (Ed.), Vol. 3091. Springer, 24-39. http:\/\/springerlink. metapress.com\/openurl.asp?genre=article&amp;issn= 0302-9743 &amp;volume= 3091 &amp;spage= 24"},{"key":"e_1_2_1_12_1","doi-asserted-by":"publisher","unstructured":"Fr\u00e9d\u00e9ric Blanqui. 2005. Definitions by rewriting in the Calculus of Constructions. Mathematical Structures in Computer Science 15 1 ( 2005 ) 37-92. https:\/\/doi.org\/10.1017\/S0960129504004426 10.1017\/S0960129504004426","DOI":"10.1017\/S0960129504004426"},{"key":"e_1_2_1_13_1","doi-asserted-by":"publisher","DOI":"10.1017\/S0956796818000072"},{"key":"e_1_2_1_14_1","doi-asserted-by":"publisher","DOI":"10.4230\/LIPIcs.FSCD"},{"key":"e_1_2_1_15_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-540-87531-4_1"},{"key":"e_1_2_1_16_1","first-page":"28","volume-title":"the Second International Workshop on Proof Exchange for Theorem Proving (PxTP 2012 ), Tjark Weber David Pichardie (Ed.)","volume":"878","author":"Boespflug Mathieu","year":"2012","unstructured":"Mathieu Boespflug, Quentin Carbonneaux, and Olivier Hermant. 2012. The \u03bb\u03a0-calculus Modulo as a Universal Proof Language. In the Second International Workshop on Proof Exchange for Theorem Proving (PxTP 2012 ), Tjark Weber David Pichardie (Ed.), Vol. Vol. 878. Manchester, United Kingdom, pp. 28-43. https:\/\/hal-mines-paristech.archivesouvertes.fr\/hal-00917845"},{"key":"e_1_2_1_17_1","doi-asserted-by":"publisher","unstructured":"Jacek Chrzaszcz and Daria Walukiewicz-Chrzaszcz. 2007. Towards Rewriting in Coq. In Rewriting Computation and Proof Essays Dedicated to Jean-Pierre Jouannaud on the Occasion of His 60th Birthday (Lecture Notes in Computer Science) Hubert Comon-Lundh Claude Kirchner and H\u00e9l\u00e8ne Kirchner (Eds.) Vol. 4600. Springer 113-131. https:\/\/doi.org\/10.1007\/978-3-540-73147-4_6 10.1007\/978-3-540-73147-4_6","DOI":"10.1007\/978-3-540-73147-4_6"},{"key":"e_1_2_1_18_1","unstructured":"Jesper Cockx. 2020. Type theory unchained: Extending Agda with user-defined rewrite rules (system description). ( 2020 ). To appear in the post-proceedings of the TYPES conference."},{"key":"e_1_2_1_19_1","unstructured":"The Coq Development Team. 2016. The Coq proof assistant reference manual. http:\/\/coq.inria. fr Version 8.6."},{"key":"e_1_2_1_20_1","doi-asserted-by":"publisher","DOI":"10.5555\/646125.758641"},{"key":"e_1_2_1_21_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-540-73228-0_9"},{"key":"e_1_2_1_22_1","doi-asserted-by":"publisher","DOI":"10.4230\/LIPIcs"},{"key":"e_1_2_1_23_1","unstructured":"Gaspard Ferey and Jean-Pierre Jouannaud. 2019. Confluence in (Un)Typed Higher-Order Theories by means of Critical Pairs. (Dec. 2019 ). https:\/\/hal.archives-ouvertes.fr\/hal-02096540 (under submission)."},{"key":"e_1_2_1_24_1","volume-title":"HOR 2019-10th International Workshop on Higher-Order Rewriting (Joint Proceedings of HOR 2019 and IWC 2019 ), Mauricio Ayala-Rinc\u00f3n, Silvia Ghilezan, and Jakob Grue Simonsen (Eds.).","author":"Genestier Guillaume","unstructured":"Guillaume Genestier. 2019. SizeChangeTool: A Termination Checker for Rewriting Dependent Types. In HOR 2019-10th International Workshop on Higher-Order Rewriting (Joint Proceedings of HOR 2019 and IWC 2019 ), Mauricio Ayala-Rinc\u00f3n, Silvia Ghilezan, and Jakob Grue Simonsen (Eds.). Dortmund, Germany, 14-19. https:\/\/hal.archives-ouvertes. fr\/hal02442465"},{"key":"e_1_2_1_25_1","doi-asserted-by":"publisher","DOI":"10.1145\/329031610.1145\/3290316"},{"key":"e_1_2_1_26_1","unstructured":"Martin Hofmann. 1993. Non Strictly Positive Datatypes in System F. Email on types mailing list. http:\/\/www.seas.upenn.edu\/ sweirich\/types\/archive\/1993\/msg00027.html."},{"key":"e_1_2_1_27_1","doi-asserted-by":"publisher","DOI":"10.4230\/LIPIcs.TLCA"},{"key":"e_1_2_1_28_1","doi-asserted-by":"publisher","DOI":"10.1109\/LICS"},{"key":"e_1_2_1_29_1","doi-asserted-by":"publisher","DOI":"10.1109\/LICS"},{"key":"e_1_2_1_30_1","volume-title":"LPAR-21: 21st International Conference on Logic for Programming, Artificial Intelligence and Reasoning. EasyChair, Maun, Botswana, 474-489","author":"Jouannaud Jean-Pierre","year":"2017","unstructured":"Jean-Pierre Jouannaud and Pierre-Yves Strub. 2017. Coq without Type Casts: A Complete Proof of Coq Modulo Theory. In LPAR-21: 21st International Conference on Logic for Programming, Artificial Intelligence and Reasoning. EasyChair, Maun, Botswana, 474-489. https:\/\/hal.inria.fr\/hal-01664457"},{"key":"e_1_2_1_31_1","doi-asserted-by":"publisher","DOI":"10.1145\/360204.360210"},{"key":"e_1_2_1_32_1","doi-asserted-by":"publisher","DOI":"10.1016\/S0049-237X(08)71945-1"},{"key":"e_1_2_1_33_1","volume-title":"All about Proofs, Proofs for All, Bruno Woltzenlogel Paleo and David Delahaye (Eds.). Studies in Logic (Mathematical logic and foundations)","author":"Paulin-Mohring Christine","unstructured":"Christine Paulin-Mohring. 2015. Introduction to the Calculus of Inductive Constructions. In All about Proofs, Proofs for All, Bruno Woltzenlogel Paleo and David Delahaye (Eds.). Studies in Logic (Mathematical logic and foundations), Vol. 55. College Publications. https:\/\/hal.inria.fr\/hal-01094195"},{"key":"e_1_2_1_34_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-319-89884-1_9"},{"key":"e_1_2_1_35_1","doi-asserted-by":"publisher","DOI":"10.1145\/3341712"},{"key":"e_1_2_1_36_1","unstructured":"Ronan Saillard. 2015. Typechecking in the lambda-Pi-Calculus Modulo: Theory and Practice. Ph.D. Dissertation. MINES ParisTech."},{"key":"e_1_2_1_37_1","unstructured":"Gert Smolka. 2015. Confluence and Normalization in Reduction Systems. ( 2015 ). https:\/\/www.ps.uni-saarland.de\/courses\/ sem-ws15\/ars. pdf (lecture notes)."},{"key":"e_1_2_1_38_1","doi-asserted-by":"publisher","DOI":"10.1007\/s10817-019-09540-0"},{"key":"e_1_2_1_39_1","doi-asserted-by":"publisher","DOI":"10.1145\/3371076"},{"key":"e_1_2_1_40_1","first-page":"1","article-title":"The Open Calculus of Constructions (Part I): An Equational Type Theory with Dependent Types for Programming, Specification, and Interactive Theorem Proving","volume":"68","author":"Stehr Mark-Oliver","year":"2005","unstructured":"Mark-Oliver Stehr. 2005a. The Open Calculus of Constructions (Part I): An Equational Type Theory with Dependent Types for Programming, Specification, and Interactive Theorem Proving. Fundamenta Informaticae 68, 1-2 ( 2005 ), 131-174.","journal-title":"Fundamenta Informaticae"},{"key":"e_1_2_1_41_1","doi-asserted-by":"crossref","unstructured":"Mark-Oliver Stehr. 2005b. The Open Calculus of Constructions (Part II): An Equational Type Theory with Dependent Types for Programming Specification and Interactive Theorem Proving. Fundamenta Informaticae 68 3 ( 2005 ) 249-288.","DOI":"10.3233\/FUN-2005-68304"},{"key":"e_1_2_1_42_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-642-15205-4_40"},{"key":"e_1_2_1_43_1","doi-asserted-by":"publisher","DOI":"10.1006\/inco"},{"key":"e_1_2_1_44_1","doi-asserted-by":"publisher","DOI":"10.1109\/LICS"},{"key":"e_1_2_1_45_1","volume-title":"Term Rewriting Systems","unstructured":"Terese. 2003. Term Rewriting Systems. Cambridge Tracts in Theoretical Computer Science, Vol. 55. Cambridge University Press."},{"key":"e_1_2_1_46_1","volume-title":"Homotopy Type Theory: Univalent Foundations of Mathematics","author":"Foundations Program The Univalent","unstructured":"The Univalent Foundations Program. 2013. Homotopy Type Theory: Univalent Foundations of Mathematics. Institute for Advanced Study."},{"key":"e_1_2_1_47_1","doi-asserted-by":"publisher","unstructured":"Vincent van Oostrom. 1994a. Confluence by Decreasing Diagrams. Theoretical Computer Science 126 2 ( 1994 ) 259-280. https:\/\/doi.org\/10.1016\/ 0304-3975 ( 92 ) 00023-K 10.1016\/0304-3975(92)00023-K","DOI":"10.1016\/0304-3975(92)00023-K"},{"key":"e_1_2_1_48_1","unstructured":"Vincent van Oostrom. 1994b. Confluence for abstract and higher-order rewriting. Ph.D. Dissertation. Vrije Universiteit Amsterdam."},{"key":"e_1_2_1_49_1","doi-asserted-by":"publisher","DOI":"10.1007\/3-540-61254-8_26"},{"key":"e_1_2_1_50_1","doi-asserted-by":"publisher","DOI":"10.1017\/S0956796802004641"},{"key":"e_1_2_1_51_1","doi-asserted-by":"publisher","DOI":"10.1007\/11814771_50"}],"container-title":["Proceedings of the ACM on Programming Languages"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3434341","content-type":"unspecified","content-version":"vor","intended-application":"text-mining"},{"URL":"https:\/\/dl.acm.org\/doi\/pdf\/10.1145\/3434341","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2026,6,19]],"date-time":"2026-06-19T07:29:45Z","timestamp":1781854185000},"score":1,"resource":{"primary":{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3434341"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2021,1,4]]},"references-count":51,"journal-issue":{"issue":"POPL","published-print":{"date-parts":[[2021,1,4]]}},"alternative-id":["10.1145\/3434341"],"URL":"https:\/\/doi.org\/10.1145\/3434341","relation":{},"ISSN":["2475-1421"],"issn-type":[{"value":"2475-1421","type":"electronic"}],"subject":[],"published":{"date-parts":[[2021,1,4]]},"assertion":[{"value":"2021-01-04","order":3,"name":"published","label":"Published","group":{"name":"publication_history","label":"Publication History"}}]}}