tailhook / quick-error

A rust-macro which makes errors easy to write

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

error: recursion limit reached while expanding the macro `quick_error`

brson opened this issue · comments

<rustup_error macros>:54:1: 59:29 error: recursion limit reached while expanding the macro `quick_error`
<rustup_error macros>:54 quick_error ! (
<rustup_error macros>:55 SORT [ $ ( $ def ) * ] items [
<rustup_error macros>:56 $ (
<rustup_error macros>:57 $ ( # [ $ imeta ] ) * => $ iitem : $ imode [ $ ( $ ivar : $ ityp ) , * ] {
<rustup_error macros>:58 $ ( $ ifuncs ) * } ) * ] buf [ $ ( # [ $ bmeta ] ) * => $ qitem : UNIT [  ] ]
<rustup_error macros>:59 queue [ $ ( $ tail ) * ] ) ; } ; (
error: Could not compile `rustup-utils`.
quick_error! {
    #[derive(Debug)]
    pub enum Error2 {
        LocatingHome {
        }
        LocatingWorkingDir {
            error: io::Error,
        } {
        }
        ReadingFile {
            name: &'static str,
            path: PathBuf,
            error: io::Error,
        } {
        }
        ReadingDirectory {
            name: &'static str,
            path: PathBuf,
            error: io::Error,
        } {
        }
        WritingFile {
            name: &'static str,
            path: PathBuf,
            error: io::Error,
        } {
        }
        CreatingDirectory {
            name: &'static str,
            path: PathBuf,
            error: io::Error,
        } {
        }
        FilteringFile {
            name: &'static str,
            src: PathBuf,
            dest: PathBuf,
            error: io::Error,
        } {
        }
        RenamingFile {
            name: &'static str,
            src: PathBuf,
            dest: PathBuf,
            error: io::Error,
        } {
        }
        RenamingDirectory {
            name: &'static str,
            src: PathBuf,
            dest: PathBuf,
            error: io::Error,
        } {
        }
        DownloadingFile {
            url: hyper::Url,
            path: PathBuf,
            error: raw::DownloadError,
        } {
        }
        InvalidUrl {
            url: String,
        } {
        }
        RunningCommand {
            name: OsString,
            error: raw::CommandError,
        } {
        }
        NotAFile {
            path: PathBuf,
        } {
        }
        NotADirectory {
            path: PathBuf,
        } {
        }
        LinkingFile {
            src: PathBuf,
            dest: PathBuf,
            error: io::Error,
        } {
        }
        LinkingDirectory {
            src: PathBuf,
            dest: PathBuf,
            error: io::Error,
        } {
        }
        CopyingDirectory {
            src: PathBuf,
            dest: PathBuf,
            error: raw::CommandError,
        } {
        }
        CopyingFile {
            src: PathBuf,
            dest: PathBuf,
            error: io::Error,
        } {
        }
        RemovingFile {
            name: &'static str,
            path: PathBuf,
            error: io::Error,
        } {
        }
        RemovingDirectory {
            name: &'static str,
            path: PathBuf,
            error: io::Error,
        } {
        }
        OpeningBrowser {
            error: Option<io::Error>,
        } {
        }
        SettingPermissions {
            path: PathBuf,
            error: io::Error,
        } {
        }
        CargoHome {
        }
        MultirustHome {
        }
    }
}

This can be worked around with #!recursion_limit].

There's nothing that can be done. I don't think it's a bug.