2009-08-25 Marek Habersack * AspGenerator.cs: correctly parse server-side tags nested in client-side ones. Fixes bug #323719 Detect IE conditional comments when processing comment blocks in TextParsed. Fixes bug #367273 2009-08-24 Marek Habersack * PageBuildProvider.cs: MapPath now takes a VirtualPath instance. Part of fix for bug #463813 * BuildManager.cs: public APIs which take virtual path strings as their parameters got internal counterparts accepting a VirtualPath instance in place of string. Part of fix for bug #463813 * TemplateBuildProvider.cs: ExtractDependencies checks if the input has already been parsed/compiled and, if yes, adds dependencies from the TemplateParser to the list of the ones extracted locally. Fixes bug #377915 * GenericBuildProvider.cs: added Parsed property. MapPath now takes a VirtualPath instance. Part of fix for bug #463813 2009-08-21 Marek Habersack * GenericBuildProvider.cs: added internal property LanguageName override which calls GetParserLanguage to get language name instead of using the application default one. * BuildManagerDirectoryBuilder.cs: removed CodeDOM provider cache, provider types are retrieved from build providers while assigning them to groups. Fixes bug #533166 2009-08-18 Marek Habersack * AspParser.cs: added a constructor which creates an internal parser, nested within the outer one, and adjusts its ILocation members to report correct locations in the outer parser for better error reporting. Inner parser also returns the outer's FileText, if available. * AspGenerator.cs: restored part of r138474 reverted in r138657, r138658 and r138659 to fix bug #525104 BuilderLocation creates a copy of Location for its own use (since the ILocation passed is actually AspParser, the line numbers change between creating a BuilderLocation and using its Location member). The end of tag, expression and client comment regular expressions now use lazy quantifiers. This fixes bugs #525104 and #517656 Client side comment blocks aren't ignored anymore, they are parsed just as the other parts of the document. Fixes bug #524358 2009-08-15 Marek Habersack * AspGenerator.cs: CodeRenderParser.DoParseExpressions - match newline characters inside expressions. Fixes bug #526449 2009-08-14 Marek Habersack * BuildManagerDirectoryBuilder.cs: when VirtualPathProvider reports a virtual directory doesn't exist, try to get the requested virtual path using VirtualPathProvider.GetFile. Fixes #525974 2009-07-30 Gonzalo Paniagua Javier * BuildManager.cs: path fixup should work now for /foo running on /foo. Fixes bug #526563. 2009-07-23 Gonzalo Paniagua Javier * BuildManager.cs: precompilation setup failed if the precompiled virtual directory was / and it was deployed somewhere else. 2009-07-21 Veerapuram Varadhan * XsdBuildProvider.cs: Use System.Data.Design version of TypedDataSetGenerator instead of System.Data's. 2009-07-21 Marek Habersack * AspTokenizer.cs: in put_back, store inTag value as well. * AspParser.cs: correctly parse code like " < " * BuildManager.cs: GetReferencedAssemblies unconditionally includes all assemblies from bin/ for precompiled sites. Fixes bug #502016 2009-07-18 Marek Habersack * DefaultResourceProvider.cs: if GetResourceObject is passed a null or empty classKey it just returns null. * AppResourcesAssemblyBuilder.cs: satellite assemblies are now built using al instead of gmcs - makes the build slightly faster. 2009-07-13 Marek Habersack * AppCodeCompiler.cs: wrap HttpApplication.LoadTypeFromBin call in try/catch, so that we can wrap the possible exception in HttpException. 2009-07-09 Marek Habersack * DefaultResourceProvider.cs, DefaultResourceProviderFactory.cs: added 2009-07-08 Marek Habersack * AspParser.cs: GetServerTag mustn't treat <% # ... %> as data-binding directives. Fixes bug #520024 * AssemblyBuilder.cs: if debugging information is on, append /d:DEBUG to the compiler's command line. 2009-06-30 Marek Habersack * AspGenerator.cs: TextParsed must remove client-side comments from the passed text before attempting to parse the text for server side controls and expressions. Fixes bug #517656 2009-06-29 Gonzalo Paniagua Javier * TemplateControlCompiler.cs: use the 'Empty' field for Unit and FontUnit. 2009-06-15 Marek Habersack * AspGenerator.cs: CreateRootBuilder quits when root builder already exist. This can happen when recursively parsing an include file. Fixes bug #512028 2009-06-12 Marek Habersack * BuildManager.cs: avoid a NREX in FixVirtualPath 2009-06-11 Marek Habersack * PageCompiler.cs: if generating code to assign output cache parameters, use special case for generating OutputCacheLocation enum reference. Fixes bug #512037 2009-06-04 Marek Habersack * AspGenerator.cs: if plain text is parsed and it contains server-side controls, parse and process them. Fixes bug #508888 2009-06-02 Gonzalo Paniagua Javier * BuildManager.cs: allow deployment of precompiled applications under any virtual path, not just the default one used when precompiling. Fixes bug #483268. 2009-06-01 Marek Habersack * BuildManager.cs: when throwing a 404 exception, pass the virtual path to the exception constructor. * AspGenerator.cs: fix mapping of our tag types into CodeConstructType. Fixes bug #508570 2009-05-26 Marek Habersack * AspGenerator.cs: before including a file specified with the directive, check if it's within the current application's root. 2009-05-18 Marek Habersack * BuildManager.cs: GetPrecompiledApplicationType () uses VirtualPathUtility.Combine to build global.asax virtual path. Patch from Robert Jordan , thanks! Fixes bug #504615 2009-05-10 Marek Habersack * AspGenerator.cs: keep processing the tag if it is not a server one and contains expressions and no code render blocks. 2009-05-05 Marek Habersack * BuildManager.cs: RemoveFailedAssemblies wraps the compilation exception to be rethrown in a HttpException instance. * AspGenerator.cs: create a Location and pass it to the parser before calling AddDirective from GetInheritedType, so that we get meaningful exception messages with source, line information etc. 2009-05-04 Marek Habersack * ThemeDirectoryBuildProvider.cs: use new AspGenerator constructor which takes AspComponentFoundery as its parameter. AspGenerator.RootBuilder isn't initialized until after the parser is initialized. * TemplateControlCompiler.cs: make sure to call ProcessGeneratedCode on each instance of ControlBuilder after it's fully generated. Fixes bug #500075 * TemplateBuildProvider.cs: moved the directive regex to AspGenerator * BaseCompiler.cs: added two internal properties, BaseType and DerivedType, which are used in calls to ControlBuilder.ProcessGeneratedCode. Fixes bug #500075 * AspGenerator.cs: implemented a work around for our parser limitation which is unable to extract the page/control's base type before parsing the actual file contents. This is necessary to support ASP.NET MVC's "generic" Inherits attribute. The reason we need to find out what the base type is before parsing the file is that we need to look at the type's custom attributes to see if a root control builder type is specified (which is what ASP.NET MVC does) and, if yes, use it instead of the default type. Fixes bug #500075 2009-04-30 Marek Habersack * BuildManager.cs: when BuildInner catches a compilation exception, wrap it in HttpException before re-throwing. 2009-04-28 Marek Habersack * AspGenerator.cs: ProcessTag doesn't process a tag which is not server-side and which has declarative expressions embedded. Fixes bug #498637 2009-04-24 Marek Habersack * AspGenerator.cs: ProcessCode should _not_ stop processing the passed code string if the filter's ProcessCodeConstruct returns false. Fixes bug #497775 2009-04-21 Marek Habersack * PageCompiler.cs: implemented new way of setting output cache parameters in the 2.0 profile. The generated code is now the same as on .NET and uses the OutputCacheParameters class to pass settings to InitOutputCache. 2009-04-17 Marek Habersack * AspGenerator.cs: if thead/tbody are parsed as children of a server-side table control, ignore them. Fixes bug #481622 2009-04-16 Marek Habersack * TemplateControlCompiler.cs: using a regexp to check whether an expression is a Bind one. Fixes bug #493639 AssignPropertyFromResources now checks whether the field/property passed to it is decorated with the Localizable custom attribute and whether the resource provider contains an entry for that property. 2009-04-15 Marek Habersack * BuildManager.cs: do not add all assemblies in bin/ when serving a precompiled site. Fixes bug #493873 When serving a precompiled site, check if the bin/ directory contains certain well-known assemblies and load them if present. 2009-04-07 Marek Habersack * TemplateControlCompiler.cs: GenerateExpressionFromString doesn't assume that the passed member is a property anymore. Fixes bug #492252 2009-04-06 Marek Habersack * BuildManager.cs: make sure that precompiled is not null before using it in GetPrecompiledType. 2009-04-03 Marek Habersack * AspParser.cs: local copy of checksum generated by the tokenizer is made right after parsing is done. * AspGenerator.cs: set tparser.MD5Checksum in Parse instead of in InitParser. Avoids empty checksums in #pragma checksum. 2009-04-02 Marek Habersack * CompilationException.cs: skip warnings in ErrorMessage and ErrorLines * BuildManager.cs: when an error occurs while compiling the requested virtual path, throw the exception, do not attempt to build again. * TemplateControlCompiler.cs: implemented missing converter for the ExpandDepth property. Fixes bug #490860 2009-04-01 Marek Habersack * AssemblyBuilder.cs: CSharpCodePragmaGenerator.ReserveSpace: added the 2 extra chars to pragmaChecksumStaticCount constant (the ones added by Gonzalo below) and removed one NewLine to account for Martin's change below. VBCodePragmaGenerator.ReserveSpace - one newline follows #ExternalSource. VBCodePragmaGenerator.DecorateFile - one newline follows #ExternalSource. 2009-04-01 Martin Baulig * AssemblyBuilder.cs: Don't emit a blank line after the #line as thid'd cause all line numbers to be off by 1. 2009-03-31 Gonzalo Paniagua Javier * AssemblyBuilder.cs: the guid has to be quoted. 2009-03-31 Marek Habersack * All of the below are part of the fix for bug #489687 * ThemeDirectoryCompiler.cs: pass VirtualPath instances to parser constructors. * BuildProvider.cs: associated virtual path is stored internally as an instance of VirtualPath, accessible via new VirtualPathInternal property. * BuildManagerDirectoryBuilder.cs: VirtualPath.IsFake is used to detect fake virtual paths. GetBuildProvider now takes a VirtualPath instead of string for the virtualPath parameter. The passed VirtualPath instance is passed unchanged to BuildProvider. * BuildManager.cs: AssertVirtualPathExists now uses VirtualPath.IsFake to check for fake virtual paths. * ApplicationFileBuildProvider.cs, GenericBuildProvider.cs, MasterPageBuildProvider.cs, PageBuildProvider.cs, ThemeBuildProvider.cs, UserControlBuildProvider.cs, WebHandlerBuildProvider.cs, WebServiceBuildProvider.cs: CreateParser overloads now take a VirtualPath instead of a string for the virtualPath parameter. * ThemeBuildProvider.cs: use new parser constructors which take VirtualPath instances instead of strings. 2009-03-30 Marek Habersack * AspTokenizer.cs: UpdateChecksum - fixed off-by-one bug when processing the checksum buffer. * AssemblyBuilder.cs: introduced a kludge to add #pragma checksum and #pragma lines (or its vb equivalent - #ExternalSource) to code-behind files named in the CodeFile/Src directives while copying them to the dynamic directory for compilation. The kludge works by recognizing the .cs and .vb extensions and wrapping the file contents in the appropriate directives. This is done in this way because the other possible way, using the CodeSnippetCompileUnit, requires the entire file to be read in memory and then passed to CodeDOM. We fall back to this way when the file being copied is neither C# or VB. 2009-03-25 Marek Habersack * AspTokenizer.cs: MD5 checksum calculation happens here. It's done incrementally as characters are read. * AspParser.cs: the MD5 checksum is no longer computed here. Moved to AspTokenizer. After parsing, both the tokenizer and the string reader are disposed of. * AssemblyBuilder.cs: renamed CopyFile to CopyFileWithChecksum, in prepration for future inclusion of checksum and line pragmas in the file being copied. Files are copied chunk by chunk, not by reading the entire contents. 2009-03-23 Zoltan Varga * PageCompiler.cs: Fix the build. 2009-03-23 Marek Habersack * TemplateBuildProvider.cs: add values of the CodeFile and Src page/master/control directives to the list of file dependencies. Extract language also for master/page, not only for controls. * PageCompiler.cs: CreateConstructors now triggers master page build, if the current page is using one. Fixes bug #487857 2009-03-16 Marek Habersack * AspGenerator.cs: when parsing nested tags (includes tags inside client-side javascript script blocks) pass the closing tag up to the containing parser. Instead of parsing the whole plain text contents, plus the two constructs we're interested in from it using regexs. This is necessary as we might be passed JavaScript code and without understanding its syntax we'll confuse the '<' character for the start of a tag. TagParsed now better handles