Skip to content
This repository has been archived by the owner on Dec 19, 2018. It is now read-only.

Create LineMappings for 0 length spans to ensure IntelliSense is provided when typing @ #1155

Closed
NTaylorMullen opened this issue Apr 3, 2017 · 2 comments
Assignees

Comments

@NTaylorMullen
Copy link
Member

We no longer generate line mappings for 0 length spans but at design time we must. It enables a user typing the at symbol by itself and getting IntelliSense.

@NTaylorMullen NTaylorMullen added this to the 2.0.0-preview1 milestone Apr 3, 2017
@NTaylorMullen NTaylorMullen self-assigned this Apr 3, 2017
NTaylorMullen added a commit that referenced this issue Apr 3, 2017
- At design time we weren't generating line mappings when a user would type `@` or `@(`. This results in no C# IntelliSense being provided to the user because the editor hasn't mapped any of Razor to the C# buffer.
- Updated the design time renderer and design time writer to account for empty expressions.
- Modified the `DefaultIRLoweringPhase` to set source locations on empty expression nodes.
- Re-generated test files to account for 0 length line mappings on empty expression nodes.

#1155
NTaylorMullen added a commit that referenced this issue Apr 3, 2017
- At design time we weren't generating line mappings when a user would type `@` or `@(`. This results in no C# IntelliSense being provided to the user because the editor hasn't mapped any of Razor to the C# buffer.
- Updated the design time renderer and design time writer to account for empty expressions.
- Modified the `DefaultIRLoweringPhase` to set source locations on empty expression nodes.
- Re-generated test files to account for 0 length line mappings on empty expression nodes.

#1155
NTaylorMullen added a commit that referenced this issue Apr 3, 2017
- At design time we weren't generating line mappings when a user would type `@` or `@(`. This results in no C# IntelliSense being provided to the user because the editor hasn't mapped any of Razor to the C# buffer.
- Updated the design time renderer and design time writer to account for empty expressions.
- Modified the `DefaultIRLoweringPhase` to set source locations on empty expression nodes.
- Re-generated test files to account for 0 length line mappings on empty expression nodes.

#1155
NTaylorMullen added a commit that referenced this issue Apr 3, 2017
- At design time we weren't generating line mappings when a user would type `@` or `@(`. This results in no C# IntelliSense being provided to the user because the editor hasn't mapped any of Razor to the C# buffer.
- Updated the design time renderer and design time writer to account for empty expressions.
- Modified the `DefaultIRLoweringPhase` to set source locations on empty expression nodes.
- Re-generated test files to account for 0 length line mappings on empty expression nodes.

#1155
@NTaylorMullen
Copy link
Member Author

NTaylorMullen commented Apr 3, 2017

baf8f4e

NTaylorMullen added a commit that referenced this issue Apr 3, 2017
- At design time we weren't generating line mappings when a user would type `@` or `@(`. This results in no C# IntelliSense being provided to the user because the editor hasn't mapped any of Razor to the C# buffer.
- Modified the `DefaultIRLoweringPhase` to allow for marker symbols, these symbols .
- Re-generated test files to account for 0 length line mappings on empty expression nodes.

#1155
NTaylorMullen added a commit that referenced this issue Apr 3, 2017
- At design time we weren't generating line mappings when a user would type `@` or `@(`. This results in no C# IntelliSense being provided to the user because the editor hasn't mapped any of Razor to the C# buffer.
- Modified the `DefaultIRLoweringPhase` to allow for marker symbols, these symbols .
- Re-generated test files to account for 0 length line mappings on empty expression nodes.

#1155
@rynowak
Copy link
Member

rynowak commented Apr 3, 2017

I'm glad that you fixed this to unblock the tooling experience. The way that this works today is largely an artifact of the current design.

I have some ideas about this, we might want to take a harder look at RazorCSharpDocument before we ship.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants