QuickLaTeX.quick.tex 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. \documentclass{article}
  2. \usepackage{agda}
  3. \begin{document}
  4. \begin{code}%
  5. \>[0]\AgdaSymbol{\{-\#}\AgdaSpace{}%
  6. \AgdaKeyword{OPTIONS}\AgdaSpace{}%
  7. \AgdaPragma{--sized-types}\AgdaSpace{}%
  8. \AgdaSymbol{\#-\}}\<%
  9. \\
  10. %
  11. \\[\AgdaEmptyExtraSkip]%
  12. \>[0]\AgdaSymbol{\{-\#}\AgdaSpace{}%
  13. \AgdaKeyword{BUILTIN}\AgdaSpace{}%
  14. \AgdaKeyword{SIZE}\AgdaSpace{}%
  15. \AgdaPostulate{Size}\AgdaSpace{}%
  16. \AgdaSymbol{\#-\}}\<%
  17. \\
  18. %
  19. \\[\AgdaEmptyExtraSkip]%
  20. \>[0]\AgdaKeyword{record}\AgdaSpace{}%
  21. \AgdaRecord{Sigma}\AgdaSpace{}%
  22. \AgdaSymbol{(}\AgdaBound{A}\AgdaSpace{}%
  23. \AgdaSymbol{:}\AgdaSpace{}%
  24. \AgdaPrimitive{Set}\AgdaSymbol{)}\AgdaSpace{}%
  25. \AgdaSymbol{(}\AgdaBound{B}\AgdaSpace{}%
  26. \AgdaSymbol{:}\AgdaSpace{}%
  27. \AgdaBound{A}\AgdaSpace{}%
  28. \AgdaSymbol{→}\AgdaSpace{}%
  29. \AgdaPrimitive{Set}\AgdaSymbol{)}\AgdaSpace{}%
  30. \AgdaSymbol{:}\AgdaSpace{}%
  31. \AgdaPrimitive{Set}\AgdaSpace{}%
  32. \AgdaKeyword{where}\<%
  33. \\
  34. \>[0][@{}l@{\AgdaIndent{0}}]%
  35. \>[2]\AgdaKeyword{coinductive}\<%
  36. \\
  37. %
  38. \>[2]\AgdaKeyword{constructor}\AgdaSpace{}%
  39. \AgdaCoinductiveConstructor{c}\<%
  40. \\
  41. %
  42. \>[2]\AgdaKeyword{field}\<%
  43. \\
  44. \>[2][@{}l@{\AgdaIndent{0}}]%
  45. \>[4]\AgdaField{proj₁}\AgdaSpace{}%
  46. \AgdaSymbol{:}\AgdaSpace{}%
  47. \AgdaBound{A}\<%
  48. \\
  49. %
  50. \>[4]\AgdaField{proj₂}\AgdaSpace{}%
  51. \AgdaSymbol{:}\AgdaSpace{}%
  52. \AgdaBound{B}\AgdaSpace{}%
  53. \AgdaField{proj₁}\<%
  54. \\
  55. %
  56. \\[\AgdaEmptyExtraSkip]%
  57. \>[0]\AgdaKeyword{data}\AgdaSpace{}%
  58. \AgdaDatatype{D}\AgdaSpace{}%
  59. \AgdaSymbol{:}\AgdaSpace{}%
  60. \AgdaPrimitive{Set}\AgdaSpace{}%
  61. \AgdaKeyword{where}\<%
  62. \\
  63. \>[0][@{}l@{\AgdaIndent{0}}]%
  64. \>[2]\AgdaInductiveConstructor{c}\AgdaSpace{}%
  65. \AgdaSymbol{:}\AgdaSpace{}%
  66. \AgdaDatatype{D}\<%
  67. \\
  68. %
  69. \\[\AgdaEmptyExtraSkip]%
  70. \>[0]\AgdaFunction{f}\AgdaSpace{}%
  71. \AgdaSymbol{:}\AgdaSpace{}%
  72. \AgdaSymbol{\{}\AgdaBound{A}\AgdaSpace{}%
  73. \AgdaSymbol{:}\AgdaSpace{}%
  74. \AgdaPrimitive{Set}\AgdaSymbol{\}}\AgdaSpace{}%
  75. \AgdaSymbol{\{}\AgdaBound{B}\AgdaSpace{}%
  76. \AgdaSymbol{:}\AgdaSpace{}%
  77. \AgdaBound{A}\AgdaSpace{}%
  78. \AgdaSymbol{→}\AgdaSpace{}%
  79. \AgdaPrimitive{Set}\AgdaSymbol{\}}\AgdaSpace{}%
  80. \AgdaSymbol{(}\AgdaBound{x}\AgdaSpace{}%
  81. \AgdaSymbol{:}\AgdaSpace{}%
  82. \AgdaBound{A}\AgdaSymbol{)}\AgdaSpace{}%
  83. \AgdaSymbol{→}\AgdaSpace{}%
  84. \AgdaBound{B}\AgdaSpace{}%
  85. \AgdaBound{x}\AgdaSpace{}%
  86. \AgdaSymbol{→}\AgdaSpace{}%
  87. \AgdaRecord{Sigma}\AgdaSpace{}%
  88. \AgdaBound{A}\AgdaSpace{}%
  89. \AgdaBound{B}\<%
  90. \\
  91. \>[0]\AgdaFunction{f}\AgdaSpace{}%
  92. \AgdaSymbol{=}\AgdaSpace{}%
  93. \AgdaCoinductiveConstructor{c}\<%
  94. \end{code}
  95. \end{document}