Merge pull request #38 from teloxide/v0.7.0

Release v0.7.0
This commit is contained in:
Hirrolot 2022-10-06 23:48:37 +06:00 committed by GitHub
commit 10cf4fc0e1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 12 additions and 9 deletions

View file

@ -6,14 +6,20 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## unreleased
## 0.7.0 - 2022-10-06
### Removed
- Remove `derive(DialogueState)` macro
- `derive(DialogueState)` macro
### Changed
- `#[command(rename = "...")]` now always renames to `"..."`, to rename multiple commands using the same pattern, use `#[command(rename_rule = "snake_case")]` and the like.
- `#[command(parse_with = ...)]` now requires a path, instead of a string, when specifying custom parsers
- `#[command(rename = "...")]` now always renames to `"..."`; to rename multiple commands using the same pattern, use `#[command(rename_rule = "snake_case")]` and the like.
- `#[command(parse_with = ...)]` now requires a path, instead of a string, when specifying custom parsers.
### Fixed
- `#[derive(BotCommands)]` even if the trait is not imported ([issue #717](https://github.com/teloxide/teloxide/issues/717)).
## 0.6.3 - 2022-07-19

View file

@ -1,9 +1,9 @@
[package]
name = "teloxide-macros"
version = "0.6.3"
version = "0.7.0"
description = "The teloxide's procedural macros"
license = "MIT"
edition = "2018"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

View file

@ -3,7 +3,6 @@ use crate::{
fields_parse::ParserType, rename_rules::RenameRule, Result,
};
#[derive(Debug)]
pub(crate) struct CommandEnum {
pub prefix: String,
pub description: Option<String>,

View file

@ -17,8 +17,6 @@ pub(crate) fn compile_error_at(msg: &str, sp: Span) -> Error {
use proc_macro2::{
Delimiter, Group, Ident, Literal, Punct, Spacing, TokenTree,
};
use std::iter::FromIterator;
// compile_error! { $msg }
let ts = TokenStream::from_iter(vec![
TokenTree::Ident(Ident::new("compile_error", sp)),

View file

@ -3,7 +3,7 @@ use syn::{Fields, FieldsNamed, FieldsUnnamed, Type};
use crate::{attr::AttrValue, error::Result};
#[derive(Debug, Clone)]
#[derive(Clone)]
pub(crate) enum ParserType {
Default,
Split { separator: Option<String> },