Almost all macro functions to provide ease of use, using go2hx code in a Haxe manner.
Static variables
staticrecover_exception:AnyInterface = null
Where the recover_exception is stored in case recover
is called.
Static methods
staticasInterface(expr:Dynamic):Dynamic
Create a simulated Go interface in Haxe, check if type with suffix _asInterface exists, and if so generate the type on the fly.
Parameters:
expr |
---|
Returns:
Expr
staticexpectedValue(value:Dynamic):Dynamic
Used in rare cases where Go compiler does not give type information for a type or is not possible and the job is handed off to the Haxe compiler.
Parameters:
value |
---|
Returns:
Expr
staticpointer(expr:Dynamic, hasSet:Dynamic):Dynamic
Create a simulated Go pointer in Haxe
Parameters:
expr | |
---|---|
hasSet |
Returns:
Expr
staticsetRef(expr:Dynamic):Dynamic
Create a Ref (simulated Go pointer but for a Haxe type that is pass by ref) regardless if the type is null or not.
Parameters:
expr |
---|
Returns:
Expr
statictoInterface(expr:Dynamic):Dynamic
Create a simulated any/interface{} type
Parameters:
expr |
---|
Returns:
Expr stdgo.AnyInterface
statictypeAssert(expr:Dynamic):Dynamic
Assert that a type is the checkType complexType, if not throw.
Parameters:
expr | must follow the format ($expr: $ct) |
---|
Returns:
Expr
statictypeEquals(expr:Dynamic):Dynamic
Check if type is equal to the checkType complexType.
Parameters:
expr | must follow the format ($expr: $ct) |
---|
Returns:
Expr Bool