aboutsummaryrefslogtreecommitdiffstats
path: root/docs/layout-of-source-files.rst
diff options
context:
space:
mode:
authorAlex Beregszaszi <alex@rtfs.hu>2017-07-17 17:24:18 +0800
committerAlex Beregszaszi <alex@rtfs.hu>2017-07-19 07:05:05 +0800
commitcffe52d6d9e23e537c710107292a2058caa3784f (patch)
tree3f5d5927f22295c0366edfcdc4f197be1d1ce033 /docs/layout-of-source-files.rst
parent01fbc636239f78134b37f9dedeacf40455ee2e0c (diff)
downloaddexon-solidity-cffe52d6d9e23e537c710107292a2058caa3784f.tar.gz
dexon-solidity-cffe52d6d9e23e537c710107292a2058caa3784f.tar.zst
dexon-solidity-cffe52d6d9e23e537c710107292a2058caa3784f.zip
Enable more examples in the documentation for testing
Diffstat (limited to 'docs/layout-of-source-files.rst')
-rw-r--r--docs/layout-of-source-files.rst27
1 files changed, 13 insertions, 14 deletions
diff --git a/docs/layout-of-source-files.rst b/docs/layout-of-source-files.rst
index e4b403f6..f9d197b7 100644
--- a/docs/layout-of-source-files.rst
+++ b/docs/layout-of-source-files.rst
@@ -197,17 +197,16 @@ for the two input parameters and two returned values.
pragma solidity ^0.4.0;
- /** @title Shape calculator.*/
- contract shapeCalculator{
- /**@dev Calculates a rectangle's surface and perimeter.
- * @param w Width of the rectangle.
- * @param h Height of the rectangle.
- * @return s The calculated surface.
- * @return p The calculated perimeter.
- */
- function rectangle(uint w, uint h) returns (uint s, uint p) {
- s = w * h;
- p = 2 * (w + h);
- }
- }
-
+ /** @title Shape calculator. */
+ contract shapeCalculator {
+ /** @dev Calculates a rectangle's surface and perimeter.
+ * @param w Width of the rectangle.
+ * @param h Height of the rectangle.
+ * @return s The calculated surface.
+ * @return p The calculated perimeter.
+ */
+ function rectangle(uint w, uint h) returns (uint s, uint p) {
+ s = w * h;
+ p = 2 * (w + h);
+ }
+ }