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

Remove some feature gates #367

Merged
merged 3 commits into from
Apr 3, 2015
Merged

Remove some feature gates #367

merged 3 commits into from
Apr 3, 2015

Conversation

tomaka
Copy link
Contributor

@tomaka tomaka commented Apr 3, 2015

Remaining features:

  • core: 154 compilation errors when I remove this one. Probably fixable, but that's a lot of work.
  • std_misc: several small things. Probably fixable too but I don't have time right now.
  • step_by: feature-gated function because added recently. Need to check what the plan is for this one. If it's not getting stable, it is possible to write a replacement.
  • rustc_private: used for the flate library. There is a replacement flate2 on crates.io, however it's just bindings for miniz.c, which would force users to have a C compiler installed. I don't like this. Probably the most problematic feature.
  • test: not sure how to have access to the bencher without this one.

} else {
return Err(::image::ImageError::UnsupportedError(format!(
"{:?} with {:?} bits per sample is unsupported", self.bits_per_sample, self.photometric_interpretation
))) // TODO: this is bad we should not fail at this point}
}
}

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to rewrite this as a match?

PhotometricInterpretation::RGB if self.bits_per_sample == [8, 8, 8, 8] => ...

it is super unintuitive like this

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@nwin
Copy link
Contributor

nwin commented Apr 3, 2015

Great

nwin added a commit that referenced this pull request Apr 3, 2015
Remove some feature gates
@nwin nwin merged commit 3b70146 into image-rs:master Apr 3, 2015
@tomaka tomaka deleted the rustup branch April 3, 2015 12:12
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

Successfully merging this pull request may close these issues.

2 participants