@@ -29,34 +29,19 @@ macro_rules! co {
2929 $crate:: coroutine:: Coroutine :: new( $name, $f, $size, $priority)
3030 } ;
3131 ( $f: expr, $size: literal, $priority: literal $( , ) ?) => {
32- $crate:: coroutine:: Coroutine :: new(
33- uuid:: Uuid :: new_v4( ) . to_string( ) ,
34- $f,
35- $size,
36- Some ( $priority) ,
37- )
32+ $crate:: coroutine:: Coroutine :: new( None , $f, $size, Some ( $priority) )
3833 } ;
3934 ( $name: expr, $f: expr, $size: expr $( , ) ?) => {
4035 $crate:: coroutine:: Coroutine :: new( $name, $f, $size, None )
4136 } ;
4237 ( $f: expr, $size: literal $( , ) ?) => {
43- $crate:: coroutine:: Coroutine :: new( uuid :: Uuid :: new_v4 ( ) . to_string ( ) , $f, $size, None )
38+ $crate:: coroutine:: Coroutine :: new( None , $f, $size, None )
4439 } ;
4540 ( $name: expr, $f: expr $( , ) ?) => {
46- $crate:: coroutine:: Coroutine :: new(
47- $name,
48- $f,
49- $crate:: common:: constants:: DEFAULT_STACK_SIZE ,
50- None ,
51- )
41+ $crate:: coroutine:: Coroutine :: new( $name, $f, None , None )
5242 } ;
5343 ( $f: expr $( , ) ?) => {
54- $crate:: coroutine:: Coroutine :: new(
55- uuid:: Uuid :: new_v4( ) . to_string( ) ,
56- $f,
57- $crate:: common:: constants:: DEFAULT_STACK_SIZE ,
58- None ,
59- )
44+ $crate:: coroutine:: Coroutine :: new( None , $f, None , None )
6045 } ;
6146}
6247
0 commit comments