BUG: You Cannot Use Smcil.exe to Compile Managed Code as Expected (309545)



The information in this article applies to:

  • Microsoft .NET Framework SDK 1.0
  • Microsoft .NET Framework SDK 1.1
  • Microsoft .NET Framework Class Libraries 1.0
  • Microsoft Windows .NET Framework Class Libraries 1.1

This article was previously published under Q309545

SYMPTOMS

The documentation for the Simple Managed Compiler (SMC) sample, located in the following directory

Microsoft Visual Studio .NET installation folder\Microsoft.NET\FrameworkSDK\Tool Developers Guide\Samples\StartSamples.htm

states that you can self-compile the SMC compiler into a managed compiler (Smcil.exe). Although the compilation succeeds, you cannot use the generated compiler, Smcil.exe, to compile managed code. For example, if you attempt to self-compile Smcil.exe to Smcil2.exe, the operation does not succeed.

RESOLUTION

The primary aim of the SMC sample is to demonstrate how to implement a compiler that targets the .NET Framework -- and the sample fulfills that aim. The workaround for the self-compile issue described in the "Symptoms" section of this article is left as an exercise for the reader of this sample (using the resources provided in the SDK).

STATUS

Microsoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article.

Modification Type:MajorLast Reviewed:4/7/2003
Keywords:kbbug kbreadme KB309545