Describe the bug
Example:
// Generated by @typespec/http-server-csharp
// <auto-generated />
#nullable enable
using System;
using System.Collections.Generic;
using System.Text.Json;
using System.Text.Json.Serialization;
using TypeSpec.Helpers;
using TypeSpec.Helpers.JsonConverters;
namespace Microsoft.MyRpNamespace;
/// <summary>
/// Azure API Key Authentication
/// </summary>
public partial class AzureApiKeyAuthentication
{
/// <summary>
/// API key authentication
/// </summary>
[JsonPropertyName("type")]
public <Unresolved Symbol: refkey[sSymbol(emitter-framework:csharp)o28]> Type { get; set; }
/// <summary>
/// location of the API key
/// </summary>
[JsonPropertyName("in")]
public <Unresolved Symbol: refkey[sSymbol(emitter-framework:csharp)o29]> In { get; set; }
/// <summary>
/// name of the API key
/// </summary>
[JsonPropertyName("name")]
public string Name { get; } = "Ocp-Apim-Subscription-Key";
}
result in C# compiler errors:
- The name 'refkey' does not exist in the current context.
- The name 'sSymbol' does not exist in the current context.
- The name 'emitter' does not exist in the current context.
- The name 'framework' does not exist in the current context.
Reproduction
- Use an ARM RP typespec
- Add the following to tspconfig.yaml
emit:
- "@typespec/http-server-csharp"
options:
"@typespec/http-server-csharp":
emitter-output-dir: "{project-root}/generated/{emitter-name}"
output-type: all
emit-mocks: none
overwrite: true
Checklist
Describe the bug
Example:
result in C# compiler errors:
Reproduction
Checklist