A D package containing my single-file modules
リビジョン | 7efd91427f30bbf776cd4db993c19a3462b724a8 (tree) |
---|---|
日時 | 2023-03-19 15:24:14 |
作者 | nemophila <stigma+osdn@disr...> |
コミッター | nemophila |
trash: Fix compiling on Linux
Fix a compiler warning about unreachable code. By default, dub
treats these (and any) warnings as errors.
@@ -161,19 +161,19 @@ private: | ||
161 | 161 | ulong getDevice(string path) { |
162 | 162 | version (Posix) { |
163 | 163 | return _posix_getDevice(path); |
164 | + } else { | |
165 | + // Not used on Windows | |
166 | + return 0; | |
164 | 167 | } |
165 | - | |
166 | - // Not used on Windows | |
167 | - return 0; | |
168 | 168 | } |
169 | 169 | |
170 | 170 | string getHomeDirectory() { |
171 | 171 | version (Posix) { |
172 | 172 | return environment["HOME"]; |
173 | + } else { | |
174 | + // Not used on Windows | |
175 | + return ""; | |
173 | 176 | } |
174 | - | |
175 | - // Not used on Windows | |
176 | - return ""; | |
177 | 177 | } |
178 | 178 | |
179 | 179 | bool isParent(string parent, string path) { |