- 11 9月, 2014 6 次提交
-
-
由 jasonmalinowski 提交于
-
由 RoslynTeam 提交于
The LexerCache short circuits the lookup of keywords whenever the text is greater than the maximum keyword length. This was being expressed as a hard coded value instead of a named constant. Changed it to be a named constant and added a test to make sure it is up to date with the actual max keyword length (changeset 1333104)
-
由 Basoundr_ms 提交于
-
由 Basoundr_ms 提交于
When extracting trivia inbetween tokens, there are cases where the token themselves are trivia. In those cases, the contract and the extraction logic for the trivia should adjusted accordingly. (changeset 1333042)
-
由 ChuckStoner 提交于
-
由 manishv 提交于
Command line compilers: Do not attach analyzer driver queue to compilation if there are no diagnostic analyzers to execute. (changeset 1332881)
-
- 10 9月, 2014 34 次提交
-
-
由 VSadov 提交于
That is - regardless of the presence of parameterized or primary constructors. In this implementation if a struct without a primary constructor has initializers and parameterless constructor is not present, we synthesize one to ensure that "new S1()" runs initializers. ***NO_CI*** (changeset 1332600)
-
由 manishv 提交于
-
由 ChuckStoner 提交于
-
由 manishv 提交于
Fix for bug 1022125: diagnostic analyzer service shouldn't load diagnostic analyzer before it is actually used This change refactors the IDE diagnostic service to track per-language workspace analyzers (VSIX based analyzers). Each analyzer assembly reference created for every analyzer asset is now queried for analyzers in context of a language, hence avoiding instantiating analyzers targeting a different language. Additionally, now that we use the MetadataReader instead of Reflection based Assembly load to find diagnostic analyzer types within an analyzer assembly, we will delay loading of language specific analyzer assemblies until it is queried for analyzers for that language. (changeset 1332021)
-
由 srivatsn 提交于
The AnalyzerFileReference type is responsible for loading a dll and instantiating individual analyzer types. We were enumerating all available types through reflection. This was the root cause of very poor error messages for diagnostic authors while writing analyzers. Since we are loading an assembly to even determine what language the analyzers are for, we end up loading more assemblies than are needed in the VS process. This change solves both of those issues by making the following changes: - Read the file using the metadata reader to determine all types that have the DiagnosticAnalyzerAttribute. Build a map of language -> analyzer typenames so that we can avoid loading the assembly if there are no types for the language of interest. - The DiagnosticAnalyzerAttribute used to take a params array of strings - changing it to be a single string with allow multiple to keep the parsing simple. - Extract the error handling code out to an event so that hosts can report errors encountered during analyzer loading. (changeset 1331893)
-
由 angocke 提交于
-
由 acasey 提交于
In dev12, it was possible to F11 a WinForms app and stop at (or just before) the Main method. As far as I can tell, the debugger was stopping on the first sequence point in My.MyApplication.Main, which Roslyn suppresses. Since there might be related scenarios that depend on having sequence points in the MyTemplate methods, just emit them all. Small difference from dev12: They generate GUID names for the MyTemplate files, whereas we just leave the filenames blank. The debugger doesn't seem to care (there's no file either way). There's no corresponding bug in C# because the Main method exists in a regular source file. (changeset 1332162)
-
由 acasey 提交于
On its own, this change seems kind of silly - instead of consuming a mangled name from the PDB, we set the name to null. The main benefit is that other PDB producers have a way to communicate to the EE that certain locals should not be consumed, regardless of how they are named. (changeset 1332108)
-
由 chandera 提交于
When computing the accessibility of operators on pointer types, use the accessibility of the pointer type itself. (changeset 1332023)
-
由 manishv 提交于
Fix for bug 1022125: diagnostic analyzer service shouldn't load diagnostic analyzer before it is actually used This change refactors the IDE diagnostic service to track per-language workspace analyzers (VSIX based analyzers). Each analyzer assembly reference created for every analyzer asset is now queried for analyzers in context of a language, hence avoiding instantiating analyzers targeting a different language. Additionally, now that we use the MetadataReader instead of Reflection based Assembly load to find diagnostic analyzer types within an analyzer assembly, we will delay loading of language specific analyzer assemblies until it is queried for analyzers for that language. (changeset 1332021)
-
由 srivatsn 提交于
The AnalyzerFileReference type is responsible for loading a dll and instantiating individual analyzer types. We were enumerating all available types through reflection. This was the root cause of very poor error messages for diagnostic authors while writing analyzers. Since we are loading an assembly to even determine what language the analyzers are for, we end up loading more assemblies than are needed in the VS process. This change solves both of those issues by making the following changes: - Read the file using the metadata reader to determine all types that have the DiagnosticAnalyzerAttribute. Build a map of language -> analyzer typenames so that we can avoid loading the assembly if there are no types for the language of interest. - The DiagnosticAnalyzerAttribute used to take a params array of strings - changing it to be a single string with allow multiple to keep the parsing simple. - Extract the error handling code out to an event so that hosts can report errors encountered during analyzer loading. (changeset 1331893)
-
由 angocke 提交于
-
由 shyamn 提交于
Note: C# and VB behaviors are different for /warnaserror. VB always allows /warnaserror-:xyz to override /warnaserror (i.e. specific option always overrides general one). C# on the other hand allows the last of these options specified on the command line to win - so if /warnaserror:xyz is followed by /warnaserror, then xyz is promoted to an error - but if /warnaserror:xyz follows /warnaserror, then xyz stays as a warning. We can't make the behavior for the two languages identical because we need to maintain backwards compatibility. (changeset 1331612)
-
由 wochae 提交于
During lowering Async method, we generate labels for state machine transition and this information is also consumed by Debugger through Pdb. Not realizing that debugger relies on this information, C# generates one additional label "Initial state" at the beginning of rewriting, which adds 1 to state numbering, causing index mismatch between state number and async-info in Pdb (since Pdb does not contain intiail state). It turns out we don't need to create this "initial state" label since we set the default value to be -1 (representing 'NotStartedStateMachine') in the constructor and dispatch will fail and fall through to the body part where "initial state" label locates. Note that VB async has already been implemented in this manner. This shelvset removes creation/use of initial states in C# and clean up affected test cases. (changeset 1331364)
-
由 angocke 提交于
Change projects to reference the Proprietary Resources NuGet package versus the project. (changeset 1331358)
-
由 tmeschter 提交于
-
由 Kevin_H 提交于
Delete test associated with "Won't Fix" bug (effort to keep it running would yield net negative returns) (changeset 1331314)
-
由 angocke 提交于
-
由 angocke 提交于
Change the NativeClient and NativeClientTests projects to use v4.0 build tools for back compat. (changeset 1331209)
-
由 jmarolf 提交于
In the case where we are generating code at the end of a file, and we have missing braces in the code above, we used to fail to add a newline character. We now check for this case and add the necessary newline. (changeset 1331188)
-
由 AlekseyTs 提交于
-
由 BalajiKris 提交于
Do not format within the braces if they're on the same line for array/collection/object initializer expressions. This is a heuristic to prevent brace completion from breaking user expectation/muscle memory in common scenarios. In Dev12 , with auto brace completion enabled, typing { in array, collection, object initializers does not format the brace session range (from { to }). this means users are used to typing in a space right after '{'. In Roslyn, we used to format this and put in the space, thus breaking muscle memory in common typing scenarios. With this change, we revert to Dev12 behavior. some examples: No formatting cases: 1. new int[] {} 2. var x = new { Age = 1 } Formatting still happens for : class C {} int Prop {} The changes themselves are inside 1. BraceCompletion where we format the tracking span 2. SmartTokenFormatting which gets triggered for TypeChar of '{' The change in both places is the same - range to format does not include the '}' (closebrace) token. (changeset 1331104)
-
由 jmarolf 提交于
-
由 angocke 提交于
Update the version of the toolset compilers used for build and make sure that all projects are using the toolset NuGet. (changeset 1330804)
-
由 Kevin_H 提交于
-
由 AlekseyTs 提交于
- Ensure we can build and run tests when current system locale isn’t English. - Move CSC/VBC help strings to resources so that they can be localized. (changeset 1330638)
-
由 heejaechang 提交于
-
由 VSadov 提交于
separated IsParameterlessValueTypeConstructor into IsParameterlessValueTypeConstructor and IsDefaultValueTypeConstructor It is pretty confusing to follow the usage of IsParameterlessValueTypeConstructor with optional flag. ***NO_CI*** (changeset 1330578)
-
由 VSadov 提交于
This is consistent with behavior of "new" when used with structs in general - we should call public parameterless constructor if present, which Activator.CreateInstance does. It is also consistent with VB and F# ***NO_CI*** (changeset 1330480)
-
由 tmeschter 提交于
Replace a couple of metadata references with the equivalent project-to-project references. (changeset 1330367)
-
由 vladres 提交于
Fix bug 1020273: Return the same value as the native C# compiler did in unchecked conversion from floating-point types to integral types in constant expressions in case of overflow. The C# spec says the result is unspecified in these cases, but we want to return the same unspecified value as the native compiler. Before this fix, Roslyn returned zero in these cases. (changeset 1330238)
-
由 VSadov 提交于
Making codegen for compound operators over properties with generic receivers same as in Dev12 for compatibility reasons. This affects cases like T x; x.P1 += foo(ref x); x[1] += foo(ref x); ***NO_CI*** (changeset 1330113)
-
由 heejaechang 提交于
Added roslyn diagnostic rule that warns about using generic CodeAction using CodeAction.Create (changeset 1330067)
-
由 AlekseyTs 提交于
- Syntax tree - Parsing - Initial binding - Naive lowering, resulting IL might be inefficient or, in some cases, might be incorrect with respect to preserving side effects in the target. (changeset 1329866)
-