@@ -857,7 +857,7 @@ impl dyn Error + Send + Sync {
857857/// ```
858858#[ unstable( feature = "error_reporter" , issue = "90172" ) ]
859859pub struct Report < E > {
860- source : E ,
860+ error : E ,
861861 show_backtrace : bool ,
862862 pretty : bool ,
863863}
@@ -868,8 +868,8 @@ where
868868{
869869 /// Create a new `Report` from an input error.
870870 #[ unstable( feature = "error_reporter" , issue = "90172" ) ]
871- pub fn new ( source : E ) -> Report < E > {
872- Report { source , show_backtrace : false , pretty : false }
871+ pub fn new ( error : E ) -> Report < E > {
872+ Report { error , show_backtrace : false , pretty : false }
873873 }
874874
875875 /// Enable pretty-printing the report.
@@ -889,9 +889,9 @@ where
889889 /// Format the report as a single line.
890890 #[ unstable( feature = "error_reporter" , issue = "90172" ) ]
891891 fn fmt_singleline ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
892- write ! ( f, "{}" , self . source ) ?;
892+ write ! ( f, "{}" , self . error ) ?;
893893
894- let sources = self . source . source ( ) . into_iter ( ) . flat_map ( <dyn Error >:: chain) ;
894+ let sources = self . error . source ( ) . into_iter ( ) . flat_map ( <dyn Error >:: chain) ;
895895
896896 for cause in sources {
897897 write ! ( f, ": {}" , cause) ?;
@@ -903,7 +903,7 @@ where
903903 /// Format the report as multiple lines, with each error cause on its own line.
904904 #[ unstable( feature = "error_reporter" , issue = "90172" ) ]
905905 fn fmt_multiline ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
906- let error = & self . source ;
906+ let error = & self . error ;
907907
908908 write ! ( f, "{}" , error) ?;
909909
@@ -950,8 +950,8 @@ impl<E> From<E> for Report<E>
950950where
951951 E : Error ,
952952{
953- fn from ( source : E ) -> Self {
954- Report :: new ( source )
953+ fn from ( error : E ) -> Self {
954+ Report :: new ( error )
955955 }
956956}
957957
0 commit comments