Skip to content

core fails to build for 16-bit pointer targets after #162879 #163158

Description

@joseluis

core fails to compile for AVR (target_pointer_width = "16") starting with nightly-2026-09-20.

Regression range:

  • nightly-2026-09-19: works
  • nightly-2026-09-20: fails

I am building for avr-none / ATmega328P with -Zbuild-std=core.

The failure is:

error[E0432]: unresolved imports `crate::num::imp::bignum::Big`, `crate::num::imp::bignum::Digit`
  --> library/core/src/num/imp/flt2dec/strategy/dragon.rs:12:31
   |
12 | use crate::num::imp::bignum::{Big, Digit};
   |                               ^^^  ^^^^^ no `Digit` in `num::imp::bignum`
   |                               |
   |                               no `Big` in `num::imp::bignum`

followed by errors such as:

error[E0425]: cannot find value `POW5TO16` in this scope

This appears to have been introduced by #162879.

That PR changed dragon.rs from using the 32-bit implementation directly:

use crate::num::imp::bignum::{Big32x40 as Big, Digit32 as Digit};

to using aliases selected by pointer width:

use crate::num::imp::bignum::{Big, Digit};

but those aliases, the bignum implementations, and the POW5TO* tables are only defined for:

#[cfg(target_pointer_width = "32")]
#[cfg(target_pointer_width = "64")]

so nothing is selected for target_pointer_width = "16".

Before #162879, AVR successfully used the Big32x40 implementation, so using that path for 16-bit pointer targets may be enough to fix it.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: This is a bug.O-AVRTarget: AVR processors (ATtiny, ATmega, etc.)T-libsRelevant to the library team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions