Expand description
Shared parsing utilities for server-less proc macros.
This crate provides common types and functions for extracting method information from impl blocks.
Structs§
- Method
Info - Parsed information about a method
- Param
Info - Parsed parameter information
- Return
Info - Parsed return type information
Enums§
- Param
Location - Parameter location for HTTP requests
Functions§
- extract_
docs - Extract doc comments from attributes
- extract_
methods - Extract all methods from an impl block
- extract_
option_ type - Check if a type is
Option<T>and extract T - extract_
result_ types - Check if a type is Result<T, E> and extract T and E
- extract_
stream_ item - Check if a type is impl Stream<Item=T> and extract T
- get_
impl_ name - Get the struct name from an impl block
- is_
id_ param - Check if a parameter name looks like an ID
- is_
option_ type - Check if a type is
Option<T> - is_
unit_ type - Check if a type is ()
- parse_
param_ attrs - Parse #[param(…)] attributes from a parameter
- parse_
params - Parse function parameters (excluding self)
- parse_
return_ type - Parse return type information