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

fail -> panic #68

Merged
merged 1 commit into from
Oct 30, 2014
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/gl_back_end.rs
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ void main()

fn pick_120_150<T>(glsl: glsl::GLSL, for_120: T, for_150: T) -> T {
match glsl {
glsl::GLSL_1_10 => fail!("GLSL 1.10 not supported"),
glsl::GLSL_1_10 => panic!("GLSL 1.10 not supported"),
glsl::GLSL_1_20
| glsl::GLSL_1_30
| glsl::GLSL_1_40 => for_120,
Expand Down Expand Up @@ -169,14 +169,14 @@ impl XYRGBA {
pick_120_150(glsl, VERTEX_SHADER_XY_RGBA_120, VERTEX_SHADER_XY_RGBA_150_CORE)
) {
Ok(id) => id,
Err(s) => fail!("compile_shader: {}", s)
Err(s) => panic!("compile_shader: {}", s)
};
let fragment_shader = match compile_shader(
gl::FRAGMENT_SHADER, // shader type
pick_120_150(glsl, FRAGMENT_SHADER_XY_RGBA_120, FRAGMENT_SHADER_XY_RGBA_150_CORE)
) {
Ok(id) => id,
Err(s) => fail!("compile_shader: {}", s)
Err(s) => panic!("compile_shader: {}", s)
};
let program = gl::CreateProgram();

Expand Down Expand Up @@ -243,14 +243,14 @@ impl XYRGBAUV {
pick_120_150(glsl, VERTEX_SHADER_XY_RGBA_UV_120, VERTEX_SHADER_XY_RGBA_UV_150_CORE)
) {
Ok(id) => id,
Err(s) => fail!("compile_shader: {}", s)
Err(s) => panic!("compile_shader: {}", s)
};
let fragment_shader = match compile_shader(
gl::FRAGMENT_SHADER, // shader type
pick_120_150(glsl, FRAGMENT_SHADER_XY_RGBA_UV_120, FRAGMENT_SHADER_XY_RGBA_UV_150_CORE)
) {
Ok(id) => id,
Err(s) => fail!("compile_shader: {}", s)
Err(s) => panic!("compile_shader: {}", s)
};

let program = gl::CreateProgram();
Expand Down