Partager via


Compiler and Language Provider Settings Schema

Compiler and language provider settings specify compiler configuration elements for available language providers. Each compiler configuration element specifies the code provider type name, compiler parameters, supported language names, and supported file extensions.

Remarks

The .NET Framework defines the initial compiler settings in the machine configuration file (Machine.config). Developers and compiler vendors can add configuration settings for a new CodeDomProvider implementation. Use the System.CodeDom.Compiler.CodeDomProvider.GetAllCompilerInfo method to programmatically enumerate language provider and compiler configuration settings on a computer.

<configuration> Element   <system.codedom>      <compilers>         <compiler>

Element Description

<system.codedom>

Specifies compiler configuration settings for available language providers.

<compilers>

Container for compiler configuration elements; contains zero or more <compiler> elements.

<compiler>

Specifies the compiler configuration attributes for a language provider.

Example

The following example illustrates a typical compiler configuration element.

<configuration>
   <system.codedom>
     <compilers>
       <!-- zero or more compiler elements -->
       <compiler
          language="c#;cs;csharp"
          extension=".cs"
          type="Microsoft.CSharp.CSharpCodeProvider, System, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"
          compilerOptions=""
          warningLevel="1" />
     </compilers>
   </system.codedom>
</configuration>

See Also

Reference

<compiler> Element
CompilerInfo
CodeDomProvider

Other Resources

Configuration File Schema for the .NET Framework