I'm no threading expert but 1000 - if those indeed are real
threads (like, preemptive OS threads) - is wa too many.
My understanding is that there's no benefit to creating more than
the number of hyperthreads your CPU supports (minus your main
thread?). So you'd want a work queue of all th
Hi,
I'm writing a picture browser program and I'd like to ask for a
bit of assistance.
My app is basically a Win32 window with an OpenGL surface.
Currently I'm able to display a lot of pictures in it. The
decompression of the bitmaps take place at the beginning of the
program.
I want to m
On Tuesday, 2 April 2019 at 18:52:07 UTC, Jacob Carlborg wrote:
On 2019-04-02 20:44, Q. Schroll wrote:
After removing the calls to writeln, the error I get is:
`this` for `read` needs to be type `Outer` not type `Inner`
You cannot access stuff in Outer because Inner objects are not
outer o
On 2019-04-02 20:44, Q. Schroll wrote:
After removing the calls to writeln, the error I get is:
`this` for `read` needs to be type `Outer` not type `Inner`
You cannot access stuff in Outer because Inner objects are not outer
objects and don't implicitly own an Outer object. In your Inner me
On 2019-04-02 15:23, Alex wrote:
__traits(getAttributes, T)
Requires a type and a field is unfortunately not a type ;/
enum attr;
struct Foo
{
@attr int a;
}
void main()
{
alias a = __traits(getAttributes, Foo.a);
}
--
/Jacob Carlborg
On 2019-04-02 15:11, Alex wrote:
How do I get the mangled name of a field? mangledName!T requires passing
a type ;/
struct Foo
{
int a;
}
void main()
{
writeln(Foo.a.mangleof);
}
--
/Jacob Carlborg
On Tuesday, 2 April 2019 at 18:20:09 UTC, Andrey wrote:
Hello,
In this example how can I access the members "read" and "q" of
struct Outer from Inner struct?
struct Outer
{
ulong q = 1;
Inner inner;
void read(ulong value)
{
q += value;
}
void run()
{
On 02-04-2019 17:48, Ron Tarrant wrote:
On Tuesday, 2 April 2019 at 14:13:09 UTC, number wrote:
Can somebody explain why getRgba() (apparently inherited from
ColorChooser) does take an out parameter instead of returning an
Gdk.RGBA?
My understanding is this:
Returning an object (as opposed
Hello,
In this example how can I access the members "read" and "q" of
struct Outer from Inner struct?
struct Outer
{
ulong q = 1;
Inner inner;
void read(ulong value)
{
q += value;
}
void run()
{
q.writeln;
read(5);
}
struct Inner
On Tuesday, 2 April 2019 at 14:13:09 UTC, number wrote:
Thank you!
You're welcome. :)
The function ignores its argument and always uses member
variable button2 instead. Changing the parameter type to
MyRadioButton and using 'button' instead of 'button2' in the
body works, so you could pass
On Tuesday, 2 April 2019 at 13:36:47 UTC, Alex wrote:
On Tuesday, 2 April 2019 at 13:23:37 UTC, Alex wrote:
__traits(getAttributes, T)
Requires a type and a field is unfortunately not a type ;/
I'd like to be able to get the attributes without having to
instantiate the base type because that
On Tuesday, 2 April 2019 at 11:31:39 UTC, Ron Tarrant wrote:
Today's the day for (yet) another blog post over on
gtkDcoding.com and the subjects are:
- the RadioButton, and
- the ColorButton.
You can find it here:
http://gtkdcoding.com/2019/04/02/0023-radio-and-color-buttons.html
Thank you
On Tuesday, 2 April 2019 at 13:23:37 UTC, Alex wrote:
__traits(getAttributes, T)
Requires a type and a field is unfortunately not a type ;/
I'd like to be able to get the attributes without having to
instantiate the base type because that is problematic and I see
no reason why it has to be i
__traits(getAttributes, T)
Requires a type and a field is unfortunately not a type ;/
How do I get the mangled name of a field? mangledName!T requires
passing a type ;/
On Tuesday, 2 April 2019 at 09:37:26 UTC, Per Nordlöw wrote:
Are there any plans on deprecating implicit conversions of
enums to integers?
Not that I know of. Given the precedence of this:
https://github.com/dlang/DIPs/blob/master/DIPs/rejected/DIP1015.md
I doubt enum/integer-types are going to
Today's the day for (yet) another blog post over on
gtkDcoding.com and the subjects are:
- the RadioButton, and
- the ColorButton.
You can find it here:
http://gtkdcoding.com/2019/04/02/0023-radio-and-color-buttons.html
On Tuesday, 2 April 2019 at 09:02:03 UTC, Dennis wrote:
You can make the enum type not an integer type.
```
struct Int{int i;}
enum E: Int {
first = Int(0),
second = Int(1),
}
```
Thanks.
Are there any plans on deprecating implicit conversions of enums
to integers?
On Monday, 1 April 2019 at 17:32:29 UTC, Andrey wrote:
Hello,
enum Key : string
{
First = "qwerty",
Last = "zaqy"
}
void main()
{
enum decl(alias values1) = q{
static foreach(value; values1)
mixin("bool " ~ value ~ " = false;");
};
enum qqq =
On Tuesday, 2 April 2019 at 08:38:28 UTC, Per Nordlöw wrote:
Is there a way (compiler flag) to forbid implicit conversions
from an enum type to integer types?
You can make the enum type not an integer type.
```
struct Int{int i;}
enum E: Int {
first = Int(0),
second = Int(1),
}
```
Is there a way (compiler flag) to forbid implicit conversions
from an enum type to integer types?
On Tuesday, 2 April 2019 at 07:47:29 UTC, Stefan Koch wrote:
On Tuesday, 2 April 2019 at 03:15:36 UTC, Alex wrote:
Is there any way to build an alias array at compile time that
isn't too heavy in resources?
{...}
Hi Alex,
I agree that there should be a way to do that.
As soon as newCTFE is
On Tuesday, 2 April 2019 at 03:15:36 UTC, Alex wrote:
Is there any way to build an alias array at compile time that
isn't too heavy in resources?
{...}
Hi Alex,
I agree that there should be a way to do that.
As soon as newCTFE is a releasable state, I'll work on that again
:)
I'd be inter
23 matches
Mail list logo