On 2016-05-21 16:06, Piotr Szturmaj wrote:
https://www.cs.bgu.ac.il/~hendlerd/papers/flat-combining.pdf [2010]
"Traditional data structure designs, whether lock-based or
lock-free, provide parallelism via fine grained synchronization
among threads.
We introduce a new synchronization par
On 2016-05-24 02:16, H. S. Teoh via Digitalmars-d wrote:
On Mon, May 23, 2016 at 04:01:08PM -0400, Andrei Alexandrescu via Digitalmars-d
wrote:
So swap(a, b) swaps the contents of a and b. This could be easily
generalized to multiple arguments such that swap(a1, a2, ..., an)
arranges things
https://www.cs.bgu.ac.il/~hendlerd/papers/flat-combining.pdf [2010]
"Traditional data structure designs, whether lock-based or
lock-free, provide parallelism via fine grained synchronization
among threads.
We introduce a new synchronization paradigm based on
coarse locking, which we call flat
https://github.com/BSVino/JaiPrimer/blob/master/JaiPrimer.md
Looks like it has some features that D has too, for instance CTFE and
default value initialization that can be disabled.
Not that it's a superior language, but I like its fresh/innovative approach.
On 2016-02-14 20:48, Eugene Wissner wrote:
I think may be we should discuss if we can/should change something in
ddb. I think there were some interesting and promising ideas in this
discussion. Maybe split the PostgreSQL driver and develop it seperately
and use an interface more similar to JDBC.
Ddb is a relational database client for D [1]. Currently it only
supports PostgreSQL but is not limited to it. It could be extended to
support other backends.
Built-in postgres client is a native implementation, that is it does not
depend on libpq. Instead it communicates directly with the
W dniu 2015-07-29 o 00:37, H. S. Teoh via Digitalmars-d pisze:
On Tue, Jul 28, 2015 at 03:29:02PM -0700, Walter Bright via Digitalmars-d wrote:
[...]
3. Stepping back a bit, when I think of parsing JSON data, I think:
auto ast = inputrange.toJSON();
where toJSON() accepts an input range
By the way.. does anyone know if Sociomantic accepts remote D jobs?
W dniu 2014-11-22 o 17:56, Ary Borenszweig pisze:
On 11/21/14, 12:36 AM, Jonathan Marler wrote:
Has the idea of function overloading via nogc been explored?
void func() @nogc
{
// logic that does not use GC
}
void func()
{
// logic that uses GC
}
void main(string[] args) // @nogc
{
W dniu 2014-11-21 o 04:36, Jonathan Marler pisze:
Has the idea of function overloading via nogc been explored?
void func() @nogc
{
// logic that does not use GC
}
void func()
{
// logic that uses GC
}
void main(string[] args) // @nogc
{
// if main is @nogc, then the @nogc version
W dniu 2014-11-11 o 23:38, Dmitry Olshansky pisze:
gchunt is a tool is to help D developers identify and keep in check the
usage of GC in their projects.
So far it just postprocesses D compiler's -vgc output into a nice Wiki
table. Results looks like this (Phobos):
W dniu 2014-03-25 11:42, dennis luehring pisze:
Am 25.03.2014 11:38, schrieb Nick Sabalausky:
On 3/25/2014 4:00 AM, Iain Buclaw wrote:
On 25 March 2014 00:04, Daniel N u...@orbiting.us wrote:
On Monday, 24 March 2014 at 12:21:55 UTC, Daniel N wrote:
I'm currently too busy to submit a
W dniu 2014-03-17 15:05, Johannes Pfau pisze:
I'm happy to announce the first GDC ARM beta on behalf of the GDC
team :)
ARM support is now at a point where the automated tests (test suite,
unit tests) pass and we're ready for feedback from real world usage.
All changes have been fully
W dniu 2014-03-10 04:44, Andrei Alexandrescu pisze:
Consider it alpha quality. Please don't announce yet before we put it in
good shape.
https://github.com/D-Programming-Language/dlang.org/pull/516
http://dlang.org/library
Great!
Altough, I would exchange title order to like std.xxx module
W dniu 2014-03-08 02:09, H. S. Teoh pisze:
Having a way to auto-generate input range boilerplate, though, would be
really, *really* nice. Coroutine-style code would be ideal.
https://github.com/pszturmaj/dgenerators
On 2014-02-26 05:50, Brad Roberts wrote:
Later,
Brad
Now I've received your email but it seems I can't reply :)
Instead, I'm receiving mail delivery error:
The mail system
bra...@puremagic.com: host mail2.puremagic.com[99.179.5.161] said: 451
4.7.1
Please try again later (TEMPFAIL) (in
On 2014-02-26 05:50, Brad Roberts wrote:
Later,
Brad
Hi, It's kinda hard to reach you by email, I've sent 3 of them :) Would
you like to accept ARM board for auto tester? Please contact me on NG
email if you wish.
Steve Teale wrote:
On Saturday, 25 January 2014 at 18:09:16 UTC, Tofu Ninja wrote:
I use monoD and it is by far the best IDE for D that I have tried, I
have tried to mess with Visual D on 3 different occasions but I have
never got it working properly and I didn't want to use eclipse either
as
Timon Gehr wrote:
On 01/24/2014 11:33 PM, Walter Bright wrote:
...
2. types do not depend on particular runtime values (the whole notion of
static typing would fall apart if it did)
http://en.wikipedia.org/wiki/Dependent_type
http://en.wikipedia.org/wiki/Refinement_type#Refinement_types
Johannes Pfau wrote:
Am Mon, 13 Jan 2014 12:25:17 +0100
schrieb Piotr Szturmaj bncr...@jadamspam.pl:
Iain Buclaw wrote:
QEMU testing is quirky. If your lucky and get it working, don't
make any system changes. :o)
What do you mean exactly?
Saying that, ARM is the only emulation that I've
Iain Buclaw wrote:
On 14 January 2014 22:36, Piotr Szturmaj bncr...@jadamspam.pl wrote:
Johannes Pfau wrote:
Am Mon, 13 Jan 2014 12:25:17 +0100
schrieb Piotr Szturmaj bncr...@jadamspam.pl:
Iain Buclaw wrote:
QEMU testing is quirky. If your lucky and get it working, don't
make any system
Johannes Pfau wrote:
Am Thu, 09 Jan 2014 19:07:17 +0100
schrieb Piotr Szturmaj bncr...@jadamspam.pl:
Hello,
Answers for GDC:
I'm developing embedded system product on ARM9/Linux platform and I
wish I could use D and vibe.d for this task.
ARMv5 or ARMv4? I tested ARMv5 and that should
Iain Buclaw wrote:
QEMU testing is quirky. If your lucky and get it working, don't make
any system changes. :o)
What do you mean exactly?
Saying that, ARM is the only emulation that I've gotten working where
I've actually built GDC ontop of.
For anyone interested:
Here are prebuilt
Hello,
I'm developing embedded system product on ARM9/Linux platform and I wish
I could use D and vibe.d for this task.
I have couple of questions in this matter:
- What is the current status of ARM support?
- Does GDC support cross-compiling to ARM?
- Is it possible to remote-debug D code on
Jordi Sayol wrote:
El 30/11/13 02:08, Piotr Szturmaj ha escrit:
Sönke Ludwig wrote:
A fresh DUB release is out. Apart from the usual bug fixes, there are a
few considerable changes:
Thanks! Have you considered adding a version number to dub help and/or a
--version option?
$ dub help
Sönke Ludwig wrote:
A fresh DUB release is out. Apart from the usual bug fixes, there are a
few considerable changes:
Thanks! Have you considered adding a version number to dub help and/or a
--version option?
On 09.10.2013 14:41, Dicebot wrote:
On Tuesday, 8 October 2013 at 22:02:07 UTC, Peter Alexander wrote:
Just learn where allocations occur and avoid them during development.
This leaves you only with accidental or otherwise unexpected allocations.
D is not expected to be a single man project
Brian Schott wrote:
On Thursday, 3 October 2013 at 20:11:02 UTC, Andrei Alexandrescu wrote:
I see we're considerably behind dmd. If improving performance would
come at the price of changing the API, it may be sensible to hold off
adoption for a bit.
Andrei
The old benchmarks measured total
On 20.09.2013 17:28, Andrei Alexandrescu wrote:
On 9/20/13 2:36 AM, bearophile wrote:
In D it's often better to use std.algorithm/range instead of raw foreach
loops (despite probably unlike C++ in D a heavy use of ranges leads to a
lower performance, even if you use the LDC2 compiler).
Why
On 20.09.2013 19:45, Andrei Alexandrescu wrote:
On 9/20/13 9:51 AM, Piotr Szturmaj wrote:
On 20.09.2013 17:28, Andrei Alexandrescu wrote:
On 9/20/13 2:36 AM, bearophile wrote:
In D it's often better to use std.algorithm/range instead of raw
foreach
loops (despite probably unlike C++ in D
I'm looking for something like __traits(getAST, fn). The AST should
represent only run-time (instantiated) code without any compile-time
features.
How hard it would be to implement this in the frontend?
It would enable analysis of code at compile-time (without the need to
modify the
On 13.09.2013 21:48, Namespace wrote:
Just out of interest.
I use Sublime 2, Notepad++ and as IDE currently Mono-D. But I will try
this evening VisualD.
Real Programmers magnetize programs directly on a HDD.
On 11.09.2013 20:49, Walter Bright wrote:
On 9/11/2013 8:01 AM, Dicebot wrote:
std.d.lexer is standard module for lexing D code, written by Brian Schott
Thank you, Brian! This is important work.
Not a thorough review, just some notes from reading the doc file:
1. I don't like the _ suffix
On 12.09.2013 01:22, Kapps wrote:
On Wednesday, 11 September 2013 at 19:57:28 UTC, Piotr Szturmaj wrote:
On 11.09.2013 20:49, Walter Bright wrote:
On 9/11/2013 8:01 AM, Dicebot wrote:
std.d.lexer is standard module for lexing D code, written by Brian
Schott
Thank you, Brian
On 03.09.2013 07:51, Walter Bright wrote:
On 9/2/2013 9:39 PM, Dylan Knutson wrote:
On Tuesday, 3 September 2013 at 04:33:16 UTC, Walter Bright wrote:
There were huge debates about this back when the C standard was in
development. I don't really want to start that up again :-), I don't
On 31.08.2013 22:33, Andrej Mitrovic wrote:
On 8/31/13, Piotr Szturmaj bncr...@jadamspam.pl wrote:
On 31.08.2013 21:52, Andrej Mitrovic wrote:
On 8/31/13, Jacob Carlborg d...@me.com wrote:
T delegate (Args) dg = result.__ctor;
dg(args);
Ah, pretty cool workaround.
Then, why not close
On 01.09.2013 20:19, Iain Buclaw wrote:
On 1 September 2013 19:01, Peter Alexander peter.alexander...@gmail.com wrote:
Thank you for sharing this experience Manu, I had no idea there were so many
issues with D on windows. I primarily use OSX without problems, but have
also used it on windows
On 31.08.2013 21:52, Andrej Mitrovic wrote:
On 8/31/13, Jacob Carlborg d...@me.com wrote:
T delegate (Args) dg = result.__ctor;
dg(args);
Ah, pretty cool workaround.
Then, why not close that old bug?
W dniu 29.08.2013 15:33, Gour pisze:
On Sun, 25 Aug 2013 17:06:27 +0200
bearophile bearophileh...@lycos.com wrote:
Probably working even more you can make the D entry a bit more
statically safe (eventually you could reach the level of Ada code) but
the amount of work and code becomes
H. S. Teoh wrote:
I've written up a proposal to solve the partially-constructed object
problem[*] in D in a very nice way by extending scope guards:
http://wiki.dlang.org/DIP44
Destroy! ;-)
I see some possible implementation problem. Using a scope guard in a
single function is
W dniu 23.08.2013 09:44, Robert Schadek pisze:
On 08/23/2013 02:07 AM, Piotr Szturmaj wrote:
W dniu 22.08.2013 16:00, Robert Schadek pisze:
Docu:
http://burner.github.io/phobos/phobos-prerelease/std_logger.html
What about specifying log level at runtime, e.g.:
// set by the user at runtime
W dniu 23.08.2013 11:01, Robert Schadek pisze:
On 08/23/2013 10:30 AM, Piotr Szturmaj wrote:
?
Any other Logger:
auto myCoolLogger = new Logger();
myCoolLogger.logLevel = LogLevel.Critical;
For the default Logger:
log.logLevel = LogLevel.Info;
I see, but isn't separate class instance
W dniu 23.08.2013 14:16, Robert Schadek pisze:
On 08/23/2013 01:10 PM, Piotr Szturmaj wrote:
so if I have a LogLevel variable I want to use:
LogLevel myLogLevel;
I need to write this:
# alternative 1 (possibly wrapped in a function)
switch (myLogLevel)
{
case LogLevel.Info: log.Info
W dniu 22.08.2013 16:00, Robert Schadek pisze:
Docu:
http://burner.github.io/phobos/phobos-prerelease/std_logger.html
What about specifying log level at runtime, e.g.:
// set by the user at runtime
LogLevel userLogLevelForX;
log(userLogLevelForX, X);
?
W dniu 21.08.2013 01:43, Ramon pisze:
I agree with those who are against it.
For a variety of reasons, one of them being that, yes, anything that
produces javasc*t does a) recognize js and b) embold and support it.
Web pages are/should be about *content* not about eye candy and gadgets.
W dniu 21.08.2013 01:49, Ramon pisze:
Ha! Expanding on myself:
Have simple web server written in D on the client and then a D-script
interpreter in that server. Possibly some minimalist friendly
interpreter thingy like Lua too (or optionally).
Only problem I see: Does D compile to/for Arm w/
W dniu 17.08.2013 16:42, Gambler pisze:
On 8/15/2013 5:55 PM, Piotr Szturmaj wrote:
bearophile:
Piotr Szturmaj:
I have found some related activity from Rust people:
https://github.com/mozilla/rust/issues/2235
https://github.com/Yoric/Mozilla-Student-Projects/issues/33
https://mail.mozilla.org
W dniu 17.08.2013 16:42, Gambler pisze:
(For example, your gist doesn't
work in IE. Not that I use IE normally, but you get my point.)
This is because the code was compiled with typed arrays support. It's
possible to compile without TA support and then it will work in IE.
W dniu 17.08.2013 23:05, Gambler pisze:
On 8/17/2013 12:43 PM, Piotr Szturmaj wrote:
W dniu 17.08.2013 16:42, Gambler pisze:
On 8/15/2013 5:55 PM, Piotr Szturmaj wrote:
bearophile:
Piotr Szturmaj:
I have found some related activity from Rust people:
https://github.com/mozilla/rust/issues
W dniu 18.08.2013 03:58, Adam D. Ruppe pisze:
I wonder how hard it would be to write that. Searching the web for kvm
though always assumes qemu. No, I want to write a super-small qemu, and
I don't care if it can't boot linux. How hard can it be?
Someone has written an LLVM backend for DCPU-16
W dniu 16.08.2013 15:32, Bruno Medeiros pisze:
On 15/08/2013 22:07, Piotr Szturmaj wrote:
W dniu 15.08.2013 21:20, Bruno Medeiros pisze:
A new version of DDT - D Development tools is out.
The major change is the new parser which is updated to the latest
version of D, and is much more robust
W dniu 15.08.2013 21:20, Bruno Medeiros pisze:
A new version of DDT - D Development tools is out.
The major change is the new parser which is updated to the latest
version of D, and is much more robust than the previous one.
Full changelog/info here:
This is SDL and std.algorithm code translated to JavaScript with
emscripten. I've used the latest git versions of LDC and emscripten (the
latter needed some modifications).
https://gist.github.com/pszturmaj/6244260
https://gist.github.com/pszturmaj/6244266
I couldn't manage to post it as
W dniu 15.08.2013 23:45, Adam D. Ruppe pisze:
On Thursday, 15 August 2013 at 21:36:07 UTC, bearophile wrote:
Integration with asm.js too is useful.
Doesn't the llvm backend do that automatically now? So ldc should get
that too. I thought I read that llvm did in a blog somewhere, but I'm
not
bearophile:
Piotr Szturmaj:
Then open sdl.html in the web browser. It should print sorted and
mapped array contents and run simple graphics demo.
Very nice. D is meant to run efficiently, but the Web is very important.
There are many situations where it could be useful to run D code
Hi D community!
What do you think of such templated aliases:
template SomeTemplate(T1, T2) { }
alias Partial(T) = SomeTemplate!(int, T);
alias Specialized = Partial!float; // equivalent to SomeTemplate!(int,
float)
I think they could be pretty helpful and they should be relatively easy
to
W dniu 12.08.2013 23:10, monarch_dodra pisze:
On Monday, 12 August 2013 at 20:06:16 UTC, Piotr Szturmaj wrote:
Hi D community!
What do you think of such templated aliases:
template SomeTemplate(T1, T2) { }
alias Partial(T) = SomeTemplate!(int, T);
alias Specialized = Partial!float
W dniu 13.07.2013 09:13, Walter Bright pisze:
On 7/12/2013 11:52 PM, BLM768 wrote:
On Saturday, 13 July 2013 at 04:23:56 UTC, Walter Bright wrote:
A big problem with it would be the equivalent of the SQL Injection
Exploit.
Since the compiler can now execute arbitrary code, someone passing
W dniu 01.07.2013 03:35, Jonathan M Davis pisze:
On Monday, July 01, 2013 03:22:15 JS wrote:
struct Foo
{
@property int data() { return m_data; } // read property
@property int data(int value) { return m_data = value; } //
write property
private: int m_data;
}
It would be
W dniu 17.06.2013 22:47, jerro pisze:
That sounded like chia, I don't think that's right.
Here's another one
http://translate.google.com/#en/sr/%C4%86
Google Translate synthesizes it incorrectly. Ć is spoken as Ci when
written alone. It's spoken differently (a little shorter) when used in
W dniu 10.06.2013 00:09, bearophile pisze:
Delphi has a large and efficient GUI toolkit in the standard library,
but I think it's not a good idea to put a GUI toolkit in Phobos. But a
little library as simpledisplay is OK.
Hmm... What if Lazarus GUI code and/or LCL could be ported to D? I've
W dniu 10.06.2013 00:29, bearophile pisze:
Piotr Szturmaj:
Hmm... What if Lazarus GUI code and/or LCL could be ported to D? I've
seen full featured Object Pascal parser in their repository. Maybe
it's possible to transcode the source to D ;) Just thinking loud.
Even if that's possible, I
W dniu 07.06.2013 07:28, Tyler Jameson Little pisze:
This would make D the truely universal language it was intended to be.
I'd love to see that! I think that Phobos code that makes allocations
can be divided (duplicated) to manual and GC versions.
I thought I read somewhere about a marker
W dniu 07.06.2013 17:01, Tyler Jameson Little pisze:
On Friday, 7 June 2013 at 14:46:30 UTC, Simen Kjaeraas wrote:
On Fri, 07 Jun 2013 16:39:15 +0200, Tyler Jameson Little
beatgam...@gmail.com wrote:
If the nogc marker could be used to overload functions then Phobos
may include both versions
W dniu 01.06.2013 07:45, SomeDude pisze:
Following this idea, I believe a fairly large chunk of Phobos could be
ported to compile with this minimal D sublanguage, and that one could
use the allocating D and its added sugar on top of it. So in the end,
the user could decide between working with
W dniu 02.06.2013 15:05, Gary Willoughby pisze:
Hi,
I get the following error while running a simple hello world program
compiled with the new v2.063 compiler. This is on Ubuntu 12.04.
error while loading shared libraries: libphobos2.so.0.63: cannot open
shared object file: No such file or
W dniu 01.06.2013 23:55, Jonathan M Davis pisze:
The guarantees of @safe hold only so long as there are no holes in it, but any
and all holes we find get fixed. Making ref be truly @safe has been a large part
of the recent ref discussions, as you can currently get away with doing
something like
W dniu 31.05.2013 19:05, Jonathan M Davis pisze:
On Friday, May 31, 2013 13:59:24 Juan Manuel Cabo wrote:
About streams: there is some phobos support for streams, though
it seems not finalized.
Everything stream-related which is currently in Phobos is outdated and
unacceptable, so it will be
W dniu 31.05.2013 16:06, finalpatch pisze:
Just want to share a new way I just discovered to do loop unrolling.
template Unroll(alias CODE, alias N)
{
static if (N == 1)
enum Unroll = format(CODE, 0);
else
enum Unroll = Unroll!(CODE, N-1)~format(CODE, N-1);
}
after
W dniu 30.05.2013 19:16, Simen Kjaeraas pisze:
On 2013-05-30, 17:16, Andrei Alexandrescu wrote:
For the full story, mosey to the redesigned changelog:
http://dlang.org/changelog.html
Kudos to Andrej for this. *This* is how a great changelog looks.
This is a very pleasant surprise to see
W dniu 23.05.2013 20:13, Brad Anderson pisze:
@nogc comes to mind (I believe Andrei mentioned it during one of the
talks released). [1][2]
1: http://d.puremagic.com/issues/show_bug.cgi?id=5219
2: http://wiki.dlang.org/DIP18
When I started learning D 2 years ago, I read on the D webpage that D
W dniu 10.05.2013 14:32, deadalnix pisze:
http://www.deadalnix.me/2013/05/10/type-safe-tagged-union-in-d-programming-language/
A trick that I used to use more and more, so I ended up creating a
generic solution and wrote an article about it.
Here's my try on this:
W dniu 07.05.2013 16:53, Sean Kelly pisze:
I'm not terribly happy with std.json do this is welcome. I do wish that
there were a SAX style parser available too though, so I could parse
JSON without allocating.
You may find this useful: https://github.com/pszturmaj/json-streaming-parser
Don't
W dniu 18.04.2013 16:58, Andrei Alexandrescu pisze:
On 4/18/13 2:38 AM, Walter Bright wrote:
On 4/17/2013 11:34 PM, deadalnix wrote:
On Thursday, 18 April 2013 at 05:59:20 UTC, kenji hara wrote:
It will break existing code.
int foo() {
typeof(return) bar() { return 1; }
return bar();
}
W dniu 19.04.2013 15:43, John Colvin pisze:
I like this. It provides a good balance of control and automation.
how would template functions be treated with auto(return)?
I see no need for special treating of template functions. In this case
only return type would be inferred. Programmers
W dniu 16.04.2013 17:22, Andrei Alexandrescu pisze:
There's a discussion that may be of interest to the larger community:
https://github.com/D-Programming-Language/dmd/pull/1877
On demand inference FTW!
void fn() auto {
...
}
auto fn() auto {
...
}
W dniu 18.04.2013 04:50, Zach the Mystic pisze:
On Thursday, 18 April 2013 at 02:40:42 UTC, Walter Bright wrote:
On 4/16/2013 8:22 AM, Andrei Alexandrescu wrote:
There's a discussion that may be of interest to the larger community:
https://github.com/D-Programming-Language/dmd/pull/1877
What
http://forum.dlang.org/thread/jcksnp$ah8$1...@digitalmars.com
My idea was to ship exp branch with phobos so all users could look into
new code. Not all users follow github/newsgroups/etc.
W dniu 12.04.2013 17:05, Manu pisze:
On 13 April 2013 00:41, Piotr Szturmaj bncr...@jadamspam.pl
mailto:bncr...@jadamspam.pl wrote:
http://forum.dlang.org/thread/__jcksnp$ah8$1...@digitalmars.com
http://forum.dlang.org/thread/jcksnp$ah8$1...@digitalmars.com
My idea was to ship exp
I know that GDC and LDC can produce ARM code, but what about D runtime -
does it work reliably?
bearophile wrote:
Piotr Szturmaj:
I know it can't be easy drop-in addition to the current range
implementation, but who knows...
Time ago I have suggested in this newsgroup that idea, naming it
vectorized lazyness, that was mostly ignored:
http://web.archiveorange.com/archive/v
H. S. Teoh wrote:
On Fri, Mar 01, 2013 at 03:35:23AM +0100, Chris Cain wrote:
On Friday, 1 March 2013 at 01:02:17 UTC, Piotr Szturmaj wrote:
Seriously, nobody will ever get performance from single-element
iterator/range pattern - this makes CPU stall!
There's no reason you can't do
Seriously, nobody will ever get performance from single-element
iterator/range pattern - this makes CPU stall!
Anytime you read one byte from typical hard disk, system reads full
sector - typically 512 bytes, no more, no less. Anytime you read one
byte from memory, CPU loads entire cache line
Piotr Szturmaj wrote:
A foo(T : A)()
that should be:
T foo(T : A)()
Eko Wahyudin wrote:
Hi, guys? I'm new in D and I come from pascal. The constructor
concept is very different, and it's very confusing for me.
I want to create some statement in D which in pascal like this.
type
TMyObjectAClass = class of TMyObject_A; // number 1
TMyObject_A =
W dniu 06.11.2012 04:43, Nick Sabalausky pisze:
What kind of memory overhead is there for a fiber?
At least one PAGESIZE (typically 4KB):
https://github.com/D-Programming-Language/druntime/blob/master/src/core/thread.d#L3828
We have:
ImportExpression:
import ( AssignExpression )
Why not also add this:
ExportStatement:
export ( AssignExpression, AssignExpression )
Both of the AssignExpressions must evaluate at compile time to a
constant string. The text contents of the first string are interpreted
as a
Chopin wrote:
Hello!
I got this 109 MB json file that I read... and it takes over 32
seconds for parseJSON() to finish it. So I was wondering if it
was a way to save it as binary or something like that so I can
read it super fast?
Thanks for all suggestions :)
Try this implementation:
Chopin wrote:
Thanks! I tried using it:
auto document = parseJSON(content).array; // this works with std.json :)
Using json.d from the link:
auto j = JSONReader!string(content);
auto document = j.value.whole.array; // this doesn't Error:
undefined identifier 'array'
If you're sure that
And replace them with global reset function:
void reset(T)(ref T digest)
if (isDigest!T)
{
digest = T.init;
}
Current usage:
SHA1 sha1;
sha1.start();
... calculate hash
sha1.start(); // start again
... calculate hash
New usage:
SHA1 sha1;
... calculate hash
sha1.reset(); // start
Marco Leise wrote:
Unlike classes, structs don't mandate a ctor call, so in
general you need to disguise the constructor as 'start()'
'Create()' or similar, where T.init is not sufficient.
I know, but in case of digests their init data is always known at
compile time, hence no special
H. S. Teoh wrote:
Then you could just write:
SHA1 sha1;
// calculate hash
sha1 = SHA1.init;
// calculate hash
...
In my proposal reset() does exactly the same.
Jonathan M Davis wrote:
On Thursday, July 26, 2012 21:09:09 Chad J wrote:
I keep hearing that scope variables are going away. I missed the
discussion on it. Why is this happening?
When I read about this, I have these in mind:
void someFunc()
{
// foo is very likely to get stack
bearophile wrote:
Piotr Szturmaj:
It seems that we ended up with a solution that was meant to fix a
language builtin but appears to be worse than that.
This is true, currently the library solution is worse (more dangerous
and more broken) than the precedent built-in feature
Jonathan M Davis wrote:
On Wednesday, October 10, 2012 17:04:41 Piotr Szturmaj wrote:
Jonathan M Davis wrote:
On Thursday, July 26, 2012 21:09:09 Chad J wrote:
I keep hearing that scope variables are going away. I missed the
discussion on it. Why is this happening?
When I read about this, I
Jonathan M Davis wrote:
On Thursday, October 11, 2012 01:24:40 Piotr Szturmaj wrote:
Could you give me an example of preventing closure allocation? I think I
knew one but I don't remember now...
Any time that a delegate parameter is marked as scope, the compiler will skip
allocating a closure
Zhenya wrote:
Hi!
I need to load some textures for my game,but I woud like to do it in
compile time.
I know that CTFE imposes restrictions on functions.So can I execute some
DevIL(Derelict3) functions?
CTFE can only evaluate D functions that have their bodies available. It
means that external
Russel Winder wrote:
On Sun, 2012-10-07 at 00:35 +0200, denizzzka wrote:
On Saturday, 6 October 2012 at 12:06:07 UTC, Thomas Koch wrote:
- I looked for a PostgreSQL client library. I found small
personal hacks and
dead projects.
https://github.com/denizzzka/dpq2
This is my personal project
Jacob Carlborg wrote:
On 2012-10-07 10:55, Russel Winder wrote:
Why only PostgreSQL. Shouldn't it also work with MySQL, Oracle, DB2,
PervasiveSQL, SQLite3, etc.?
From the example I assume that this is just a library for managing
connections and that everything else is just string-based SQL
Thiez wrote:
On Sunday, 7 October 2012 at 12:39:35 UTC, Piotr Szturmaj wrote:
In my prostgres client one may specify field types at compile time. If
I had divided the client into two separate layers it would return a
Variant[] at first layer, then convert it to user specified tuple
1 - 100 of 370 matches
Mail list logo