Changed pi symbol to 'pi'

This commit is contained in:
Your Name 2017-12-14 22:48:19 +01:00
parent 46de83b4b1
commit 3f0c5047f1
5 changed files with 8 additions and 8 deletions

View File

@ -1,5 +1,5 @@
(defmodule Double
(def π 3.141592653589793)
(def pi 3.141592653589793)
(def e 2.718281828459045)
(register = (Fn [Double Double] Bool))
(register < (Fn [Double Double] Bool))

View File

@ -1,5 +1,5 @@
(defmodule Float
(def π 3.1415926536f)
(def pi 3.1415926536f)
(register neg (Fn [Float] Float))
(register + (Fn [Float Float] Float))
(register - (Fn [Float Float] Float))

View File

@ -1,7 +1,7 @@
(defmodule Geometry
(defn degree-to-radians [n]
(Double.* n (Double./ Double.π 180.0)))
(Double.* n (Double./ Double.pi 180.0)))
(defn radians-to-degree [n]
(Double.* n (Double./ 180.0 Double.π)))
(Double.* n (Double./ 180.0 Double.pi)))
)

View File

@ -25,7 +25,7 @@
;; (definterface min (λ [a a] a))
;;(definterface from-string (λ [a] String))
(definterface π a)
(definterface pi a)
;; These interfaces are defined internally:
;;(definterface copy (λ [&a] a))

View File

@ -58,7 +58,7 @@
---
# Defining things
```
(defn circle-area [r] (* π (* r r))
(defn circle-area [r] (* pi (* r r))
(defn id [x] x)
@ -69,7 +69,7 @@
# Type inference
```
(defn circle-area [r] (* π (* r r)) : (λ [Float] Float)
(defn circle-area [r] (* pi (* r r)) : (λ [Float] Float)
(defn id [x] x) : (λ [a] a)
@ -359,7 +359,7 @@ Double : Module = {
sin : (λ [Double] Double)
str : (λ [Double] String)
to-int : (λ [Double] Int)
π : Double
pi : Double
}
```