https://issues.dlang.org/show_bug.cgi?id=18530
Martin Nowak changed:
What|Removed |Added
Hardware|x86 |All
OS|Mac OS
object.d includes this function _postblitRecurse that's intentionally
public but undocumented. As far as I can see only unittests are using
it. What's the deal with it? Thanks! -- Andrei
https://issues.dlang.org/show_bug.cgi?id=18547
Issue ID: 18547
Summary: Win32: throwing exception in fiber crashes application
Product: D
Version: D2
Hardware: x86
OS: Windows
Status: NEW
Severity: normal
On 3/2/18 10:26 AM, Timon Gehr wrote:
On 02.03.2018 16:05, Steven Schveighoffer wrote:
On 3/2/18 10:00 AM, Timon Gehr wrote:
On 02.03.2018 15:39, Steven Schveighoffer wrote:
In this interpetation, -noboundscheck switches DMD to a different
dialect of D. In that dialect, out-of-bounds
On Friday, 2 March 2018 at 18:07:34 UTC, carblue wrote:
(It may be absolutely unrelated, but there once was a very
productive and knowledgeable compiler et. al. contributor,
9rnsr, Hara Kenji; though not contributing to dmd since ~ 1.5
years any more, he's still ranked #1 in number of
On 03/02/2018 03:39 PM, Steven Schveighoffer wrote:
On 3/1/18 5:27 PM, ag0aep6g wrote:
[...]
No, I'm looking at the source code.
At the very basic level, you have this:
assert(foo == 0);
Or whatever other condition you have. What this does is gives the
compiler leeway to ASSUME foo is 0 at
https://issues.dlang.org/show_bug.cgi?id=18530
Steven Schveighoffer changed:
What|Removed |Added
CC|
On Thursday, 22 February 2018 at 14:36:10 UTC, Radu wrote:
Whould like to know what's the state of dip1000?
The fact that it takes 8 days for any reply, doesn't that say
something?
@safe is a high ranked technical issue in vision papers (in
german we say something like "paper is patient"),
On Friday, March 02, 2018 11:25:00 Steven Schveighoffer via Digitalmars-d
wrote:
> Yes, I think assertions should be kept in @safe code. It's weird to have
> array bounds checks kept, but not assertions (which is how you would do
> equivalent bounds checks in a custom type).
Then just don't
On 03/02/2018 01:50 PM, Jonathan M Davis wrote:
On Friday, March 02, 2018 13:32:24 Andrei Alexandrescu via Digitalmars-d
wrote:
object.d includes this function _postblitRecurse that's intentionally
public but undocumented. As far as I can see only unittests are using
it. What's the deal with
On Thursday, 1 March 2018 at 16:37:02 UTC, aliak wrote:
I've put up a little experiment
If you're interested: https://github.com/aliak00/optional
Nice! Optional is like std's Nullable with extra bells and
whistles to make it as painless as you can offer it. I've read
all of Optional's
On 3/2/18 2:45 PM, H. S. Teoh wrote:
On Fri, Mar 02, 2018 at 02:23:14PM -0500, Andrei Alexandrescu via Digitalmars-d
wrote:
[...]
But I don't have a simple method to ascribe the blame to a specific
PR. Is the only way to look at the date then look at the log? Thanks.
-- Andrei
This is how I
On 3/2/18 3:26 PM, Nordlöw wrote:
On Wednesday, 28 February 2018 at 20:07:50 UTC, Steven Schveighoffer wrote:
auto x = cast(Object)((cast(size_t *)null) + 1);
Is this preferred performance-wise over `cast(void*)(size_t.max)`?
No, it just works, as opposed to, um... not working ;)
I think
On 3/2/18 1:21 PM, Jonathan M Davis wrote:
On Friday, March 02, 2018 11:25:00 Steven Schveighoffer via Digitalmars-d
wrote:
Yes, I think assertions should be kept in @safe code. It's weird to have
array bounds checks kept, but not assertions (which is how you would do
equivalent bounds checks
https://issues.dlang.org/show_bug.cgi?id=18501
--- Comment #2 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/dlang/phobos
https://github.com/dlang/phobos/commit/b9196a976c75b5584290fd111261c507af14
fix issue 18501 - randomShuffle and partialShuffle
https://issues.dlang.org/show_bug.cgi?id=18501
github-bugzi...@puremagic.com changed:
What|Removed |Added
Status|NEW |RESOLVED
On Wednesday, 28 February 2018 at 20:07:50 UTC, Steven
Schveighoffer wrote:
auto x = cast(Object)((cast(size_t *)null) + 1);
Is this preferred performance-wise over `cast(void*)(size_t.max)`?
On Friday, March 02, 2018 14:23:14 Andrei Alexandrescu via Digitalmars-d
wrote:
> On 03/02/2018 01:50 PM, Jonathan M Davis wrote:
> > On Friday, March 02, 2018 13:32:24 Andrei Alexandrescu via Digitalmars-d
> >
> > wrote:
> >> object.d includes this function _postblitRecurse that's intentionally
On Friday, 2 March 2018 at 18:17:02 UTC, Paolo Invernizzi wrote:
On Friday, 2 March 2018 at 18:07:34 UTC, carblue wrote:
(It may be absolutely unrelated, but there once was a very
productive and knowledgeable compiler et. al. contributor,
9rnsr, Hara Kenji; though not contributing to dmd
On 3/2/18 3:23 PM, Christian Köstlin wrote:
To give an example:
class Thread {
...
Thread start() {...}
}
class Timer : Thread {
...
}
void main() {
// Timer timer = new Timer().start; // this does not work
auto timer = new Timer().start; // because timer is of type Thread
}
On 3/2/18 3:02 PM, Steven Schveighoffer wrote:
It's easier than that.
The git blame view in github shows it as this commit:
https://github.com/dlang/druntime/commit/f98a02142767d2d14b574cd381670dbd53b90d36
If you look in the upper left, it shows "master (#1181)", where 1181 is
the PR
That's a much nicer way of saying what I was trying to get across. :-)
Early respondents to a lengthy survey about D usage are not necessarily a
good representation of the more casual user's needs for the language.
--bb
On Thu, Mar 1, 2018 at 1:49 PM, Jonathan M Davis via
On Friday, March 02, 2018 13:32:24 Andrei Alexandrescu via Digitalmars-d
wrote:
> object.d includes this function _postblitRecurse that's intentionally
> public but undocumented. As far as I can see only unittests are using
> it. What's the deal with it? Thanks! -- Andrei
It looks like it was
On Fri, Mar 02, 2018 at 02:23:14PM -0500, Andrei Alexandrescu via Digitalmars-d
wrote:
[...]
> But I don't have a simple method to ascribe the blame to a specific
> PR. Is the only way to look at the date then look at the log? Thanks.
> -- Andrei
This is how I usually do it:
1) Find the hash of
To give an example:
class Thread {
...
Thread start() {...}
}
class Timer : Thread {
...
}
void main() {
// Timer timer = new Timer().start; // this does not work
auto timer = new Timer().start; // because timer is of type Thread
}
thanks in advance,
christian
https://issues.dlang.org/show_bug.cgi?id=18548
Issue ID: 18548
Summary: [2.079 Beta] std.format ignores templated toString if
another toString is not a template
Product: D
Version: D2
Hardware: All
OS: All
On 03.03.2018 01:20, H. S. Teoh wrote:
On Fri, Mar 02, 2018 at 11:51:08PM +, Jonathan Marler via Digitalmars-d
wrote:
I believe I found small hole in template parameter semantics.
[...] you can't create a template that accepts a value of any type.
Not true:
template
On 02/28/2018 11:48 AM, Patrick Schluter wrote:
> Just for information. DWT doesn't build with 2.079 because of overloads
> not allowed . I'm not good enough to do something about it but only
> wanted to make people aware of it. I also opened an issue at the dwt
> project.
On Friday, 2 March 2018 at 13:05:58 UTC, Russel Winder wrote:
Science, in and of itself, cannot be dodgy.
science must involve humans, and humans are often dodgy.
Yes there are debates to be had, cf. Popper, Kuhn, etc. but the
foundation of science is hypotheses, experimentation, and
On Saturday, 3 March 2018 at 00:20:14 UTC, H. S. Teoh wrote:
On Fri, Mar 02, 2018 at 11:51:08PM +, Jonathan Marler via
Digitalmars-d wrote:
[...]
Not true:
template counterexample(alias T) {}
int x;
string s;
alias U = counterexample!x; // OK
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA512
Glad to announce D 2.079.0.
This release comes with experimental `@nogc` exception throwing
(-dip1008), a lazily initialized GC, better support for minimal
runtimes, and an experimental Windows toolchain based on the lld
linker and MinGW import
On Friday, 2 March 2018 at 12:20:31 UTC, Paulo Pinto wrote:
And if you like C so much, what are you doing in a safe systems
programming language forum?
How safe is D.. i mean really ;-)
and why do people ask me that question.. I don't get it.
I program (or try to) in as many languages as
On 3/2/2018 10:07 AM, carblue wrote:
I generally already used -dip1000 since DConf2017 and it served me well, until
about 2 month ago, "by accident" code was committed to std.uni that broke my
builds, see issue #17961. I invested a lot of time to fix this by PR 6041.
The current state is: I
On 02/26/2018 03:59 PM, Adam D. Ruppe wrote:
> http://dplug.dpldocs.info/v6.0.22/dplug.html
>
> 6.0.22 of the dplug package.
Cool stuff Adam, thx. Was thinking about this for a while myself.
A central doc provider could have some benefit, e.g. searching across
different libraries.
Compared to
On Saturday, 3 March 2018 at 01:50:25 UTC, Martin Nowak wrote:
Glad to announce D 2.079.0.
I've got a blog post coming on this in a few hours, so I would
ask anyone considering sharing this on /r/programming before then
to please refrain :-)
On Saturday, 3 March 2018 at 02:12:52 UTC, Martin Nowak wrote:
A central doc provider could have some benefit, e.g. searching
across different libraries.
Yeah, I have code for that written for select libraries already
(on the main dpldocs.info site), but haven't opened it up to the
full dub
https://issues.dlang.org/show_bug.cgi?id=18461
feklushkin.de...@gmail.com changed:
What|Removed |Added
Summary|core.bitop.bt returns |codegen bug in dmd
On 03/02/2018 02:24 AM, Jacob Carlborg wrote:
Travis CI allows you to specify a D compiler in the following ways:
* - the latest version of the specified compiler
* -beta - the latest beta
* -nightly - the nightly build
* - - a specific version of the compiler
Where is "dmd", "ldc" or
On 2 March 2018 at 10:07, carblue via Digitalmars-d
wrote:
> On Thursday, 22 February 2018 at 14:36:10 UTC, Radu wrote:
>>
>> Whould like to know what's the state of dip1000?
>
>
> The fact that it takes 8 days for any reply, doesn't that say something?
> @safe is a
https://issues.dlang.org/show_bug.cgi?id=17779
Mike Franklin changed:
What|Removed |Added
Status|NEW |RESOLVED
https://issues.dlang.org/show_bug.cgi?id=5212
Walter Bright changed:
What|Removed |Added
CC|
Gtk-d and DWT are both too big to automatically build on the
server, but I did some manual work on them.
DWT:
http://dwt.dpldocs.info/org.eclipse.swt.widgets.html
GTK-D:
http://dpldocs.info/experimental-docs/gtk.Application.Application.html
The gtk one has me translating some syntax from C
https://issues.dlang.org/show_bug.cgi?id=18549
Issue ID: 18549
Summary: name gets overwritten in template definition
Product: D
Version: D2
Hardware: x86_64
OS: All
Status: NEW
Severity: normal
https://issues.dlang.org/show_bug.cgi?id=18208
github-bugzi...@puremagic.com changed:
What|Removed |Added
Status|NEW |RESOLVED
https://issues.dlang.org/show_bug.cgi?id=17964
--- Comment #3 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/dlang/druntime
https://github.com/dlang/druntime/commit/fe4425678d9de2c085b1cdc0a97b28d2f8cf0dc8
Issue 17964 - [CTFE] If array is large enough it
https://issues.dlang.org/show_bug.cgi?id=17188
--- Comment #8 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/dlang/druntime
https://github.com/dlang/druntime/commit/02f30af1e4b90de78dfa959abd4ba0d3c77e0bef
fix Issue 17188 - qsort predicate requires scope
https://issues.dlang.org/show_bug.cgi?id=18300
github-bugzi...@puremagic.com changed:
What|Removed |Added
Resolution|DUPLICATE |FIXED
--
https://issues.dlang.org/show_bug.cgi?id=18531
github-bugzi...@puremagic.com changed:
What|Removed |Added
Status|NEW |RESOLVED
https://issues.dlang.org/show_bug.cgi?id=18531
--- Comment #2 from github-bugzi...@puremagic.com ---
Commit pushed to master at https://github.com/dlang/druntime
https://github.com/dlang/druntime/commit/a8415b6558d1ae461b923e5e6a42d2458989f352
fix issue 18531 -
https://issues.dlang.org/show_bug.cgi?id=18300
--- Comment #4 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/dlang/druntime
https://github.com/dlang/druntime/commit/8b8754d77faa2d02186c9991f5ec9b23d67db280
fix issue 18300: range error with long symbol
As far as I understand, this is generally how ref counting is supposed
to be done, and with a simple payload like `int` it's supposed to be
properly safe already:
module my_rc_thingy;
struct RCint
{
import core.stdc.stdlib: free, malloc;
private static struct Store
{
On 03/03/2018 12:22 AM, ag0aep6g wrote:
But what about `tupleof`? It ignores `private` and it's allowed in
`@safe` code:
[...]
Now that I've sent this, I find the affected Phobos type I couldn't
pinpoint. It's `File`:
void main() @safe
{
import std.stdio: File,
I believe I found small hole in template parameter semantics.
I've summarized it here
(https://github.com/marler8997/dlangfeatures#template-auto-value-parameter). Wanted to get feedback before I look into creating a PR for it.
--
COPY/PASTED from
On 02.03.18 21:39, Steven Schveighoffer wrote:
> On 3/2/18 3:23 PM, Christian Köstlin wrote:
>> To give an example:
>>
>> class Thread {
>> ...
>> Thread start() {...}
>> }
>>
>> class Timer : Thread {
>> ...
>> }
>>
>>
>> void main() {
>> // Timer timer = new Timer().start; // this
https://issues.dlang.org/show_bug.cgi?id=16243
--- Comment #22 from github-bugzi...@puremagic.com ---
Commit pushed to master at https://github.com/dlang/dmd
https://github.com/dlang/dmd/commit/3ec7537f76142b23f5eed062f0420a20abcc0f9b
Temporary workaround for Issue 16243 (#7970)
--
https://issues.dlang.org/show_bug.cgi?id=18550
--- Comment #1 from hst...@quickfur.ath.cx ---
(Not to mention, the makefile outright fails because it makes assumptions
incompatible with my system, therefore one of the compilation targets fail. Why
generating HTML docs should depend on compiling a
https://issues.dlang.org/show_bug.cgi?id=18208
--- Comment #5 from github-bugzi...@puremagic.com ---
Commit pushed to master at https://github.com/dlang/druntime
https://github.com/dlang/druntime/commit/f16bd2db0cca3559be2bda9626b86f26f62e9cc8
fix issue 18208 - add unittest
--
https://issues.dlang.org/show_bug.cgi?id=17188
github-bugzi...@puremagic.com changed:
What|Removed |Added
Status|REOPENED|RESOLVED
>> class Timer : Thread {
>> override Timer start() { ... }
>> }
>>
>> https://dlang.org/spec/function.html#virtual-functions
>>
>> (see item 6)
>>
>> -Steve
> Thanks for this.
> It works for me only without the override (with override I get
> Error: function timer.Timer.start does not override
On Sat, Mar 03, 2018 at 01:13:43AM +0100, Christian Köstlin via
Digitalmars-d-learn wrote:
> >> class Timer : Thread {
> >> override Timer start() { ... }
> >> }
> >>
> >> https://dlang.org/spec/function.html#virtual-functions
> >>
> >> (see item 6)
> >>
> >> -Steve
> > Thanks for this.
> > It
https://issues.dlang.org/show_bug.cgi?id=18550
Issue ID: 18550
Summary: Offline option for dlang.org makefile
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: enhancement
On Fri, Mar 02, 2018 at 11:51:08PM +, Jonathan Marler via Digitalmars-d
wrote:
> I believe I found small hole in template parameter semantics.
> [...] you can't create a template that accepts a value of any type.
Not true:
template counterexample(alias T) {}
int x;
On Saturday, 3 March 2018 at 01:50:25 UTC, Martin Nowak wrote:
Glad to announce D 2.079.0.
This release comes with experimental `@nogc` exception throwing
(-dip1008), a lazily initialized GC, better support for minimal
runtimes, and an experimental Windows toolchain based on the
lld linker
https://issues.dlang.org/show_bug.cgi?id=18551
Issue ID: 18551
Summary: Improve hint for "does not override any function
Product: D
Version: D2
Hardware: x86
OS: Mac OS X
Status: NEW
Severity: enhancement
An all-D MySQL/MariaDB client library:
https://github.com/mysql-d/mysql-native
==
Tagged 'v2.1.0', which mainly adds a few new features, including greatly
simplified shortcut syntax for prepared statements (with automatic,
implicit caching and re-use):
hi there,
I just flased a armbain for nanoPi M3.
And, I just installed ldc2-1.2.0 armhf using apt-get. it compiles
d code with combination with gcc armhf and compiled program runs
great even the arch is aarch64.
But I realized that ldc2 is too old, I know that latest ldc2 is
1.8.0.
So,
trying to do this C code, in D, but getting error:
"Error: assignment cannot be used as a condition, perhaps `==`
was meant?"
any help much appreciated:
--
while ((*dst++ = *src++)) {}
--
On Wednesday, 28 February 2018 at 14:05:19 UTC, Jonathan M Davis
wrote:
I expect that pretty much anything you propose that requires
code flow analysis is DOA. Walter is almost always against
features that require it, because it's so hard to get right,
and the places that D does use it tend to
I do not know, but from my experience it is good at it. I have done many
benchmarks for plenty of code, and in recent D compilers -boundscheck=off
does not improve speed. To be fair using -boundscheck=off make D code
slower in many cases, which is wierd but true.
On Fri, Mar 2, 2018 at 8:48 AM,
On Thursday, 1 March 2018 at 12:20:08 UTC, Steven Schveighoffer
wrote:
On 3/1/18 7:05 AM, Gary Willoughby wrote:
On Thursday, 1 March 2018 at 10:10:27 UTC, John Burton wrote:
My question is how do I tell if a pointer is "garbage
collected" or not?
You could try `GC.addrOf()` or `GC.query()`
On Friday, 2 March 2018 at 08:44:53 UTC, Gary Willoughby wrote:
It would be interesting to test whether those methods handle
these scenarios.
Yeah, it doesn't work.
https://dpaste.dzfl.pl/55116efd0c9c
On Friday, 2 March 2018 at 04:38:24 UTC, psychoticRabbit wrote:
On Friday, 2 March 2018 at 03:57:25 UTC, barry.harris wrote:
Sorry little rabbit, your are misguided in this belief. Back
in day we all used C and this is the reason most "safer"
languages exist today.
You can write pretty
On 3/1/18 5:27 PM, ag0aep6g wrote:
You're looking at the behavior of the compiled executable. Then it makes
sense to say that a program compiled with the checks has defined
behavior (throwing Errors) and a program without the checks does
something undefined (because the compiler manual
On 3/2/18 9:23 AM, Steven Schveighoffer wrote:
On 3/1/18 11:50 PM, Nick Sabalausky (Abscissa) wrote:
How could this be accomplished? Is it even possible?
You'd have to do this in the parent. You can duplicate the file
descriptor, so that writing to either goes to the same spot, but you
On 3/2/18 10:00 AM, Timon Gehr wrote:
On 02.03.2018 15:39, Steven Schveighoffer wrote:
In this interpetation, -noboundscheck switches DMD to a different
dialect of D. In that dialect, out-of-bounds accesses (and
overlapping copies, apparently) always have UB, in both @system and
@safe
On 02.03.2018 15:39, Steven Schveighoffer wrote:
In this interpetation, -noboundscheck switches DMD to a different
dialect of D. In that dialect, out-of-bounds accesses (and overlapping
copies, apparently) always have UB, in both @system and @safe code.
That defeats the purpose of @safe.
On Friday, 2 March 2018 at 09:44:20 UTC, psychoticRabbit wrote:
trying to do this C code, in D, but getting error:
"Error: assignment cannot be used as a condition, perhaps `==`
was meant?"
any help much appreciated:
--
while ((*dst++ = *src++)) {}
--
You can't use this syntax
On Wednesday, 28 February 2018 at 18:27:49 UTC, Jiyan wrote:
On Wednesday, 28 February 2018 at 18:23:04 UTC, Jiyan wrote:
Hey,
i thought i had understood postblit, but in my Code the
following is happening (simplified):
struct C
{
this(this){/*Do sth*/}
list!C;
void opAssign(const C c)
{
On Monday, 26 February 2018 at 21:07:52 UTC, Meta wrote:
This is possible in the language today using the implicit class
construction feature of runtime variadic arrays:
class VArray
{
Variant[] va;
this(T...)(T ts) { foreach(t; ts) { va ~= Variant(t); } }
}
void test(VArray ta...)
On Friday, 2 March 2018 at 11:00:09 UTC, Jonathan M Davis wrote:
In any case, I expect that anyone who wants D3 is going to have
a very hard time convincing Walter and Andrei that such large
breaking changes would be worth it at this point.
- Jonathan M Davis
I agree. I don't think there is
On Friday, March 02, 2018 09:44:20 psychoticRabbit via Digitalmars-d-learn
wrote:
> trying to do this C code, in D, but getting error:
> "Error: assignment cannot be used as a condition, perhaps `==`
> was meant?"
>
> any help much appreciated:
>
> --
> while ((*dst++ = *src++)) {}
> --
On Friday, 2 March 2018 at 10:01:34 UTC, Jonathan M Davis wrote:
On Friday, March 02, 2018 09:44:20 psychoticRabbit via
Digitalmars-d-learn wrote:
trying to do this C code, in D, but getting error:
"Error: assignment cannot be used as a condition, perhaps `==`
was meant?"
any help much
Hi,
The following works as expected:
auto range = [1, 2, 3, 4, 5];
foreach (i, el; range) {
writeln(i, ": ", el);
}
but this slight modification doesn't:
auto range = iota(5);
foreach (i, el; range) {
writeln(i, ": ", el);
}
DMD 2.078.3 says:
Error: cannot infer argument
On 02/03/2018 11:21 PM, Arredondo wrote:
Hi,
The following works as expected:
auto range = [1, 2, 3, 4, 5];
foreach (i, el; range) {
writeln(i, ": ", el);
}
s/range/array/
Arrays have a different foreach syntax than ranges do.
On Friday, 2 March 2018 at 10:21:39 UTC, Arredondo wrote:
Hi,
The following works as expected:
auto range = [1, 2, 3, 4, 5];
foreach (i, el; range) {
writeln(i, ": ", el);
}
but this slight modification doesn't:
auto range = iota(5);
foreach (i, el; range) {
writeln(i, ": ",
On Friday, March 02, 2018 10:21:39 Arredondo via Digitalmars-d-learn wrote:
> Hi,
>
> The following works as expected:
>
> auto range = [1, 2, 3, 4, 5];
> foreach (i, el; range) {
> writeln(i, ": ", el);
> }
>
> but this slight modification doesn't:
>
> auto range = iota(5);
> foreach (i, el;
On Fri, 2018-03-02 at 02:35 +, Meta via Digitalmars-d-announce
wrote:
> […]
> D1 -> D2 nearly killed D (can't remember which, but it was either
> Walter or Andrei that have said this on multiple occasions). A D2
> -> D3 transition might generate a lot of publicity if done very
> carefully,
On Friday, 2 March 2018 at 10:21:05 UTC, Russel Winder wrote:
[…]
There are those who use C because the only other option is
assembly language, so they make the right decision. This is an
indicator that high-level language toolchain manufacturers have
failed to port to their platform. I'll
https://issues.dlang.org/show_bug.cgi?id=18541
Jonathan M Davis changed:
What|Removed |Added
CC|
On Friday, 2 March 2018 at 10:08:57 UTC, Simen Kjærås wrote:
This is of course only partly true.
while ((*dst++ = *src++) != 0) {}
works just great, and also better shows what's actually being
tested for in the loop.
--
Simen
That's what I was after. Thanks!
Whilst we are espousing opinions…
On Fri, 2018-03-02 at 08:02 +, Paulo Pinto via Digitalmars-d-
announce wrote:
> On Friday, 2 March 2018 at 04:38:24 UTC, psychoticRabbit wrote:
> > […]
> >
> > You can write pretty safe code in C these days, without too
> > much trouble. We have the tooling
On Friday, 2 March 2018 at 10:27:27 UTC, Nicholas Wilson wrote:
try
https://dlang.org/phobos/std_range.html#enumerate
This worked. Thank you!
On Friday, 2 March 2018 at 08:25:51 UTC, dangbinghoo wrote:
So, does anyone know how to install latest ldc2 from arm-debain?
You can use the dlang install.sh script to download LDC and put
it in your home dir: https://dlang.org/install.html
-Johan
On Friday, 2 March 2018 at 10:21:39 UTC, Arredondo wrote:
Hi,
The following works as expected:
auto range = [1, 2, 3, 4, 5];
foreach (i, el; range) {
writeln(i, ": ", el);
}
but this slight modification doesn't:
auto range = iota(5);
foreach (i, el; range) {
writeln(i, ": ",
On Friday, 2 March 2018 at 09:59:53 UTC, deadalnix wrote:
Honestly, this is not that hard. It's very hard in DMD because
it doesn't go through an SSA like form at any point. It's
rather disappointing to see the language spec being decided
upon based on design decision made in a compiler many
On Friday, 2 March 2018 at 10:32:08 UTC, Jonathan M Davis wrote:
foreach does not support indices for ranges, only arrays. When
you have
foreach(e; range)
it gets lowered to
foreach(auto __range = range; !__range.empty;
__range.popFront())
{
auto e = __range.front;
}
There are no
On Friday, 2 March 2018 at 10:34:31 UTC, bauss wrote:
You can also call "array" from "std.array".
auto range = iota(5).array;
foreach (i, el; range) {
writeln(i, ": ", el);
}
Thank you. That's how I had it in my original code, I was just
trying to avoid gratuitous memory
https://issues.dlang.org/show_bug.cgi?id=18541
Basile B. changed:
What|Removed |Added
Status|NEW |RESOLVED
On Friday, 2 March 2018 at 10:21:05 UTC, Russel Winder wrote:
...continue with C in the face of overwhelming evidence
it is the wrong thing to do.
yeah, the health fanatics who promote their crap to goverments
and insurance agencies, use very similar arguments about sugar,
salt, alchohol,
https://issues.dlang.org/show_bug.cgi?id=6082
Steven Schveighoffer changed:
What|Removed |Added
CC|
1 - 100 of 118 matches
Mail list logo