) { . . . while cb(0)
. . . }
You could just adapt a call to it using a lambda function:
async_task( (error) => myCb(error, count) );
D makes sure the enclosing stack is copied to the heap and count
is reachable. Maybe this helps...
Regards,
André
On Friday, 27 November 2015 at 08:53:18 UTC, Jack Applegame wrote:
On Thursday, 26 November 2015 at 17:27:34 UTC, André wrote:
My question now is: is there some more elegant solution to
achieve this? Something like in C++ when you have std::map's
of std::map's and just access the elements
On Friday, 27 November 2015 at 04:21:41 UTC, Nicholas Wilson
wrote:
AA are weird in that AFAIK you need to "initialise" them before
you try to look suff up in them else they crash. i.e.
int[string] foo;
// auto e = "1" in foo; // crash AA not initialised
foo[ "blah"] = 0;
foo.remove("blah");
know I could create a function for that but I am
looking for a standard approach that already exists.
Thanks!
André
understand args is a TypeTuple and therefore expand is not
working.
Is there a simple way to get it working?
Kind regards
André
too many trees in front of my eyes.
Thanks for the answers.
Kind regards
André
On Tuesday, 10 March 2015 at 19:16:23 UTC, Adam D. Ruppe wrote:
On Tuesday, 10 March 2015 at 19:11:22 UTC, André wrote:
Is there a simple way to get it working?
The simplest: just write `bar(args
Thanks a lot.
I will forward this recommendation (DGUI BitBucket).
Kind regards
André
On Monday, 17 November 2014 at 16:40:18 UTC, ketmar via
Digitalmars-d-learn wrote:
On Mon, 17 Nov 2014 15:41:25 +
Andre via Digitalmars-d-learn
digitalmars-d-learn@puremagic.com wrote
On Sunday, 24 June 2012 at 23:04:14 UTC, Sean Kelly wrote:
On Jun 24, 2012, at 11:40 AM, Jarl André
jarl.an...@gmail.com@puremagic.com jarl.an...@gmail.com
wrote:
Is it wrong to badge myself with asynchronous sockets? :)
Nope. It's pretty weird stuff if you've never done event-based
I have now completely and totally replaced the inner contents of
my server library with modified Splat code. It ran so much faster
that I was actually afraid I had got it wrong. It seemed not be
any wrong with it, so adding Splat actually made it super kidding
me fast. I have now learned a few
On Sunday, 24 June 2012 at 19:10:55 UTC, Tobias Pankrath wrote:
* add -g and -debug=splat (or any other keywords) to the build
command
You don't need a keyword -debug is sufficient. To make the
binary work with a debugger you does not even need -debug, only
-g. -debug only includes code
The learning curve has been from like zero to something. I am
still grasping for some fundamental knowledge that I need to
fully get whats going on. Had to read documentation for sockets
in C to understand anything at all. That says a lot. Coming from
BufferedReader hell in Java and did never
Evry single time I encounter them I yawn. It means using the next
frickin hour to comment away code, add more log statements and
try to eleminate whats creating the hell of bugz, segmantation
fault. Why can't the compiler tell me anything else than the fact
that i have referenced data that
Thank you for the Windows compatibility. I will try it out ASAP.
I have now added some subtle changes to the server and example
echo server. I have added an example for how byte streams can be
passed to the server by converting them to base64. In my example
the base64 encoded data is
Now the similarity to the original quickserver library in java is
so ripped off that I had an email sent over to the author asking
for permission to continue on the api clone or alternatively
change the api. Comments or suggestions? sucks totally or worth a
penny?
Hi
I have searched high and low to figure this one out. There does
not seems to be a an accessible way of getting a unique key for a
socket. I have learned that port numbers count a great deal but
really shouldn't there be some internal numbering or
representation of each socket that the
On Thursday, 31 May 2012 at 14:46:42 UTC, Alex Rønne Petersen
wrote:
On 31-05-2012 16:44, Jarl André jarl.an...@gmail.com
wrote:
Hi
I have searched high and low to figure this one out. There
does not
seems to be a an accessible way of getting a unique key for a
socket. I
have learned
I don't know why but for some reason this did not come to my
mind. LOL
Its a bit embarassing really because I work with Java every day
and memory reference is a core feature. But I think the SocketSet
buzzed my brain making me think that it gave me different objects
or something. But
On Wednesday, 30 May 2012 at 08:40:48 UTC, Dejan Lekic wrote:
On Friday, 18 May 2012 at 06:35:59 UTC, Jarl André wrote:
I am a Java developer who is tired of java.nio and similar
complex socket libraries.
In Java you got QuickServer, the ultimate protocol creation
centered socket library
On Wednesday, 30 May 2012 at 08:40:48 UTC, Dejan Lekic wrote:
On Friday, 18 May 2012 at 06:35:59 UTC, Jarl André wrote:
I am a Java developer who is tired of java.nio and similar
complex socket libraries.
In Java you got QuickServer, the ultimate protocol creation
centered socket library
On Monday, 21 May 2012 at 19:06:24 UTC, Nathan M. Swan wrote:
On Monday, 21 May 2012 at 17:54:56 UTC, Adam D. Ruppe wrote:
On Saturday, 19 May 2012 at 20:33:49 UTC, Nathan M. Swan wrote:
It has some pitfalls (e.g. I can't find a good way to stop
the server)
When I use it, I just leave it
On Wednesday, 30 May 2012 at 20:09:43 UTC, Jarl André wrote:
On Monday, 21 May 2012 at 19:06:24 UTC, Nathan M. Swan wrote:
On Monday, 21 May 2012 at 17:54:56 UTC, Adam D. Ruppe wrote:
On Saturday, 19 May 2012 at 20:33:49 UTC, Nathan M. Swan
wrote:
It has some pitfalls (e.g. I can't find a good
On Monday, 28 May 2012 at 18:53:50 UTC, Ali Çehreli wrote:
On 05/28/2012 11:50 AM, Jarl André jarl.an...@gmail.com
wrote:
1. Is there a way to convert from string INFO to
LogLevel.INFO, by name?
conv.to can do that:
import std.conv;
enum LogLevel { ALL, INFO, WARNING }
void main
Hi
I have a project on github,
https://github.com/jarlah/d2-simple-socket-server, where I have
added very custom logger library. In this logger library I have
an enum LogLevel that looks like enum LogLevel { ALL, INFO,
WARNING etc }
Questions:
1. Is there a way to convert from string INFO
On Friday, 25 May 2012 at 20:55:12 UTC, Donald Duvall wrote:
On Friday, 25 May 2012 at 20:50:25 UTC, Donald Duvall wrote:
On Wednesday, 23 May 2012 at 19:24:53 UTC, Jarl André wrote:
On Wednesday, 23 May 2012 at 13:39:09 UTC, Jarl André wrote:
On Saturday, 19 May 2012 at 20:33:49 UTC, Nathan M
Sorry for the typo: I do NOT understand it completely.
Thanks for the feedback! Well, for me I am a Java enterprise
developer working with Java on Unix, but, I have worked with
.NET in the past giving me a tiny portion of mercy to those
that enjoys Visual Studio :) Its actually a blazing
On Saturday, 19 May 2012 at 20:33:49 UTC, Nathan M. Swan wrote:
On Friday, 18 May 2012 at 06:35:59 UTC, Jarl André wrote:
I am a Java developer who is tired of java.nio and similar
complex socket libraries.
In Java you got QuickServer, the ultimate protocol creation
centered socket library
On Wednesday, 23 May 2012 at 13:39:09 UTC, Jarl André wrote:
On Saturday, 19 May 2012 at 20:33:49 UTC, Nathan M. Swan wrote:
On Friday, 18 May 2012 at 06:35:59 UTC, Jarl André wrote:
I am a Java developer who is tired of java.nio and similar
complex socket libraries.
In Java you got
I am a Java developer who is tired of java.nio and similar
complex socket libraries.
In Java you got QuickServer, the ultimate protocol creation
centered socket library. You don't have to write any channels and
readers and what not. You just instantiate a server, configures
the handlers
On Thursday, 17 May 2012 at 18:36:22 UTC, Jarl André wrote:
On Thursday, 17 May 2012 at 14:08:27 UTC, Vincent wrote:
On Sunday, 25 March 2012 at 17:50:45 UTC, Andrea Fontana wrote:
Hope it's clear...
Nope, it's something like chess and have nothing common with
simplicity of the real JSON
On Wednesday, 1 December 2010 at 08:17:37 UTC, zusta wrote:
Hey guys,
I'm trying to read a JSON-formated file. The parsing of the
file seems to be
correct, but I always get the following error:
Error: no [] operator overload for type JSONValue.
For testing purposes, I also tried the code of
Am 04.03.2012 16:27, schrieb Dmitry Olshansky:
On 04.03.2012 14:49, André wrote:
Hi,
I have a project compiled as libary and a seccond example project using
this library. The library is compiled without errors.
As it's a linker error I'd recommend checking that phobos and library
are built
. If comment one
of the two import statements, then it is working.
I know there is no error in /std/regex.d. I do not even use this module.
But how to find out the root cause of this issue?
Kind regards
André
dmd -c main.d -of..proj_dir../F/FExample/FExample/obj/Debug/main.o
-I/usr/include/d/dmd
you are right, that was the error.
Thanks.
Kind regards
André
Am 29.02.2012 18:27, schrieb Kevin Cox:
I think you need the -lib in the linker command (too?).
On Feb 29, 2012 12:25 PM, André an...@s-e-a-p.de
mailto:an...@s-e-a-p.de wrote:
Hi,
I use Mono-D and have a hello world
where I tried to write an templated overload to
std.variant.Algebraic.
Thanks,
André
.
If you _know_ that your numbers are small enough though, it doesn't actually
matter, since you'll never get an overflow.
I actually didn't care about that problem but I _will_ do that in future.
Regards,
André
35 matches
Mail list logo