Skip to content

Add Local Flags #1608

@ranjitjhala

Description

@ranjitjhala

The current "-Finclude=" cannot be used with the FLUXFLAGS because that pattern is passed to ALL the crates, including the extern crates like flux-core, which means we get errors like the below whenever any code uses those operations (i.e. everywhere!)

error[E0999]: use of struct `std::ops::Range` that was not included when checking external crate
  --> crypto-playground/src/utils.rs:9:9
   |
 9 |     dst[0..n].copy_from_slice(&src[0..n]);
   |         ^^^^
   |
help: when checking external crate, include the file or module where the excluded item is defined
  --> /Users/rjhala/.rustup/toolchains/nightly-2025-11-25-aarch64-apple-darwin/lib/rustlib/src/rust/library/core/src/ops/range.rs:82:12
   |
82 | pub struct Range<Idx> {
   |            ^^^^^

error[E0999]: use of trait `std::clone::Clone` that was not included when checking external crate
   --> crypto-playground/src/utils.rs:13:1
    |
 13 | pub fn ms_memset<T: std::clone::Clone>(dst: &mut [T], c: T, n: usize) {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |

Following the discussion here #dev > Strange "not included" errors we should have a FLUXLOCALFLAGS which are ONLY passed to all targets in the current invocation, so if we have multiple "local" crates or packages use the FLUXLOCALFLAGS ONLY when checking those local packages.

Metadata

Metadata

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions