Mercurial > urweb
diff tests/badInline.ur @ 1804:62c18ecbfec4
Tweaking treatment of function application: substitute or introduce a 'let'?
author | Adam Chlipala <adam@chlipala.net> |
---|---|
date | Sun, 05 Aug 2012 14:55:28 -0400 (2012-08-05) |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/badInline.ur Sun Aug 05 14:55:28 2012 -0400 @@ -0,0 +1,12 @@ +style s1 +style s2 +style s3 + +fun ifClass r cls c = if r then classes cls c else c + +fun main (n : int) : transaction page = return <xml><body> + <p class={ifClass (n = 0) s1 + (ifClass (n = 1) s2 + (ifClass (n = 2) s3 + null))}>Hi</p> +</body></xml>