Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Even then, this seems like a lot of work to overcome a non-problem, akin to developing a C++11 compiler which uses "begin" and "end" instead of braces because of some emotional attachment to Pascal.

The thing is, it's actually trivial to do that using the C++ preprocessor.

In fact, Steve Bourne wrote the Bourne shell exactly in this fashion, with the following C substitution macros (based on Algol-68):

    #define STRING char *
    #define IF if(
    #define THEN ){
    #define ELSE } else {
    #define FI ;}
    #define WHILE while (
    #define DO ({
    #define OD ;}
    #define INT int
    #define BEGIN {
    #define END }
Source: Expert C Programming: Deep C Secrets, p. 13. Peter Van der Linden. 1994.

(this isn't to deny that Python with Braces is a rather frivolous idea)



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: