typing: add `ARangeExpr::init_callsite` and use it everywhere

One more callsite, and less method got manually

Signed-off-by: Jean Privat <jean@pryen.org>
Merge: Fix ffi null service

With nitg-g, the linker could fail when the same two piece of code will be in distinct files,
since the #ifndef trick does not cross compilation units.

This merge is just a workaroud where we use a global flag to avoid multiple definition.
While it works (thus is an improvement) it is ugly and broke the separate compilation concerns.

Pull-Request: #368
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
phase: use a better name on output

By defaut this uses the lowercased prefix of the classname.
But specific phases can redefine `to_s` if required.

Signed-off-by: Jean Privat <jean@pryen.org>
phase: add option --disable-phase

Can be used to desactivate specific phases when testing and debugging.
The option can also lists the sequence of phases and their dependencies.

Signed-off-by: Jean Privat <jean@pryen.org>
Merge: Callgraph

Quick patches so that RTA can give two new pieces of information.

1. what are the live CallSites? `RTA::live_callsites`
2. for each live CallSite, what are the live targets (MMethodDef) `RTA::live_targets`

Pull-Request: #369
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>
Merge branch 'strings'
Merge: Opt disable phase

`--disable-phase` to disable phase and broke tools :)

The point is to improve testing and comparison with and without specific (optional) phases

Pull-Request: #371
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Merge: Fix visibility importation

Pull-Request: #360
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
lib: added sha1 on String

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>
nitg: Use gcc special attributes and directives.

`noreturn` tags `show_backtrace` as no return
ie. `__attribute__ ((noreturn))`

`likely` tags runtime error checks with `unlikely`
ie. `__builtin_expect((x),0)`

These special C annotations can be disabled with --no-gcc-directive
The additional `--no-gcc-directive correct-likely` invert the
`__builtin_expect` target.

Signed-off-by: Jean Privat <jean@pryen.org>
Merge: lib: added sha1 on String

Added function to compute the SHA-1 of a String in both its Binary and to hex form.

Pull-Request: #366
Reviewed-by: Jean Privat <jean@pryen.org>
lib/sha1: fix nitunit

Signed-off-by: Jean Privat <jean@pryen.org>
tests: update error messages

Signed-off-by: Jean Privat <jean@pryen.org>
Merge: CallSite on AFor and ARange

Use CallSite to resolve and type some implicit services.
Subsequent phases will like them!

Currenlty: all the AFor and ARange services are converted and tools updated.
TODO: Array and SuperString

Pull-Request: #370
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>
mnit_android: Adding SensorEvent in input_event module

Signed-off-by: Romain Chanoir <chanoir.romain@courrier.uqam.ca>
mnit_android: Adding android_sensor module

Signed-off-by: Romain Chanoir <chanoir.romain@courrier.uqam.ca>
dino: move down hearts according to platform

Signed-off-by: Alexis Laferrière <alexis.laf@xymus.net>
dino: display text under the hearts

Signed-off-by: Alexis Laferrière <alexis.laf@xymus.net>
dino: cavemen do not get run over by dead dino

Signed-off-by: Alexis Laferrière <alexis.laf@xymus.net>
dino: each caveman has a predisposition for a hunting pattern

Signed-off-by: Alexis Laferrière <alexis.laf@xymus.net>