Commit Graph

18 Commits

Author SHA1 Message Date
Pat Hickey
6e3ec6a96d Minor refactors to make wiggle-generate reusable externally (#34)
* wiggle-generate: pass witx doc in explicitly

* wiggle-generate: Names takes &Config, minor refactor for reuse
2020-03-06 16:55:05 -08:00
Jakub Konka
16fe947e65 Make generated modules public
While public might be an overkill, until we successfully merge
`wiggle` with `wasi-common` (and others), I suggest we just make
the modules fully public and work from there.
2020-02-28 21:49:08 +01:00
Pat Hickey
bb6995ceaf make wiggle-generate ordinary lib, and wiggle the proc-macro lib
this allows us to reuse the code in wiggle-generate elsewhere, because
a proc-macro=true lib can only export a #[proc_macro] and not ordinary
functions.

In lucet, I will depend on wiggle-generate to define a proc macro that
glues wiggle to the specifics of the runtime.
2020-02-28 11:43:43 -08:00
Pat Hickey
10dcaeeab4 factor lifetime determination into its own module 2020-02-27 11:21:40 +01:00
Pat Hickey
29c3ef9d09 we now parse witx paths and the ctx type name in the macro invocation 2020-01-30 16:38:16 -08:00
Pat Hickey
0ba8e73184 change proc macro argument parsing to use syn 2020-01-30 14:29:53 -08:00
Pat Hickey
373560b88a and now funcs work again 2020-01-27 20:28:27 -08:00
Pat Hickey
ec456e9e50 new memory model. not quite complete 2020-01-27 18:20:47 -08:00
Pat Hickey
b4f21752b0 generate a module trait and call it 2020-01-23 12:53:10 -08:00
Pat Hickey
cb24fd97c0 better error trait design 2020-01-23 11:21:04 -08:00
Pat Hickey
c05475b806 generate: now we have a way to do errors, i guess 2020-01-22 20:47:40 -08:00
Pat Hickey
b8feffe6e1 funcs get abi type definitions 2020-01-20 15:10:11 -08:00
Pat Hickey
9291495e57 put names all in one place. some stub code for funcs! 2020-01-19 19:33:41 -08:00
Pat Hickey
cd686915aa clear out a bunch of old code, reorganize 2020-01-19 18:46:16 -08:00
Pat Hickey
4c7b3e8685 import some other helpers from pat's crate
* parse the proc macro argument into a file path
* use a much simpler witx spec by default
2020-01-17 15:48:51 -08:00
Jakub Konka
f24b0240ae Start tweaking original wig with Pat's suggestion 2020-01-17 19:30:37 +01:00
Jakub Konka
64f0793388 Fix incorrect hardcoded path to witx spec 2020-01-17 14:59:51 +01:00
Jakub Konka
6f6c6499c6 Set up machinery 2020-01-17 14:54:05 +01:00