mirror of
https://github.com/vulkano-rs/vulkano.git
synced 2024-11-29 18:24:26 +00:00
Remove debugging println in tests
This commit is contained in:
parent
f9f014c789
commit
8f76d6f74e
@ -1,4 +1,5 @@
|
|||||||
|
|
||||||
|
/// Parses a SPIR-V document.
|
||||||
pub fn parse_spirv(data: &[u8]) -> Result<Spirv, ParseError> {
|
pub fn parse_spirv(data: &[u8]) -> Result<Spirv, ParseError> {
|
||||||
if data.len() < 20 {
|
if data.len() < 20 {
|
||||||
return Err(ParseError::MissingHeader);
|
return Err(ParseError::MissingHeader);
|
||||||
@ -25,6 +26,9 @@ pub fn parse_spirv(data: &[u8]) -> Result<Spirv, ParseError> {
|
|||||||
parse_u32s(&data)
|
parse_u32s(&data)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Parses a SPIR-V document from a list of u32s.
|
||||||
|
///
|
||||||
|
/// Endianess has already been handled.
|
||||||
fn parse_u32s(i: &[u32]) -> Result<Spirv, ParseError> {
|
fn parse_u32s(i: &[u32]) -> Result<Spirv, ParseError> {
|
||||||
if i.len() < 5 {
|
if i.len() < 5 {
|
||||||
return Err(ParseError::MissingHeader);
|
return Err(ParseError::MissingHeader);
|
||||||
@ -54,6 +58,7 @@ fn parse_u32s(i: &[u32]) -> Result<Spirv, ParseError> {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Error that can happen when parsing.
|
||||||
#[derive(Debug, Clone)]
|
#[derive(Debug, Clone)]
|
||||||
pub enum ParseError {
|
pub enum ParseError {
|
||||||
MissingHeader,
|
MissingHeader,
|
||||||
@ -291,8 +296,6 @@ mod test {
|
|||||||
#[test]
|
#[test]
|
||||||
fn test() {
|
fn test() {
|
||||||
let data = include_bytes!("../tests/frag.spv");
|
let data = include_bytes!("../tests/frag.spv");
|
||||||
let doc = parse::parse_spirv(data).unwrap();
|
parse::parse_spirv(data).unwrap();
|
||||||
|
|
||||||
println!("{:?}", doc);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user