@@ -2,6 +2,7 @@ use super::{compose::validate_compose, FunctionInfo, ModuleInfo, ShaderStages, T
2
2
use crate :: arena:: UniqueArena ;
3
3
use crate :: {
4
4
arena:: Handle ,
5
+ proc,
5
6
proc:: OverloadSet as _,
6
7
proc:: { IndexableLengthError , ResolveError } ,
7
8
} ;
@@ -198,9 +199,9 @@ impl super::Validator {
198
199
pub ( super ) fn validate_const_expression (
199
200
& self ,
200
201
handle : Handle < crate :: Expression > ,
201
- gctx : crate :: proc:: GlobalCtx ,
202
+ gctx : proc:: GlobalCtx ,
202
203
mod_info : & ModuleInfo ,
203
- global_expr_kind : & crate :: proc:: ExpressionKindTracker ,
204
+ global_expr_kind : & proc:: ExpressionKindTracker ,
204
205
) -> Result < ( ) , ConstExpressionError > {
205
206
use crate :: Expression as E ;
206
207
@@ -243,7 +244,7 @@ impl super::Validator {
243
244
module : & crate :: Module ,
244
245
info : & FunctionInfo ,
245
246
mod_info : & ModuleInfo ,
246
- expr_kind : & crate :: proc:: ExpressionKindTracker ,
247
+ expr_kind : & proc:: ExpressionKindTracker ,
247
248
) -> Result < ShaderStages , ExpressionError > {
248
249
use crate :: { Expression as E , Scalar as Sc , ScalarKind as Sk , TypeInner as Ti } ;
249
250
@@ -293,16 +294,16 @@ impl super::Validator {
293
294
} ?;
294
295
// If we know both the length and the index, we can do the
295
296
// bounds check now.
296
- if let crate :: proc:: IndexableLength :: Known ( known_length) = length {
297
+ if let proc:: IndexableLength :: Known ( known_length) = length {
297
298
if value >= known_length {
298
299
return Err ( ExpressionError :: IndexOutOfBounds ( base, value) ) ;
299
300
}
300
301
}
301
302
}
302
- Err ( crate :: proc:: U32EvalError :: Negative ) => {
303
+ Err ( proc:: U32EvalError :: Negative ) => {
303
304
return Err ( ExpressionError :: NegativeIndex ( base) )
304
305
}
305
- Err ( crate :: proc:: U32EvalError :: NonConst ) => { }
306
+ Err ( proc:: U32EvalError :: NonConst ) => { }
306
307
}
307
308
308
309
ShaderStages :: all ( )
0 commit comments