Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
Revised syntax question
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Brian Rogoff <bpr@b...>
Subject: Revised syntax question
    I have an issue with the Revised syntax (from OCaml P4, with URL 

How about 

    do e1; e2; e3; done e4

and change while/for to be consistent with this and return a value 
in done?  

    while e1 
      do e2; 
    done e3

    for i = e1 to e2 do e3; done ()

This saves a keyword "return" and looks a bit more consistent, though
maybe a touch noisier when you don't return a value from a loop. Anyone 
using Revised have a different opinion?

-- Brian