<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">
Hi Thorsten,</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">
<br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">
the example I saw uses copattern as you did. not sure how K would interfere with the termination process but it does look like a bug to me.<br>
</div>
<div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div id="Signature">
<div>
<div></div>
<div id="divtagdefaultwrapper" dir="ltr" style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Calibri, Arial, Helvetica, sans-serif;">
<font size="3"><b>Thanks,</b></font></div>
<div dir="ltr" style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Calibri, Arial, Helvetica, sans-serif;">
<font size="3"><b>Jason Hu</b></font></div>
<div dir="ltr" style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Calibri, Arial, Helvetica, sans-serif;">
<font size="3"><b><a href="https://hustmphrrr.github.io/">https://hustmphrrr.github.io/</a></b></font><br>
<font size="3"><b></b></font><font style="font-size:12pt" size="3"><span style="color: rgb(69, 129, 142);"><span style="font-family:trebuchet ms,sans-serif"><b><a target="_blank"></a></b></span></span></font></div>
</div>
</div>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Agda <agda-bounces@lists.chalmers.se> on behalf of William Harrison <william.lawrence.harrison@gmail.com><br>
<b>Sent:</b> August 15, 2020 10:30 AM<br>
<b>To:</b> Thorsten Altenkirch <Thorsten.Altenkirch@nottingham.ac.uk><br>
<b>Cc:</b> agda@lists.chalmers.se <agda@lists.chalmers.se><br>
<b>Subject:</b> Re: [Agda] Weird termination problem</font>
<div> </div>
</div>
<div dir="auto">Hi Thorsten,
<div><br>
</div>
<div>If you came up with a pithy example and then integrated in with the Agda docs (specifically <a href="https://agda.readthedocs.io/en/v2.6.1/language/without-k.html">https://agda.readthedocs.io/en/v2.6.1/language/without-k.html</a>), that’s be welcome. By
me, at least.
<div><br>
</div>
<div>Bill<br>
<br>
<div dir="ltr">Sent from my iPad</div>
<div dir="ltr"><br>
<blockquote type="cite">On Aug 15, 2020, at 10:21 AM, Thorsten Altenkirch <Thorsten.Altenkirch@nottingham.ac.uk> wrote:<br>
<br>
</blockquote>
</div>
<blockquote type="cite">
<div dir="ltr">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style>
<!--
@font-face
{font-family:"Cambria Math"}
@font-face
{font-family:Calibri}
@font-face
{font-family:Consolas}
p.x_MsoNormal, li.x_MsoNormal, div.x_MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif}
a:link, span.x_MsoHyperlink
{color:blue;
text-decoration:underline}
pre
{margin:0cm;
margin-bottom:.0001pt;
font-size:10.0pt;
font-family:"Courier New"}
span.x_HTMLPreformattedChar
{font-family:Consolas}
p.x_xmsonormal, li.x_xmsonormal, div.x_xmsonormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Calibri",sans-serif}
span.x_EmailStyle22
{font-family:"Calibri",sans-serif;
color:windowtext}
.x_MsoChpDefault
{font-size:10.0pt}
@page WordSection1
{margin:72.0pt 72.0pt 72.0pt 72.0pt}
div.x_WordSection1
{}
-->
</style>
<div class="x_WordSection1">
<p class="x_MsoNormal"><span style="">I found </span></p>
<p class="x_MsoNormal"><span style=""><a href="https://github.com/agda/agda/issues/2890">https://github.com/agda/agda/issues/2890</a></span></p>
<p class="x_MsoNormal"><span style="">but this mentions “with” which I wasn’t using. Also increasing termination depth didn’t help in my case.</span></p>
<p class="x_MsoNormal"><span style=""> </span></p>
<p class="x_MsoNormal"><span style="">I can try to cook up a short example but maybe this is a known issue?</span></p>
<p class="x_MsoNormal"><span style=""> </span></p>
<p class="x_MsoNormal"><span style="">Thorsten</span></p>
<p class="x_MsoNormal"><span style=""> </span></p>
<div style="border:none; border-top:solid #B5C4DF 1.0pt; padding:3.0pt 0cm 0cm 0cm">
<p class="x_MsoNormal"><b><span style="font-size:12.0pt; color:black">From: </span>
</b><span style="font-size:12.0pt; color:black">Agda <agda-bounces@lists.chalmers.se> on behalf of Thorsten Altenkirch <Thorsten.Altenkirch@nottingham.ac.uk><br>
<b>Date: </b>Saturday, 15 August 2020 at 15:16<br>
<b>To: </b>Jason -Zhong Sheng- Hu <fdhzs2010@hotmail.com>, "agda@lists.chalmers.se" <agda@lists.chalmers.se><br>
<b>Subject: </b>Re: [Agda] Weird termination problem</span></p>
</div>
<div>
<p class="x_MsoNormal"> </p>
</div>
<p class="x_MsoNormal"><span style="">Yes, indeed this worked. And the difference was that in the previous version I hadn’t used no-K.</span></p>
<p class="x_MsoNormal"><span style=""> </span></p>
<p class="x_MsoNormal"><span style="">Thanks a lot – I was truly stumped. And I do remember that there were some issues with termination checking when switching on no-K.</span></p>
<p class="x_MsoNormal"><span style=""> </span></p>
<p class="x_MsoNormal"><span style="">Cheers,</span></p>
<p class="x_MsoNormal"><span style="">Thorsten</span></p>
<p class="x_MsoNormal"><span style=""> </span></p>
<div style="border:none; border-top:solid #B5C4DF 1.0pt; padding:3.0pt 0cm 0cm 0cm">
<p class="x_MsoNormal"><b><span style="font-size:12.0pt; color:black">From: </span>
</b><span style="font-size:12.0pt; color:black">Jason -Zhong Sheng- Hu <fdhzs2010@hotmail.com><br>
<b>Date: </b>Saturday, 15 August 2020 at 15:10<br>
<b>To: </b>Thorsten Altenkirch <psztxa@exmail.nottingham.ac.uk>, "agda@lists.chalmers.se" <agda@lists.chalmers.se><br>
<b>Subject: </b>Re: Weird termination problem</span></p>
</div>
<div>
<p class="x_MsoNormal"> </p>
</div>
<div>
<p class="x_MsoNormal" style="background:white"><span style="font-size:12.0pt; color:black">I once saw someone else's code where termination checker also failed with no good reason. the author worked around it by turning on K. could you see if K works around
it for you?</span></p>
</div>
<div>
<div>
<p class="x_MsoNormal"><span style="font-size:12.0pt; color:black"> </span></p>
</div>
<div id="x_Signature">
<div>
<div id="x_divtagdefaultwrapper">
<p class="x_MsoNormal"><b><span style="font-size:12.0pt; color:black">Thanks,</span></b></p>
</div>
<div>
<p class="x_MsoNormal"><b><span style="font-size:12.0pt; color:black">Jason Hu</span></b></p>
</div>
<div>
<p class="x_MsoNormal"><b><span style="font-size:12.0pt; color:black"><a href="https://hustmphrrr.github.io/">https://hustmphrrr.github.io/</a></span></b></p>
</div>
</div>
</div>
</div>
<div class="x_MsoNormal" align="center" style="text-align:center">
<hr size="0" width="100%" align="center">
</div>
<div id="x_divRplyFwdMsg">
<p class="x_MsoNormal"><b><span style="color:black">From:</span></b><span style="color:black"> Agda <agda-bounces@lists.chalmers.se> on behalf of Thorsten Altenkirch <Thorsten.Altenkirch@nottingham.ac.uk><br>
<b>Sent:</b> August 15, 2020 9:25 AM<br>
<b>To:</b> agda@lists.chalmers.se <agda@lists.chalmers.se><br>
<b>Subject:</b> [Agda] Weird termination problem</span> </p>
<div>
<p class="x_MsoNormal"> </p>
</div>
</div>
<div>
<div>
<p class="x_xmsonormal"><span style="font-size:11.0pt">Hi,</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt"> </span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">I just transferred some code form my lecture notes to my book draft and now the termination checker complains where there was no problem before:</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt"> </span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">thm : {P : Form} → ([] </span>
<span style="font-size:11.0pt; font-family:"Cambria Math",serif">⊢</span><span style="font-size:11.0pt"> P)
</span><span style="font-size:11.0pt; font-family:"Cambria Math",serif">⇔</span><span style="font-size:11.0pt">
</span><span style="font-size:11.0pt; font-family:"Cambria Math",serif">⊢</span><span style="font-size:11.0pt">sk P</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">proj₁ thm d = skC→sk (</span><span style="font-size:11.0pt; font-family:"Cambria Math",serif">⊢</span><span style="font-size:11.0pt">→</span><span style="font-size:11.0pt; font-family:"Cambria Math",serif">⊢</span><span style="font-size:11.0pt">skC
d)</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">proj₂ thm SS = S-d</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">proj₂ thm KK = K-d</span></p>
<p class="x_xmsonormal"><span lang="DE" style="font-size:11.0pt">proj₂ thm (app d e) = app (proj₂ thm d) (proj₂ thm e)</span></p>
<p class="x_xmsonormal"><span lang="DE" style="font-size:11.0pt"> </span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">so here </span><span style="font-size:11.0pt; font-family:"Cambria Math",serif">⊢</span><span style="font-size:11.0pt">sk P is inductively defined and there should be no problem – and indeed there wasn’t
before. But now</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt"> </span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">Termination checking failed for the following functions:</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt"> thm</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">Problematic calls:</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt"> proj₂ thm e</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt"> </span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">I can’t make any sense out of it. Has anybody an inkling what could have happened or any advice what I could do to fix it.</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt"> </span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">I can prove the <= direction on its own with no problems. The definition of
</span><span style="font-size:11.0pt; font-family:"Cambria Math",serif">⇔ is exactly the same as before and it doesn’t help if I expand it. Also the definition of products is the same as before.
</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt"> </span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">If you want to have a look at the code please let me know – I will give you access to the repo.</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt"> </span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">Cheers,</span></p>
<p class="x_xmsonormal"><span style="font-size:11.0pt">Thorsten</span></p>
</div>
<pre> </pre>
<pre>This message and any attachment are intended solely for the addressee</pre>
<pre>and may contain confidential information. If you have received this</pre>
<pre>message in error, please contact the sender and delete the email and</pre>
<pre>attachment. </pre>
<pre> </pre>
<pre>Any views or opinions expressed by the author of this email do not</pre>
<pre>necessarily reflect the views of the University of Nottingham. Email</pre>
<pre>communications with the University of Nottingham may be monitored </pre>
<pre>where permitted by law.</pre>
<pre> </pre>
<pre> </pre>
<pre> </pre>
</div>
<pre> </pre>
<pre>This message and any attachment are intended solely for the addressee</pre>
<pre>and may contain confidential information. If you have received this</pre>
<pre>message in error, please contact the sender and delete the email and</pre>
<pre>attachment. </pre>
<pre> </pre>
<pre>Any views or opinions expressed by the author of this email do not</pre>
<pre>necessarily reflect the views of the University of Nottingham. Email</pre>
<pre>communications with the University of Nottingham may be monitored </pre>
<pre>where permitted by law.</pre>
<pre> </pre>
<pre> </pre>
<pre> </pre>
</div>
<pre>
This message and any attachment are intended solely for the addressee
and may contain confidential information. If you have received this
message in error, please contact the sender and delete the email and
attachment.
Any views or opinions expressed by the author of this email do not
necessarily reflect the views of the University of Nottingham. Email
communications with the University of Nottingham may be monitored
where permitted by law.
</pre>
<span>_______________________________________________</span><br>
<span>Agda mailing list</span><br>
<span>Agda@lists.chalmers.se</span><br>
<span>https://lists.chalmers.se/mailman/listinfo/agda</span><br>
</div>
</blockquote>
</div>
</div>
</div>
</body>
</html>