comparison src/mono_reduce.sml @ 1932:98895243b5b6

Change handling of returned text blobs, to activate the normal EWrite optimizations
author Adam Chlipala <adam@chlipala.net>
date Wed, 11 Dec 2013 18:22:10 -0500
parents 0480b8f29a47
children 16c219c74426
comparison
equal deleted inserted replaced
1931:1a04b1edded2 1932:98895243b5b6
99 | EField (e, _) => impure e 99 | EField (e, _) => impure e
100 100
101 | ECase (e, pes, _) => impure e orelse List.exists (fn (_, e) => impure e) pes 101 | ECase (e, pes, _) => impure e orelse List.exists (fn (_, e) => impure e) pes
102 102
103 | EError _ => true 103 | EError _ => true
104 | EReturnBlob {blob = e1, mimeType = e2, ...} => impure e1 orelse impure e2 104 | EReturnBlob {blob = NONE, mimeType = e2, ...} => impure e2
105 | EReturnBlob {blob = SOME e1, mimeType = e2, ...} => impure e1 orelse impure e2
105 | ERedirect (e, _) => impure e 106 | ERedirect (e, _) => impure e
106 107
107 | EStrcat (e1, e2) => impure e1 orelse impure e2 108 | EStrcat (e1, e2) => impure e1 orelse impure e2
108 109
109 | ESeq (e1, e2) => impure e1 orelse impure e2 110 | ESeq (e1, e2) => impure e1 orelse impure e2
490 @ post 491 @ post
491 end 492 end
492 | EStrcat (e1, e2) => summarize d e1 @ summarize d e2 493 | EStrcat (e1, e2) => summarize d e1 @ summarize d e2
493 494
494 | EError (e, _) => summarize d e @ [Abort] 495 | EError (e, _) => summarize d e @ [Abort]
495 | EReturnBlob {blob = e1, mimeType = e2, ...} => summarize d e1 @ summarize d e2 @ [Abort] 496 | EReturnBlob {blob = NONE, mimeType = e2, ...} => summarize d e2 @ [Abort]
497 | EReturnBlob {blob = SOME e1, mimeType = e2, ...} => summarize d e1 @ summarize d e2 @ [Abort]
496 | ERedirect (e, _) => summarize d e @ [Abort] 498 | ERedirect (e, _) => summarize d e @ [Abort]
497 499
498 | EWrite e => summarize d e @ [WritePage] 500 | EWrite e => summarize d e @ [WritePage]
499 501
500 | ESeq (e1, e2) => summarize d e1 @ summarize d e2 502 | ESeq (e1, e2) => summarize d e1 @ summarize d e2