Skip to content

Commit

Permalink
AML: Allow Field in ToInteger (rebased) (#213)
Browse files Browse the repository at this point in the history
  • Loading branch information
rw-vanc authored Apr 13, 2024
1 parent 35f9fba commit 4390f04
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions aml/src/expression.rs
Original file line number Diff line number Diff line change
Expand Up @@ -812,6 +812,9 @@ where
AmlValue::Buffer(data) => {
AmlValue::Integer(try_with_context!(context, AmlValue::Buffer(data).as_integer(context)))
}
AmlValue::Field { .. } => {
AmlValue::Integer(try_with_context!(context, operand.as_integer(context)))
}
AmlValue::String(string) => AmlValue::Integer(try_with_context!(
context,
if string.starts_with("0x") {
Expand Down

0 comments on commit 4390f04

Please sign in to comment.