mirror of
https://github.com/encounter/rust-sdl2.git
synced 2026-07-10 21:18:41 -07:00
Add impl AsRef<SurfaceRef> for SurfaceRef
This commit is contained in:
@@ -37,6 +37,12 @@ pub struct SurfaceRef {
|
||||
_raw: ()
|
||||
}
|
||||
|
||||
impl AsRef<SurfaceRef> for SurfaceRef {
|
||||
fn as_ref(&self) -> &SurfaceRef {
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_surface_ref_size() {
|
||||
// `SurfaceRef` must be 0 bytes.
|
||||
|
||||
Reference in New Issue
Block a user