Skip to content

Commit 9b8c760

Browse files
committed
Fix comment
1 parent cafd480 commit 9b8c760

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/libraries/System.Runtime.InteropServices.JavaScript/gen/JSImportGenerator/JSExportGenerator.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -241,9 +241,7 @@ private static NamespaceDeclarationSyntax GenerateRegSource(
241241
.WithModifiers(TokenList(new[] { Token(SyntaxKind.StaticKeyword) }))
242242
.WithBody(Block(registerStatements));
243243

244-
// HACK: protect the code from trimming by putting it behind a comparison we know
245-
// will always evaluate to false at runtime, but the linker can't see through at
246-
// build time. It seems there's no attribute to block trimming of a method?
244+
// HACK: protect the code from trimming with DynamicDependency attached to a ModuleInitializer
247245
MemberDeclarationSyntax initializerMethod = MethodDeclaration(PredefinedType(Token(SyntaxKind.VoidKeyword)), Identifier(selfInitName))
248246
.WithAttributeLists(
249247
SingletonList<AttributeListSyntax>(

0 commit comments

Comments
 (0)