www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - function app.download (string[] links) is not callableusing argument

reply "Suliman" <evermind live.ru> writes:
I try to compile simple example:

import std.net.curl;

void main()
{
download("ftp.digitalmars.com/sieve.ds", 
"D:\\Project\\2014\\txt_downloader\\img\\1.foo");

}

but I am getting error:

function app.download (string[] links) is not callableusing 
argument types (string, string)
Nov 27 2014
next sibling parent reply "Suliman" <evermind live.ru> writes:
Look like it was missed installation or so. I installed new copy 
of dmd and error gone away.
Nov 27 2014
parent "Suliman" <evermind live.ru> writes:
The downloading still do not work. Work only:

get("dlang.org");
Nov 27 2014
prev sibling next sibling parent reply Daniel =?UTF-8?B?S296w6Fr?= via Digitalmars-d-learn writes:
V Thu, 27 Nov 2014 13:39:40 +0000
Suliman via Digitalmars-d-learn <digitalmars-d-learn puremagic.com>
napsáno:

 I try to compile simple example:
 
 import std.net.curl;
 
 void main()
 {
 download("ftp.digitalmars.com/sieve.ds", 
 "D:\\Project\\2014\\txt_downloader\\img\\1.foo");
 
 }
 
 but I am getting error:
 
 function app.download (string[] links) is not callableusing 
 argument types (string, string)
please try std.net.curl.download("ftp.digitalmars.com/sieve.ds", "D:\\Project\\2014\\txt_downloader\\img\\1.foo"); seems you have some name colision
Nov 27 2014
parent reply "Evil Satanson" <ihatewindoz gmail.com> writes:
On Thursday, 27 November 2014 at 14:35:08 UTC, Daniel Kozák via 
Digitalmars-d-learn wrote:
 V Thu, 27 Nov 2014 13:39:40 +0000
 Suliman via Digitalmars-d-learn 
 <digitalmars-d-learn puremagic.com>
 napsáno:

 I try to compile simple example:
 
 import std.net.curl;
 
 void main()
 {
 download("ftp.digitalmars.com/sieve.ds", 
 "D:\\Project\\2014\\txt_downloader\\img\\1.foo");
 
 }
 
 but I am getting error:
 
 function app.download (string[] links) is not callableusing 
 argument types (string, string)
please try std.net.curl.download("ftp.digitalmars.com/sieve.ds", "D:\\Project\\2014\\txt_downloader\\img\\1.foo"); seems you have some name colision
He has, I've seen his whole code. And it's pretty obviuse :-D Let him guess what it is xD
Nov 27 2014
parent reply "Suliman" <evermind live.ru> writes:
Running .\txtdownloader.exe
std.stream.OpenException std\stream.d(50): Cannot open or create 
file 'D:\Projec
t\2014\txt_downloader\img\1.foo'
----------------
0x0041BA59 in void std.stream.File.open(immutable(char)[], 
std.stream.FileMode)
0x00404B75 in void 
std.net.curl.download!(std.net.curl.AutoProtocol).download(co
nst(char)[], immutable(char)[], std.net.curl.AutoProtocol) at 
C:\DMD\dmd2\window
s\bin\..\..\src\phobos\std\net\curl.d(268)
0x00402038 in _Dmain
0x0041250C in void rt.dmain2._d_run_main(int, char**, extern (C) 
int function(ch
ar[][])*).runAll().void __lambda1()
0x004124DF in void rt.dmain2._d_run_main(int, char**, extern (C) 
int function(ch
ar[][])*).runAll()
0x004123F8 in _d_run_main
0x0040D268 in main
0x0045CF9D in mainCRTStartup
0x75C0336A in BaseThreadInitThunk
0x77679F72 in RtlInitializeExceptionChain
0x77679F45 in RtlInitializeExceptionChain
Error executing command run: Program exited with code 1
Nov 27 2014
parent reply "Suliman" <evermind live.ru> writes:
Oh! It's work! I forgot to change path on my home PC!
Nov 27 2014
parent reply "Suliman" <evermind live.ru> writes:
Is there any way to detect where collision was occurred?
Nov 27 2014
next sibling parent "Suliman" <evermind live.ru> writes:
On Thursday, 27 November 2014 at 17:39:10 UTC, Suliman wrote:
 Is there any way to detect where collision was occurred?
It's look like collision was with method name.
Nov 27 2014
prev sibling parent Daniel Kozak via Digitalmars-d-learn <digitalmars-d-learn puremagic.com> writes:
Dne Thu, 27 Nov 2014 18:39:09 +0100 Suliman via Digitalmars-d-learn  
<digitalmars-d-learn puremagic.com> napsal(a):

 Is there any way to detect where collision was occurred?
Yes, read error description it has been app.download I guess -- Vytvořeno poštovní aplikací Opery: http://www.opera.com/mail/
Nov 27 2014
prev sibling parent "Evil Satanson" <ihatewindoz gmail.com> writes:
On Thursday, 27 November 2014 at 13:39:41 UTC, Suliman wrote:
 I try to compile simple example:

 import std.net.curl;

 void main()
 {
 download("ftp.digitalmars.com/sieve.ds", 
 "D:\\Project\\2014\\txt_downloader\\img\\1.foo");

 }

 but I am getting error:

 function app.download (string[] links) is not callableusing 
 argument types (string, string)
You are fucking retard, bro :) This code works, but you're not showing the rest of it :-D
Nov 27 2014