Question about a proof in integration theory I have a doubt about a proof in integration theory. First let me introduce a
Definition (antiderivative)
Let $f:[a,b]\rightarrow \mathbb R$ be continuous. We call an antiderivative of $f$ every function $F\in C^0([a,b])\cap C^1((a,b))$ such that $F'(x)=f(x)$. 
Theorem
Let $f:[a,b]\rightarrow \mathbb R$ be continuous and let $F_1$ and $F_2$ be two antiderivatives. Then $\exists \ c\in \mathbb R :F_2(x)=F_1(x)+c \ \forall x \in [a,b]$.
Proof
Let $G(x):=F_2(x)-F_1(x)$. Since $F_1$ and $F_2$ are both antiderivatives $G\in C^0([a,b])\cap C^1((a,b))$
$G'(x)=F'_2(x)-F'_1(x)=f(x)-f(x)=0\ \forall x \in \mathbb R$
So the derivative of $G$ equals to zero.
Here comes the doubt, after this it says: is not the fact that the derivative is zero that implies $G$ is a constant, but using Lagrange mean value theorem:
In every $[a,x_0] \subset [a,b]$ for Lagrange mean value theorem we have
$G(x_0)-G(a)=(x_0-a)G'(x_0)=0,\ c\in(a,x_0) \Rightarrow G(x_0)=G(a)\ \forall x\in(a,x_0) \Rightarrow$
$\Rightarrow G(x_0)=G(a)\ \forall x\in [a,b] \Rightarrow G(x_0)=c \Rightarrow F_2(x)=F_1(x)+c \ \forall x\in[a,b]$.
Why I'm not allowed to say that if the derivative is zero the function is a constant?
Is that because if a function is constant then the derivative is zero, and not vice versa?

"Why I'm not allowed to say that if the derivative is zero the function is a constant?
Is that because if a function is constant then the derivative is zero, and not vice versa?"
Because this may be false if your domain is not an interval.  Consider the function
$$
f(x) = \begin{cases} 1, & x < 0 \\ 2, & x > 0. \end{cases}
$$
This function has $f'(x)=0$ where it is differentiable, but it is not a constant.  
Notice that in your argument you are on an interval, so the assumption that the derivative exists everywhere and is zero is enough to conclude that $f$ is constant.  
