下記のようにコンパイラの最適化で省略される個所にブレイクポイントを設定できないことがあります。
1 2 3 4 5 6 7 8 |
while (num_of_line > 0) { /* 中略 */ if (num_of_lines < 10) { continue; /* ここにブレイクポイントを設定できない */ } } |
下記のようにコンパイラの最適化で省略される個所にブレイクポイントを設定できないことがあります。
1 2 3 4 5 6 7 8 |
while (num_of_line > 0) { /* 中略 */ if (num_of_lines < 10) { continue; /* ここにブレイクポイントを設定できない */ } } |
///
1 2 3 4 5 6 7 8 9 |
/// <summary> /// Adds two doubles and returns the result. /// </summary> /// <returns> /// The sum of two doubles. /// </returns> /// <param name="a">A double precision number.</param> /// <param name="b">A double precision number.</param> public static double Add(double a, double b) |
Git LFS (Large File Strage) で管理したファイルのチェックアウトを試みると下記のようなエラーとなる
1 |
Encountered 2 file(s) that should have been pointers, but weren't: |
"windows.h" は、16bit版 Windowsのヘッダファイルを多数インクルードしている。WIN32_LEAN_AND_MEAN
を define することで、32bitアプリには不要なヘッダファイルのインクルードを抑止してコンパイル時間を短縮できる。
表計算ソフト(LibreOffice Calc)を使って、SNSなどで使うアイコンをつくってみました。
派生クラスで override することができるのは、基底クラスで virtual をつけたメンバー関数(=仮想関数)だけです。しかし、もし virtualをつけていない(つけるのを忘れた)メンバー関数(=非仮想関数)を派生クラスで override しようと試みると何が起こるでしょうか?
続きを読む
git add の結果を取り消す方法
1 |
$ git reset HEAD mistake.txt |
補足 : ステージングの情報をリセットするだけ。ワーキングやコミットには影響しない。
下記のようなコマンドを実行すれば、コミットもワーキングもリセットする(コミット前に戻す)ことになる。
1 |
$ git reset --hard HEAD^ |
git remote add コマンドを実行するとエラーとなる。
1 2 |
$ git remote add origin https://JaneDoe@dev.azure.com/JaneDoe/MyRepository/_git/MyRepository fatal: remote origin already exists. |
Windows形式の改行コード (CR+LF) の表示 ^M を抑止する方法
下記の例のように行末の ^M が目障りである。
1 2 |
-// Created on: 2019/01/26 9:22:59 +// Created on: 2019/01/26 10:04:07^M |
^M == CR == 0x0A
1 |
$ git config --local core.whitespace cr-at-eol |
1 |
$ git config --local --unset core.whitespace |