mirror of
https://github.com/mii443/tokenizers.git
synced 2025-08-22 16:25:30 +00:00
Upgrade to PyO3 0.23 (#1708)
* Upgrade to PyO3 0.23 * Macos-12 deprecated? * Clippy. * Clippy auto ellision.
This commit is contained in:
@ -57,7 +57,7 @@ where
|
||||
Ok(serializer.output)
|
||||
}
|
||||
|
||||
impl<'a> ser::Serializer for &'a mut Serializer {
|
||||
impl ser::Serializer for &mut Serializer {
|
||||
// The output type produced by this `Serializer` during successful
|
||||
// serialization. Most serializers that produce text or binary output should
|
||||
// set `Ok = ()` and serialize into an `io::Write` or buffer contained
|
||||
@ -355,7 +355,7 @@ impl<'a> ser::Serializer for &'a mut Serializer {
|
||||
//
|
||||
// This impl is SerializeSeq so these methods are called after `serialize_seq`
|
||||
// is called on the Serializer.
|
||||
impl<'a> ser::SerializeSeq for &'a mut Serializer {
|
||||
impl ser::SerializeSeq for &mut Serializer {
|
||||
// Must match the `Ok` type of the serializer.
|
||||
type Ok = ();
|
||||
// Must match the `Error` type of the serializer.
|
||||
@ -391,7 +391,7 @@ impl<'a> ser::SerializeSeq for &'a mut Serializer {
|
||||
}
|
||||
|
||||
// Same thing but for tuples.
|
||||
impl<'a> ser::SerializeTuple for &'a mut Serializer {
|
||||
impl ser::SerializeTuple for &mut Serializer {
|
||||
type Ok = ();
|
||||
type Error = Error;
|
||||
|
||||
@ -423,7 +423,7 @@ impl<'a> ser::SerializeTuple for &'a mut Serializer {
|
||||
}
|
||||
|
||||
// Same thing but for tuple structs.
|
||||
impl<'a> ser::SerializeTupleStruct for &'a mut Serializer {
|
||||
impl ser::SerializeTupleStruct for &mut Serializer {
|
||||
type Ok = ();
|
||||
type Error = Error;
|
||||
|
||||
@ -463,7 +463,7 @@ impl<'a> ser::SerializeTupleStruct for &'a mut Serializer {
|
||||
//
|
||||
// So the `end` method in this impl is responsible for closing both the `]` and
|
||||
// the `}`.
|
||||
impl<'a> ser::SerializeTupleVariant for &'a mut Serializer {
|
||||
impl ser::SerializeTupleVariant for &mut Serializer {
|
||||
type Ok = ();
|
||||
type Error = Error;
|
||||
|
||||
@ -502,7 +502,7 @@ impl<'a> ser::SerializeTupleVariant for &'a mut Serializer {
|
||||
// `serialize_entry` method allows serializers to optimize for the case where
|
||||
// key and value are both available simultaneously. In JSON it doesn't make a
|
||||
// difference so the default behavior for `serialize_entry` is fine.
|
||||
impl<'a> ser::SerializeMap for &'a mut Serializer {
|
||||
impl ser::SerializeMap for &mut Serializer {
|
||||
type Ok = ();
|
||||
type Error = Error;
|
||||
|
||||
@ -559,7 +559,7 @@ impl<'a> ser::SerializeMap for &'a mut Serializer {
|
||||
|
||||
// Structs are like maps in which the keys are constrained to be compile-time
|
||||
// constant strings.
|
||||
impl<'a> ser::SerializeStruct for &'a mut Serializer {
|
||||
impl ser::SerializeStruct for &mut Serializer {
|
||||
type Ok = ();
|
||||
type Error = Error;
|
||||
|
||||
@ -590,7 +590,7 @@ impl<'a> ser::SerializeStruct for &'a mut Serializer {
|
||||
|
||||
// Similar to `SerializeTupleVariant`, here the `end` method is responsible for
|
||||
// closing both of the curly braces opened by `serialize_struct_variant`.
|
||||
impl<'a> ser::SerializeStructVariant for &'a mut Serializer {
|
||||
impl ser::SerializeStructVariant for &mut Serializer {
|
||||
type Ok = ();
|
||||
type Error = Error;
|
||||
|
||||
|
Reference in New Issue
Block a user