On 2015-04-18 20:20, Darrell Gallion wrote:
Thought there were other complications on Windows for 64bit?
I don't know, I never used it.
--
/Jacob Carlborg
On 2015-04-19 10:56, Jacob Carlborg wrote:
The makefile isn't updated, see [1]. Trying adding
"STABLE_DMD_VER=2.067.0" to the command you're running.
Pull request: https://github.com/D-Programming-Language/dlang.org/pull/968
--
/Jacob Carlborg
On 2015-04-19 10:56, Jacob Carlborg wrote:
The makefile isn't updated, see [1]. Trying adding
"STABLE_DMD_VER=2.067.0" to the command you're running.
That won't work because someone thought it was a good idea to split the
download site per year :( . Try overr
ot; to the command you're running.
[1]
https://github.com/D-Programming-Language/dlang.org/blob/master/posix.mak#L29-L31
--
/Jacob Carlborg
On 2015-04-17 21:35, Jacob Carlborg wrote:
UDA's were available when these attributes/keywords were created.
Reasons why they're still not UDA's are probably a mix of avoiding code
breakage and someone that needs to make the change.
Were _not_ available ...
--
/Jacob Carlborg
y're still not UDA's are probably a mix of avoiding code
breakage and someone that needs to make the change.
--
/Jacob Carlborg
sword.
ftp://digitalmars.com/coffimplib.zip
If you compile as 64bit or with the -m32mscoff flag the compiler will
output object files in the COFF format.
--
/Jacob Carlborg
On Linux that is
GCC, on OS X it's Clang/GCC, on Windows it's either DMC or VS depending
on what object format is used, I guess.
DMC is not even available for any other platform than Windows.
--
/Jacob Carlborg
incompatible because
rely on different compiler built-ins.
The title says (Linux), where DMD uses GCC and not DMC.
--
/Jacob Carlborg
ny new attributes, not as keywords but as
compiler recognized UDA's. Then it's possible to use the fully qualified
name of the UDA to disambiguate.
--
/Jacob Carlborg
luded from the cpl_progress.h file.
--
/Jacob Carlborg
if( GDALGetGeoTransform( hDataset, adfGeoTransform.ptr ) == CE_None )
{
}
}
--
/Jacob Carlborg
ubles. Static arrays are stack allocated and passed by value, the
function expects an array which is passed by reference. Try adding
".ptr" to "adfGeoTransform" in the call to GDALGetGeoTransform.
[1] http://dlang.org/arrays.html#static-arrays
--
/Jacob Carlborg
e.com/library/mac/documentation/Cocoa/Reference/ObjCRuntimeRef/index.html
[2] https://github.com/D-Programming-Language/dmd/pull/4321
--
/Jacob Carlborg
iversal binary containing both the 32 and 64bit version. All
system libraries on OS X are universal binaries, so cross-compiling is
usually no problem.
--
/Jacob Carlborg
your favorite languages I can recommend DWT [1], a
port of SWT to D. It works for Windows and Linux, a port of OS X is
being worked on.
[1] https://github.com/d-widget-toolkit/dwt
--
/Jacob Carlborg
the case with
symbols that are actually deprecated.
Thank you for the explanation.
--
/Jacob Carlborg
t get around to moving it
along when I was supposed to or because someone else deprecated it and
didn't mark it the way that I normally mark them, in which case, I sometimes
miss those.
Ok, thanks.
--
/Jacob Carlborg
Is the deprecation process used for Phobos and druntime code documented
somewhere? I.e. how long after a deprecation is a symbols removed and so on.
--
/Jacob Carlborg
s would be ideal, thanks.
You can either:
1. Convert an up to date user32.lib to OMF
2. Create your own user32.lib from the DLL
3. Compile using the COFF format and use the Visual Studio runtime
instead. This has been recently added (I'm not sure if it's released
yet) and requires using a flag
--
/Jacob Carlborg
king about runtime because I want the
same binary to run on all windows versions so I have to support both and
determine which one I am running on at runtime.
Use the regular system API's as you would in C. Should be easy to find
if you search the web.
--
/Jacob Carlborg
dub use the dynamic version of phobos.
I'm not sure how Dub builds vibe.d but if a shared library is present
isn't that usually preferred to static libraries?
--
/Jacob Carlborg
lease via Dub.
--
/Jacob Carlborg
t know anything about threads created outside
of D, unless you explicitly register them with the runtime.
--
/Jacob Carlborg
uts "calling foo bar"
end
end
Bar.new.send("foo bar") # calls the method "foo bar"
CoffeeScript:
class Foo
bar: ->
console.log "bar"
a = { class: "foo" }
console.log a.class # prints "foo"
--
/Jacob Carlborg
MachineMixin (T)
{
private StateMachine!T _stateMachine;
// other code that need access to _stateMachine
}
class MainMenu : Scene
{
mixin StateMachineMixin!(typeof(this));
}
--
/Jacob Carlborg
I'm guessing you like to avoid that if possible.
--
/Jacob Carlborg
ve any dependencies except for system libraries.
[1] https://github.com/d-widget-toolkit/dwt
--
/Jacob Carlborg
i does not get imported and
you get lot of different issues from missing declarations.
So it just picks the first filename matching "object" and doesn't care
about its module name.
--
/Jacob Carlborg
ng dmd to get the dependencies. But the module
system should still prevent it. It seems like the compiler uses the
filename instead of the declared module name as the module name.
--
/Jacob Carlborg
On 06/10/14 19:48, H. S. Teoh via Digitalmars-d-learn wrote:
This looks wrong to me. Are you sure this finds *all* possible
graphemes?
No, the data I gave was to detect a complete code unit. Graphemes are
something else, I think Uranuz is mixing up the Unicode terms.
--
/Jacob Carlborg
new sequence started?
Have a look here [1]. For example, if you have a byte that is between
U+0080 and U+07FF you know that you need two bytes to get that whole
code point.
[1] http://en.wikipedia.org/wiki/UTF-8#Description
--
/Jacob Carlborg
If you have OS X, you can use Instruments that comes installed with Xcode.
--
/Jacob Carlborg
On 2014-09-30 22:19, anonymous wrote:
import std.typetuple: staticMap;
enum stringOf(alias thing) = thing.stringof;
It's better to use __traits(identifier) instead of .stringof.
--
/Jacob Carlborg
On 2014-09-26 21:52, John Colvin wrote:
Yes, but it depends on the complexity of the headers. C++ templates
aren't supported for example.
Templates are supported, if they're already instantiated.
--
/Jacob Carlborg
s has nothing to do
with Object.factory.
--
/Jacob Carlborg
lly only
working on Linux.
--
/Jacob Carlborg
support for COFF in 32bit. I don't think this has been released yet, but
it's available in git master.
--
/Jacob Carlborg
, throw an exception instead.
--
/Jacob Carlborg
es in DVM [3]
[1] https://github.com/SiegeLord/Tango-D2
[2] http://siegelord.github.io/Tango-D2/tango.net.http.HttpGet.html
[3]
https://github.com/jacob-carlborg/dvm/blob/master/dvm/commands/Fetch.d#L80
--
/Jacob Carlborg
On 04/09/14 22:30, Kagamin wrote:
emplace calls constructor, and constructor can't be realistically
required to be nogc. It depends on the constructor. Similar for destroy.
But if the constructor is @nogc or if there's a default constructor.
--
/Jacob Carlborg
github.com/D-Programming-Language/dmd/commit/840d88a6e539e9817cffdc4abe8ad6357897d54a
--
/Jacob Carlborg
On 27/08/14 23:48, jicman wrote:
On Wednesday, 27 August 2014 at 06:20:24 UTC, Jacob Carlborg
wrote:
On 23/08/14 19:50, jicman wrote:
This is line 7634:
const Size DEFAULT_SCALE = { 5, 13 };
What does the error say and how can I fix it? Thanks.
Does the following make any difference
it, I think. It's declared in "drawing.d". Well, at least I
found one declared there. But that's not a union, it's a struct. I don't
understand why it complains about a struct.
--
/Jacob Carlborg
On 23/08/14 19:50, jicman wrote:
This is line 7634:
const Size DEFAULT_SCALE = { 5, 13 };
What does the error say and how can I fix it? Thanks.
Does the following make any difference?
const Size DEFAULT_SCAL = Size(5, 13)
--
/Jacob Carlborg
On 26/08/14 00:57, jicman wrote:
Ok, let's try something simpler... Where can I find the D1 v1.076
compiler error meaning of,
Error: duplicate union initialization for size
for this line,
const Size DEFAULT_SCALE = { 5, 13 };
How does the code for Size look like?
--
/Jacob Carlborg
code for these functions so I don't know if there's anything stopping
them from begin @nogc.
--
/Jacob Carlborg
re a way to get around this?
@nogc is a very new attribute. The runtime and standard library have not
been properly annotated with this attribute yet.
As a workaround you could try copy implementation of these functions to
you're own code and annotate them as appropriate.
--
/Jacob Carlborg
running in 32 vs 64 bits?
Use "D_LP64". This indicates pointers are 64 bits.
--
/Jacob Carlborg
On 2014-08-07 20:23, "Nordlöw" wrote:
What is the best way to forward a string[] as argument to a function
called through std.concurrency.spawn().
What about just accessing core.runtime.Runtime.args from the new thread?
--
/Jacob Carlborg
cally allocated.
--
/Jacob Carlborg
the module boundary. I'd guess that's
because of the separate compilation model.
That seems to be the case. I just got confused about the different
behavior when put in a single or two modules.
--
/Jacob Carlborg
able data. I'm sure there's
something in the spec about it...
Sounds reasonable.
--
/Jacob Carlborg
quot;.
But if I move the function "asd" into the "main" module and completely
skip the "foo" module the assert passes.
I don't know if I'm thinking completely wrong here but this seems like a
bug to me.
--
/Jacob Carlborg
On 2014-06-29 22:28, Evan Davis wrote:
I have no idea how this error exists. Can anyone help me fix it?
Perhaps some mismatch between mutable/const/immutable?
--
/Jacob Carlborg
d try some different value. If you
search on Google I'm sure you'll find something.
--
/Jacob Carlborg
quot; link flag to suppress the console.
There are API's to get access to the arguments passed to WinMain, if
necessary.
--
/Jacob Carlborg
works for Windows but you can
have a look at the code [1], or perhaps Nick can explain it.
[1] https://github.com/jacob-carlborg/dvm/blob/master/dvm/commands/Use.d#L34
--
/Jacob Carlborg
lower than the eager ones.
--
/Jacob Carlborg
e [2] to help with
this sort of things.
[1] http://dsource.org/projects/tango
[2] http://dsource.org/projects/tango/docs/stable/tango.io.UnicodeFile.html
--
/Jacob Carlborg
On 10/06/14 16:06, bearophile wrote:
You can define a enum boolean value in the version unittest block, and
another inside the debug {} else {}. And then you can use "if (b1 || b2)
{ ... }".
"static if" is probably what's needed.
--
/Jacob Carlborg
f the array.
--
/Jacob Carlborg
) ); //
error
}
Have a look at this thread:
http://forum.dlang.org/thread/lkl0lp$204h$1...@digitalmars.com
--
/Jacob Carlborg
On 16/05/14 11:19, John Colvin wrote:
Any plans to get any preprocessor stuff working? Presumably libclang can
make this feasible.
Yes, eventually. Although, currently libclang doesn't really provide an
API for the preprocessor, so that needs to be added.
--
/Jacob Carlborg
it.getvalue); // will print 5 at compile time
return myfruit.getvalue();
}
Although, I don't know if it will allocate it during runtime as well.
--
/Jacob Carlborg
o the best
method.
You can use DStep [1] to automatically generate bindings. It requires
some manual tweaking afterwards but it will give you a good start.
[1] https://github.com/jacob-carlborg/dstep
--
/Jacob Carlborg
supports more features.
--
/Jacob Carlborg
is capable to do. I
know that at least in DWT, many widgets contain quite a lot of code to
customize them, to make them behave similarly on all platforms.
--
/Jacob Carlborg
On 13/05/14 06:32, InfinityPlusB wrote:
yup, that will work.
If I wasn't hell bent on naming variables, I probably would have figured
this out. :P
Perhaps you could use an associative array. Then you get sort of named
variables.
--
/Jacob Carlborg
features, I'm guessing
it's not as comprehensive as DWT, Gtk or Qt.
--
/Jacob Carlborg
when I instantiated it with
"wchar" it didn't compile.
--
/Jacob Carlborg
an turn it into a function by doing:
void foo (alias func) ()
{
alias Types = ParameterTypeTuple!(func!int);
}
Unfortunately I don't know the types it's going to be instantiated with.
That's part of the introspecting to figure out.
[1] https://github.com/D-Programming-Language
g hacks like .stringof. I know there's __parameters as
well, but that doesn't work either.
--
/Jacob Carlborg
7;t consider it stable, but it will automatically generate the
help text. You can see some of it's uses here [3].
[1] https://github.com/SiegeLord/Tango-D2
[2] https://github.com/jacob-carlborg/mambo/tree/master/mambo/arguments
[3]
https://github.com/jacob-carlborg/dstep/blob/master/dstep/driver/Application.d#L53
--
/Jacob Carlborg
I think so.
If you're on a 32bit machine you probably need to install a development
package. Perhaps libcurl4-gnutls-dev or libcurl4-openssl-dev.
--
/Jacob Carlborg
the
GC's view
// --> GC collects here <--
printf(b); // the string may have been collected here
}
Of course, if the C function is storing the parameter in a global
variable you got problems. You really need to be sure of what the C
functions is doing. To be on the safe side there's always GC.addRoot.
--
/Jacob Carlborg
amiliar with calling conventions and how the stack and
registers work. But take this as an example:
extern (C) void foo (in char*);
void bar ()
{
string s = "asd";
foo(s.ptr);
}
Even if "s" is passed in a register to "foo", won't the stack of "bar"
still be available until "foo" returns?
--
/Jacob Carlborg
t:
extern(C) auto example()
Same as above, extern(C) does not change how memory is collected. If it
is a C function, then it depends entirely on that particular function.
--
/Jacob Carlborg
Dub, which will handle all dependencies automatically.
--
/Jacob Carlborg
e. You can also use DStep [2] to create D
bindings for the C code.
[1] http://forum.dlang.org/thread/lgspgg$2i8l$1...@digitalmars.com
[2] https://github.com/jacob-carlborg/dstep
--
/Jacob Carlborg
On Tuesday, 18 March 2014 at 07:19:05 UTC, Jacob Carlborg wrote:
What exact problems do you have?
Note that SWT is not thread safe. All UI changes need to be
made on the UI thread. This is usually done using the
"Display.asyncExec" method.
Forgot the link to the exa
thread. This is usually done using the
"Display.asyncExec" method.
--
/Jacob Carlborg
veloper.apple.com/library/mac/documentation/Cocoa/Reference/ObjCRuntimeRef/Reference/reference.html
[2] http://www.dsource.org/projects/dstep
[3] http://wiki.dlang.org/DIP43
[4] https://github.com/jacob-carlborg/dmd/tree/d-objc
--
/Jacob Carlborg
ic", "semantic2" and "semantic3". For more information see:
http://wiki.dlang.org/DMD_Source_Guide
--
/Jacob Carlborg
"mytool: ERROR: ...".
Perhaps you can do something with core.runtime.Runtime.traceHandler.
--
/Jacob Carlborg
ut it would be nice to at
least see which modules and declarations are available.
--
/Jacob Carlborg
On 2014-01-24 07:11, Uplink_Coder wrote:
I'm trying to serialize my struct through CT-Refelction
Here's a serialization library if you need it [1]. It will hopefully be
included as std.serialization in Phobos at some point.
https://github.com/jacob-carlborg/orange
--
/Jacob Carlborg
d be
"Blue" or "Red".
I can use __traits(allMembers,Enum)
for the identifiers, but how do I get the Values ?
Try getMember: http://dlang.org/traits.html#getMember
--
/Jacob Carlborg
reliable enough.
--
/Jacob Carlborg
ty do anything in terms of speed/safety here?
It can access global variables.
--
/Jacob Carlborg
On 2014-01-17 22:14, H. S. Teoh wrote:
Is that because D doesn't have implicit casting via opCast? -- because,
conceivably, if
x = d.abc;
gets lowered to
x = d.opCast!(typeof(x))(d.abc);
then the above can be made to work.
I don't know, maybe.
t work. Variant doesn't retain the static type, which is needed
in this case.
--
/Jacob Carlborg
On 2014-01-17 15:29, Andrea Fontana wrote:
I think it would be useful to put full path on __FILE__ or to add
another constant. Anyone?
I agree. Probably safest to add a new constant, to avoid breaking code.
--
/Jacob Carlborg
On 2014-01-17 10:50, Andrea Fontana wrote:
Hmm I thought It can be done reading __FILE__ at compile-time, but it
gives me just the relative path.
Right, forgot about __FILE__.
--
/Jacob Carlborg
to have the path of source itself?
That doesn't sound very easy to fix. When running the executable it's
completely disconnected from the source file it was compiled from.
Except for possibly some debug info.
--
/Jacob Carlborg
e? All done dynamically without any property
being pre-declared.
I have no way of seeing this work. The problem is you need to somehow
store the static type revived in opDispatch. But to store an unknown
type as an instance variable you need to use a template class.
--
/Jacob Carlborg
t the static
type. But perhaps that's what you're saying.
--
/Jacob Carlborg
need to rename
the file. As far as I know, Linux doesn't have any form of system attribute.
[1]
https://github.com/D-Programming-Language/phobos/commit/5ab8dae665c27ed45eced244720e23e53ef23457
--
/Jacob Carlborg
node class, so maybe that is the better option.
The Tango XML parser is one of the fastest XML parser available:
http://dotnot.org/blog/archives/2008/03/10/xml-benchmarks-updated-graphs-with-rapidxml/
--
/Jacob Carlborg
that a
specific element (like "svg") should use a specific subclass, but
"mapping" after building is ok too I suppose.
I'm not sure what you're trying to do but the implementation in Tango
uses structs for the nodes so you cannot subclass that.
--
/Jacob Carlborg
601 - 700 of 1682 matches
Mail list logo