1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
use glsl::parser::Parse; use glsl::syntax; #[test] fn incorrect_statement() { let r = syntax::TranslationUnit::parse( " int fetch_transform(int id) { return id; } bool ray_plane() { if 1 { } ", ); assert!(r.is_err()); }