Marc Vertes
539f6f1c6f
Handle composite types with sub-types imported from runtime
2018-06-28 14:22:20 +02:00
Marc Vertes
77c015fcb8
Handle type assertions (first attempt)
2018-06-27 14:59:23 +02:00
Marc Vertes
a062e34ba8
Fix map check expression
2018-06-26 18:27:14 +02:00
Marc Vertes
19ca75ae2a
Fix golint error
2018-06-26 14:18:19 +02:00
Marc Vertes
542ccdedf6
Fix type propagation in calls returning multiple values
2018-06-26 13:30:28 +02:00
Marc Vertes
6480e831a1
Fix handling pointers on reflect object as method receiver
2018-06-26 00:08:36 +02:00
Sebastien Binet
476a31322d
Go get ellipsis ( #1 )
...
* gi: rename gi_c into _gi_c
* gi: rename test into _test
* gi: fix README syntax
2018-06-26 10:17:01 +02:00
Sebastien Binet
f9706f970f
interp: use correct GOPATH from go/build.Default ( #2 )
...
This CL uses go/build.Default.GOPATH to infer the correct value for
$GOPATH at build time.
Previously, pkgDir would fail if somebody were to build and test
containous/gi from a different GOPATH location (e.g. GOPATH=/build/go)
2018-06-25 18:29:51 +02:00
Marc Vertes
19fb8d578d
cfg: fix range exit
2018-06-23 14:12:55 +02:00
Marc Vertes
77f28149d9
Fixes for golint & go vet
2018-06-22 19:36:34 +02:00
Marc Vertes
b608e2f3c2
Add support for iota
2018-06-22 02:52:45 +02:00
Marc Vertes
deb1c0136c
Add support to variadic functions
2018-06-21 12:39:50 +02:00
Marc Vertes
75146ed4fc
Fix method receivers handling
2018-06-20 17:30:14 +02:00
Marc Vertes
41bfcfbfb0
minor code cleaning
2018-06-20 10:57:39 +02:00
Marc Vertes
cf0ee1e75c
Fix assign outside of local scope. Support append (1 item only)
2018-06-20 10:03:20 +02:00
Marc Vertes
71c4ec10b2
Improve type handling, simplify arrays
2018-06-19 16:40:24 +02:00
Marc Vertes
9d1fe83dcd
Add support for slice expressions
2018-06-14 00:00:31 +02:00
Marc Vertes
b4c6624f3c
Do not export private AST node fields
2018-06-13 15:42:01 +02:00
Marc Vertes
24fe12afc3
handle method declaration with no receiver variable name
2018-06-13 11:18:48 +02:00
Marc Vertes
356b614f0f
update tests
2018-06-07 15:15:12 +02:00
Marc Vertes
ed13240362
source import: use alternate path
2018-06-07 14:32:20 +02:00
Marc Vertes
0421c732d1
source imports: use vendoring by default
2018-06-07 14:10:10 +02:00
Marc Vertes
912a37be7b
Add support to import source packages
2018-06-07 12:03:18 +02:00
Marc Vertes
e7b21fb31f
preliminary work to support interfaces and type assertion
2018-06-06 10:32:16 +02:00
Marc Vertes
cceaf1b832
Fix invocation of runtime interface methods (preliminary attempt)
2018-06-05 15:18:33 +02:00
Marc Vertes
7fe7872a4c
use 'dot -Txlib' instead of 'dotty' to display graphs
2018-05-31 16:19:05 +02:00
Marc Vertes
6ad67bdea2
Add BuiltinT type for go builtin operations: new, make, println, ...
2018-05-31 15:36:11 +02:00
Marc Vertes
9fd9ec44ff
Allow direct call of runtime functions passed as argument to script
2018-05-30 13:33:32 +02:00
Marc Vertes
0ffb8077ca
Comment out plugin example
2018-05-30 09:26:58 +02:00
Marc Vertes
f9805e21f7
Fix reflection type conversion for exports. Sample plugin example.
2018-05-30 09:13:02 +02:00
Marc Vertes
755f53ceae
Fix handling methods on runtime struct fields
2018-05-29 22:28:18 +02:00
Marc Vertes
9537e89abe
update tests
2018-05-28 17:43:31 +02:00
Marc Vertes
19856117f6
Fix regression on exported functions
2018-05-28 17:42:24 +02:00
Marc Vertes
9064f91264
Improve types, pointers and methods. Add several tests.
2018-05-25 19:32:06 +02:00
Marc Vertes
afb0f45bd7
Fix exports to pass govet and golint
2018-05-21 18:21:18 +02:00
Marc Vertes
910b86e3d9
Fix handling of reflect values. Add math test
2018-05-19 10:21:37 +02:00
Marc Vertes
7284edd7c8
Reformat tests. No functional change.
2018-05-18 17:52:22 +02:00
Marc Vertes
62da45a792
Appease vet and lint gods
2018-05-18 16:43:44 +02:00
Marc Vertes
13a46857a5
Fix types zero values and exports as generic interfaces
2018-05-17 16:15:30 +02:00
Marc Vertes
00ad9cc2ce
improve interpreter init. Allow re-entrant Eval()
2018-05-17 13:33:17 +02:00
Marc Vertes
82c93bb780
Add support to init function. Better handling of entry point.
2018-05-16 15:35:13 +02:00
Marc Vertes
a17ffff644
wrapNode: handle return values
2018-05-12 15:38:16 +02:00
Marc Vertes
583acadf8b
Allow runtime to call intrepreted functions
...
A function in the interpreter can now be wrapped into a reflect
generated func, to be callable by runtime (pre-compiled code).
As an example, see test/server.go, a complete http server with
scripts callbacks.
2018-05-11 19:47:21 +02:00
Marc Vertes
a9af4de31d
AST: transform multi assignement into several single assigns
2018-05-08 17:52:43 +02:00
Marc Vertes
f50a028d55
ast: transform multi assign statement into single ones
2018-05-04 10:51:23 +02:00
Marc Vertes
4f726d1d97
Support incremeting dereferenced pointers
2018-05-01 12:28:55 +02:00
Marc Vertes
cf2a86678d
Fix indirect assign for pointers
2018-04-30 18:15:18 +02:00
Marc Vertes
3e159d482d
add support for pointers
2018-04-30 13:52:28 +02:00
Marc Vertes
cf20464ec3
Fix a bug in 'for range' processing
2018-04-30 11:13:37 +02:00
Marc Vertes
67c2171574
remove spurious swap file
2018-04-29 17:29:31 +02:00