Changeset 388
- Timestamp:
- 07/16/08 07:27:30 (5 months ago)
- Files:
-
- trunk/tools/tools/downloader.d (modified) (1 diff)
- trunk/tools/tools/smart_import.d (modified) (2 diffs)
- trunk/tools/tools/threadpool.d (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/tools/tools/downloader.d
r384 r388 6 6 //\todo: complete this 7 7 return s.replace(" ", "%20"); 8 } 9 10 string getFilename(string url) { 11 auto pos1 = url.rfind("/"); 12 if (pos1 == -1) return "index.html"; 13 url = url[pos1+1 .. $]; 14 auto pos2 = url.find("?"); 15 if (pos2 != -1) url = url[0 .. pos2]; 16 if (url.length) return url; 17 else return "index.html"; 8 18 } 9 19 trunk/tools/tools/smart_import.d
r330 r388 11 11 char[] buf; 12 12 while (sup.length) { 13 if (sup[0] == ' |') {13 if (sup[0] == ',') { 14 14 res ~= buf; 15 15 buf = ""; … … 19 19 if (buf.length) res ~= buf; 20 20 } else { 21 if (i[0] == ' ;' || i[0] == ']') {21 if (i[0] == ',' || i[0] == ']') { 22 22 if (buffer.length) { 23 23 res ~= base~buffer; trunk/tools/tools/threadpool.d
r387 r388 1 1 module tools.threadpool; 2 2 public import tools.base; 3 // mixin(expandImport!("std.thread ; tools.[threads; log;functional]"));3 // mixin(expandImport!("std.thread, tools.[threads, log, functional]")); 4 4 import std.thread, tools.threads; 5 5 import tools.log, tools.functional;
