New tests.
[mono.git] / mcs / class / System.Web / System.Web.Compilation / ChangeLog
index e1d2497a823d7a87d7f72420094e3f104fe2fefe..35e40f1d41b6bce3e2fa455d0d35a2c31870c776 100644 (file)
@@ -1,3 +1,490 @@
+2008-08-14  Marek Habersack  <mhabersack@novell.com>
+
+       * AspGenerator.cs: do not ignore directives inside HTML comments.
+
+       * TemplateControlCompiler.cs: .NET allows for whitespace between
+       the directive start (<%) and the directive type character. Added
+       code which copes with such situations correctly.
+
+2008-08-13  Marek Habersack  <mhabersack@novell.com>
+
+       * TemplateControlCompiler.cs: rewrote the Bind regular expressions
+       to allow for single quotes and an optional second parameter to the
+       "call".
+       Added an Eval regular expression.
+       Both Bind and Eval calls in data expressions are now converted
+       into a CodeDOM method invocations, to allow support for possible
+       languages which use a different call format (previously code
+       snippets were used)
+       Added a method to construct the Eval invoke expression which
+       simplifies code in other areas.
+       
+
+2008-08-06  Marek Habersack  <mhabersack@novell.com>
+
+       * TemplateControlCompiler.cs: handle situation when a property of
+       a control for which we're generating the code is of type
+       'Type'. In such case, variable.GetType() will return
+       System.MonoType, which must not be output to the generated
+       source. Thanks to Robert Jordan for giving the idea for the hack!
+
+2008-06-30  Marek Habersack  <mhabersack@novell.com>
+
+       * AspGenerator.cs: hush the warnings and fix invalid type
+       comparison.
+
+       * AssemblyBuilder.cs: hush the warnings and add some debugging
+       CWLs.
+
+       * AspParser.cs, AppResourcesCompiler.cs, TemplateBuildProvider.cs,
+       CachingCompiler.cs, BaseCompiler.cs, TemplateControlCompiler.cs,
+       SimpleBuildProvider.cs, BuildManager.cs: hush the warnings
+
+2008-06-18  Marek Habersack  <mhabersack@novell.com>
+
+       * TemplateControlCompiler.cs: AddChildCall properly processes the
+       PartialCachingAttribute now.
+
+2008-06-11  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: if an error occurs while assigning the
+       requested path to an assembly builder inside BuildAssembly, throw
+       an exception.
+
+       * BaseCompiler.cs: do not generate #line pragma for code which
+       exists only in memory.
+
+2008-05-30  Marek Habersack  <mhabersack@novell.com>
+
+       * ClientBuildManager.cs: do not use synthetized event accessors
+       (to avoid locks).
+
+2008-05-28  Marek Habersack  <mhabersack@novell.com>
+
+       * AspParser.cs, AspGenerator.cs, BaseCompiler.cs: added support
+       for #pragma checksum
+
+2008-05-19  Marek Habersack  <mhabersack@novell.com>
+
+       * AspGenerator.cs: if the last tag parsed was a code directive,
+       ignore any accumulated text if it's 100% whitespace.
+       Do not parse code render directives inside comments.
+
+2008-05-15  Marek Habersack  <mhabersack@novell.com>
+
+       * AspComponentFoundry.cs: treat AssemblyFoundry in a special way
+       when adding a foundry to the array list. AssemblyFoundry instances
+       are stacked at the end of the array list in a LIFO manner. That
+       way TagNameFoundry takes precedence over AssemblyFoundry should
+       the two contain the same type.
+
+2008-05-14  Marek Habersack  <mhabersack@novell.com>
+
+       * ParseException.cs: location can be null in the FileText property
+       getter.
+
+2008-05-07  Marek Habersack  <mhabersack@novell.com>
+
+       * AspGenerator.cs: push the include file directory to the parser
+       include directory stack and pop it after parsing the include, so
+       that the relative file paths are resolved correctly. Fixes bug
+       #324536
+
+2008-05-06  Marek Habersack  <mhabersack@novell.com>
+
+       * TemplateControlCompiler.cs: compatibility - added the
+       __stringResource static field to the generated class and a call to
+       SetStringResourcePointer to the FrameworkInitialize method.
+
+       * PageCompiler.cs: __fileDependencies should also be defined in
+       the 1.x profile.
+       Page properties assigned in the page directive should be set
+       inside BuildControlTree in the 2.0 profile.
+
+2008-04-29  Marek Habersack  <mhabersack@novell.com>
+
+       * WebServiceCompiler.cs: if compiling a body-less web service, try
+       to load the class type from the loaded assemblies before
+       attempting to find it in the assemblies on disk.
+
+2008-04-28  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: ignore bad assemblies in the bin/
+       directory. Fixes bug #315816
+
+2008-04-26  Marek Habersack  <mhabersack@novell.com>
+
+       * GenericBuildProvider.cs: the Parse () method should reuse the
+       previously opened TextReader when calling generator.Parse (), to
+       avoid opening the input file multiple times. Fixes bug #383881
+
+2008-04-25  Marek Habersack  <mhabersack@novell.com>
+
+       * AspGenerator.cs: put some safeguards in, to make sure streams
+       are closed in any case.
+
+2008-04-24  Marek Habersack  <mhabersack@novell.com>
+
+       * AspComponentFoundry.cs: added a new GetComponentType overload
+       which returns component source and a boolean flag whether the
+       control was registered from web.config (2.0).
+
+2008-04-22  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: ignore also arbitrary exceptions when
+       batch-building an assembly. Fixes bug #323556
+
+2008-04-19  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: use absolute virtual path to query the
+       VirtualPathProvider for path existence.
+       When ASP.NET is self-hosted, force
+        non-batch compilation. Fixes bug #380985
+
+       * ILocation.cs: added a new property, FileText.
+       
+       * Location.cs: added implementation of the ILocation.FileText
+       property.
+
+       * ParseException.cs: use the new ILocation.FileText, if defined,
+       to get the file source.
+       
+       * AspGenerator.cs: when TextReader is present, use it to read with
+       the VirtualPathProvider to read the file source. Fixes bug #381364
+
+       * AspParser.cs: added a new property FileText to provide the file
+       contents which was read in the constructor.
+
+2008-04-18  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: when any parsing error occurs during batch
+       building, ignore the file which caused it. If the file with
+       parsing error is the one requested by user, throw the parsing
+       exception. Fixes bug #323742
+
+2008-04-15  Marek Habersack  <mhabersack@novell.com>
+
+       * CachingCompiler.cs: dispose of streams the way it should
+       be done.
+
+2008-04-09  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: refactoring - the SetCommonParameters and
+       GetDefaultCompilerTypeForLanguage moved here from BuildProvider,
+       and made internal static.
+       Do not catch compilation exceptions and wrap them in
+       HttpException, let the CompilationException pass through. Fixes
+       bug #377904
+
+       * AppWebReferencesCompiler.cs: added - support for compiling of
+       wsdl files found in the App_WebResources directory. Fixes bug
+       #377934
+
+       * BuildProvider.cs: refactoring - moved the SetCommonParameters
+       and GetDefaultCompilerTypeForLanguage to BuildManager
+
+       * WsdlBuildProvider.cs: added the CodeCompilerType property
+       override.
+       Namespace for the generated code is taken from the wsdl path,
+       relative to App_Code or App_WebReferences, if the wsdl in question
+       is under on of those directories.
+       GenerateCode uses OpenReader () so that VirtualPathProvider works
+       for wsdl files.
+
+       * AssemblyBuilder.cs: make sure Encoding.UTF8 is explicitly used
+       when generating source from code unit and use
+       WebEncoding.FileEncoding when adding code files to the unit. Fixes
+       bug #377938
+       Cope with virtualPath being null in BuildAssembly.
+       Reference assemblies specified in web.config when linking.
+
+2008-04-08  Marek Habersack  <mhabersack@novell.com>
+
+       * AspComponentFoundry.cs: add loaded assembly to the
+       BuildManager's list of referenced assemblies instead to
+       WebConfigurationmanager.ExtraAssemblies. Fixes bug #377915
+
+       * AppCodeCompiler.cs: VirtualPath used in PhysicalToVirtual.
+
+       * BuildManager.cs: switched to VirtualPath instead of a string
+       path in several methods.
+       Batch compilation is turned off if we have a custom
+       VirtualPathProvider which implements only the VirtualFile and
+       falls back to DefaultVirtualDirectory implementation for directory
+       access.
+       Added an internal method AddToReferencedAssemblies.
+       Remove invalidated entry from
+       WebConfigurationManager.ExtraAssemblies.
+
+       * GenericBuildProvider.cs: AddCodeFile accepts a virtual path.
+
+       * BuildProvider.cs: SetVirtualPath accepts a VirtualPath now.
+
+       * AssemblyBuilder.cs: constructors use the new VirtualPath class
+       now.
+       AddCodeFile can use the VirtualPathProvider if necessary now.
+       BuildAssembly overloads accept VirtualPath parameter instead of a
+       string path now.
+
+       * TemplateBuildProvider.cs: GetCodeBehindSource returns the
+       virtual path now.
+
+2008-03-31  Marek Habersack  <mhabersack@novell.com>
+
+       * AppCodeCompiler.cs: implemented support for AppInitialize (a
+       static method in any class defined in the App_Code source files),
+       ran just after the App_Code assemblies are compiled in order to
+       perform any application initialization actions.
+
+2008-03-27  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: AssertVirtualPathExists now queries the
+       VirtualPathProvider for path existence if physical path check
+       fails, before throwing the 404 exception.
+
+2008-03-13  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: if we're running in a case-insensitive
+       environment, use case-insensitive comparer for the build caches. 
+
+2008-02-29  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: implement a mechanism to ignore certain virtual
+       paths when batch compiling. Helps applications which may have
+       .as?x files which won't work on mono for various reasons (one such
+       sample is mojoportal).
+
+2008-02-28  Marek Habersack  <mhabersack@novell.com>
+
+       * TemplateControlCompiler.cs: make sure that data-bound attribute
+       assignments properly convert the Bind expression to the Eval
+       one. Fixes bug #362039
+
+       * AspGenerator.cs: in 2.0+, aspx files which contain the Content
+       controls can contain only them, whitespace and directives. Fixes
+       bug #339747
+
+2008-02-27  Marek Habersack  <mhabersack@novell.com>
+
+       * AspComponentFoundry.cs: use BuildManager.GetCompiledType in the
+       LoadType method for the 2.0 profile.
+
+       * CompilationException.cs: use a different format of ErrorMessage
+       for the 2.0+ profile.
+
+2008-02-26  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: known file types extensions are now matched
+       case-insensitively.
+
+2008-02-25  Marek Habersack  <mhabersack@novell.com>
+
+       * TemplateControlCompiler.cs: GetContainerType now checks whether
+       the binding container returned from the builder implements
+       IDataItemContainer (for 2.0+ profiles) and looks for one more
+       property, Rows, if no Items property is found.
+
+2008-02-08  Gert Driesen  <drieseng@users.sourceforge.net>
+
+       * AppSettingsExpressionBuilder.cs: Improve exception messages. Return
+       "raw" appsetting value if targetType is null.
+
+2008-02-07  Marek Habersack  <mhabersack@novell.com>
+
+       * CompilationException.cs: added new constructor which takes
+       CompilerResults as one of the parameters.
+       Added CompilerOutput property.
+
+       * AssemblyBuilder.cs: use the new CompilationError constructor.
+
+       * BuildManager.cs: check for virtualPath existence before
+       attempting to compile the assemblies. Fixes bug #359465
+
+2008-02-06  Marek Habersack  <mhabersack@novell.com>
+
+       * GenericBuildProvider.cs: GetGeneratedType may return a type even
+       though the results are null.
+
+       * AssemblyBuilder.cs: if there are no units, no source files, no
+       resources and no embedded resources in the passed options then
+       do not attempt to compile the assembly. Fixes bug #359325
+
+       * AppResourcesAssemblyBuilder.cs, AppCodeCompiler.cs: expect that
+       BuildAssembly may return null results.
+
+       * BuildManager.cs: protect non-page builds from endless recursion
+       if a non-page file recursively references/includes another file
+       from the same batch. If such case is detected, the recursively
+       referenced file is compiled into a separate assembly and removed
+       from the previous compilation batch. Fixes bug #358742.
+       If AssemblyBuilder returns no results from BuildAssembly, it might
+       mean we're dealing with a compilation of empty .as[hm]x files,
+       with no code and only code-behind in bin/. Do not report an error
+       in that case, only add the compiled types to the cache. Fixes bug
+       #357624.
+
+2008-02-05  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: GetAbsoluteVirtualPath correctly converts
+       non-rooted relative paths to absolute ones now. Fixes bug
+       #357504.
+
+       * GenericBuildProvider.cs: introduced a new abstract method,
+       GetReferencedAssemblies, which is called on descendant builders to
+       get a list of assemblies referenced by the parsed file. Fixes bug
+       #357499.
+
+       * AssemblyBuilder.cs: added a new overload of the
+       AddAssemblyReference method, to be used by build providers to
+       register assemblies collected by the corresponding parser.
+
+       * TemplateBuildProvider.cs, SimpleBuildProvider.cs: implemented
+       overload of the new abstract method GetReferencedAssemblies.
+
+       * AspGenerator.cs: introduced a new overload for the Parse method
+       which accepts a bool indicating whether or not to initialize the
+       parser. The overload is used when parsing server-side
+       includes. Fixes bug #357498
+
+2008-02-04  Marek Habersack  <mhabersack@novell.com>
+
+       * AssemblyBuilder.cs: do not use WebEncoding.FileEncoding when
+       generating source code files. Fixes bug #357053.
+
+       * AspGenerator.cs: set isApplication before parsing. Fixes bug
+       #357036.
+
+2008-01-31  Jb Evain  <jbevain@novell.com>
+
+       * AspGenerator.cs: correct typo. Fix #357547.
+
+2008-01-27  Marek Habersack  <mhabersack@novell.com>
+
+       * BuildManager.cs: GetReferencedAssemblies includes the extra
+       assemblies and the App_Code assemblies. Patch from Mike Morano
+       <mmorano@mikeandwan.us>, thanks!
+
+2008-01-24  Marek Habersack  <mhabersack@novell.com>
+
+       * WebHandlerBuildProvider.cs: derive from the new
+       SimpleBuildProvider class.
+
+       * BuildManager.cs: full implementation of the batch compilation
+       for the 2.0 profile. The implementation is most probably different
+       to MS.NET's but the effects are the same (or nearly the same -
+       there are some minor differences). There are missing bits and
+       pieces, but minor ones - to be added later.
+
+       * SimpleBuildProvider.cs: new build provider abstract class
+       deriving from the GenericBuildProvider that implements common code
+       for building web handlers and web services.
+
+       * GenericBuildProvider.cs: new generic abstract class used to
+       implement base builder code for all the build provider types and
+       maximize code reuse.
+
+       * PageBuildProvider.cs: derive from the new TemplateBuildProvider
+       class and implement all the necessary abstract members. 
+       Handle "fake" virtual paths, to properly support generating of the
+       WSDL helper code.
+
+       * BuildProvider.cs: SetVirtualPath now converts the passed path to
+       absolute URL.
+       Added internal virtual method GenerateCode, used by derived
+       classes.
+       SetCommonParameters no longer sets the referenced assemblies, this
+       is done in BuildManager now.
+       Added an internal virtual property CodeUnit which returns the
+       build provider's compilation unit.
+
+       * PageCompiler.cs: fix assignment of base types for asynchronous
+       pages, to match MS.NET.
+       For asynchronous pages, add the necessary methods generation.
+
+       * BaseCompiler.cs: default namespace is now set using a constant.
+       Renamed the Init method into ConstructType, to better reflect its
+       purpose and made the method internal - it is used by the build
+       providers.
+       Added several CreateProvider overloads for easier and more unified
+       compilation provider creation.
+       Added an internal MainClassType property to enable class type name
+       retrieval from other parts of the class hierarchy.
+
+       * ApplicationFileBuildProvider.cs: new build provider deriving
+       from the TemplateBuildProvider class to compile the global.asax
+       file.
+
+       * AspGenerator.cs: properly handle parsers which have no input
+       file path given, but use TextReader instead.
+       Dependencies are virtual paths now, convert them to physical ones
+       before creating cache dependency.
+
+       * CachingCompiler.cs: parser dependencies are virtual paths now,
+       convert them to physical ones before creating cache dependency.
+
+       * AssemblyBuilder.cs: full implementation of the documented
+       functionality as well as a lot of internal build code
+       added. Produces assemblies using the same style what MS.NET for
+       temporary and target file naming. Handles partial type squashing
+       if the same partial type is used by several code compile units
+       added to the same builder instance.
+
+       * MasterPageBuildProvider.cs: use the new TemplateBuildProvider
+       base class and add implementation of all the abstract methods
+       required by it.
+
+       * ThemeDirectoryBuildProvider.cs: new build provider to compile
+       theme directories. Replaces the old ThemeDirectoryCompiler class.
+
+       * UserControlBuildProvider.cs: use the new TemplateBuildProvider
+       base class and add implementation of all the abstract methods
+       required by it.
+
+       * TemplateBuildProvider.cs: new internal abstract class which
+       implements the common tasks for all the template control build
+       providers.
+
+       * WebServiceBuildProvider.cs: use the new SimpleBuildProvider base
+       type to implement building.
+
+2008-01-17  Igor Zelmanovich <igorz@mainsoft.com>
+
+       * BaseCompiler.cs: Assign AppRelativeVirtualPath correctly
+
+2008-01-08  Marek Habersack  <mhabersack@novell.com>
+
+       * TemplateControlCompiler.cs: statements to assign
+       fields/properties from resources must be processed at the very end
+       of the control creation method. Some controls (like HyperLink) can
+       set their Text attribute using literal content. In such cases, in
+       order to properly localize the control, the value read from the
+       local page resources must be assigned after the literal value has
+       been added to the control. Fixes bug #323494
+
+2008-01-07  Marek Habersack  <mhabersack@novell.com>
+
+       * CachingCompiler.cs: added an overload to the Compile method
+       which accepts a flag whether or not to include debug information
+       in the generated assembly.
+
+2008-01-02  Marek Habersack  <mhabersack@novell.com>
+
+       * TemplateControlCompiler.cs: add line pragma wherever necessary.
+
+       * PageCompiler.cs: reorder the statements to match MS.NET output.
+       Output line pragma information for directive attributes.
+
+       * BaseCompiler.cs: add a set of AddLinePragma methods for various
+       CodeDOM elements. 
+       Output line pragmas when adding server-side scripts to the CodeDOM
+       tree.
+
+       * AspGenerator.cs: use ServerSideScript to store script location
+       in the original file.
+
+       * UserControlCompiler.cs: output line pragmas for the init
+       method.
+
 2007-12-28  Marek Habersack  <mhabersack@novell.com>
 
        * PageCompiler.cs: MS.NET compatibility: added the