On Sunday, 4 May 2014 at 16:40:08 UTC, Suliman wrote:
I am trying to compile next code:
import std.net.curl;
import std.stdio;
void main()
{
writeln(get(https://google.com/;));
}
and got next error
http://www.everfall.com/paste/id.php?y37dr6qmu54h
this is related to verifying
On Tuesday, 6 May 2014 at 15:13:41 UTC, Artur Skawina via
Digitalmars-d-learn wrote:
On 05/06/14 16:45, via Digitalmars-d-learn wrote:
On Tuesday, 6 May 2014 at 14:25:01 UTC, Artur Skawina via
Digitalmars-d-learn wrote:
I'm not sure why you'd want to wrap the .offsetof expression
in
a
On Tuesday, 13 May 2014 at 08:56:43 UTC, FrankLike wrote:
I want to start the process by std.process.
module main;
import std.process,std.stdio;
void main()
{
string url = http://dlang.org/;;
executeShell(escapeShellCommand(wget, url, -O,
dlang-index.html));
On Tuesday, 13 May 2014 at 10:48:06 UTC, FrankLike wrote:
does it work when you run iexplore localhost:8000 in command
line? is path to iexplore in your windows path?
Ok,I get the answer by myself.
module main;
import std.process,std.stdio;
void main()
{
//spawnProcess(C:\\Program Files
On Wednesday, 14 May 2014 at 17:08:21 UTC, Joakim wrote:
Hi,
Quick question regarding TKD (tkinter):
Is there a way to set focus on the application window
automatically on run? I'm on Mac OS X if that's of any
importance.
I have tried to grep the documentation but I can't find
anything
On Thursday, 15 May 2014 at 17:30:22 UTC, Gary Willoughby wrote:
On Wednesday, 14 May 2014 at 21:23:02 UTC, DaveG wrote:
tkd\window\window.d(426): Error: undefined identifier
CommandCallback
Added the missing import and now all works fine. Fixed in
v1.0.5-beta. Any more issues open them up
On Friday, 16 May 2014 at 04:58:47 UTC, Jack wrote:
A follow up from :
http://forum.dlang.org/thread/nsdomtdbqqlylrmgo...@forum.dlang.org
I discovered that it was not a C::B issue as I already compiled
it with Xamarin Studio and it was still spewing out the error:
On Friday, 16 May 2014 at 09:44:11 UTC, bearophile wrote:
John Colvin:
Any plans to get any preprocessor stuff working?
Do you mean in D?
Bye,
bearophile
i think he means in dstep.
On Wednesday, 3 December 2014 at 02:41:16 UTC, Shriramana Sharma
via Digitalmars-d-learn wrote:
On Tue, Dec 2, 2014 at 10:45 PM, Mayuresh Kathe via
Digitalmars-d-learn digitalmars-d-learn@puremagic.com wrote:
Okay, if that is the case, I'll dive into Mr. Alexandrescu's
book as soon as
I get my
On Saturday, 10 January 2015 at 23:32:47 UTC, bearophile wrote:
Laeeth Isharc:
In D there is a feature that allows a function to accept both
an array of items and items,
yes - it is funny there is not an overloading that accepts
arrays
I meant this D feature:
void foo(T)(T[] items...) {
On Thursday, 8 January 2015 at 11:29:30 UTC, Laeeth Isharc wrote:
this conversation is so funny: well what's wrong with this .
It's a keyword...
Aa Ha ha ha ha , rol.
Seriously, is it so complicated to use a D editor ? I mean
with syntax color...
Man afraid to ask stoopid questions stays
On Sunday, 18 October 2015 at 13:29:50 UTC, Ola Fosheim Grøstad
wrote:
On Sunday, 18 October 2015 at 12:50:43 UTC, Namespace wrote:
On Tuesday, 13 October 2015 at 23:26:14 UTC, Laeeth Isharc
wrote:
https://www.quora.com/Why-is-Python-so-popular-despite-being-so-slow
Andrei suggested posting
On Wednesday, 14 October 2015 at 05:42:12 UTC, Ola Fosheim
Grøstad wrote:
On Tuesday, 13 October 2015 at 23:26:14 UTC, Laeeth Isharc
wrote:
https://www.quora.com/Why-is-Python-so-popular-despite-being-so-slow
Andrei suggested posting more widely.
That's flaimbait:
«Many really popular
On Saturday, 3 October 2015 at 01:41:55 UTC, Laeeth Isharc wrote:
https://www.youtube.com/watch?v=hKcOkWzj0_s
a little old but still relevant. talks about importance of
brevity and strong types for readability (also avoiding
boilerplate). two of the partners there committed to read
every
On Saturday, 3 October 2015 at 16:33:38 UTC, Laeeth Isharc wrote:
On Saturday, 3 October 2015 at 15:58:38 UTC, Mengu wrote:
On Saturday, 3 October 2015 at 01:41:55 UTC, Laeeth Isharc
wrote:
https://www.youtube.com/watch?v=hKcOkWzj0_s
a little old but still relevant. talks about importance of
On Monday, 8 February 2016 at 21:09:47 UTC, cy wrote:
object.member lets me access the member of the object, but what
if I want to access those members in a generic way, but in a
different arrangement depending on context? Like if I wanted to
first follow a tree down, and second priority would
On Monday, 8 February 2016 at 22:46:06 UTC, cy wrote:
On Monday, 8 February 2016 at 22:38:45 UTC, Mengu wrote:
i believe you can use __traits(getMember) there.
Great! Should have refreshed before sending that reply...
I wonder if mixin("a."~member) is better or worse than
On Thursday, 3 August 2017 at 03:59:40 UTC, Johnson Jones wrote:
How can be use gtkD to load images, I assume through gdkpixbuf?
While I am getting errors loading images through glade's image:
(test.exe:8188): Gtk-[1;33mWARNING[0m **: Could not load
image 'a.jpg': Couldn't recognize the
On Monday, 14 August 2017 at 13:48:36 UTC, Dominikus Dittes
Scherkl wrote:
if I use fixed-type functions, I can do the following:
uint foo(uint n)
{
++n; // modify n - as this function has received a copy of
n, this is always possible
return 42;
}
uint bar(const uint n)
{
On Saturday, 23 September 2017 at 11:23:26 UTC, Nicholas Wilson
wrote:
On Saturday, 23 September 2017 at 08:45:00 UTC, Mengu wrote:
[...]
So it fails:
trying to find if an element exists in an AA
in a regex
invoked as a callback from curl
inside a parallel foreach.
Interesting that it just
hi all
i've successfully compiled phobos master with gmake on freebsd.
(make fails, i've no clue at all as to why)
how do i compile my project now against my local phobos with dub?
with plain dmd?
i tried (in dub.sdl):
- full path to new libphobos.so with -defaultlib to dflags
- full path
hello everyone
i have a small program that parses an xml file, holding a list
with 13610 elements. after making the list, it iterates over the
list (paralele), goes to a web site and grabs the related data
for that element.
it works perfect for the first 1K element in the list. after that
On Tuesday, 26 September 2017 at 17:06:28 UTC, drug wrote:
26.09.2017 00:34, Mengu пишет:
[...]
not big deal probably, but isn't ~32GB enormous value here? I
would check why bigDataFun return this.
i could not find out why.
d certainly needs to improve on freebsd. i don't think devs
On Monday, 25 September 2017 at 21:34:40 UTC, Mengu wrote:
hi all
this following code block [0] is exiting with "terminated by
signal SIGBUS (Misaligned address error)" error. it processes
like 200K rows and then fails. any ideas?
[...]
hi all
does anyone else have any ideas?
On Friday, 29 September 2017 at 02:34:08 UTC, DreadKyller wrote:
On Thursday, 28 September 2017 at 14:01:33 UTC, user1234 wrote:
[...]
I understand that, but because the operator isn't defined
normally for classes unless overloaded, then your statement
about this being an inconsistency on
On Tuesday, 26 September 2017 at 00:36:36 UTC, Vladimir Panteleev
wrote:
On Monday, 25 September 2017 at 21:34:40 UTC, Mengu wrote:
delete fileContents;
This looks suspicious - it is a slice of the memory-mapped
file, not memory on the GC-managed heap, so "delete" is
inapplicable to it.
hi all
this following code block [0] is exiting with "terminated by
signal SIGBUS (Misaligned address error)" error. it processes
like 200K rows and then fails. any ideas?
void getHotels() {
import std.parallelism : taskPool;
import std.functional : partial;
auto sunHotels =
On Wednesday, 27 September 2017 at 17:58:27 UTC, Ali Çehreli
wrote:
On 09/27/2017 08:33 AM, Ky-Anh Huynh wrote:
> [...]
Wissner wrote:
> [...]
The fact that such an important operator is explained so late
in the book is due to the book's strong desire to have a linear
flow.
[...]
ustad,
On Sunday, 3 December 2017 at 20:05:47 UTC, bitwise wrote:
I've finally started learning git, due to our team expanding
beyond one person - awesome, right? Anyways, I've got things
more or less figured out, which is nice, because being clueless
about git is a big blocker for me trying to do
On Tuesday, 5 December 2017 at 14:01:35 UTC, Marc wrote:
On Tuesday, 5 December 2017 at 13:40:08 UTC, Daniel Kozak wrote:
but this will change all other uppercase to lowercase, so
maybe it is not what you want. If you really want just change
first char to upper, then there is nothing wrong to
On Thursday, 14 December 2017 at 14:07:25 UTC, Adam D. Ruppe
wrote:
I was playing with this myself based on Jacob's code and made
it look like this:
extern (Objective-C) interface ViewController :
NSViewController {
extern (C)
@ObjCMethodOverride("loadView")
static
On Saturday, 16 December 2017 at 14:05:28 UTC, Vino wrote:
On Saturday, 16 December 2017 at 13:59:11 UTC, Vino wrote:
On Saturday, 16 December 2017 at 12:39:53 UTC, Kagamin wrote:
[...]
H, All,
Are are also getting the same exception on Windows after
updating the dmd to version v2.077.1,
On Wednesday, 6 December 2017 at 12:43:09 UTC, Fredrik Boulund
wrote:
On Wednesday, 6 December 2017 at 10:42:31 UTC, Dgame wrote:
Or you simply do
writeln("longword".array.sort);
This is so strange. I was dead sure I tried that but it failed
for some reason. But after trying it
On Tuesday, 5 December 2017 at 14:34:57 UTC, Mengu wrote:
On Tuesday, 5 December 2017 at 14:01:35 UTC, Marc wrote:
On Tuesday, 5 December 2017 at 13:40:08 UTC, Daniel Kozak
wrote:
[...]
Yes, this is not what I want. I want to convert only the first
letter of the word to lower case and left
On Wednesday, 20 December 2017 at 18:04:57 UTC, Ali Çehreli wrote:
On 12/20/2017 07:02 AM, ChangLong wrote:
> [...]
is not
> [...]
The problem is not with opAssign but with left(), which returns
an rvalue. It's by design that rvalues cannot be bound to
references in D.
[...]
was just
On Wednesday, 20 December 2017 at 16:54:35 UTC, Marc wrote:
Give this function I'd like to run it at compile time:
import std.concurrency : Generator, yield;
[...]
but when I do:
[...]
I get the following erros:
On Saturday, 30 December 2017 at 19:00:07 UTC, aliak wrote:
On Friday, 29 December 2017 at 20:47:44 UTC, Dukc wrote:
[...]
Hmm, interesting. Not sure that's what I'm looking for but I
like it anyway :)
I'm more looking to deal with situations like this:
Instead of this:
auto result =
On Monday, 25 December 2017 at 12:03:32 UTC, aliak wrote:
Hi, been looking for a way to convert an array to a tuple, but
can't seem to find one. Is there one?
Looking for something like:
alias Point = Tuple!(int, "x", int, "y");
enum data = "1,2:8,9";
auto points = data
.split(':')
On Monday, 25 December 2017 at 14:12:32 UTC, Marc wrote:
Does to!(string)(char[]) do any memory allocation on conversion
or is this similar to a cast or what else?
yes, it is allocating memory. you can test such cases with @nogc
[0].
you can get a char[] via .dup of a string and then you
On Monday, 25 December 2017 at 16:13:48 UTC, Thomas Mader wrote:
Hello,
I would like to set the path to a directory at compile time but
it doesn't seem to be possible yet.
I tried it with a -version=CustomPath argument and inside the
version statement in the code I tried to read the value
On Friday, 29 December 2017 at 13:08:38 UTC, rikki cattermole
wrote:
On 29/12/2017 12:59 PM, rjframe wrote:
On Fri, 29 Dec 2017 12:39:25 +, Nicholas Wilson wrote:
[...]
I've actually thought about doing this to get rid of a bunch
of if
qualifiers in my function declarations. `static
On Friday, 5 January 2018 at 13:02:12 UTC, qznc wrote:
I'm exploring [0] C++ interop after watching Walter's
presentation [1].
I hit a block with classes as template parameters. This means
vector works, but vector does not. D seems to map
vector!Foo to vector. Likewise shared_ptr is a
On Saturday, 23 December 2017 at 08:57:18 UTC, kerdemdemir wrote:
On Friday, 22 December 2017 at 23:33:55 UTC, Mengu wrote:
On Thursday, 21 December 2017 at 21:11:58 UTC, Steven
Schveighoffer wrote:
On 12/21/17 4:00 PM, kerdemdemir wrote:
I have a case like :
http://rextester.com/NFS28102
I
On Tuesday, 9 January 2018 at 07:57:19 UTC, Vino wrote:
Hi All,
Request your help on how to create a struct with the output of
the below program.
Program:
import std.algorithm: all, map, filter;
import std.stdio: File, writeln;
import std.typecons: Tuple, tuple;
import std.container.array;
On Tuesday, 26 December 2017 at 00:47:14 UTC, Marc wrote:
something like this:
struct S {
// variables...
string doGen(int n) { return ""; }
alias gen = memoize!doGen;
}
The error I got is:
Error: need 'this' for 'doGen' of type 'string(int n)'
I can't make doGen static because it
On Monday, 25 December 2017 at 22:58:50 UTC, David Nadlinger
wrote:
On Monday, 25 December 2017 at 20:39:52 UTC, Mengu wrote:
is partially applying templates possible?
Check out std.meta.Apply{Left, Right}.
— David
thanks a lot mr. smith & david.
On Wednesday, 27 December 2017 at 23:47:14 UTC, Biotronic wrote:
[...]
much, much better. thanks biotronic.
On Friday, 22 December 2017 at 17:53:34 UTC, Marc wrote:
How can I create a alias to a struct method?
struct S {
string doSomething(int n) { return ""; }
}
I'd like to do something like this (imaginary code):
alias doSomething = S.doSomething;
then call it by doSomething(3)
I got the
On Friday, 22 December 2017 at 22:09:05 UTC, H. S. Teoh wrote:
On Fri, Dec 22, 2017 at 09:13:31PM +, kerdemdemir via
Digitalmars-d-learn wrote:
I want to make a logging function for member variables by
using reflection.
[...]
class B
{
void Log()
{
auto a =
On Thursday, 21 December 2017 at 21:11:58 UTC, Steven
Schveighoffer wrote:
On 12/21/17 4:00 PM, kerdemdemir wrote:
I have a case like :
http://rextester.com/NFS28102
I have a factory method, I am creating some instances given
some enums.
My question is about :
void PushIntoVector(
On Thursday, 21 December 2017 at 18:45:27 UTC, Adam D. Ruppe
wrote:
On Thursday, 21 December 2017 at 18:20:19 UTC, H. S. Teoh wrote:
When the scoped destruction of structs isn't an option,
RefCounted!T seems to be a less evil alternative than an
unreliable class dtor. :-/
Alas, RefCounted
is partially applying templates possible?
On Wednesday, 27 December 2017 at 21:39:49 UTC, Mengu wrote:
On Wednesday, 27 December 2017 at 20:54:17 UTC, bitwise wrote:
[...]
there's also a simple workaround for fields with the same type:
https://run.dlang.io/is/dsFajq
import std.stdio;
struct S {
int x;
int y;
}
auto
On Wednesday, 27 December 2017 at 20:54:17 UTC, bitwise wrote:
On Wednesday, 27 December 2017 at 20:04:29 UTC, Marc wrote:
I'd like to set the members of a class by its name at runtime,
I would do something like this:
__traits(getMember, myClass, name) = value;
but since name is only know
On Wednesday, 7 February 2024 at 22:16:54 UTC, Alexander Zhirov
wrote:
Is there a way to identify a client by MAC address when using
the Vibe library?
The `NetworkAddress`
[structure](https://vibed.org/api/vibe.core.net/NetworkAddress)
does not provide such features. Or did I miss something?
On Monday, 22 January 2024 at 10:56:04 UTC, atzensepp wrote:
Dear D-gurus,
being new to D I am trying my first steps and the language is
quite intuitive and appealing.
When reading a file and creating a hash for the reocrds I want
to get only the most recent ones. For this I need to convert
56 matches
Mail list logo