Hello Nick,
I wish you were a higher-up at Epic ;) They seem to have pretty much
the opposite attitude, and I get so worked-up every time I see a quote
from CliffyB or any of the others...
I'm sorry to disappoint, but gaming is the only case where building to the
latest hardware has any
== Quote from Leandro Lucarella (llu...@gmail.com)'s article
benefit from using NO_SCAN if your 800M of data are plain old data. Did
you tried it? And if you never have interior pointers to that data, your
program can possibly avoid a lot of false positives due to the
conservativism if you use
This post is a partial copy of a post of mine from digitalmars.D.learn. Lot of
people seem to ignore that place.
This is the only way I have found to create a certain static array at compile
time:
int sumSqrt(int n) {
int result = 0;
while (n) {
int digit = n % 10;
n /=
Stewart Gordon wrote:
Jason House wrote:
snip
Method 1:
if (x !in y)
foo();
else{
auto z = x in y;
bar(z);
}
Method 2:
auto z = x in y;
if (z is null)
foo;
else
bar(z);
Method 1 essentially calls in twice while method 2 calls in once.
snip
But there's no requirement to look it
bearophile wrote:
This post is a partial copy of a post of mine from digitalmars.D.learn. Lot of
people seem to ignore that place.
This is the only way I have found to create a certain static array at compile
time:
int sumSqrt(int n) {
int result = 0;
while (n) {
int digit =
Andrei Alexandrescu wrote:
grauzone wrote:
* std.mmfile: integrate with the garbage collector. It should be
there.
Why should the GC know about it?
To add: in all sane situations, the mmaped region won't contain any
pointers, and the GC doesn't have to scan it. Allocating address space
is
On Mon, 25 May 2009 05:57:39 -0400, bearophile
bearophileh...@lycos.com wrote:
This post is a partial copy of a post of mine from digitalmars.D.learn. Lot of
people seem to ignore that place.
This is the only way I have found to create a certain static array at compile
time:
int sumSqrt(int
Denis Koroskin wrote:
I just started using nothrow functions a little bit and came across the
following issue.
Some of the functions that I'd like to mark as nothrow have debug
asserts inside them.
They used to throw an Exception, but I'd like to change their behavior
and terminate an
Max Samukha:
Your example can be rewritten like this: [...]
Thank you, it works.
I have tried using result~=m; in a forward-directed for loop, but that didn't
work. I think because result=m~result; creates a new array, while result~=m;
tries to extend it, failing (even if with result~=m; D1
bearophile wrote:
Max Samukha:
Your example can be rewritten like this: [...]
Thank you, it works.
I have tried using result~=m; in a forward-directed for loop, but that didn't
work. I think because result=m~result; creates a new array, while result~=m;
tries to extend it, failing (even if
Lionello Lunesu wrote:
Andrei,
I noticed in random.d, uniform template, that popFront is called in
different locations for integral compared to floating point types: for
integral types you .front first and .popFront afterwards, but for
floating point types you start with .popFront and then
Definitely warrants a bug report. I'm busy today but I might find time
for it tomorrow.
http://d.puremagic.com/issues/show_bug.cgi?id=3025
Andrei Alexandrescu wrote:
This is somewhat OT but I think it's an interesting problem. Consider
the following data:
double[][] a =
[
[ 1, 4, 7, 8 ],
[ 1, 7 ],
[ 1, 7, 8],
[ 4 ],
[ 7 ],
];
We want to compute an n-way union, i.e., efficiently span all elements
in all
Andrei Alexandrescu:
Needless to say, nWayUnion is a range :o).
It's better for nWayUnion to be a lazy iterable.
As probably others have already said, you can keep an heap of pointers, and
compute the heap invariant using as opCmp a function that uses the values they
point to. When nWayUnion
nobody, el 25 de mayo a las 07:37 me escribiste:
== Quote from Leandro Lucarella (llu...@gmail.com)'s article
benefit from using NO_SCAN if your 800M of data are plain old data. Did
you tried it? And if you never have interior pointers to that data, your
program can possibly avoid a lot of
nobody, el 25 de mayo a las 03:24 me escribiste:
As other asked, are you using D1 Tango/Phobos? D2? In Tango/D2 you can
DMD v2.030 on Linux.
enable logging in the GC (using the LOGGING version identifier).
How to do it in D2?
You should recompile Druntime's GC with -version=LOGGING.
Frits van Bommel, el 25 de mayo a las 12:37 me escribiste:
Stewart Gordon wrote:
Jason House wrote:
snip
Method 1:
if (x !in y)
foo();
else{
auto z = x in y;
bar(z);
}
Method 2:
auto z = x in y;
if (z is null)
foo;
else
bar(z);
Method 1 essentially calls in twice
bearophile wrote:
It's a bug in D1, actually. The bug was fixed in D2 but not yet in
D1. As you increase the value, D1 will just silently segfault
eventually. I believe D1 will be fixed in the next release.
So I'll be unable to loop a template 1000 times in D1 too?
The problem is that
Walter Bright:
The problem is that enough recursion will blow up the stack in the
compiler. I set a limit below that. But, naturally, for any limit I set
someone will try to exceed it.
I accept that some limits exist. For many situations a template nesting of 1000
is plenty. My problems
== Quote from Leandro Lucarella (llu...@gmail.com)'s article
nobody, el 25 de mayo a las 03:24 me escribiste:
As other asked, are you using D1 Tango/Phobos? D2? In Tango/D2 you can
DMD v2.030 on Linux.
enable logging in the GC (using the LOGGING version identifier).
How to do it
Georg Wrede wrote:
Andrei Alexandrescu wrote:
This is somewhat OT but I think it's an interesting problem. Consider
the following data:
double[][] a =
[
[ 1, 4, 7, 8 ],
[ 1, 7 ],
[ 1, 7, 8],
[ 4 ],
[ 7 ],
];
We want to compute an n-way union, i.e., efficiently span all
bearophile wrote:
The most general input is a lazy range of lazy sorted ranges, in this situation the
nWayUnion has to first duplicate it into an eager array of such ranges, and
then turn it into an heap as before.
I guess in most situations you don't have more than thausands of such sorted
Hi!
I'm in need of heavy (long, complicated, interesting, whatever)
templates and/or compile-time functions to help me debug the
compile-time debugger I'm writing. Can you paste/attach some here, or
give me links?
Thanks,
Ary
Ary Borenszweig wrote:
Hi!
I'm in need of heavy (long, complicated, interesting, whatever)
templates and/or compile-time functions to help me debug the
compile-time debugger I'm writing. Can you paste/attach some here, or
give me links?
Thanks,
Ary
Have you considered Phobos2 itself?
nobody, el 25 de mayo a las 18:31 me escribiste:
== Quote from Leandro Lucarella (llu...@gmail.com)'s article
nobody, el 25 de mayo a las 03:24 me escribiste:
As other asked, are you using D1 Tango/Phobos? D2? In Tango/D2 you can
DMD v2.030 on Linux.
enable logging in the GC
Reply to Ary,
Hi!
I'm in need of heavy (long, complicated, interesting, whatever)
templates and/or compile-time functions to help me debug the
compile-time debugger I'm writing. Can you paste/attach some here, or
give me links?
Thanks,
Ary
HECK yes!
BCS wrote:
Hello Yigal,
C# assemblies are analogous to C/C++/D libs.
you can't create a standalone executable in D just by parsing the D
source files (for all the imports) if you need to link in external libs.
you need to at least specify the lib name if it's on the linker's
search path or
Reply to Yigal,
BCS wrote:
Hello Yigal,
C# assemblies are analogous to C/C++/D libs.
you can't create a standalone executable in D just by parsing the D
source files (for all the imports) if you need to link in external
libs.
you need to at least specify the lib name if it's on the linker's
Andrei Alexandrescu wrote:
Georg Wrede wrote:
Andrei Alexandrescu wrote:
This is somewhat OT but I think it's an interesting problem. Consider
the following data:
double[][] a =
[
[ 1, 4, 7, 8 ],
[ 1, 7 ],
[ 1, 7, 8],
[ 4 ],
[ 7 ],
];
We want to compute an n-way union,
Ary Borenszweig wrote:
Hi!
I'm in need of heavy (long, complicated, interesting, whatever)
templates and/or compile-time functions to help me debug the
compile-time debugger I'm writing. Can you paste/attach some here, or
give me links?
Thanks,
Ary
I'd give tools and xf.* a shot, they
Georg Wrede:
You probably have to have an array of structs, where each struct
contains a reference to a subarray, and a copy of the first value of
this subarray.
Keeping a cached copy of the first item of the subarray (subrange) may be
better in some situations and worse (compared to
Georg Wrede Wrote:
Andrei Alexandrescu wrote:
Georg Wrede wrote:
Andrei Alexandrescu wrote:
This is somewhat OT but I think it's an interesting problem. Consider
the following data:
double[][] a =
[
[ 1, 4, 7, 8 ],
[ 1, 7 ],
[ 1, 7, 8],
[ 4 ],
[ 7 ],
Georg Wrede wrote:
Andrei Alexandrescu wrote:
You can assume that each array is sorted.
Err, you didn't comment on my algorithm, at the end. So, either it is
worthless to an extent not deserving even a dismissal, or you didn't
read the rest of the post.
I am sorry, at the first two reads
bearophile wrote:
For Andrei: in my last post I have suggested to remove from the heap
the references to the sub-ranges as soon they are exhausted. But lot
of tests of mine have shown me that's often not the most efficient
strategy: http://www.fantascienza.net/leonardo/ar/list_deletions.html
Jason House wrote:
Don't get offended, he didn't respond to anyone else's algorithm either.
I just wanted to bring what I think is an interesting problem to the
table; my response shouldn't be used as a yardstick for one's ability to
define a good algorithm.
Now that I feel pressured to
bearophile wrote:
For Andrei: in my last post I have suggested to remove from the heap
the references to the sub-ranges as soon they are exhausted. But lot
of tests of mine have shown me that's often not the most efficient
strategy: http://www.fantascienza.net/leonardo/ar/list_deletions.html
Sorry for bumping this thread once, but I came across this issue again today.
It took my all the day to cut my project as much as possible while still
preserving this bug.
Changing nearly anything also vanishes the bug. Here are some examples:
1) There are a few cases where I extend an empty
Sorry for a lot of mistakes in this post, I'm sleepy (it's almost 5 am here)
and forgot to make a second pass through the text to fix them.
Andrei Alexandrescu wrote:
Georg Wrede wrote:
Andrei Alexandrescu wrote:
You can assume that each array is sorted.
Err, you didn't comment on my algorithm, at the end. So, either it is
worthless to an extent not deserving even a dismissal, or you didn't
read the rest of the post.
I am
Hello Jason,
I bet BCS had the advantage of a real keyboard ;)
you are 89% correct: http://en.wikipedia.org/wiki/Acer_Aspire_One
Who have the sqlserver2000 for d2 api ?
Can you give me ? thank you !
doliv...@sina.com
Sam Hu skrev:
To Kristoffer:
I tried and the dwt2 is compiled successfully,but the same problem that can not
compile app with DSSS ,nor can compile an app which include more than one
module.
Is is possible to pass me a copy of your compiled sets?I am as cuirous as
depressed what' the
Ary Borenszweig:
Thanks. Later in my head I instantiated the template and noticed the
problem.
In time I have created similar problems in my code 2-3 times, missing a
static before some if.
Can't the compiler help spot such bugs? If the variables a dynamic if works on
are constants
hasen hasan.alj...@gmail.com wrote in message
news:gv72f1$2s7...@digitalmars.com...
So, do you regularly visit http://stackoverflow.com/ or no?
No, not really. There's a lot of thing about it I don't like, so I never use
it.
http://d.puremagic.com/issues/show_bug.cgi?id=3010
Don clugd...@yahoo.com.au changed:
What|Removed |Added
Keywords||patch
--- Comment #2
http://d.puremagic.com/issues/show_bug.cgi?id=1994
Don clugd...@yahoo.com.au changed:
What|Removed |Added
Keywords||patch
CC|
http://d.puremagic.com/issues/show_bug.cgi?id=2952
Don clugd...@yahoo.com.au changed:
What|Removed |Added
CC||clugd...@yahoo.com.au
http://d.puremagic.com/issues/show_bug.cgi?id=2952
--- Comment #2 from Don clugd...@yahoo.com.au 2009-05-25 03:02:40 PDT ---
I have fixed this but can't post it to the runtime source since dsource is
down.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
http://d.puremagic.com/issues/show_bug.cgi?id=932
Don clugd...@yahoo.com.au changed:
What|Removed |Added
Status|NEW |RESOLVED
CC|
http://d.puremagic.com/issues/show_bug.cgi?id=3024
Koroskin Denis 2kor...@gmail.com changed:
What|Removed |Added
CC||2kor...@gmail.com
http://d.puremagic.com/issues/show_bug.cgi?id=3025
Summary: uniform(float,float) pops first, uniform(int,int) pops
last
Product: D
Version: 2.030
Platform: PC
OS/Version: Windows
Status: NEW
Severity:
d-bugm...@puremagic.com wrote:
http://d.puremagic.com/issues/show_bug.cgi?id=2952
--- Comment #2 from Don clugd...@yahoo.com.au 2009-05-25 03:02:40 PDT ---
I have fixed this but can't post it to the runtime source since dsource is
down.
In an earlier thread on one of the newsgroups, Sean
http://d.puremagic.com/issues/show_bug.cgi?id=339
Don clugd...@yahoo.com.au changed:
What|Removed |Added
Keywords||diagnostic
53 matches
Mail list logo