On Sunday, 22 May 2016 at 21:21:33 UTC, Rishub Nagpal wrote:
On Sunday, 22 May 2016 at 12:13:07 UTC, ixid wrote:
What is the best OpenGL tutorial with D to use? I've tried to
use d-gamedev-intro and opengl-tutorials and seem to get
errors, files that are no longer included are needed (dgl)?
an
On Tuesday, May 24, 2016 23:19:32 Elie Morisse via Digitalmars-d-learn wrote:
> On Saturday, 13 October 2012 at 22:58:56 UTC, Timon Gehr wrote:
> > Afaik free-function operator overloads (but not in the context
> > of UFCS) were considered and turned down because D did not want
> > to get amidst di
On Saturday, 13 October 2012 at 22:58:56 UTC, Timon Gehr wrote:
Afaik free-function operator overloads (but not in the context
of UFCS) were considered and turned down because D did not want
to get amidst discussions about adding Koenig lookup. UFCS does
not do Koenig lookup.
I don't get it,
On Tuesday, May 24, 2016 19:52:17 Era Scarecrow via Digitalmars-d-learn wrote:
> On Tuesday, 24 May 2016 at 18:43:22 UTC, Adam D. Ruppe wrote:
> > On Tuesday, 24 May 2016 at 18:42:41 UTC, Gary Willoughby wrote:
> >> I have a T* pointer to the start of a malloc'd chunk of
> >> memory, the type T and
On Tuesday, May 24, 2016 18:28:44 Meta via Digitalmars-d-learn wrote:
> On Tuesday, 24 May 2016 at 15:07:55 UTC, Jonathan M Davis wrote:
> > On Tuesday, May 24, 2016 10:10:16 Steven Schveighoffer via
> >
> > Digitalmars-d-learn wrote:
> >> A while ago, I discovered that this works.
> >>
> >> class
On Wednesday, 11 May 2016 at 14:30:44 UTC, Vladimir Panteleev
wrote:
On Tuesday, 10 May 2016 at 04:48:23 UTC, Jeremy DeHaan wrote:
Building DMD, Phobos, and druntime on Linux is so easy and
straight forward. It all works as expected. What's up with
building DMD on Windows?
For historical reas
On Wednesday, 11 May 2016 at 14:30:44 UTC, Vladimir Panteleev
wrote:
On Tuesday, 10 May 2016 at 04:48:23 UTC, Jeremy DeHaan wrote:
After DMD is built, other things keep getting built by DMC. I
get more than a few errors due to having an eof character on
the first line of some .h files, or somet
On Tuesday, 24 May 2016 at 18:43:22 UTC, Adam D. Ruppe wrote:
On Tuesday, 24 May 2016 at 18:42:41 UTC, Gary Willoughby wrote:
I have a T* pointer to the start of a malloc'd chunk of
memory, the type T and the number of T's stored in the chunk.
Is there an efficient way of converting this infor
On Tuesday, 24 May 2016 at 15:17:37 UTC, Adam D. Ruppe wrote:
On Tuesday, 24 May 2016 at 14:29:53 UTC, John Nixon wrote:
This naively doesn’t seem right because the RHS of an
assignment should not be altered by it.
It's because the char[] being shallow copied still leads to
mutable stuff.
W
On Tuesday, 24 May 2016 at 15:27:45 UTC, llaine wrote:
As written in the description I'm really new to D, I discovered
it a few weeks ago thanks to the D Conf in Berlin.
After playing around for couple of days with it, I wanted to
share my journey with you guys on several points.
Thanks for
On 5/24/16 4:03 PM, pineapple wrote:
I would've expected this to work, but instead I get a compile error. Is
my syntax wrong? Is this just not a case that map can handle, and I
should be doing something else?
import std.algorithm : map;
import std.conv : to;
import std.stdio : wri
I would've expected this to work, but instead I get a compile
error. Is my syntax wrong? Is this just not a case that map can
handle, and I should be doing something else?
import std.algorithm : map;
import std.conv : to;
import std.stdio : writeln;
import std.string : join;
On Tuesday, 24 May 2016 at 18:43:22 UTC, Adam D. Ruppe wrote:
On Tuesday, 24 May 2016 at 18:42:41 UTC, Gary Willoughby wrote:
I have a T* pointer to the start of a malloc'd chunk of
memory, the type T and the number of T's stored in the chunk.
Is there an efficient way of converting this infor
On Tuesday, 24 May 2016 at 18:44:45 UTC, ag0aep6g wrote:
Seems to be a problem in ApplyLeft:
import std.meta: AliasSeq, ApplyLeft;
alias addType(T, string name) = AliasSeq!(T, name);
alias addTypeInt = ApplyLeft!(addType, int);
alias FullyInstantiated = addTypeInt!"foo";
Fails with:
On Tuesday, 24 May 2016 at 18:03:17 UTC, cy wrote:
https://p0nce.github.io/d-idioms/ I wanted to mention as well,
if you like idioms. That guy has some good ideas.
On Tuesday, 24 May 2016 at 17:36:45 UTC, Ali Çehreli wrote:
Yes, a link from that page points to a book that *can* be
bought but i
On 5/24/16 2:11 PM, Steven Schveighoffer wrote:
I get these errors:
Undefined symbols for architecture x86_64:
"dyld_enumerate_tlv_storage(void (dyld_tlv_states, dyld_tlv_info
const*) block_pointer)", referenced from:
_d_dyld_getTLSRange(void*, void**, unsigned long*) in osx_tls.o
"
On Tuesday, 24 May 2016 at 18:42:41 UTC, Gary Willoughby wrote:
I have a T* pointer to the start of a malloc'd chunk of memory,
the type T and the number of T's stored in the chunk.
Is there an efficient way of converting this information to a D
array of type T[] or even T[n]?
Slice it:
T[]
On 05/24/2016 06:22 PM, Edwin van Leeuwen wrote:
That's what I assumed at first.. So why does the following fail with:
cannot interpret double at compile time? I assumed staticMap would
automatically flatten the resulting AliasSeqs.
```
import std.meta : AliasSeq, ApplyLeft, staticMap;
struct P
I have a T* pointer to the start of a malloc'd chunk of memory,
the type T and the number of T's stored in the chunk.
Is there an efficient way of converting this information to a D
array of type T[] or even T[n]?
On Tuesday, 24 May 2016 at 15:07:55 UTC, Jonathan M Davis wrote:
On Tuesday, May 24, 2016 10:10:16 Steven Schveighoffer via
Digitalmars-d-learn wrote:
A while ago, I discovered that this works.
class C {
union
{
private int _my_var;
public const int my_var;
}
void
On 5/24/16 2:11 PM, Steven Schveighoffer wrote:
I get these errors:
Undefined symbols for architecture x86_64:
"dyld_enumerate_tlv_storage(void (dyld_tlv_states, dyld_tlv_info
const*) block_pointer)", referenced from:
_d_dyld_getTLSRange(void*, void**, unsigned long*) in osx_tls.o
"
I get these errors:
Undefined symbols for architecture x86_64:
"dyld_enumerate_tlv_storage(void (dyld_tlv_states, dyld_tlv_info
const*) block_pointer)", referenced from:
_d_dyld_getTLSRange(void*, void**, unsigned long*) in osx_tls.o
"__d_dyld_getTLSRange", referenced from:
_D2r
https://p0nce.github.io/d-idioms/ I wanted to mention as well, if
you like idioms. That guy has some good ideas.
On Tuesday, 24 May 2016 at 17:36:45 UTC, Ali Çehreli wrote:
Yes, a link from that page points to a book that *can* be
bought but it's available online as well:
It's worth buying, b
On Tuesday, 24 May 2016 at 06:59:18 UTC, Jacob Carlborg wrote:
What we need is something like this [1]:
auto c = Config{ foo: "foo", bar: "bar };
The compiler will know for sure that "c" is of type Config
because the right side includes the type.
[1] https://issues.dlang.org/show_bug.cgi?id=
On 05/24/2016 10:05 AM, cy wrote:
> On Tuesday, 24 May 2016 at 15:27:45 UTC, llaine wrote:
>> Of course I went to the getstarted.html page but
>
>> as a newbie with no system programming background I feel there are too
>> many choices for me.
>
> Oh, I don't think system programming is the issue
On Tuesday, 24 May 2016 at 15:27:45 UTC, llaine wrote:
I'm running Fedora 23 on a daily basis and the installation was
OK. Not as easy as on mac but still.
Yeah, rpm based distributions like Fedora/Redhat/etc have
historically been a real pain when it comes to installing stuff.
Depending on i
On Tuesday, 24 May 2016 at 15:27:45 UTC, llaine wrote:
Hi everybody,
[...]
5 - Tools
I've seen your comment on the DCD issue related to DUB (#198). It
mays be the plugin (and not DCD ) that doesn't register well
vibe-d. Also it's possible that it didn't work because vibe-d was
not yet fetch
On Tuesday, 24 May 2016 at 15:09:43 UTC, Adam D. Ruppe wrote:
On Tuesday, 24 May 2016 at 15:01:33 UTC, Edwin van Leeuwen
wrote:
// I expected AliasSeq!(double,"x")???
pragma(msg,test); // tuple((double), "x")
What Phobos calls AliasSeq is called tuple inside the compiler.
They are the same th
Dne 24.5.2016 v 17:27 llaine via Digitalmars-d-learn napsal(a):
Hi everybody,
As written in the description I'm really new to D, I discovered it a
few weeks ago thanks to the D Conf in Berlin.
After playing around for couple of days with it, I wanted to share my
journey with you guys on sev
On Saturday, 21 May 2016 at 23:06:10 UTC, Ali Çehreli wrote:
On 05/21/2016 12:56 PM, captain_fid wrote:
>>> [...]
fail me
>>> [...]
value); }
>>> [...]
have a
>> [...]
something.
> [...]
missing/forgetting/misunderstanding here.
opCast is for explicit type conversions. However, you seem to
Hi everybody,
As written in the description I'm really new to D, I discovered
it a few weeks ago thanks to the D Conf in Berlin.
After playing around for couple of days with it, I wanted to
share my journey with you guys on several points.
1 - Installation (DMD and DUB)
I'm running Fedor
On Tuesday, 24 May 2016 at 14:29:53 UTC, John Nixon wrote:
This naively doesn’t seem right because the RHS of an
assignment should not be altered by it.
It's because the char[] being shallow copied still leads to
mutable stuff.
What I typically do here is just add a method `dup` to the struc
On Tuesday, 24 May 2016 at 15:01:33 UTC, Edwin van Leeuwen wrote:
// I expected AliasSeq!(double,"x")???
pragma(msg,test); // tuple((double), "x")
What Phobos calls AliasSeq is called tuple inside the compiler.
They are the same thing, just different names.
static assert(is(test == AliasSeq
On Tuesday, May 24, 2016 10:10:16 Steven Schveighoffer via Digitalmars-d-learn
wrote:
> A while ago, I discovered that this works.
>
> class C {
> union
> {
>private int _my_var;
>public const int my_var;
> }
> void do_something() { _my_var = 4; }
> }
Yeah. That's
Hi all,
I am trying to get the type and name of a field at compile time,
but can't get the following to work. Anyone any idea of why test
is not of the type AliasSeq!(double, "x")?
```
import std.meta : AliasSeq;
struct Point { double x; double y; }
alias test = AliasSeq!(
typeof(__tra
1 import std.stdio;
2
3 struct CS{
4 char[] t;
5 CS opAssign(const CS rhs){
6 writeln("CS.opAssign called");
7 this.t = rhs.t.dup;
8 return this;}
9 };
10 void test_fun(const ref CS rhs){
11 CS cs = rhs;//error cannot implicitly convert expression
(rhs) of typ
On 5/21/16 1:32 PM, dan wrote:
Is it possible to have a class which has a variable which can be seen
from the outside, but which can only be modified from the inside?
Something like:
class C {
int my_var = 3; // semi_const??
void do_something() { my_var = 4; }
}
And then in another f
Probably normal, see this discussion:
https://forum.dlang.org/post/mailman.400.1389749305.15871.digitalmar...@puremagic.com
Anyway dmd is not known to have a quality backend, try ldc or gdc.
On Tuesday, 24 May 2016 at 13:17:22 UTC, chmike wrote:
After closer examination it seam that the second line with 9 is
a bogus insertion. Removing it should fix the code line table.
app.d 9
0x43aafb
app.d 11
After closer examination it seam that the second line with 9 is a
bogus insertion. Removing it should fix the code line table.
app.d 90x43aafb
app.d 110x43aafe
app.d
On Tuesday, 24 May 2016 at 05:01:39 UTC, ag0aep6g wrote:
You're missing that `parse`'s parameter is `ref`.
`splitValue.front` is not an lvalue, so it can't be passed in a
ref parameter.
This works:
auto f = splitValue.front;
parse!int(f);
Thanks. DMD desperately needs bette
Hello,
I've notice that gdb was improperly displaying source lines with
disassembled code.
I looked at the assembly to check what is inlined and what not
and the difference between the use of is and == in the machine
code.
I then tested with objdump with a simple program and saw the same
pr
Here you have the object lines from app with the addresses.
./app.d:[++]
app.d 30x43aae8
app.d 50x43aaf0
app.d 70x43aaf7
app.d
On 2016-03-07 10:18, ciechowoj wrote:
I'm using `dub` to build project. And every time I run `dub` it seems to
check if dependencies are up to date, which takes some time. Is there a
way to switch of that checking? Or any other way to speed up building
process? It really slows down my modify-comp
On 2016-05-23 21:51, Lodovico Giaretta wrote:
Hi,
Today I stumbled upon this weird error:
struct ConfigContainer
{
Config[string] configs;
}
struct Config
{
string foo;
string bar;
}
enum ConfigContainer cc = {
configs: [
45 matches
Mail list logo