Symbol value is now a long

We only handle types that are integer is a way. So there is no need for
a char *.

Signed-off-by: Celelibi <celelibi@gmail.com>
Generate symbols for primary expressions

First step towards generating code.

Signed-off-by: Celelibi <celelibi@gmail.com>
Merge remote-tracking branch 'cigale-gh/master'

Signed-off-by: Celelibi <celelibi@gmail.com>

Conflicts:
	quad.h
Remove useless spaces on empty lines

Because coding style matters.

Signed-off-by: Celelibi <celelibi@gmail.com>
No need for %left or %right

Operator associativity and priority is now explicit in the grammar.

Signed-off-by: Celelibi <celelibi@gmail.com>
Merge remote-tracking branch 'cigale-gh/master'

Signed-off-by: Celelibi <celelibi@gmail.com>

Conflicts:
	quad.h
Move quand type to quad.h

Because that's where ot belong instead of constants.h.

Signed-off-by: Celelibi <celelibi@gmail.com>
Quad operator is an enum, not a char *

char *operator is useless and unused. The quad_put function now takes an
enum quad_type instead of the char *.

Signed-off-by: Celelibi <celelibi@gmail.com>
Split the scalar types

Now the scalar types can be differenciated in the grammar.

Signed-off-by: Celelibi <celelibi@gmail.com>
Compute the result type of an operation

The new functions will be used to check whether the operations are legal
in terms of type and to compute the type of the result.

Signed-off-by: Celelibi <celelibi@gmail.com>
Expressions now generate quads

Assigment too! But not conditions yet.

Signed-off-by: Celelibi <celelibi@gmail.com>
Fix quad_concat when an argument is NULL

Do not try to dereference a NULL pointer while still providing a
meaningful result.

Signed-off-by: Celelibi <celelibi@gmail.com>
Little refactoring of quad.c

Breaking long lines and prefer early function exit than a big part of
code under an if.

Signed-off-by: Celelibi <celelibi@gmail.com>
Add \n at the end of MIPS instructions

Because they're needed.

Signed-off-by: Celelibi <celelibi@gmail.com>
Generate quads all the way up

And produce some MIPS code, even if it's wrong and incomplete.

Signed-off-by: Celelibi <celelibi@gmail.com>
Some things to do

Signed-off-by: Celelibi <celelibi@gmail.com>
Merge remote-tracking branch 'cigale-gh/master'

Signed-off-by: Celelibi <celelibi@gmail.com>

Conflicts:
	latex.y
	quad.c
	quad.h
	tds.c
	tds.h