mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
The %s would not properly print function pointers.
This commit is contained in:
@@ -39,10 +39,11 @@ fn uint128? int_from_any(any arg, bool *is_neg) @private
|
||||
{
|
||||
switch (arg.type.kindof)
|
||||
{
|
||||
case TypeKind.POINTER:
|
||||
case FUNC:
|
||||
case POINTER:
|
||||
*is_neg = false;
|
||||
return (uint128)(uptr)*(void**)arg.ptr;
|
||||
case TypeKind.DISTINCT:
|
||||
case DISTINCT:
|
||||
return int_from_any(arg.as_inner(), is_neg);
|
||||
default:
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user