docs: cleaning references to C; smoothing parameter syntax description

This commit is contained in:
Yoichi Hirai 2016-11-24 18:32:45 +01:00
parent 0599a14954
commit fed50403ff
No known key found for this signature in database
GPG Key ID: E7B75D080FCF7992

View File

@ -7,15 +7,15 @@ Expressions and Control Structures
Input Parameters and Output Parameters Input Parameters and Output Parameters
====================================== ======================================
Like in Javascript and in C, functions may take parameters as input; As in Javascript, functions may take parameters as input;
unlike in Javascript and C, they may also return arbitrary number of unlike in Javascript and C, they may also return arbitrary number of
parameters as output. parameters as output.
Input Parameters Input Parameters
---------------- ----------------
The input parameters are declared type followed The input parameters are declared the same way as variables are. As an
by name (though unused input parameters do not need names). exception, unused parameters can omit the variable name.
For example, suppose we want our contract to For example, suppose we want our contract to
accept one kind of external calls with two integers, we would write accept one kind of external calls with two integers, we would write
something like:: something like::
@ -57,7 +57,7 @@ of assignment.
Control Structures Control Structures
=================== ===================
Most of the control structures from C or JavaScript are available in Solidity Most of the control structures from JavaScript are available in Solidity
except for ``switch`` and ``goto``. So except for ``switch`` and ``goto``. So
there is: ``if``, ``else``, ``while``, ``do``, ``for``, ``break``, ``continue``, ``return``, ``? :``, with there is: ``if``, ``else``, ``while``, ``do``, ``for``, ``break``, ``continue``, ``return``, ``? :``, with
the usual semantics known from C or JavaScript. the usual semantics known from C or JavaScript.