nit.git
8 years agosrc/compiler: Added fixint variants to compiler
Lucas Bajolet [Fri, 7 Aug 2015 19:49:15 +0000 (15:49 -0400)]
src/compiler: Added fixint variants to compiler

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agolib/standard/text: Updated to_num to support fix ints
Lucas Bajolet [Fri, 7 Aug 2015 17:43:10 +0000 (13:43 -0400)]
lib/standard/text: Updated to_num to support fix ints

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agoMerge: tests: specific mass-definition of tests marked todo
Jean Privat [Mon, 10 Aug 2015 16:13:02 +0000 (12:13 -0400)]
Merge: tests: specific mass-definition of tests marked todo

The magic string "NOT YET IMPLEMENTED" that is used to mark tests as *todo* are now extendable as new magic strings can be added to the `todo` file (one per line)
Moreover, specific engines and platforms can define additional magic strings in the `todo` files in their `sav` subdirectories.
E.g. `sav/Darwin/todo` for magic strings that will be used only for tests run on max os x.

Pull-Request: #1626
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>

8 years agoMerge: separate_compiler: remove the use of weak symbols.
Jean Privat [Mon, 10 Aug 2015 16:13:00 +0000 (12:13 -0400)]
Merge: separate_compiler: remove the use of weak symbols.

thus always compile stub of methods to avoid unresolved symbols

weak symbols seem to cause issues on some platforms *cough mac os x cough*

Pull-Request: #1625
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>

8 years agoMerge: Clean primitive
Jean Privat [Mon, 10 Aug 2015 16:12:58 +0000 (12:12 -0400)]
Merge: Clean primitive

Cleaning of binary operations on primitive data types:

* `lshift` and `rshift` are replaced by the usual `<<` and `>>`
* `bin_and` is replaced by `&`
* `bin_or` is replaced by `|`
* `bin_not` is replaced by `~`
* `bin_xor` is replaced by `^`

Note: Due to bootstrap issues, `<<` and `>>` are now FFI

Pull-Request: #1624
Reviewed-by: Jean Privat <jean@pryen.org>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>

8 years agoMerge: More abstract classes
Jean Privat [Mon, 10 Aug 2015 16:12:53 +0000 (12:12 -0400)]
Merge: More abstract classes

The current leniency of abstract methods (see #808) make that a lot of concrete classes inherit abstract methods (I counted 5048 cases in the whole code base).
Some trivial cases are classes that just should be abstract.

Pull-Request: #1622
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>

8 years agoMerge: Stricter default arguments
Jean Privat [Mon, 10 Aug 2015 16:12:51 +0000 (12:12 -0400)]
Merge: Stricter default arguments

This change the way that default arguments are handled.

Now, defaults arguments can only follow the used one.
This improve the readability of calls and the association between calls and declarations thus solve a lot of issues of users.

~~~
fun foo(a: nullable Int, b: Int, c: nullable Int) do ...
foo(null,2,null) # OK
foo(null,2) # equivalent
foo(2) # now refused! but previously accepted as equivalent.
~~~

Only exception: the last parameter of an assignment method is always the last argument

~~~
fun foo=(a: nullable Int, b: Int, c: nullable Int, d: nullable Int) do ...
foo(null,2,null) = 0 # OK
foo(null,2) = 0 # equivalent
foo(2) = 0 # now refused! but previously accepted as equivalent
~~~

No specific black magic is added to automatic constructor.
Therefore an optional constructor parameter in a class can becore mandatory in a subclass if a new mandatory attribute is introduced.

~~~
class A
   var a: nullable Int
end
class B
  super A
  var b: Int
end
var a1 = new A(null) # OK
var a2 = new A # equivalent
var b1 = new B(null, 2) # OK
var b2 = new B(2) # now refused! but previously accepted as equivalent
~~~

This issue only required some small adaptation in existing piece of code: nitdoc, sexp, serialization and dom. The latter is PRized independently in #1616 but included here for jenkins.
Most of these changes (first commits) are in fact bugfixes or make the code cleaner so this is an argument in favor of this new stricter specification.

This PR has also the advantage of simplifying the model as the whole policy of the default argument is moved to the typing analysis: it is now just a pure calling convention.

Close #1453

Pull-Request: #1618
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>

8 years agotests: Update sav for legacy tests
Lucas Bajolet [Mon, 10 Aug 2015 15:00:03 +0000 (11:00 -0400)]
tests: Update sav for legacy tests

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agolib/standard/: Removed bin_and/or/xor/not from math
Lucas Bajolet [Fri, 7 Aug 2015 20:27:58 +0000 (16:27 -0400)]
lib/standard/: Removed bin_and/or/xor/not from math

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agotests: Darwin special sav for test_regex_check
Jean Privat [Sat, 8 Aug 2015 01:00:50 +0000 (21:00 -0400)]
tests: Darwin special sav for test_regex_check

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

8 years agotests: Darwin skips cocoa, mpi and emscripten
Jean Privat [Sat, 8 Aug 2015 00:59:19 +0000 (20:59 -0400)]
tests: Darwin skips cocoa, mpi and emscripten

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

8 years agotests: add Darwin/todo to mass blacklist some tests
Jean Privat [Fri, 7 Aug 2015 21:21:21 +0000 (17:21 -0400)]
tests: add Darwin/todo to mass blacklist some tests

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

8 years agotests.sh: use `todo` files to store magic strings
Jean Privat [Fri, 7 Aug 2015 21:18:34 +0000 (17:18 -0400)]
tests.sh: use `todo` files to store magic strings

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

8 years agotests: update tests related to default arguments
Jean Privat [Thu, 6 Aug 2015 18:34:40 +0000 (14:34 -0400)]
tests: update tests related to default arguments

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

8 years agoneo: update because no more default param in the model
Jean Privat [Thu, 6 Aug 2015 18:57:41 +0000 (14:57 -0400)]
neo: update because no more default param in the model

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

8 years agomodel: remove things about default parameters
Jean Privat [Thu, 6 Aug 2015 18:33:54 +0000 (14:33 -0400)]
model: remove things about default parameters

Everything is in typing now.

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

8 years agotyping: change specification about default arguments. everything is done here
Jean Privat [Thu, 6 Aug 2015 18:32:14 +0000 (14:32 -0400)]
typing: change specification about default arguments. everything is done here

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

8 years agoseparate_compiler: always compile stub of methods to avoid unresolved symbols
Jean Privat [Fri, 7 Aug 2015 21:00:22 +0000 (17:00 -0400)]
separate_compiler: always compile stub of methods to avoid unresolved symbols

week symbols seem to cause issues on some platforms *couch mac os x couch*

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

8 years agolib/standard: Remove lshift and rshift from Int and Byte
Lucas Bajolet [Fri, 7 Aug 2015 20:26:13 +0000 (16:26 -0400)]
lib/standard: Remove lshift and rshift from Int and Byte

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agolib/standard/kernel: Use literal bytes in nitunits
Lucas Bajolet [Fri, 7 Aug 2015 19:55:52 +0000 (15:55 -0400)]
lib/standard/kernel: Use literal bytes in nitunits

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agosrc/interpreter: Clean uses of recvval in interpreter
Lucas Bajolet [Fri, 7 Aug 2015 19:51:20 +0000 (15:51 -0400)]
src/interpreter: Clean uses of recvval in interpreter

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agoMerge: Prepare qualified identifiers
Jean Privat [Fri, 7 Aug 2015 18:11:03 +0000 (14:11 -0400)]
Merge: Prepare qualified identifiers

First step to solve #1260: do not lose qualifiers in the AST.

This is just a API change without new features. qualifiers are still ignored but now they are in the AST.

Pull-Request: #1620
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agoMerge: Own rand seed
Jean Privat [Fri, 7 Aug 2015 15:38:38 +0000 (11:38 -0400)]
Merge: Own rand seed

Inject a basic patform-independent reproducible pseudo-random generator when `srand_form` (thus NIT_SRAND) is used.
This will allows to have more reproductible tests on various architecture.

Related with #1387

Pull-Request: #1621
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Reviewed-by: Alexis Laferrière <alexis.laf@xymus.net>

8 years agoMerge: Benitlux report tool
Jean Privat [Fri, 7 Aug 2015 15:38:33 +0000 (11:38 -0400)]
Merge: Benitlux report tool

Intro a tool to print a pretty report on the availability of beers at the excellent Brasserie Bénélux.

Pull-Request: #1619
Reviewed-by: Jean Privat <jean@pryen.org>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agoMerge: UTF-8 byte reading error
Jean Privat [Fri, 7 Aug 2015 15:38:26 +0000 (11:38 -0400)]
Merge: UTF-8 byte reading error

A small bug in char_at and length_of_char_at found their way and up until now did not pose any problem, however on some borderline cases (such as the 0x10FFFF example below) the char was misread as 0xFFFD.

The standard specifies the first byte of a 4 byte sequence to start with a `0b1111_0xxx` form, that the masks used in these methods did not check properly.

Pull-Request: #1617
Reviewed-by: Jean Privat <jean@pryen.org>
Reviewed-by: Alexis Laferrière <alexis.laf@xymus.net>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>

8 years agoastutil: update nitunit related to AST
Jean Privat [Fri, 7 Aug 2015 00:12:26 +0000 (20:12 -0400)]
astutil: update nitunit related to AST

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

8 years agotests: update sav related to AST
Jean Privat [Fri, 7 Aug 2015 00:09:40 +0000 (20:09 -0400)]
tests: update sav related to AST

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

8 years agosrc: update AST client to handle qualified identifiers (no semantic change)
Jean Privat [Thu, 6 Aug 2015 21:04:12 +0000 (17:04 -0400)]
src: update AST client to handle qualified identifiers (no semantic change)

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

8 years agoparser: regenerate with qualifiers in the AST
Jean Privat [Thu, 6 Aug 2015 21:03:16 +0000 (17:03 -0400)]
parser: regenerate with qualifiers in the AST

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

8 years agogrammar: keep qualified information in the AST. Does not change the CST.
Jean Privat [Thu, 6 Aug 2015 21:02:36 +0000 (17:02 -0400)]
grammar: keep qualified information in the AST. Does not change the CST.

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

8 years agosrc: make AUnaryopExpr abstract
Jean Privat [Fri, 7 Aug 2015 15:25:27 +0000 (11:25 -0400)]
src: make AUnaryopExpr abstract

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

8 years agolib: make some classes abstract
Jean Privat [Fri, 7 Aug 2015 15:25:05 +0000 (11:25 -0400)]
lib: make some classes abstract

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

8 years agotests: update some sav because change in random
Jean Privat [Tue, 30 Jun 2015 20:25:47 +0000 (16:25 -0400)]
tests: update some sav because change in random

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

8 years agoffi: compile extern C files with -Wno-unused-function to avoid warning on C dead...
Jean Privat [Fri, 7 Aug 2015 01:04:50 +0000 (21:04 -0400)]
ffi: compile extern C files with -Wno-unused-function to avoid warning on C dead code

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

8 years agocontrib/benitlux: add a report tool
Alexis Laferrière [Thu, 6 Aug 2015 19:32:06 +0000 (15:32 -0400)]
contrib/benitlux: add a report tool

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

8 years agocontrib/benitlux: add services to list known beers and days
Alexis Laferrière [Thu, 6 Aug 2015 19:30:58 +0000 (15:30 -0400)]
contrib/benitlux: add services to list known beers and days

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

8 years agolib/sepx: provide location to each parsed node
Jean Privat [Thu, 6 Aug 2015 18:59:20 +0000 (14:59 -0400)]
lib/sepx: provide location to each parsed node

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

8 years agonitdoc: explicitly set titles of articles to null in constructor call
Jean Privat [Thu, 6 Aug 2015 15:14:28 +0000 (11:14 -0400)]
nitdoc: explicitly set titles of articles to null in constructor call

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

8 years agoserialization: initialize `keep_going` to null
Jean Privat [Thu, 6 Aug 2015 15:13:45 +0000 (11:13 -0400)]
serialization: initialize `keep_going` to null

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

8 years agoMerge: Cleanup lib/dom
Jean Privat [Thu, 6 Aug 2015 19:00:52 +0000 (15:00 -0400)]
Merge: Cleanup lib/dom

This part was required while developing some change in the spec of default parameter (see #1453)
But this series of commit seems good enough and could be independently useful.
It also remove all warnings in the lib/dom directory

Pull-Request: #1616
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>

8 years agoMerge: Add debug option to compiler
Jean Privat [Thu, 6 Aug 2015 19:00:48 +0000 (15:00 -0400)]
Merge: Add debug option to compiler

Addition of a `-g` option to the compiler, right now it just disables gdb-side optimisation, but it may become more capable in the long run.

Pull-Request: #1615
Reviewed-by: Alexis Laferrière <alexis.laf@xymus.net>
Reviewed-by: Jean Privat <jean@pryen.org>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>

8 years agoMerge: example: optional attribute with a default value
Jean Privat [Thu, 6 Aug 2015 19:00:36 +0000 (15:00 -0400)]
Merge: example: optional attribute with a default value

This one comes from a discussion with @R4PaSs

I'm not sure I want to really expose it as I still think that current constructors need more love and work.
So at least test the current behavior.

If you people have other alternatives, you can show them.

Pull-Request: #1614
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>
Reviewed-by: Alexis Laferrière <alexis.laf@xymus.net>

8 years agotests: Added tests for char_at method on borderline cases
Lucas Bajolet [Thu, 6 Aug 2015 18:57:51 +0000 (14:57 -0400)]
tests: Added tests for char_at method on borderline cases

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agolib/standard: Fix NativeString::length_of_char_at and char_at
Lucas Bajolet [Thu, 6 Aug 2015 18:38:36 +0000 (14:38 -0400)]
lib/standard: Fix NativeString::length_of_char_at and char_at

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agoshare/man: Update nitc.md for debug option
Lucas Bajolet [Thu, 6 Aug 2015 16:10:15 +0000 (12:10 -0400)]
share/man: Update nitc.md for debug option

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agocompiler: Add -g option to compiler
Lucas Bajolet [Thu, 6 Aug 2015 14:50:02 +0000 (10:50 -0400)]
compiler: Add -g option to compiler

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agolib/dom: remove useless visibility
Jean Privat [Thu, 6 Aug 2015 15:04:07 +0000 (11:04 -0400)]
lib/dom: remove useless visibility

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

8 years agolib/dom: remove `null` call warning
Jean Privat [Thu, 6 Aug 2015 15:03:50 +0000 (11:03 -0400)]
lib/dom: remove `null` call warning

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

8 years agolib/dom: add missing documentation
Jean Privat [Thu, 6 Aug 2015 15:02:58 +0000 (11:02 -0400)]
lib/dom: add missing documentation

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

8 years agotests: update sav for text_xml_read
Jean Privat [Thu, 6 Aug 2015 14:35:27 +0000 (10:35 -0400)]
tests: update sav for text_xml_read

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

8 years agolib/dom: give location to all parsed XML nodes
Jean Privat [Thu, 6 Aug 2015 14:33:43 +0000 (10:33 -0400)]
lib/dom: give location to all parsed XML nodes

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

8 years agolib/dom: remove urequired use of named arguments
Jean Privat [Thu, 6 Aug 2015 14:31:23 +0000 (10:31 -0400)]
lib/dom: remove urequired use of named arguments

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

8 years agolib/dom: initialize `XMLEntity::parent` to null
Jean Privat [Thu, 6 Aug 2015 14:31:57 +0000 (10:31 -0400)]
lib/dom: initialize `XMLEntity::parent` to null

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

8 years agolib/dom: remove useless variable
Jean Privat [Thu, 6 Aug 2015 14:29:03 +0000 (10:29 -0400)]
lib/dom: remove useless variable

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

8 years agoMerge: Text::to_bytes
Jean Privat [Wed, 5 Aug 2015 22:37:50 +0000 (18:37 -0400)]
Merge: Text::to_bytes

Simple addition to the Bytes module, to build one from any Text type

Pull-Request: #1613
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>
Reviewed-by: Jean Privat <jean@pryen.org>

8 years agoexample: optional attribute with a default value
Jean Privat [Wed, 5 Aug 2015 18:47:32 +0000 (14:47 -0400)]
example: optional attribute with a default value

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

8 years agolib/standard/bytes: Text::to_bytes method
Lucas Bajolet [Wed, 5 Aug 2015 18:12:46 +0000 (14:12 -0400)]
lib/standard/bytes: Text::to_bytes method

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agoMerge: lib/maths: add `nan` and `inf` as special Float
Jean Privat [Wed, 5 Aug 2015 15:53:12 +0000 (11:53 -0400)]
Merge: lib/maths: add `nan` and `inf` as special Float

with bits of IEEE 754

Pull-Request: #1612
Reviewed-by: Alexis Laferrière <alexis.laf@xymus.net>
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>

8 years agoMerge: Can use lib/github/github_curl without a oauth token
Jean Privat [Wed, 5 Aug 2015 15:53:09 +0000 (11:53 -0400)]
Merge: Can use lib/github/github_curl without a oauth token

Nothing fancy but I wanted to merge PR tonight and I found the oauth token requirement a bit harsh

Pull-Request: #1611
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agoMerge: contrib: add a simple planner that use lib/ai
Jean Privat [Wed, 5 Aug 2015 15:53:06 +0000 (11:53 -0400)]
Merge: contrib: add a simple planner that use lib/ai

This is a basic implementation for a TP given by a professor who wants to remain anonymous.
I'm quite sure the algorithm and the implementation can be improved, but it does the job in a quite acceptable time performance.

Pull-Request: #1596
Reviewed-by: Alexis Laferrière <alexis.laf@xymus.net>
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>

8 years agocontrib: add a simple planner that use lib/ai
Jean Privat [Wed, 5 Aug 2015 15:51:24 +0000 (11:51 -0400)]
contrib: add a simple planner that use lib/ai

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

8 years agolib/maths: add `nan` and `inf` as special Float
Jean Privat [Wed, 5 Aug 2015 08:08:41 +0000 (04:08 -0400)]
lib/maths: add `nan` and `inf` as special Float

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

8 years agoMerge: jwrapper reproduces Java class hierarchy in Nit and serialize model
Jean Privat [Wed, 5 Aug 2015 07:04:25 +0000 (03:04 -0400)]
Merge: jwrapper reproduces Java class hierarchy in Nit and serialize model

Continuing the work of #1578, #1589 and #1599, this PR adds the last big feature missing from jwrapper: duplicating the class hierarchy from Java to the generated wrapper classes. This allows user code to benefit from polymorphism when invoking Java methods wrappers.

This is done by collecting the implements and extends declaration from the javap output, rebuilding the class hierarchy and adding the super declarations needed to reproduce the hierarchy in Nit. To support a compatible hierarchy across modules, the model can now be serialized to a file and read by the following passes. Note that jwrapper wraps classes and interfaces in the same way so the implements and the extends hierarchy are merge into one on the Nit side.

What's to do next:
* Integrate generated modules in the `::java` and `::android` libraries!
* Add tools to extract concerns from a Jar archive to subdivide the wrappers in many modules. This could be done by targeting types, but more experimentation is needed.
* Clean up the duplicated features from the grep search and the serialized models. This is also an evolution as the grep features should be phased out in favor of a better `::java` lib and the serialized models.
* Automate declaring importations by using knowledge from the serialized models.
* Generate casts between the Java wrapper classes?
* Update the documentation with the latest changes.

What I'm probably not gonna do unless someone needs it:
* Full vararg types support, this would probably require using the JNI from C. In the time being, it can be done manually with a fixed number of parameters, as needed.

Pull-Request: #1608
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>
Reviewed-by: Jean Privat <jean@pryen.org>

8 years agolib/performance_analysis: relax unit test expected results
Alexis Laferrière [Tue, 4 Aug 2015 20:45:19 +0000 (16:45 -0400)]
lib/performance_analysis: relax unit test expected results

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

8 years agocontrib/jwrapper examples: update android_api to use a serialized model
Alexis Laferrière [Mon, 3 Aug 2015 16:35:18 +0000 (12:35 -0400)]
contrib/jwrapper examples: update android_api to use a serialized model

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

8 years agocontrib/jwrapper examples: update java_api to benefit from polymorphism
Alexis Laferrière [Sat, 1 Aug 2015 13:26:36 +0000 (09:26 -0400)]
contrib/jwrapper examples: update java_api to benefit from polymorphism

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

8 years agocontrib/jwrapper: saving the model must be asked by an option
Alexis Laferrière [Tue, 4 Aug 2015 18:40:41 +0000 (14:40 -0400)]
contrib/jwrapper: saving the model must be asked by an option

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

8 years agocontrib/jwrapper: only reference to `java.lang.Object` if known by the model
Alexis Laferrière [Tue, 4 Aug 2015 18:24:33 +0000 (14:24 -0400)]
contrib/jwrapper: only reference to `java.lang.Object` if known by the model

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

8 years agocontrib/jwrapper: add an option to not generate methods
Alexis Laferrière [Mon, 3 Aug 2015 18:20:38 +0000 (14:20 -0400)]
contrib/jwrapper: add an option to not generate methods

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

8 years agocontrib/jwrapper: use serialized models to build the complete class hierarchy
Alexis Laferrière [Mon, 3 Aug 2015 16:36:16 +0000 (12:36 -0400)]
contrib/jwrapper: use serialized models to build the complete class hierarchy

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

8 years agocontrib/jwrapper: intro reading models from file
Alexis Laferrière [Mon, 3 Aug 2015 16:29:25 +0000 (12:29 -0400)]
contrib/jwrapper: intro reading models from file

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

8 years agocontrib/jwrapper: write the model to a file next to the Nit module
Alexis Laferrière [Mon, 3 Aug 2015 16:33:01 +0000 (12:33 -0400)]
contrib/jwrapper: write the model to a file next to the Nit module

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

8 years agocontrib/jwrapper: enable serialization of model
Alexis Laferrière [Mon, 3 Aug 2015 14:06:52 +0000 (10:06 -0400)]
contrib/jwrapper: enable serialization of model

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

8 years agocontrib/jwrapper: generate classes in linearization order
Alexis Laferrière [Mon, 3 Aug 2015 13:42:20 +0000 (09:42 -0400)]
contrib/jwrapper: generate classes in linearization order

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

8 years agocontrib/jwrapper: prevent name conflicts with inherited properties
Alexis Laferrière [Sat, 1 Aug 2015 13:24:18 +0000 (09:24 -0400)]
contrib/jwrapper: prevent name conflicts with inherited properties

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

8 years agocontrib/jwrapper: generate only locally introduced methods in each class
Alexis Laferrière [Sat, 1 Aug 2015 13:25:48 +0000 (09:25 -0400)]
contrib/jwrapper: generate only locally introduced methods in each class

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

8 years agocontrib/jwrapper: silence all useless-superclass warnings
Alexis Laferrière [Sat, 1 Aug 2015 13:09:18 +0000 (09:09 -0400)]
contrib/jwrapper: silence all useless-superclass warnings

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

8 years agocontrib/jwrapper: compute the methods introduced by each classes
Alexis Laferrière [Sat, 1 Aug 2015 13:32:32 +0000 (09:32 -0400)]
contrib/jwrapper: compute the methods introduced by each classes

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

8 years agocontrib/jwrapper: copy class hierarchy over to Nit
Alexis Laferrière [Mon, 3 Aug 2015 13:46:53 +0000 (09:46 -0400)]
contrib/jwrapper: copy class hierarchy over to Nit

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

8 years agocontrib/jwrapper: build class hierarchy into a POSet
Alexis Laferrière [Wed, 29 Jul 2015 19:04:48 +0000 (15:04 -0400)]
contrib/jwrapper: build class hierarchy into a POSet

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

8 years agocontrib/jwrapper: collect super-classes data
Alexis Laferrière [Wed, 29 Jul 2015 18:08:59 +0000 (14:08 -0400)]
contrib/jwrapper: collect super-classes data

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

8 years agocontrib/jwrapper: revamp class header generation
Alexis Laferrière [Wed, 29 Jul 2015 18:18:52 +0000 (14:18 -0400)]
contrib/jwrapper: revamp class header generation

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

8 years agocontrib/jwrapper: create the tmp directory as needed
Alexis Laferrière [Mon, 3 Aug 2015 16:24:52 +0000 (12:24 -0400)]
contrib/jwrapper: create the tmp directory as needed

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

8 years agocontrib/jwrapper: implement == and hash in JavaClass and JavaMethod
Alexis Laferrière [Sat, 1 Aug 2015 13:05:04 +0000 (09:05 -0400)]
contrib/jwrapper: implement == and hash in JavaClass and JavaMethod

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

8 years agocontrib/jwrapper: close module file stream after writing
Alexis Laferrière [Mon, 3 Aug 2015 16:30:24 +0000 (12:30 -0400)]
contrib/jwrapper: close module file stream after writing

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

8 years agocontrib/jwrapper grammar: reorder of the grammar file (no other changes)
Alexis Laferrière [Sun, 2 Aug 2015 16:20:01 +0000 (12:20 -0400)]
contrib/jwrapper grammar: reorder of the grammar file (no other changes)

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

8 years agocontrib/jwrapper grammar: unify all lists of things that look like a type
Alexis Laferrière [Wed, 29 Jul 2015 18:08:12 +0000 (14:08 -0400)]
contrib/jwrapper grammar: unify all lists of things that look like a type

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

8 years agoMerge: curl: implement CURLOPT_TIMEOUT and CURLOPT_TIMEOUT_MS
Jean Privat [Wed, 5 Aug 2015 01:08:27 +0000 (21:08 -0400)]
Merge: curl: implement CURLOPT_TIMEOUT and CURLOPT_TIMEOUT_MS

Signed-off-by: Alexandre Terrasa <alexandre@moz-code.org>

Pull-Request: #1610
Reviewed-by: Jean Privat <jean@pryen.org>
Reviewed-by: Jean-Philippe Caissy <jpcaissy@piji.ca>

8 years agoMerge: lib/performance_analysis: relax nitunit expected results
Jean Privat [Wed, 5 Aug 2015 01:08:19 +0000 (21:08 -0400)]
Merge: lib/performance_analysis: relax nitunit expected results

This should be enough to fix #1562.

Pull-Request: #1609
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>
Reviewed-by: Jean Privat <jean@pryen.org>

8 years agocontrib/github_merge: can merge localy without github oauth (need readonly)
Jean Privat [Wed, 5 Aug 2015 01:06:29 +0000 (21:06 -0400)]
contrib/github_merge: can merge localy without github oauth (need readonly)

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

8 years agolib/github: can connect without OAuth token
Jean Privat [Wed, 5 Aug 2015 01:04:07 +0000 (21:04 -0400)]
lib/github: can connect without OAuth token

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

8 years agolib/curl: Collection::to_curlslist do not crash on empty lists
Jean Privat [Wed, 5 Aug 2015 01:00:18 +0000 (21:00 -0400)]
lib/curl: Collection::to_curlslist do not crash on empty lists

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

8 years agocurl: implement CURLOPT_TIMEOUT and CURLOPT_TIMEOUT_MS
Alexandre Terrasa [Tue, 4 Aug 2015 21:57:19 +0000 (17:57 -0400)]
curl: implement CURLOPT_TIMEOUT and CURLOPT_TIMEOUT_MS

Signed-off-by: Alexandre Terrasa <alexandre@moz-code.org>

8 years agolib/performance_analysis: relax unit test expected results
Alexis Laferrière [Tue, 4 Aug 2015 20:45:19 +0000 (16:45 -0400)]
lib/performance_analysis: relax unit test expected results

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

8 years agoMerge: Tinks! fix frame lock between clients and servers
Jean Privat [Tue, 4 Aug 2015 20:10:28 +0000 (16:10 -0400)]
Merge: Tinks! fix frame lock between clients and servers

This PR greatly improve multiplayer performance by removing the synchronous frames between the clients and server.

There is still a lot of stuff to do on Tinks! see the notes in #1601.

Pull-Request: #1607
Reviewed-by: Jean Privat <jean@pryen.org>
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agoMerge: Simplify integer parsing
Jean Privat [Tue, 4 Aug 2015 20:10:26 +0000 (16:10 -0400)]
Merge: Simplify integer parsing

As a follow-up to #1602, a more aggressive factorization of the parser, along with a few methods that produce Numeric values of the right type.

Pull-Request: #1606
Reviewed-by: Alexandre Terrasa <alexandre@moz-code.org>
Reviewed-by: Jean Privat <jean@pryen.org>

8 years agoMerge: Fix nitcorn `Content-Length` when working with UTF-8 files
Jean Privat [Tue, 4 Aug 2015 20:10:23 +0000 (16:10 -0400)]
Merge: Fix nitcorn `Content-Length` when working with UTF-8 files

Changes:
* use `bytelen` instead of `length` when setting `Content-Length` header
* add media types for web fonts

Pull-Request: #1605
Reviewed-by: Jean Privat <jean@pryen.org>
Reviewed-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agotests: Update sav for parser updates
Lucas Bajolet [Tue, 4 Aug 2015 18:35:49 +0000 (14:35 -0400)]
tests: Update sav for parser updates

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agosrc: Parser regeneration
Lucas Bajolet [Tue, 4 Aug 2015 14:36:03 +0000 (10:36 -0400)]
src: Parser regeneration

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>

8 years agosrc: Modified compilers for the support of the new Integers
Lucas Bajolet [Mon, 3 Aug 2015 22:21:35 +0000 (18:21 -0400)]
src: Modified compilers for the support of the new Integers

Signed-off-by: Lucas Bajolet <r4pass@hotmail.com>