Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/pure-cfg/src/compiler/c-target/print-as-c.sml
ViewVC logotype

Diff of /branches/pure-cfg/src/compiler/c-target/print-as-c.sml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 616, Sun Mar 13 14:52:11 2011 UTC revision 617, Sun Mar 13 16:51:09 2011 UTC
# Line 170  Line 170 
170                        str "else"; ppStms blk2)                        str "else"; ppStms blk2)
171                    | CL.S_While(e, blk) => (                    | CL.S_While(e, blk) => (
172                        inHBox (fn () => (str "while"; sp(); ppExp e)); ppStms blk)                        inHBox (fn () => (str "while"; sp(); ppExp e)); ppStms blk)
173                      | CL.S_For(inits, cond, incrs, blk) => let
174                          fun ppInit (ty, x, e) = inHBox (fn () => (
175                                ppTy(ty, SOME x);
176                                sp(); str "="; sp();
177                                ppExp e))
178                          in
179                            inHBox (fn () => (
180                              str "for"; sp(); str "(";
181                              ppList {pp = ppInit, sep = fn () => str ",", l = inits};
182                              str ";"; sp();
183                              ppExp cond; str ";"; sp();
184                              ppList {pp = ppExp, sep = fn () => str ",", l = incrs}));
185                            ppStms blk
186                          end
187                    | CL.S_Call(f, args) => (                    | CL.S_Call(f, args) => (
188                        inHBox (fn () => (str f; ppArgs args; str ";"));                        inHBox (fn () => (str f; ppArgs args; str ";"));
189                        PP.newline strm)                        PP.newline strm)

Legend:
Removed from v.616  
changed lines
  Added in v.617

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0