nit.git
11 years agonitdbg: Added function to continue execution automatically with -c option
Lucas Bajolet [Thu, 14 Mar 2013 21:01:59 +0000 (17:01 -0400)]
nitdbg: Added function to continue execution automatically with -c option

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

11 years agonitdbg: Added missing documentation on commited functions
Lucas BAJOLET [Tue, 5 Mar 2013 23:53:45 +0000 (18:53 -0500)]
nitdbg: Added missing documentation on commited functions

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

11 years agonitdbg: Added documentation for the trace and untrace functions
Lucas BAJOLET [Tue, 5 Mar 2013 23:44:04 +0000 (18:44 -0500)]
nitdbg: Added documentation for the trace and untrace functions

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

11 years agonitdbg: The untrace function can now be called via the interactive shell
R4PaSs [Tue, 5 Mar 2013 22:46:22 +0000 (17:46 -0500)]
nitdbg: The untrace function can now be called via the interactive shell

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

11 years agonitdbg: Added command to untrace a variable
R4PaSs [Tue, 5 Mar 2013 22:45:46 +0000 (17:45 -0500)]
nitdbg: Added command to untrace a variable

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

11 years agonitdbg: Trace function, auto adds an object to trace when encountering a traced objec...
R4PaSs [Tue, 5 Mar 2013 22:44:55 +0000 (17:44 -0500)]
nitdbg: Trace function, auto adds an object to trace when encountering a traced object in a funciton call

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

11 years agonitdbg: Added the trace detection in main loop
R4PaSs [Tue, 5 Mar 2013 22:44:02 +0000 (17:44 -0500)]
nitdbg: Added the trace detection in main loop

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

11 years agonitdbg: Added function to add a variable to the trace list
R4PaSs [Tue, 5 Mar 2013 22:43:12 +0000 (17:43 -0500)]
nitdbg: Added function to add a variable to the trace list

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

11 years agonitdbg: Added function to trace a variable and all its super definitions
R4PaSs [Tue, 5 Mar 2013 23:26:53 +0000 (18:26 -0500)]
nitdbg: Added function to trace a variable and all its super definitions

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

11 years agonitdbg: Seeks an argument in the specified frame to see if the variable is an argumen...
Lucas BAJOLET [Tue, 5 Mar 2013 22:39:49 +0000 (17:39 -0500)]
nitdbg: Seeks an argument in the specified frame to see if the variable is an argument in the function definition

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

11 years agonitdbg: Added function to parse a command and get only its identifiers
Lucas BAJOLET [Tue, 5 Mar 2013 22:38:29 +0000 (17:38 -0500)]
nitdbg: Added function to parse a command and get only its identifiers

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

11 years agonitdbg: Added function to strip arguments from a function call or definition
Lucas BAJOLET [Tue, 5 Mar 2013 22:37:09 +0000 (17:37 -0500)]
nitdbg: Added function to strip arguments from a function call or definition

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

11 years agostdlib: Char, added functions is_alpha and is_alphanumeric (used for several operatio...
Lucas BAJOLET [Tue, 5 Mar 2013 22:35:18 +0000 (17:35 -0500)]
stdlib: Char, added functions is_alpha and is_alphanumeric (used for several operations in debugger)

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

11 years agonitdbg: Added class containing the trace information for a variable and the frame...
Lucas Bajolet [Thu, 14 Mar 2013 20:31:41 +0000 (16:31 -0400)]
nitdbg: Added class containing the trace information for a variable and the frame involved for this variable

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

11 years agonitdbg: Added function to stop execution and input commands before program crash.
Lucas Bajolet [Tue, 19 Mar 2013 18:06:26 +0000 (14:06 -0400)]
nitdbg: Added function to stop execution and input commands before program crash.

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

11 years agonitdbg: Added condition to avoid breaking on non-statements (ABlockExpr)
R4PaSs [Tue, 5 Mar 2013 23:20:36 +0000 (18:20 -0500)]
nitdbg: Added condition to avoid breaking on non-statements (ABlockExpr)

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

11 years agonitdbg: Added documentation for the features of the debugger
Lucas BAJOLET [Fri, 22 Feb 2013 20:10:08 +0000 (15:10 -0500)]
nitdbg: Added documentation for the features of the debugger

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

11 years agonitdbg: Added command to modify variables at runtime
R4PaSs [Tue, 5 Mar 2013 23:19:56 +0000 (18:19 -0500)]
nitdbg: Added command to modify variables at runtime

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

11 years agonitdbg: Added function to modify a variable nested in a complex object instance
Lucas BAJOLET [Fri, 22 Feb 2013 19:55:01 +0000 (14:55 -0500)]
nitdbg: Added function to modify a variable nested in a complex object instance

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

11 years agonitdbg: Added function to modify the state of a variable in the current frame
Lucas BAJOLET [Fri, 22 Feb 2013 19:54:17 +0000 (14:54 -0500)]
nitdbg: Added function to modify the state of a variable in the current frame

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

11 years agonitdbg: Added function that returns a new instance for any type and value
Lucas BAJOLET [Fri, 22 Feb 2013 19:51:40 +0000 (14:51 -0500)]
nitdbg: Added function that returns a new instance for any type and value

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

11 years agonitdbg: Added function to create a bool instance with its value
Lucas BAJOLET [Fri, 22 Feb 2013 19:48:54 +0000 (14:48 -0500)]
nitdbg: Added function to create a bool instance with its value

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

11 years agonitdbg: Added function to create a char instance with its value
Lucas BAJOLET [Fri, 22 Feb 2013 19:48:35 +0000 (14:48 -0500)]
nitdbg: Added function to create a char instance with its value

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

11 years agonitdbg: Added function to create a float instance with its value
Lucas BAJOLET [Fri, 22 Feb 2013 19:48:13 +0000 (14:48 -0500)]
nitdbg: Added function to create a float instance with its value

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

11 years agonitdbg: Added function to generate a Int instance with its value
Lucas BAJOLET [Fri, 22 Feb 2013 19:47:22 +0000 (14:47 -0500)]
nitdbg: Added function to generate a Int instance with its value

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

11 years agonitdbg: Added command to print the content of any SequenceRead collection
R4PaSs [Tue, 5 Mar 2013 23:14:44 +0000 (18:14 -0500)]
nitdbg: Added command to print the content of any SequenceRead collection

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

11 years agonitdbg: Added function to print a collection recursively
Lucas BAJOLET [Fri, 22 Feb 2013 19:06:30 +0000 (14:06 -0500)]
nitdbg: Added function to print a collection recursively

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

11 years agonitdbg: Removes the braces of a string and returns an array of string containing...
Lucas Bajolet [Thu, 14 Mar 2013 20:07:14 +0000 (16:07 -0400)]
nitdbg: Removes the braces of a string and returns an array of string containing indexes or ranges for further processing

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

11 years agonitdbg: Gets a collection nested in a MutableInstance
Lucas BAJOLET [Fri, 22 Feb 2013 19:04:13 +0000 (14:04 -0500)]
nitdbg: Gets a collection nested in a MutableInstance

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

11 years agonitdbg: Added an index parser returning the indexes of a range or int contained in...
Lucas BAJOLET [Fri, 22 Feb 2013 19:03:39 +0000 (14:03 -0500)]
nitdbg: Added an index parser returning the indexes of a range or int contained in a String

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

11 years agonitdbg: Added function to get the real length of a collection
Lucas BAJOLET [Fri, 22 Feb 2013 19:17:21 +0000 (14:17 -0500)]
nitdbg: Added function to get the real length of a collection

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

11 years agonitdbg: Added aliases
R4PaSs [Tue, 5 Mar 2013 23:12:00 +0000 (18:12 -0500)]
nitdbg: Added aliases

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

11 years agonitdbg: Added the command to place a temporary breakpoint
Lucas BAJOLET [Thu, 21 Feb 2013 23:42:44 +0000 (18:42 -0500)]
nitdbg: Added the command to place a temporary breakpoint

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

11 years agonitdbg: Added counter to Breakpoint class + documentation
Lucas Bajolet [Thu, 14 Mar 2013 19:55:08 +0000 (15:55 -0400)]
nitdbg: Added counter to Breakpoint class + documentation

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

11 years agonitdbg: Added command to list all commands available
Lucas BAJOLET [Thu, 21 Feb 2013 23:22:19 +0000 (18:22 -0500)]
nitdbg: Added command to list all commands available

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

11 years agonitdbg: Can remove breakpoints
Lucas BAJOLET [Thu, 21 Feb 2013 23:08:02 +0000 (18:08 -0500)]
nitdbg: Can remove breakpoints

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

11 years agonitdbg: Can break on a breakpoint
Lucas Bajolet [Thu, 14 Mar 2013 19:51:37 +0000 (15:51 -0400)]
nitdbg: Can break on a breakpoint

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

11 years agonitdbg: Can place a breakpoint on a line of a file
Lucas BAJOLET [Thu, 21 Feb 2013 22:59:38 +0000 (17:59 -0500)]
nitdbg: Can place a breakpoint on a line of a file

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

11 years agonitdbg: Placed foundations for Breakpoints, can search in a HashMap if the breakpoint...
Lucas BAJOLET [Thu, 21 Feb 2013 22:58:16 +0000 (17:58 -0500)]
nitdbg: Placed foundations for Breakpoints, can search in a HashMap if the breakpoint exists

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

11 years agonitdbg: Added module and class Breakpoint
Lucas Bajolet [Mon, 18 Mar 2013 19:16:25 +0000 (15:16 -0400)]
nitdbg: Added module and class Breakpoint

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

11 years agonitdbg: Added step-in function
Lucas BAJOLET [Thu, 21 Feb 2013 22:28:27 +0000 (17:28 -0500)]
nitdbg: Added step-in function

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

11 years agonitdbg: Added possibility to step-out of a function
Lucas BAJOLET [Thu, 21 Feb 2013 22:27:42 +0000 (17:27 -0500)]
nitdbg: Added possibility to step-out of a function

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

11 years agonitdbg: Added comments to separate the code into regions
Lucas BAJOLET [Thu, 21 Feb 2013 22:15:10 +0000 (17:15 -0500)]
nitdbg: Added comments to separate the code into regions

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

11 years agonitdbg: Added the possibility to continue the execution without stopping on each...
Lucas BAJOLET [Thu, 21 Feb 2013 22:11:14 +0000 (17:11 -0500)]
nitdbg: Added the possibility to continue the execution without stopping on each statement

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

11 years agonitdbg: Added the possibility to step over an instruction
Lucas Bajolet [Mon, 18 Mar 2013 19:09:59 +0000 (15:09 -0400)]
nitdbg: Added the possibility to step over an instruction

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

11 years agonitdbg: Added function to process commands
Lucas Bajolet [Tue, 19 Mar 2013 17:57:36 +0000 (13:57 -0400)]
nitdbg: Added function to process commands
Added command print/p to print a variable

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

11 years agonitdbg: Added function to print the value of a variable
Lucas BAJOLET [Thu, 21 Feb 2013 20:56:37 +0000 (15:56 -0500)]
nitdbg: Added function to print the value of a variable

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

11 years agonitdbg: Added function to seek a variable in the specified frame
Lucas Bajolet [Thu, 14 Mar 2013 19:00:29 +0000 (15:00 -0400)]
nitdbg: Added function to seek a variable in the specified frame

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

11 years agonitdbg: Added function to get a variable in the selected frame by its name
Lucas BAJOLET [Thu, 21 Feb 2013 20:46:28 +0000 (15:46 -0500)]
nitdbg: Added function to get a variable in the selected frame by its name

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

11 years agonitdbg: Added function to get a specific variable in a MutableInstance (recursively)
Lucas Bajolet [Thu, 14 Mar 2013 18:57:40 +0000 (14:57 -0400)]
nitdbg: Added function to get a specific variable in a MutableInstance (recursively)

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

11 years agonitdbg: Added a new function to get an attribute in a MutableInstance (Complex Object)
Lucas BAJOLET [Thu, 21 Feb 2013 20:31:54 +0000 (15:31 -0500)]
nitdbg: Added a new function to get an attribute in a MutableInstance (Complex Object)

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

11 years agonitdbg: Added capacity to interpret with debugger in nit.nit
Lucas Bajolet [Thu, 14 Mar 2013 18:55:57 +0000 (14:55 -0400)]
nitdbg: Added capacity to interpret with debugger in nit.nit

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

11 years agonitdbg: Added module debugger
Lucas Bajolet [Thu, 14 Mar 2013 18:48:25 +0000 (14:48 -0400)]
nitdbg: Added module debugger

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

11 years agostdlib: Strings, added tests for is_numeric function
Lucas BAJOLET [Mon, 18 Feb 2013 22:10:56 +0000 (17:10 -0500)]
stdlib: Strings, added tests for is_numeric function

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

11 years agostdlib: AbstractString, added function is_numeric
Lucas Bajolet [Mon, 18 Mar 2013 19:04:04 +0000 (15:04 -0400)]
stdlib: AbstractString, added function is_numeric

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

11 years agoupdate c_src (now with ffi)
Jean Privat [Tue, 12 Feb 2013 11:35:38 +0000 (06:35 -0500)]
update c_src (now with ffi)

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

11 years agoMerge branch 'al-libs'
Jean Privat [Mon, 11 Feb 2013 14:10:10 +0000 (09:10 -0500)]
Merge branch 'al-libs'

11 years agolib: add missing #include<stdio.h>
Jean Privat [Mon, 11 Feb 2013 14:09:22 +0000 (09:09 -0500)]
lib: add missing #include<stdio.h>

Commit adbf39fb9f8c2df3bc23b5de7dfba34f5058c1e4 forgot to add it

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

11 years agoMerge remote-tracking branch 'alexis/ffi-in-nitc'
Jean Privat [Thu, 7 Feb 2013 18:20:52 +0000 (13:20 -0500)]
Merge remote-tracking branch 'alexis/ffi-in-nitc'

11 years agotests: adds tests for the FFI with C
Alexis Laferrière [Tue, 5 Feb 2013 14:13:00 +0000 (09:13 -0500)]
tests: adds tests for the FFI with C

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

11 years agonitc/ffi: adds full FFI support for C to nitc
Alexis Laferrière [Wed, 6 Feb 2013 13:07:04 +0000 (08:07 -0500)]
nitc/ffi: adds full FFI support for C to nitc

This commit adds all required features to use the nested C code, add it
to the compilation script and invoke it.

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

11 years agonitc/ffi: allows to declare C type of extern classes from Nit
Alexis Laferrière [Wed, 6 Feb 2013 13:06:02 +0000 (08:06 -0500)]
nitc/ffi: allows to declare C type of extern classes from Nit

This feature uses the FFI grammar but acts at the level of the native
interface. It allows the user to specify the C equivalent of a Nit
extern class. Instances of extern classes are automatically converted
to this type when passed to C. The equivalent C type must be a pointer
or compatible with a pointer type.

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

11 years agonitc/ffi: adds a variable to know if a module uses the native interface
Alexis Laferrière [Wed, 6 Feb 2013 13:03:05 +0000 (08:03 -0500)]
nitc/ffi: adds a variable to know if a module uses the native interface

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

11 years agonitc/ffi: adds the extern_inline module to manage foreign code blocks
Alexis Laferrière [Tue, 5 Feb 2013 23:37:13 +0000 (18:37 -0500)]
nitc/ffi: adds the extern_inline module to manage foreign code blocks

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

11 years agocompiling: moves up the compiling_writer module to be used by the new FFI
Alexis Laferrière [Fri, 14 Sep 2012 18:23:18 +0000 (14:23 -0400)]
compiling: moves up the compiling_writer module to be used by the new FFI

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

11 years agoniti: adds tools to compile C code
Alexis Laferrière [Fri, 1 Feb 2013 23:29:02 +0000 (18:29 -0500)]
niti: adds tools to compile C code

It will be widely used by the native interface.

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

11 years agonitc: adds module name and license to separate_options
Alexis Laferrière [Tue, 5 Feb 2013 23:32:34 +0000 (18:32 -0500)]
nitc: adds module name and license to separate_options

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

11 years agotests: add base_adaptive.nit
Jean Privat [Tue, 5 Feb 2013 16:34:44 +0000 (11:34 -0500)]
tests: add base_adaptive.nit

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

11 years agoflow: force the creation of a specific merge after the analysis of the node
Jean Privat [Tue, 5 Feb 2013 16:31:18 +0000 (11:31 -0500)]
flow: force the creation of a specific merge after the analysis of the node

11 years agoflow: AProxyExpr do not lose true/false context information
Jean Privat [Tue, 5 Feb 2013 16:30:49 +0000 (11:30 -0500)]
flow: AProxyExpr do not lose true/false context information

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

11 years agoflow: fix dot file---forgot the closing }
Jean Privat [Tue, 5 Feb 2013 16:29:31 +0000 (11:29 -0500)]
flow: fix dot file---forgot the closing }

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

11 years agoflow: use the correct entry point in visit_expr
Jean Privat [Tue, 5 Feb 2013 16:29:04 +0000 (11:29 -0500)]
flow: use the correct entry point in visit_expr

calling `visit` instead of `enter_visit` skips all the current_node update.

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

11 years agoflow: rewrite AOrExpr to be symmetric with AAndExpr
Jean Privat [Tue, 5 Feb 2013 16:27:30 +0000 (11:27 -0500)]
flow: rewrite AOrExpr to be symmetric with AAndExpr

no semantic changes

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

11 years agoflow: do not lose the after_expr context in AAssertExpr
Jean Privat [Tue, 5 Feb 2013 16:26:16 +0000 (11:26 -0500)]
flow: do not lose the after_expr context in AAssertExpr

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

11 years agolib: adds base64 module and according tests
Alexis Laferrière [Mon, 4 Feb 2013 19:31:20 +0000 (14:31 -0500)]
lib: adds base64 module and according tests

Implements the base64 encode and decode algorithms in Nit.

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

11 years agolib: check the return of calls to pipe(), report errors and abort on fail
Alexis Laferrière [Wed, 30 Jan 2013 21:10:41 +0000 (16:10 -0500)]
lib: check the return of calls to pipe(), report errors and abort on fail

This commits prevents compilation warnings and allows easier debugging.

Better solutions are still possible but will require to modifiy the API.

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

11 years agolib: fix method FDStream::write_char
Alexis Laferrière [Wed, 30 Jan 2013 20:52:02 +0000 (15:52 -0500)]
lib: fix method FDStream::write_char

This function was only partially implemented in C without being defined in
Nit. This commits removes the partial implementation which triggered a warning
at compilation and replaces it by a working and accessible method using
the legacy native interface.

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

11 years agomisc: extends Vim syntax highlighting for the FFI
Alexis Laferrière [Tue, 29 Jan 2013 20:56:45 +0000 (15:56 -0500)]
misc: extends Vim syntax highlighting for the FFI

First, this recognizes the use of inline foreign code. It also switches
language highlighting for the inlined language. This commit supports only
inlined C and Python code, but more can easily be added.

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

11 years agomisc: adds extern class type to vim syntax highlighting
Alexis Laferrière [Thu, 31 May 2012 00:17:10 +0000 (20:17 -0400)]
misc: adds extern class type to vim syntax highlighting

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

11 years agomisc: adapts gtksourceview/nit.lang to extern code use
Alexis Laferrière [Sat, 6 Aug 2011 16:14:32 +0000 (12:14 -0400)]
misc: adapts gtksourceview/nit.lang to extern code use

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

11 years agoffi: adds the FFI syntax to the grammar
Alexis Laferrière [Tue, 29 Jan 2013 20:32:59 +0000 (15:32 -0500)]
ffi: adds the FFI syntax to the grammar

The FFI allows the user to write all Nit and foreign code for a Nit module
within the same .nit file.

This syntax will be used by the FFI implementation.

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

11 years agoffi/android: display Nit errors on the system log
Alexis Laferrière [Fri, 27 Apr 2012 18:13:53 +0000 (14:13 -0400)]
ffi/android: display Nit errors on the system log

Redirect low level Nit error messages to the standard logging system
on android.

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

11 years agoclib: uses a macro to manage error printing, allowing customization
Alexis Laferrière [Tue, 29 Jan 2013 19:48:11 +0000 (14:48 -0500)]
clib: uses a macro to manage error printing, allowing customization

This will be used in the Android port to print errors in the standard
logging system.

The variadic macro format used by PRINT_ERROR is not in C89 but it is
in the standard C99.

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

11 years agotests: propose alternate and fixme for base_super_linext_*
Jean Privat [Thu, 31 Jan 2013 13:50:46 +0000 (08:50 -0500)]
tests: propose alternate and fixme for base_super_linext_*

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

11 years agotyping: remove NOT YET IMPLEMENTED in ASuperExpr
Jean Privat [Thu, 31 Jan 2013 13:50:05 +0000 (08:50 -0500)]
typing: remove NOT YET IMPLEMENTED in ASuperExpr

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

11 years agomodel: implements lookup_*_definition with linearization
Jean Privat [Thu, 31 Jan 2013 13:49:31 +0000 (08:49 -0500)]
model: implements lookup_*_definition with linearization

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

11 years agomodel: add linearize_mclasses, linearize_mclassdefs, linearize_mpropdefs
Jean Privat [Thu, 31 Jan 2013 13:48:12 +0000 (08:48 -0500)]
model: add linearize_mclasses, linearize_mclassdefs, linearize_mpropdefs

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

11 years agoPOSet is an AbstractSorter
Jean Privat [Thu, 31 Jan 2013 13:45:42 +0000 (08:45 -0500)]
POSet is an AbstractSorter

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

11 years agolib: make AbstractSorter#compare public
Jean Privat [Thu, 31 Jan 2013 13:45:14 +0000 (08:45 -0500)]
lib: make AbstractSorter#compare public

Moreover, a good fix could be to rename  AbstractSorter to Comparator

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

11 years agotests: force live methods in base_*_variance to helps nitc-g
Jean Privat [Sat, 26 Jan 2013 21:55:21 +0000 (16:55 -0500)]
tests: force live methods in base_*_variance to helps nitc-g

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

11 years agotests: update nitg-s base_attr_gen_alt1
Jean Privat [Sat, 26 Jan 2013 21:10:11 +0000 (16:10 -0500)]
tests: update nitg-s base_attr_gen_alt1

Not sure when this was broken however

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

11 years agonitg: new complier service supercall
Jean Privat [Fri, 25 Jan 2013 20:37:34 +0000 (15:37 -0500)]
nitg: new complier service supercall

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

11 years agomodel: implements lookup_next_definition
Jean Privat [Fri, 25 Jan 2013 19:54:26 +0000 (14:54 -0500)]
model: implements lookup_next_definition

Still static however.

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

11 years agotyping: enable calls on a conflicting local property (with a warning)
Jean Privat [Fri, 25 Jan 2013 18:16:56 +0000 (13:16 -0500)]
typing: enable calls on a conflicting local property (with a warning)

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

11 years agoniti, nitg & rta: use lookup_first_definition
Jean Privat [Fri, 25 Jan 2013 18:15:45 +0000 (13:15 -0500)]
niti, nitg & rta: use lookup_first_definition

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

11 years agomodel: implements lookup_first_definition with a default code
Jean Privat [Fri, 25 Jan 2013 18:14:48 +0000 (13:14 -0500)]
model: implements lookup_first_definition with a default code

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

11 years agomodelbuilder: check inheritance loops
Jean Privat [Fri, 25 Jan 2013 03:09:12 +0000 (22:09 -0500)]
modelbuilder: check inheritance loops

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

11 years agotests: cleanup files from sav/fixme
Jean Privat [Fri, 25 Jan 2013 02:40:05 +0000 (21:40 -0500)]
tests: cleanup files from sav/fixme

Some general fixme are now useless.
Just remove them of move them to the correct place.

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

11 years agotests: fig base_isa_nullable_vt.nit
Jean Privat [Thu, 24 Jan 2013 03:29:51 +0000 (22:29 -0500)]
tests: fig base_isa_nullable_vt.nit

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

11 years agoniti: disable interpretor_type_test
Jean Privat [Thu, 24 Jan 2013 03:23:05 +0000 (22:23 -0500)]
niti: disable interpretor_type_test

some type test are buggy. I do not know why.

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