This change adds some conditional output that depends on whether a named resource was contained in a file or not. This eliminates some compiler errors in the generated code when using manually-named resources.