Discuss selective application of representer
まだ誰も着手していません。
評価
調査の方向性
ファイル、テスト、エントリポイントについては何も言及されていません。まず現在の C# の書き換えテーブルと3つのポリシー上の問いを確認してください。この issue は、選択的な書き換え、概念の依存関係、将来の representer の変更についてプロジェクトとして合意された見解が得られた時点で完了です。
索引モデルが issue の本文から書いたものです。
説明
Whilst many representer rewrites need to be applied to all exercises there are cases where a rewrite should be disabled for a particular exercise. For example, the readonly modifier should not be removed from code in the constants exercise where the concept is introduced.
The requirement to disable a rewrite for the exercise in which the related concept is introduced is fairly clear cut. However, the related issue of whether a rewrite should be disabled where its inclusion would prevent good/bad practice being reported to the student needs some discussion.
Which of the following is Excercism's position:
A. "Once a concept (which may be associated with some good practice or other) has been introduced then a rewrite that would suppress the good practice should be disabled and bad practice reported to the student"
or
B. "Reports to the student should be concerned only with the concepts that the exercise is designed to demonstrate"
Good practice relates to the writing of robust, maintainable and performant code.
These are the current C# rewrites:
| Rewrite | Concept | Excercise | Good Practice Importance |
|---|---|---|---|
| Add Braces | None | None | None |
| Expression extensions | ?? | ?? | ?? |
| Invert Neg Conditions | None | None | None |
| exponnt form to ucase | None | None | None |
| normalize identifiers | basics | basics | High |
| normalize whitespace | None | None | None |
| remove comments | None | None | None |
| optional parentheses | None | None | None |
| remove readonly | readonly | constants | High |
| remove usings | accessibility | namespaces | None |
| simplify bool equals | booleans | booleans | Medium |
| String->string | strings | strings | Low |
| Fully Qualified Name | basics | basics | Very Low |
Although Identifiers are a major element in good practice and rewriting will eface them, the practicalities of representations rule out dealing with them as we would wish in the concept exercises.
Of the current rewrites, removing readonly has a fairly high impact on good practice and simplifying boolean expressions (if (x == true) -> if (x)) is medium to high. casing string less important and reducing fully qualified names is low (maybe because it would probably take care of itself - I think we are entitled to rely on that).
Three questions:
-
Should we disable rewrites for exercises where there is a dependency on a concept with high or medium importance?
-
Should we increase the number of exercises where concepts which have a high or medium good practice importance are taken as a dependency?
-
What kind of rewrites will be added to the representer in the future?
- 主要言語
- C#
- スター
- 1
- フォーク
- 7
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートなし
- コントリビューションガイドなし
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
exercism/csharp-representer のほかの issue
-
難易度 4/5 3〜5日 初心者へのやさしさ 25/100
-
Enable nullablesオープン
難易度 2/5 1〜3時間 初心者へのやさしさ 35/100
exercism/csharp-representer#18 · コメント 2 件 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 35/100
exercism/csharp-representer#11 · コメント 1 件 ·
-
Normalize `readonly`オープン
難易度 5/5 1週間以上 初心者へのやさしさ 20/100
exercism/csharp-representer#4 · コメント 1 件 · リアクション 1 件 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 25/100
exercism/csharp-representer#3 · コメント 1 件 · リアクション 2 件 ·
exercism/csharp-representer の issue をすべて見る
似ている issue
-
bug effort:S P3
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
nightscout/nocturne#3136 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 67/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 76/100
GameShowLDA/AskMkiM#1075 ·
メンテナーはふだん 1 日以内に返信
-
is:fix
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信