On Monday, 9 November 2020 at 20:57:33 UTC, Daniel Kozak wrote:
On Mon, Nov 9, 2020 at 9:50 PM rinfz via Digitalmars-d-learn <
digitalmars-d-learn@puremagic.com> wrote:
On Monday, 9 November 2020 at 20:40:59 UTC, rinfz wrote:
> On Monday, 9 November 2020 at 19:55:07 UTC, Vino wrote:
>> ...
>
On Tuesday, 10 November 2020 at 01:00:50 UTC, Mark wrote:
Hi all,
my question would be about using D or not using D.
Here are some things you will NOT get in D:
youtube -> Dconf 2014 Day 2 Keynote: The Last Thing D Needs --
Scott Meyers
For example, you will not get neurosis from it, or
On Tuesday, 10 November 2020 at 01:00:50 UTC, Mark wrote:
Hi all,
Anyone have any thoughts how C++ and D compare?
C++ has a bit more mathematical feeling, everything has been
sorted out in the spec, even if the rules are crazy difficult. D
feels like it's up to _you_ to write the spec as
On Tue, Nov 10, 2020 at 01:00:50AM +, Mark via Digitalmars-d-learn wrote:
[...]
> my question would be about using D or not using D. Is the newest C++
> iteration any good compared to D?
[...]
> I haven't looked into the newest C++. In theory, they might have added
> something helpful in the
On Tuesday, 10 November 2020 at 01:00:50 UTC, Mark wrote:
Anyone have any thoughts how C++ and D compare?
Broadly speaking: D has a better core language, and C++ has a
much better library and tooling ecosystem.
Hi all,
my question would be about using D or not using D. Is the newest
C++ iteration any good compared to D?
The reason I haven't used C++ anymore for years is that I was too
naive sometimes. I tried to use new features in Visual C++, found
myself being like a beta-tester for some things.
On Monday, 9 November 2020 at 22:04:55 UTC, kdevel wrote:
It appears to me that the overload resolution may depend on the
/value/ of the function argument. According to [1] the type of
1 is int and that of 1L is long. Thus I would have expected
foo!int and foo!long being called in those cases.
On Monday, 9 November 2020 at 22:04:55 UTC, kdevel wrote:
It appears to me that the overload resolution may depend on the
/value/ of the function argument. According to [1] the type of
1 is int and that of 1L is long.
That's not exactly true because of value range propagation. It is
weird in
Today I came across this:
~~~id.d
import std.stdio : writeln;
T foo (T) (T s)
{
__PRETTY_FUNCTION__.writeln;
return s;
}
short foo (short s)
{
__PRETTY_FUNCTION__.writeln;
return s;
}
T id (T) (T t)
{
return t;
}
int main ()
{
foo (1);
foo (1L);
foo (id (1));
foo
On Mon, Nov 9, 2020 at 9:50 PM rinfz via Digitalmars-d-learn <
digitalmars-d-learn@puremagic.com> wrote:
> On Monday, 9 November 2020 at 20:40:59 UTC, rinfz wrote:
> > On Monday, 9 November 2020 at 19:55:07 UTC, Vino wrote:
> >> ...
> >
> > The only curl option you need to set within the loop is
On Monday, 9 November 2020 at 20:40:59 UTC, rinfz wrote:
On Monday, 9 November 2020 at 19:55:07 UTC, Vino wrote:
...
The only curl option you need to set within the loop is the
CurlOption.url. So your foreach block should look more like:
foreach (...) {
string url = chain(apihost,
On Monday, 9 November 2020 at 19:55:07 UTC, Vino wrote:
...
The only curl option you need to set within the loop is the
CurlOption.url. So your foreach block should look more like:
foreach (...) {
string url = chain(apihost, only(':'), to!string(apiport),
apiuri).to!string;
Just delete it
On Mon, Nov 9, 2020 at 9:00 PM Vino via Digitalmars-d-learn <
digitalmars-d-learn@puremagic.com> wrote:
> Hi All,
>
>Request your help to on how to improve the performance of the
> below code.
>
> import std.conv: to;
> import std.net.curl : get, HTTP, CurlOption;
> import
Hi All,
Request your help to on how to improve the performance of the
below code.
import std.conv: to;
import std.net.curl : get, HTTP, CurlOption;
import std.parallelism: parallel;
import std.range: chain, only;
import std.typecons: Tuple, tuple;
void main ()
{
Array!(Tuple!(int,string))
On Monday, 9 November 2020 at 18:55:44 UTC, Ali Çehreli wrote:
On 11/9/20 9:53 AM, k2aj wrote:
> string text = "welcome2worldinfo";
> string hg = toUpper(text[0..7] ~ "-" ~ text[7..8] ~ "-" ~
text[8..13]);
If those concatenations with the ~ operators prove to be costly
at runtime, the
On Monday, 9 November 2020 at 18:55:44 UTC, Ali Çehreli wrote:
On 11/9/20 9:53 AM, k2aj wrote:
> string text = "welcome2worldinfo";
> string hg = toUpper(text[0..7] ~ "-" ~ text[7..8] ~ "-" ~
text[8..13]);
If those concatenations with the ~ operators prove to be costly
at runtime, the
On 11/9/20 9:53 AM, k2aj wrote:
> string text = "welcome2worldinfo";
> string hg = toUpper(text[0..7] ~ "-" ~ text[7..8] ~ "-" ~ text[8..13]);
If those concatenations with the ~ operators prove to be costly at
runtime, the following range expression may be faster because it does
not allocate
On Monday, 9 November 2020 at 16:00:28 UTC, Vino wrote:
Hi All,
Request your help on how to extract sub string from a
string, below is an example in PHP, need your help on how to do
the same in D.
$text = "welcome2worldinfo";
$hg = strtoupper(substr($text , 0, 7).'-'.substr($text, 7,
On Monday, 9 November 2020 at 16:00:28 UTC, Vino wrote:
Hi All,
Request your help on how to extract sub string from a
string, below is an example in PHP, need your help on how to do
the same in D.
$text = "welcome2worldinfo";
$hg = strtoupper(substr($text , 0, 7).'-'.substr($text, 7,
On Mon, Nov 09, 2020 at 03:39:05PM +, Per Nordlöw via Digitalmars-d-learn
wrote:
> Is there any library that can deal with decoding and generating
> character matchers for Unicode regular expression described at
>
> https://www.regular-expressions.info/unicode.html
I'm pretty sure std.regex
On Sunday, 8 November 2020 at 10:47:34 UTC, Per Nordlöw wrote:
Can I just do, for instance,
cast(dchar)0xd8000
for
`\Ud800`
to accomplish this?
There's also:
dchar(0xd8000)
Hi All,
Request your help on how to extract sub string from a string,
below is an example in PHP, need your help on how to do the same
in D.
$text = "welcome2worldinfo";
$hg = strtoupper(substr($text , 0, 7).'-'.substr($text, 7,
1).'-'.substr($text, 8, 5));
print_r($hg) \\ Output :
On Sunday, 8 November 2020 at 19:31:50 UTC, frame wrote:
On Sunday, 8 November 2020 at 19:29:39 UTC, frame wrote:
On Sunday, 8 November 2020 at 16:30:40 UTC, Vino wrote:
Request your help on how to get the first value of "type"
from the below json, the expected output required is as below,
Is there any library that can deal with decoding and generating
character matchers for Unicode regular expression described at
https://www.regular-expressions.info/unicode.html
On Monday, 9 November 2020 at 09:05:58 UTC, Imperatorn wrote:
On Monday, 9 November 2020 at 08:06:54 UTC, Andrey wrote:
Hello,
Are here any differences in creation of dynamic array with
known size?
auto array = new wchar[](111);
and
wchar[] array;
array.length = 111;
You can check
On Monday, 9 November 2020 at 08:06:54 UTC, Andrey wrote:
Hello,
Are here any differences in creation of dynamic array with
known size?
auto array = new wchar[](111);
and
wchar[] array;
array.length = 111;
It's the same. If the two are valid then you are in a function.
So it's an
On Monday, 9 November 2020 at 08:06:54 UTC, Andrey wrote:
Hello,
Are here any differences in creation of dynamic array with
known size?
auto array = new wchar[](111);
and
wchar[] array;
array.length = 111;
In theory
auto array = new wchar[111]; // or new wchar[](111);
should do less
On Monday, 9 November 2020 at 09:05:58 UTC, Imperatorn wrote:
On Monday, 9 November 2020 at 08:06:54 UTC, Andrey wrote:
Hello,
Are here any differences in creation of dynamic array with
known size?
auto array = new wchar[](111);
and
wchar[] array;
array.length = 111;
You can check
On Monday, 9 November 2020 at 08:06:54 UTC, Andrey wrote:
Hello,
Are here any differences in creation of dynamic array with
known size?
auto array = new wchar[](111);
and
wchar[] array;
array.length = 111;
You can check using compiler explorer:
https://godbolt.org/
Hello,
Are here any differences in creation of dynamic array with known
size?
auto array = new wchar[](111);
and
wchar[] array;
array.length = 111;
30 matches
Mail list logo