2023-01-18 21:42:49 +11:00
# Parser
This package contains the static analyser used for parsing Wails projects so that we may:
- Generate the bindings for the frontend
- Generate Typescript definitions for the structs used by the bindings
## Implemented
2023-02-25 09:47:50 +11:00
- [ ] Bound types
- [x] Struct Literal Pointer
- [ ] Variable
- [ ] Assignment
- [x] Struct Literal Pointer
- [ ] Function
2023-02-25 12:46:26 -08:00
- [ ] Same package
- [ ] Different package
2023-02-25 09:47:50 +11:00
- [ ] Function
- [x] Parsing of bound methods
2023-02-20 20:36:58 +11:00
- [x] Method names
2023-02-25 09:47:50 +11:00
- [x] Method parameters
2023-02-20 20:36:58 +11:00
- [x] Zero parameters
- [x] Single input parameter
- [x] Single output parameter
- [x] Multiple input parameters
- [x] Multiple output parameters
- [x] Named output parameters
2023-02-21 07:52:29 +11:00
- [x] int/8/16/32/64
- [x] Pointer
- [x] uint/8/16/32/64
2023-02-20 20:36:58 +11:00
- [x] Pointer
- [x] float
2023-02-21 07:52:29 +11:00
- [x] Pointer
2023-02-20 20:36:58 +11:00
- [x] string
2023-02-21 07:52:29 +11:00
- [x] Pointer
2023-02-20 20:36:58 +11:00
- [x] bool
2023-02-21 07:52:29 +11:00
- [x] Pointer
2023-02-25 09:47:50 +11:00
- [x] Struct
2023-02-20 20:36:58 +11:00
- [x] Pointer
2023-02-21 07:52:29 +11:00
- [x] Slices
- [x] Pointer
2023-02-20 20:36:58 +11:00
- [x] Maps
2023-02-21 07:52:29 +11:00
- [x] Pointer
2023-02-25 09:47:50 +11:00
- [x] Model Parsing
2023-02-20 20:36:58 +11:00
- [x] In same package
2023-02-25 09:47:50 +11:00
- [x] In different package
- [x] Multiple named fields, e.g. one,two,three string
- [x] Scalars
- [x] Arrays
- [x] Maps
- [x] Structs
- [x] Recursive
- [x] Anonymous
2023-02-20 20:36:58 +11:00
- [ ] Generation of models
2023-03-22 13:15:14 -07:00
- [x] Scalars
2023-02-20 20:36:58 +11:00
- [ ] Arrays
- [ ] Maps
2023-03-22 13:15:14 -07:00
- [x] Structs
2023-01-18 21:42:49 +11:00
- [ ] Generation of bindings
2023-12-12 21:51:40 +11:00
- [ ] Classes
- [ ] Interfaces
- [ ] Enums
2023-01-18 21:42:49 +11:00
## Limitations
2023-02-25 09:47:50 +11:00
There are many ways to write a Go program so there are many program structures that we would need to support. This is a work in progress and will be improved over time. The current limitations are:
2023-01-18 21:42:49 +11:00
- The call to `application.New()` must be in the `main` package
- Bound structs must be declared as struct literals