Unisyn expressions.

Test

Once there were many different character sets that were unified by Unicode. Today we have many different programming languages, each with a slightly different syntax from all the others. The multiplicity of such syntaxes imposes unnecessary burdens on users and language designers. UniSyn is proposed as a common syntax that can be used by many different programming languages.

Advantages of having one uniform language syntax:

Special features

Dyadic operator priorities

UniSyn has only three levels of dyadic operator priority which makes it easier to learn. Conversely: Perl has 25 levels of operator priority. Can we really expect users to learn such a long list?

Even three levels of priority are enough to parse subroutine declarations, for loops and if statements with nested expressions:

     is
 sub          as
        array             then
                    ==                    else
                 v1    v2         plus                  then
                               v3      v4         ==                     else
                                               v5    v6         minus            times
                                                             v7       v8      v9           +
                                                                                       v10   v11

The priority of a dyadic operator is determined by the Unicode Mathematical Alphanumeric Symbols that is used to encode it.

The new operators provided by the Unicode standard allows us to offer users a wider range of operators and brackets with which to express their intentions clearly within the three levels of operator precedence provided.

Other languages

Lisp, Bash, Tcl are well known, successful languages that use generic syntaxes.

For documentation see: CPAN