detect_assignment_op

Function detect_assignment_op 

Source
fn detect_assignment_op(bytes: &[u8], pos: usize) -> Option<(Option<u8>, usize)>
Expand description

Detect an assignment operator starting at byte offset pos in bytes. Returns Some((Some(op_char), after_eq)) for compound assignments (+=, -=, *=, /=), Some((None, after_eq)) for plain =, or None if no recognised assignment op (or == / other comparison) starts here.