From 1bece356c13b8fc0b790d606a680b0d618318265 Mon Sep 17 00:00:00 2001 From: DanielGavin Date: Sat, 16 Nov 2024 21:23:08 +0100 Subject: [PATCH] Add more #attributes and support the latest Odin. --- src/odin/printer/visit.odin | 16 ++++++++++++++++ src/server/marshal.odin | 3 --- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/src/odin/printer/visit.odin b/src/odin/printer/visit.odin index fbc836c8..9ad7c34a 100644 --- a/src/odin/printer/visit.odin +++ b/src/odin/printer/visit.odin @@ -2258,6 +2258,22 @@ visit_signature_field_flag :: proc(p: ^Printer, flags: ast.Field_Flags) -> ^Docu document = cons_with_nopl(document, text("using")) } + if .No_Broadcast in flags { + document = cons_with_nopl(document, text("#no_broadcast")) + } + + if .No_Capture in flags { + document = cons_with_nopl(document, text("#no_capture")) + } + + if .Subtype in flags { + document = cons_with_nopl(document, text("#subtype")) + } + + if .By_Ptr in flags { + document = cons_with_nopl(document, text("#by_ptr")) + } + return document } diff --git a/src/server/marshal.odin b/src/server/marshal.odin index b9912a48..dc816e04 100644 --- a/src/server/marshal.odin +++ b/src/server/marshal.odin @@ -256,9 +256,6 @@ marshal_to_writer :: proc(w: io.Writer, v: any, opt: ^Marshal_Options) -> (err: case runtime.Type_Info_Simd_Vector: return .Unsupported_Type - case runtime.Type_Info_Relative_Pointer: - return .Unsupported_Type - case runtime.Type_Info_Matrix: return .Unsupported_Type