From d6d38e405484148855192144a74024519c11b731 Mon Sep 17 00:00:00 2001 From: Elinor Fung Date: Tue, 25 Jun 2024 05:22:12 -0700 Subject: [PATCH] Update AssesmblyBuilder.DefineDynamicModule to call out that .NET Core/5+ only supports one module per assembly (#10057) * Update AssesmblyBuilder.DefineDynamicModule to call out that .NET Core/5+ only supports one module per assembly * Update xml/System.Reflection.Emit/AssemblyBuilder.xml Co-authored-by: Jan Kotas --------- Co-authored-by: Jan Kotas --- xml/System.Reflection.Emit/AssemblyBuilder.xml | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/xml/System.Reflection.Emit/AssemblyBuilder.xml b/xml/System.Reflection.Emit/AssemblyBuilder.xml index aeab14be3cf..c2c048fcb2c 100644 --- a/xml/System.Reflection.Emit/AssemblyBuilder.xml +++ b/xml/System.Reflection.Emit/AssemblyBuilder.xml @@ -576,7 +576,9 @@ The following code example shows how to define and use a dynamic assembly. The e . @@ -607,9 +609,15 @@ The following code example shows how to define and use a dynamic assembly. The e -or- - The length of is greater than the system-defined maximum length. + The length of is greater than the system-defined maximum length. + + -or- + + .NET Framework only: A module with the same has already been defined in this assembly. + is . + .NET Core and .NET 5+ only: A dynamic module has already been defined in this assembly. The caller does not have the required permission. The assembly for default symbol writer cannot be loaded. @@ -916,7 +924,7 @@ The following code example shows how to define and use a dynamic assembly. The e The name of the dynamic module. When overridden in a derived class, defines a dynamic module in this assembly. A representing the defined dynamic module. - .NET Core supports only one module. + .NET Core and .NET 5+ support only one module per assembly. @@ -1772,7 +1780,7 @@ The following code example shows how to define and use a dynamic assembly. The e The name of the requested dynamic module. When overridden in a derived class, returns the dynamic module with the specified name. A representing the requested dynamic module. - .NET Core supports only one module. + .NET Core and .NET 5+ support only one module per assembly..