<p>The apostrophe(s) in Haskell (and thus Plutus) are part of the name; they do not hold any specific meaning.</p>
<p>Haskell as a functional programming language borrows from mathematical notation. An apostrophe on a variable name conveys that it is somewhat related to another variable (without or with more apostrophes).</p>
<p>Imagine a simple function that adds three values. You could write these several ways.</p>
<pre><code>addThreeNumbers a b c = a + b + c
addThreeNumbers' a b c = b + c + a
addThreeNumbers'' a b c = b + a + c
addThreeNumbers''' a b c = c + a + b
</code></pre>
<p>and so on. The result will always be the same.</p>
<hr />
<p>The apostrophes in your example are, however, not of the same type as the prefix data types. This is an indicator that <a href="https://wiki.haskell.org/Template_Haskell" rel="nofollow noreferrer">template haskell</a> is being used.</p>

CC BY-SA 4.0
2021-06-08T03:13:18.880Z
but in my case, unstableMakeIsData is a function name and ''Date is not defined before. The apostrophe(s) is a prefix not suffix, I think It might be different.
mackie
CC BY-SA 4.0
2021-06-08T05:28:05.757Z
I found your example in this commit: https://github.com/input-output-hk/plutus/commit/01f14933a8fc35e02aaec4cedfeac6dc5396b382 -- take a look at the Instances.hs
Matthias Sieber
CC BY-SA 4.0
2021-06-08T05:31:52.103Z
I apologize for the confusion. The apostrophes in front of the type hint at template haskell
Matthias Sieber
CC BY-SA 4.0
2021-06-27T15:44:16.953Z
Thank you a lot!
Java wanna bee
CC BY-SA 4.0
2021-06-08T03:03:15.423Z
2021-06-08T05:31:05.973Z
2021-06-08T05:31:05.973Z
Matthias Sieber
<p>I have noticed the frequent appearance of two consecutive apostrophes in Haskell code.</p>
<p>Like this:</p>
<pre><code>newtype Date = Date Integer
data EndDate = Fixed Integer | Never
unstableMakeIsData ''Date
unstableMakeIsData ''EndDate
</code></pre>
<p>What does <code>''</code> mean in haskell?</p>

<plutus><smart-contract><haskell>
What does two consecutive apostrophes mean in Haskell and Plutus?
# What does two consecutive apostrophes mean in Haskell and Plutus?

(Asked by: username_0 on 2021-06-08)

I have noticed the frequent appearance of two consecutive apostrophes in Haskell code.

Like this:

```
newtype Date = Date Integer
data EndDate = Fixed Integer | Never
unstableMakeIsData ''Date
unstableMakeIsData ''EndDate

```

What does `''` mean in haskell?

**Tags:** plutus, smart-contract, haskell


---

## 1 answers

### Answer by username_1 on 2021-06-08. Score: 3

The apostrophe(s) in Haskell (and thus Plutus) are part of the name; they do not hold any specific meaning.

Haskell as a functional programming language borrows from mathematical notation. An apostrophe on a variable name conveys that it is somewhat related to another variable (without or with more apostrophes).

Imagine a simple function that adds three values. You could write these several ways.

```
addThreeNumbers a b c = a + b + c
addThreeNumbers' a b c = b + c + a
addThreeNumbers'' a b c = b + a + c
addThreeNumbers''' a b c = c + a + b

```

and so on. The result will always be the same.

---

The apostrophes in your example are, however, not of the same type as the prefix data types. This is an indicator that [template haskell](https://wiki.haskell.org/Template_Haskell) is being used.

> **Comments:**
> **username_0**: but in my case, unstableMakeIsData is a function name and ''Date is not defined before. The apostrophe(s) is a prefix not suffix, I think It might be different.  
> **username_1**: I found your example in this commit: https://github.com/input-output-hk/plutus/commit/01f14933a8fc35e02aaec4cedfeac6dc5396b382 -- take a look at the Instances.hs  
> **username_1**: I apologize for the confusion. The apostrophes in front of the type hint at template haskell  
> **username_2**: Thank you a lot!  

---

