single_entry_point: Retain applied transforms

This transform does not use the top-level ctx.Clone() method, so we
need to manually copy the applied transforms over to the destination
program.

This fixes the GLSL backend, where this transform was dropping the
applied transforms and breaking a required transform dependency later
in the chain.

Change-Id: I3db688fe35dfbe67468b9941f739cb2ecf3a843b
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/72220
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
diff --git a/src/transform/single_entry_point.cc b/src/transform/single_entry_point.cc
index da9c273..fb99663 100644
--- a/src/transform/single_entry_point.cc
+++ b/src/transform/single_entry_point.cc
@@ -105,6 +105,11 @@
 
   // Clone the entry point.
   ctx.dst->AST().AddFunction(ctx.Clone(entry_point));
+
+  // Retain the list of applied transforms.
+  // We need to do this manually since we are not going to use the top-level
+  // ctx.Clone() function.
+  ctx.dst->SetTransformApplied(ctx.src->TransformsApplied());
 }
 
 SingleEntryPoint::Config::Config(std::string entry_point)