From 5c3b42aff1a79d0d21beea8ed653bd9ca32c652b Mon Sep 17 00:00:00 2001 From: Hans Svensson Date: Thu, 25 Jan 2024 09:57:08 +0100 Subject: [PATCH] Fix Typo and whitespace in sophia_features.md (#500) --- docs/sophia_features.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/sophia_features.md b/docs/sophia_features.md index 3025f82..a696441 100644 --- a/docs/sophia_features.md +++ b/docs/sophia_features.md @@ -84,7 +84,7 @@ the return value of the call. ```sophia contract interface VotingType = - entrypoint : vote : string => unit + entrypoint vote : string => unit contract Voter = entrypoint tryVote(v : VotingType, alt : string) = @@ -204,7 +204,7 @@ When a `contract` or a `contract interface` implements another `contract interfa #### Subtyping and variance -Subtyping in Sophia follows common rules that take type variance into account. As described by [Wikipedia](https://en.wikipedia.org/wiki/Covariance_and_contravariance_(computer_science)), +Subtyping in Sophia follows common rules that take type variance into account. As described by [Wikipedia](https://en.wikipedia.org/wiki/Covariance_and_contravariance_(computer_science)), >Variance refers to how subtyping between more complex types relates to subtyping between their components. @@ -224,11 +224,11 @@ A good example of where it matters can be pictured by subtyping of function type ```sophia contract interface Animal = entrypoint age : () => int - + contract Dog : Animal = entrypoint age() = // ... entrypoint woof() = "woof" - + contract Cat : Animal = entrypoint age() = // ... entrypoint meow() = "meow" @@ -628,7 +628,7 @@ arithmetic operations: - remainder (`x mod y`), satisfying `y * (x / y) + x mod y == x` for non-zero `y` - exponentiation (`x ^ y`) -All operations are *safe* with respect to overflow and underflow. +All operations are *safe* with respect to overflow and underflow. The division and modulo operations throw an arithmetic error if the right-hand operand is zero.