-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from harmony-one/fix_parameter_problems
Fix parameter problems
- Loading branch information
Showing
4 changed files
with
61 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,26 @@ | ||
%{ | ||
#include <stdint.h> | ||
#include <cstdint> | ||
%} | ||
|
||
typedef unsigned char uint8_t; | ||
typedef signed char int8_t; | ||
typedef unsigned short uint16_t; | ||
typedef signed short int16_t; | ||
typedef unsigned int uint32_t; | ||
typedef signed int int32_t; | ||
typedef unsigned long uint64_t; | ||
typedef signed long int64_t; | ||
%include "stdint.i" | ||
|
||
namespace std { | ||
using uint8_t = ::uint8_t; | ||
using int8_t = ::int8_t; | ||
using uint16_t = ::uint16_t; | ||
using int16_t = ::int16_t; | ||
using uint32_t = ::uint32_t; | ||
using int32_t = ::int32_t; | ||
using uint64_t = ::uint64_t; | ||
using int64_t = ::int64_t; | ||
} | ||
|
||
%typemap(gotype) uint8_t, uint8_t const, uint8_t const &, std::uint8_t, std::uint8_t const, std::uint8_t const & "uint8" | ||
%typemap(gotype) int8_t, int8_t const, int8_t const &, std::int8_t, std::int8_t const, std::int8_t const & "int8" | ||
%typemap(gotype) uint16_t, uint16_t const, uint16_t const &, std::uint16_t, std::uint16_t const, std::uint16_t const & "uint16" | ||
%typemap(gotype) int16_t, int16_t const, int16_t const &, std::int16_t, std::int16_t const, std::int16_t const & "int16" | ||
%typemap(gotype) uint32_t, uint32_t const, uint32_t const &, std::uint32_t, std::uint32_t const, std::uint32_t const & "uint32" | ||
%typemap(gotype) int32_t, int32_t const, int32_t const &, std::int32_t, std::int32_t const, std::int32_t const & "int32" | ||
%typemap(gotype) uint64_t, uint64_t const, uint64_t const &, std::uint64_t, std::uint64_t const, std::uint64_t const & "uint64" | ||
%typemap(gotype) int64_t, int64_t const, int64_t const &, std::int64_t, std::int64_t const, std::int64_t const & "int64" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters