Skip to content

Commit

Permalink
Better default value for the big_endian parameter
Browse files Browse the repository at this point in the history
Signed-off-by: Manuel Saelices <[email protected]>
  • Loading branch information
msaelices committed Jan 30, 2025
1 parent 399b460 commit 5852cb9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions stdlib/src/builtin/simd.mojo
Original file line number Diff line number Diff line change
Expand Up @@ -1961,7 +1961,7 @@ struct SIMD[type: DType, size: Int](

@staticmethod
fn from_bytes[
big_endian: Bool = False
big_endian: Bool = is_big_endian()
](bytes: InlineArray[Byte, Self.type_len]) -> Scalar[type]:
"""Converts a byte array to an scalar integer.
Expand All @@ -1987,7 +1987,7 @@ struct SIMD[type: DType, size: Int](
return value

fn as_bytes[
big_endian: Bool = False
big_endian: Bool = is_big_endian()
](self) -> InlineArray[Byte, Self.type_len]:
"""Convert the scalar integer to a byte array.
Expand Down

0 comments on commit 5852cb9

Please sign in to comment.