Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple applicable items in scope for quarter() #1675

Open
ohardy opened this issue Mar 10, 2025 · 1 comment
Open

Multiple applicable items in scope for quarter() #1675

ohardy opened this issue Mar 10, 2025 · 1 comment

Comments

@ohardy
Copy link

ohardy commented Mar 10, 2025

No error with chrono 0.4.39 and with 0.4.40:

    Checking mongodb v3.2.2
error[E0034]: multiple applicable items in scope
   --> /Users/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/arrow-arith-53.4.0/src/temporal.rs:91:36
    |
91  |         DatePart::Quarter => |d| d.quarter() as i32,
    |                                    ^^^^^^^ multiple `quarter` found
    |
note: candidate #1 is defined in the trait `ChronoDateExt`
   --> /Users/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/arrow-arith-53.4.0/src/temporal.rs:637:5
    |
637 |     fn quarter(&self) -> u32;
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^
note: candidate #2 is defined in the trait `Datelike`
   --> /Users/user/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/chrono-0.4.40/src/traits.rs:47:5
    |
47  |     fn quarter(&self) -> u32 {
    |     ^^^^^^^^^^^^^^^^^^^^^^^^
help: disambiguate the method for candidate #1
    |
91  |         DatePart::Quarter => |d| ChronoDateExt::quarter(&d) as i32,
    |                                  ~~~~~~~~~~~~~~~~~~~~~~~~~~
help: disambiguate the method for candidate #2
    |
91  |         DatePart::Quarter => |d| Datelike::quarter(&d) as i32,
    |                                  ~~~~~~~~~~~~~~~~~~~~~

    Checking arrow-cast v53.4.0
    Checking arrow-ord v53.4.0
    Checking arrow-string v53.4.0
For more information about this error, try `rustc --explain E0034`.
error: could not compile `arrow-arith` (lib) due to 1 previous error
warning: build failed, waiting for other jobs to finish...
@djc
Copy link
Member

djc commented Mar 10, 2025

See the discussion in #1666.

@djc djc changed the title Multiple applicable items in scope Multiple applicable items in scope for quarter() Mar 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants