Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 62 additions & 0 deletions .github/copilot-instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# Copilot Instructions for EfficientUnionGenerator

## What's this file for?

- This file provides instructions for generating source or operating as an agent
for this repository to GitHub Copilot or other AI code assistants.
- When implementing new features, please use the technology selection,
design policy, and module configuration shown here as a premise.
- If in doubt, explore the files in the repository and ask the user "Is this
what you meant?"

## Preconditions

- The comments or documentations in the source codes must be in English unless
there is specific instructions.
- The answer in the shell writes in user local language as possible as.
- When making code changes, if the number of lines modified is likely to exceed
200, please prompt the user beforehand with the message: "This instruction may
result in over 200 lines of code being modified. Do you wish to proceed?"
- When making significant changes, first create a plan outlining what you intend
to do, then propose it to the user by saying, "We plan to proceed with this
approach." If the user requests modifications to the plan at this stage,
revise the plan accordingly and resubmit it.

## Project overview

EfficientUnionGenerator is a C# source generator to implement union types
without boxings for unmanaged members. EfficientUnionGenerator supports both
type identifier mode: external member and bit-convolute member.


Please refer to the [README.md](../README.md) for more details about the
project, including its features, installation instructions, and usage examples.

## Directories and files

This project has the following directory structure:

```
./
+-- .editorconfig # Editor configuration file
+-- .gitignore # Git ignore file
+-- EfficientUnionGenerator.slnx # Visual Studio solution file
+-- LICENSE.txt # License information for the project
+-- README.md # Project overview and documentation
+-- global.json # .NET SDK version configuration
+-- .github/
| +-- workflows/ # GitHub Actions workflow files
| | +-- dotnet-CI.yml # CI workflow for .NET builds and tests
| +-- copilot-instructions.md # This file: instructions for GitHub Copilot
+-- resources/ # Misc. resource files for the project
+-- src/ # Source code for the library
| +-- EfficientUnionGenerator/ # Main library code
+-- EfficientUnionGenerator.Test/ # Unit tests for the library
+-- EfficientUnionGenerator.SampleApp/ # Sample application demonstrating library usage
```

## Coding style

- Unless specific commented, the coding style should follow .editorconfig file.
- Unless specific commented, the coding style should follow the [Microsoft C# coding conventions](https://learn.microsoft.com/en-us/dotnet/csharp/fundamentals/coding-style/coding-conventions).
- All of public members must have XML documentation comments.
28 changes: 28 additions & 0 deletions .github/workflows/dotnet-CI.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: .NET Core CI

on:
push:
branches: [ "main", "develop" ]
pull_request:
branches: [ "main", "develop" ]

jobs:
build-and-test:
runs-on: [windows-latest]

steps:
- name: Checkout
uses: actions/checkout@v4

- uses: actions/setup-dotnet@v5
with:
dotnet-version: '10.0.x'

- name: Restore dependencies
run: dotnet restore EfficientUnionGenerator.slnx

- name: Build solution
run: dotnet build EfficientUnionGenerator.slnx --no-restore

- name: Run tests
run: dotnet test EfficientUnionGenerator.slnx --no-build --verbosity normal
2 changes: 1 addition & 1 deletion EfficientUnionGenerator.slnx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<Solution>
<Project Path="src/EfficientUnionGenerator.DebugApp/EfficientUnionGenerator.DebugApp.csproj" Id="328c4817-42f5-44d3-be03-8118c44d1d58" />
<Project Path="src/EfficientUnionGenerator.SampleApp/EfficientUnionGenerator.SampleApp.csproj" Id="328c4817-42f5-44d3-be03-8118c44d1d58" />
<Project Path="src/EfficientUnionGenerator.Test/EfficientUnionGenerator.Test.csproj" Id="b0f436db-3eee-48fb-aaf8-264e78a1a938" />
<Project Path="src/EfficientUnionGenerator/EfficientUnionGenerator.csproj" Id="7b1b2fc2-1729-497a-be6a-5970166dc8b6" />
</Solution>
2 changes: 1 addition & 1 deletion src/EfficientUnionGenerator/Properties/launchSettings.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"profiles": {
"プロファイル 1": {
"commandName": "DebugRoslynComponent",
"targetProject": "..\\EfficientUnionGenerator.DebugApp\\EfficientUnionGenerator.DebugApp.csproj"
"targetProject": "..\\EfficientUnionGenerator.SampleApp\\EfficientUnionGenerator.SampleApp.csproj"
}
}
}
Loading