keccak.h 924 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. #pragma once
  2. /**
  3. * @brief Solana keccak system call
  4. **/
  5. #include <sol/types.h>
  6. #ifdef __cplusplus
  7. extern "C" {
  8. #endif
  9. /**
  10. * Length of a Keccak hash result
  11. */
  12. #define KECCAK_RESULT_LENGTH 32
  13. /**
  14. * Keccak
  15. *
  16. * @param bytes Array of byte arrays
  17. * @param bytes_len Number of byte arrays
  18. * @param result 32 byte array to hold the result
  19. */
  20. /* DO NOT MODIFY THIS GENERATED FILE. INSTEAD CHANGE platform-tools-sdk/sbf/c/inc/sol/inc/keccak.inc AND RUN `cargo run --bin gen-headers` */
  21. #ifndef SOL_SBFV2
  22. uint64_t sol_keccak256(const SolBytes *, int, uint8_t *);
  23. #else
  24. typedef uint64_t(*sol_keccak256_pointer_type)(const SolBytes *, int, uint8_t *);
  25. static uint64_t sol_keccak256(const SolBytes * arg1, int arg2, uint8_t * arg3) {
  26. sol_keccak256_pointer_type sol_keccak256_pointer = (sol_keccak256_pointer_type) 3615046331;
  27. return sol_keccak256_pointer(arg1, arg2, arg3);
  28. }
  29. #endif
  30. #ifdef __cplusplus
  31. }
  32. #endif
  33. /**@}*/