mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
- Make printing typeids give some helpful typeid data.
This commit is contained in:
@@ -141,8 +141,6 @@ fn usz? Formatter.out_str(&self, any arg) @private
|
|||||||
{
|
{
|
||||||
switch (arg.type.kindof)
|
switch (arg.type.kindof)
|
||||||
{
|
{
|
||||||
case TYPEID:
|
|
||||||
return self.out_substr("typeid");
|
|
||||||
case VOID:
|
case VOID:
|
||||||
return self.out_substr("void");
|
return self.out_substr("void");
|
||||||
case FAULT:
|
case FAULT:
|
||||||
@@ -188,6 +186,8 @@ fn usz? Formatter.out_str(&self, any arg) @private
|
|||||||
if (@catch(n) != NOT_FOUND) n!;
|
if (@catch(n) != NOT_FOUND) n!;
|
||||||
switch (arg.type.kindof)
|
switch (arg.type.kindof)
|
||||||
{
|
{
|
||||||
|
case TYPEID:
|
||||||
|
return self.out_substr("typeid[")! + self.ntoa((iptr)*(typeid*)arg, false, 16)! + self.out_substr("]")!;
|
||||||
case ENUM:
|
case ENUM:
|
||||||
usz i = types::any_to_enum_ordinal(arg, usz)!!;
|
usz i = types::any_to_enum_ordinal(arg, usz)!!;
|
||||||
assert(i < arg.type.names.len, "Illegal enum value found, numerical value was %d.", i);
|
assert(i < arg.type.names.len, "Illegal enum value found, numerical value was %d.", i);
|
||||||
|
|||||||
@@ -49,6 +49,7 @@
|
|||||||
- Deprecate objc enums in favour of const inline enums backed by NS numerical types, and with the NS prefix, to better align with the objc api (macOS).
|
- Deprecate objc enums in favour of const inline enums backed by NS numerical types, and with the NS prefix, to better align with the objc api (macOS).
|
||||||
- Deprecate `event_type_from` function in favour of using NSEvent directly, to better align with the objc api (macOS).
|
- Deprecate `event_type_from` function in favour of using NSEvent directly, to better align with the objc api (macOS).
|
||||||
- Add unit tests for objc and core_foundation (macOS).
|
- Add unit tests for objc and core_foundation (macOS).
|
||||||
|
- Make printing typeids give some helpful typeid data.
|
||||||
|
|
||||||
## 0.7.7 Change list
|
## 0.7.7 Change list
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user