all: fix new compiler warnings
This commit is contained in:
parent
c0afc5cf2a
commit
64416d417b
3 changed files with 3 additions and 6 deletions
|
|
@ -71,7 +71,7 @@ unsafe fn with_client<T, F: FnOnce(&Client) -> T>(data: *const u8, f: F) -> T {
|
|||
self.cell.set(self.val);
|
||||
}
|
||||
}
|
||||
CLIENT.with(|cell| unsafe {
|
||||
CLIENT.with(|cell| {
|
||||
let client = data as *const Client;
|
||||
Rc::increment_strong_count(client);
|
||||
let client = Rc::from_raw(client);
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ impl GlTexture {
|
|||
|
||||
#[allow(dead_code)]
|
||||
pub unsafe fn to_framebuffer(self: &Rc<Self>) -> Result<Rc<GlFrameBuffer>, RenderError> {
|
||||
self.ctx.with_current(|| unsafe {
|
||||
self.ctx.with_current(|| {
|
||||
let mut fbo = 0;
|
||||
glGenFramebuffers(1, &mut fbo);
|
||||
glBindFramebuffer(GL_FRAMEBUFFER, fbo);
|
||||
|
|
|
|||
|
|
@ -11,10 +11,7 @@ pub trait WindowsExt<T> {
|
|||
}
|
||||
|
||||
impl<T> WindowsExt<T> for [T] {
|
||||
type Windows<'a, const N: usize>
|
||||
where
|
||||
T: 'a,
|
||||
= WindowsIter<'a, T, N>;
|
||||
type Windows<'a, const N: usize> = WindowsIter<'a, T, N> where T: 'a;
|
||||
|
||||
fn array_windows_ext<'a, const N: usize>(&'a self) -> Self::Windows<'a, N> {
|
||||
WindowsIter { slice: self }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue