Skip to content

Expose SemanticModel functionality from the Expression Compiler #423

@amcasey

Description

@amcasey

In order to provide the full editing experience in the Watch and Immediate windows, we'll need to provide a SemanticModel for the editor services to consume. This will enable scenarios such as semantic colorization and Intellisense, even in cases where source is not available.

Presently, the expression compiler constructs a custom binder chain based on inputs from the debugger (rather than from source or metadata, as in the compiler). It should be possible construct a SemanticModel that wraps this binder.

Less clear, is how to expose this SemanticModel from the expression compiler. Since the lifetime of the expression compiler is controlled by the debugger, it seems most likely that the debugger will need to expose a new API that the expression compiler can implement and the editor can call. Since the debugger is unlikely to take a dependency on Microsoft.CodeAnalysis, we'll either have to pass the SemanticModel around as object or return a different sort of object, from which a SemanticModel can be constructed.

Metadata

Metadata

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions