1. Sep 15, 2021
    • David's avatar
      Rename and reorg types (#462) · 635142e3
      David authored
      * Renames
      
      * More renames
      
      * fmt
      
      * s/RpcParams/Params/
      
      * Add a type alias `SubscriptionResponse` to `Notification` which is parametrized to `SubscriptionPayload`
      Move `SubscriptionResponse` to the `response` module
      
      * Fix doc links
      
      * Cleanup and some docs
      
      * Review feedback
      
      * cleanup
      635142e3
  2. Sep 11, 2021
  3. Sep 09, 2021
  4. Sep 08, 2021
  5. Sep 01, 2021
    • Niklas Adolfsson's avatar
      feat: alias attribute for proc macros (#442) · 3ad1cc21
      Niklas Adolfsson authored
      
      
      * feat: alias attribute for proc macros
      
      * implement David's suggested no more unsub field
      
      * keep aliases outside namespace
      
      * revert example
      
      * fix build
      
      * Update proc-macros/src/attributes.rs
      
      Co-authored-by: default avatarDavid <[email protected]>
      
      * grumbles: alias -> aliases
      
      * grumbles v2: alias -> aliases
      
      Co-authored-by: default avatarDavid <[email protected]>
      3ad1cc21
    • Niklas Adolfsson's avatar
      Make it possible to treat empty JSON response as no params (#446) · bf211cb2
      Niklas Adolfsson authored
      
      
      * treat empty json as no params when optional
      
      * add test with nested array brackets
      
      * address grumbles: better tests
      
      * Update types/src/v2/params.rs
      
      Co-authored-by: default avatarDavid <[email protected]>
      
      * introduce RpcParams::sequence_ignore_empty
      
      * address grumbles: ignore empty json in RpcParams
      
      * Update proc-macros/src/render_server.rs
      
      * address grumbles: remove trim in next_inner()
      
      * address grumbles: trim_start after params.next()
      
      * address more grumbles
      
      * [proc macros]: add test for empty array
      
      * make proc macro kind of work
      
      * add hack to make it work in proc macros
      
      * add hack to make it work in proc macros
      
      * [] ->
      
      * revert cerebral palsy
      
      * Update proc-macros/tests/ui/correct/basic.rs
      
      * Update proc-macros/tests/ui/correct/basic.rs
      
      * address grumbles
      
      * improve is_option
      
      * add test for core::option::Option
      
      Co-authored-by: default avatarDavid <[email protected]>
      bf211cb2
  6. Aug 27, 2021
    • Niklas Adolfsson's avatar
      [proc macros]: support generic type params (#436) · 1045c785
      Niklas Adolfsson authored
      
      
      * PoC support generic type params
      
      * more annoying example
      
      * add trait bounds for generic params in proc macros
      
      * add compile-time test for complicated trait
      
      * smarter trait bounds in proc macros
      
      * add non-working example for now
      
      * revert nits
      
      * Update examples/proc_macro.rs
      
      Co-authored-by: default avatarDavid <[email protected]>
      
      * Update proc-macros/src/helpers.rs
      
      Co-authored-by: default avatarDavid <[email protected]>
      
      * add messy code but works
      
      * cleanup
      
      * add some simple compile check in tests
      
      * fix doc link
      
      * fix doc link last time
      
      * address grumbles
      
      * docs
      
      * Update proc-macros/src/helpers.rs
      
      * Update proc-macros/src/helpers.rs
      
      * Update proc-macros/src/helpers.rs
      
      * Update proc-macros/src/helpers.rs
      
      * Update proc-macros/src/visitor.rs
      
      * fix nit: | -> ||
      
      * Update proc-macros/src/helpers.rs
      
      Co-authored-by: default avatarDavid <[email protected]>
      
      * Update proc-macros/src/helpers.rs
      
      Co-authored-by: default avatarDavid <[email protected]>
      
      * Update proc-macros/src/helpers.rs
      
      Co-authored-by: default avatarDavid <[email protected]>
      
      * add issues to introduced TODOs
      
      * generics support where clause on trait
      
      * Update proc-macros/src/helpers.rs
      
      Co-authored-by: default avatarDavid <[email protected]>
      
      * Update proc-macros/src/helpers.rs
      
      * address grumbles
      
      * add more docs
      
      Co-authored-by: default avatarDavid <[email protected]>
      1045c785
  7. Aug 25, 2021
  8. Aug 13, 2021
  9. Jul 12, 2021
  10. Jul 01, 2021
    • Igor Aleksanov's avatar
      New proc macro (#387) · ddb50806
      Igor Aleksanov authored
      
      
      * Start working on the new proc macro system
      
      * Add skeleton for rendering
      
      * Improve error reporting
      
      * Main part of 'render_client'
      
      * Implement RPC client generation
      
      * Client successfully rendered
      
      * Add doc-comment generation for the API client
      
      * Check that all the methods have receiver
      
      * Start working on the server impl
      
      * Add helper method to find server crate
      
      * Fix usage of client rpc path
      
      * Decent progress on the server macro implementation
      
      * Server macro compiled successfully
      
      * Remove unneeded re-export
      
      * Insert SubscriptionSink argument to the subscription server signatures
      
      * Add basic doc-comment for the macro
      
      * no_run -> ignore
      
      * Trait with subscription compiles
      
      * Extend the example
      
      * Add integration test for client/server impl
      
      * Add trybuild setup
      
      * Set correct span for attribute parsing related errors
      
      * Add basic set of trybuild tests
      
      * Add tests for client and server generated separately
      
      * Improve proc-macro documentation
      
      * Update proc-macros/src/lib.rs
      
      Co-authored-by: default avatarNiklas Adolfsson <[email protected]>
      
      * Fix a couple of bugs in docs
      
      * Fix rendering subscription with params
      
      Co-authored-by: default avatarNiklas Adolfsson <[email protected]>
      ddb50806