From 18066352a0053d3c3093283775f7c049496796f4 Mon Sep 17 00:00:00 2001 From: Buyaa Namnan Date: Mon, 28 Aug 2023 21:58:30 -0700 Subject: [PATCH 1/3] Add missing docs for System.Reflection.Metadata --- .../InstructionEncoder.xml | 11 +++-- .../SignatureTypeEncoder.xml | 42 +++++++++---------- .../SwitchInstructionEncoder.xml | 8 ++-- 3 files changed, 32 insertions(+), 29 deletions(-) diff --git a/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml b/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml index d211f740bf2..db207c6764f 100644 --- a/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml +++ b/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml @@ -895,10 +895,13 @@ A single label may be marked multiple times, the last offset wins. - To be added. - To be added. - To be added. - To be added. + The number of branches the instruction will have. + Starts encoding a switch instruction. + A that will be used to emit the labels for the branches. + Before using this in any other way, the method must be called on the returned value exactly times. Failure to do so will throw . + + + less than or equal to zero. diff --git a/xml/System.Reflection.Metadata.Ecma335/SignatureTypeEncoder.xml b/xml/System.Reflection.Metadata.Ecma335/SignatureTypeEncoder.xml index ba421bc29cc..7f9908d3025 100644 --- a/xml/System.Reflection.Metadata.Ecma335/SignatureTypeEncoder.xml +++ b/xml/System.Reflection.Metadata.Ecma335/SignatureTypeEncoder.xml @@ -37,7 +37,7 @@ - To be added. + Encodes a type in a signature. To be added. @@ -65,8 +65,8 @@ - To be added. - To be added. + The where the signature will be written. + Creates a . To be added. @@ -165,7 +165,7 @@ - To be added. + Encodes . To be added. @@ -193,7 +193,7 @@ System.Reflection.Metadata.BlobBuilder - To be added. + The where the signature is written to. To be added. To be added. @@ -223,7 +223,7 @@ - To be added. + Encodes . To be added. @@ -252,7 +252,7 @@ - To be added. + Encodes . To be added. @@ -311,7 +311,7 @@ - To be added. + Encodes . To be added. @@ -491,7 +491,7 @@ - To be added. + Encodes . To be added. @@ -520,7 +520,7 @@ - To be added. + Encodes . To be added. @@ -549,7 +549,7 @@ - To be added. + Encodes . To be added. @@ -578,7 +578,7 @@ - To be added. + Encodes . To be added. @@ -607,7 +607,7 @@ - To be added. + Encodes . To be added. @@ -700,7 +700,7 @@ - To be added. + Encodes . To be added. @@ -729,7 +729,7 @@ - To be added. + Encodes . To be added. @@ -758,7 +758,7 @@ - To be added. + Encodes . To be added. @@ -847,7 +847,7 @@ - To be added. + Encodes . To be added. @@ -876,7 +876,7 @@ - To be added. + Encodes . To be added. @@ -905,7 +905,7 @@ - To be added. + Encodes . To be added. @@ -934,7 +934,7 @@ - To be added. + Encodes . To be added. @@ -963,7 +963,7 @@ - To be added. + Encodes . To be added. diff --git a/xml/System.Reflection.Metadata.Ecma335/SwitchInstructionEncoder.xml b/xml/System.Reflection.Metadata.Ecma335/SwitchInstructionEncoder.xml index 66912df2afe..339486b160a 100644 --- a/xml/System.Reflection.Metadata.Ecma335/SwitchInstructionEncoder.xml +++ b/xml/System.Reflection.Metadata.Ecma335/SwitchInstructionEncoder.xml @@ -20,8 +20,8 @@ - To be added. - To be added. + Encodes the branches of an IL switch instruction. + See for usage guidelines. @@ -44,8 +44,8 @@ To be added. - To be added. - To be added. + Encodes a branch that is part of a switch instruction. + See for usage guidelines. From 404956bd68acd329b2f0061e511b49f16f7811d9 Mon Sep 17 00:00:00 2001 From: Buyaa Namnan Date: Tue, 29 Aug 2023 14:23:00 -0700 Subject: [PATCH 2/3] Apply suggestions from code review Co-authored-by: Genevieve Warren <24882762+gewarren@users.noreply.github.com> --- .../InstructionEncoder.xml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml b/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml index db207c6764f..bf86076189f 100644 --- a/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml +++ b/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml @@ -900,8 +900,9 @@ A single label may be marked multiple times, the last offset wins. A that will be used to emit the labels for the branches. Before using this in any other way, the method must be called on the returned value exactly times. Failure to do so will throw . - - less than or equal to zero. + is less than or equal to zero. + + was not called on the returned value exactly times. From 159257e870dfc0defe3b4558c90ad4db9ab61505 Mon Sep 17 00:00:00 2001 From: Buyaa Namnan Date: Tue, 29 Aug 2023 14:24:18 -0700 Subject: [PATCH 3/3] Update xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml --- xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml b/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml index bf86076189f..6fe85e5317d 100644 --- a/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml +++ b/xml/System.Reflection.Metadata.Ecma335/InstructionEncoder.xml @@ -901,8 +901,8 @@ A single label may be marked multiple times, the last offset wins. Before using this in any other way, the method must be called on the returned value exactly times. Failure to do so will throw . is less than or equal to zero. - - was not called on the returned value exactly times. + + was not called on the returned value exactly times.