I was reading about the Julia dataframe implementation yesterday,
trying to understand their decisions and how D might implement.
From my notes,
1. they are currently using a dictionary of column vectors.
2. for NA (not available) they are currently using an array of
bytes, effectively as a
On Monday, 2 November 2015 at 13:54:09 UTC, Jay Norwood wrote:
I was reading about the Julia dataframe implementation
yesterday, trying to understand their decisions and how D might
implement.
From my notes,
1. they are currently using a dictionary of column vectors.
2. for NA (not available)
On Monday, 2 November 2015 at 01:02:45 UTC, AnoHito wrote:
Hi, I am trying to write a simple interface to the MRuby Ruby
interpreter so I can use ruby scripts in my D program. I was
able to get MRuby compiled as a DLL without too much
difficulty, but the headers are very long and complicated,
On Monday, 2 November 2015 at 15:56:20 UTC, Atila Neves wrote:
Try this instead:
https://github.com/jacob-carlborg/dstep
It's been used to convert C Ruby declarations to D:
https://github.com/jacob-carlborg/orbit/tree/master/ruby
Atila
I might try it later, but I don't think the header
On Tuesday, 3 November 2015 at 06:14:14 UTC, Jonathan M Davis
wrote:
You should pretty much never use __FILE__ or __LINE__ as
template arguments unless you actually need to. The reason is
that it will end up creating a new instantiation of the
template pretty much every time that it's used,
On Monday, November 02, 2015 00:36:14 anonymous via Digitalmars-d-learn wrote:
> On 01.11.2015 23:49, Adam D. Ruppe wrote:
> > Yeah, just make the other args normal runtime instead of template:
>
> Or make it two nested templates:
>
> template show(T ...)
> {
> void show(string file =
On Tuesday, November 03, 2015 03:16:06 Andrew via Digitalmars-d-learn wrote:
> I've written a short D program that involves many lookups into a
> static array. When I make the array immutable the program runs
> faster. This must mean that immutable is more than a restriction
> on access, it must
On Tuesday, 3 November 2015 at 06:14:14 UTC, Jonathan M Davis
wrote:
You should pretty much never use __FILE__ or __LINE__ as
template arguments unless you actually need to. The reason is
that it will end up creating a new instantiation of the
template pretty much every time that it's used,
On Monday, 2 November 2015 at 20:25:44 UTC, Adam D. Ruppe wrote:
On Sunday, 1 November 2015 at 14:26:21 UTC, Nordlöw wrote:
Is there a reason why Phobos doesn't contain a lazy range
variant of std.string.replace?
Would something like map work with the predicate being
if(matches_needle)
On 11/02/2015 04:22 AM, Nordlöw wrote:
On Sunday, 1 November 2015 at 14:26:21 UTC, Nordlöw wrote:
Is there a reason why Phobos doesn't contain a lazy range variant of
std.string.replace?
Ping.
What is the use case?
The implementation doesn't seem trivial to me as it needs to maintain an
On Monday, 2 November 2015 at 19:53:09 UTC, Ali Çehreli wrote:
On 11/02/2015 04:22 AM, Nordlöw wrote:
On Sunday, 1 November 2015 at 14:26:21 UTC, Nordlöw wrote:
Is there a reason why Phobos doesn't contain a lazy range
variant of
std.string.replace?
Ping.
What is the use case?
Chaining
On Sunday, 1 November 2015 at 14:26:21 UTC, Nordlöw wrote:
Is there a reason why Phobos doesn't contain a lazy range
variant of std.string.replace?
Would something like map work with the predicate being
if(matches_needle) return replacement; else return original; ?
On Tuesday, 3 November 2015 at 01:55:27 UTC, Freddy wrote:
Is there any way I can Unionize range Types?
---
auto primeFactors(T)(T t, T div = 2)
{
if (t % div == 0)
{
return t.only.chain(primeFactors(t / div, div));
}
if (div > t)
{
return [];
}
else
On 11/02/2015 08:43 PM, steven kladitis wrote:
> import std.stdio, std.algorithm, std.array, std.traits,std.range,
> std.typecons,std.complex;
>
> enum AreSortableArrayItems(T) = isMutable!T &&
> __traits(compiles, T.init < T.init) &&
>
When I create a generator using an interface (or abstract class)
I must cast the concrete instance to the interface. Why does the
Generator not know that B is a implementation of the interface of
A?
/// Test Code
interface A {}
class B : A{}
// Fails
auto testGen1 = new Generator!A({
On Sunday, 1 November 2015 at 23:36:15 UTC, anonymous wrote:
On 01.11.2015 23:49, Adam D. Ruppe wrote:
Yeah, just make the other args normal runtime instead of
template:
Or make it two nested templates:
template show(T...)
{
void show(string file = __FILE__, uint line = __LINE__,
On Monday, 2 November 2015 at 02:30:09 UTC, AnoHito wrote:
On Monday, 2 November 2015 at 02:13:29 UTC, BBasile wrote:
On Monday, 2 November 2015 at 01:02:45 UTC, AnoHito wrote:
[...]
the headers are very long and complicated, and porting them
entirely to D would be a huge project in and of
On Saturday, 31 October 2015 at 16:06:47 UTC, Russel Winder wrote:
On Sat, 2015-10-31 at 15:41 +, tcak via Digitalmars-d-learn
wrote:
On Saturday, 31 October 2015 at 14:37:23 UTC, rumbu wrote:
> On Friday, 30 October 2015 at 10:35:03 UTC, Laeeth Isharc
> wrote:
> > I'm writing a talk for
On Sunday, 1 November 2015 at 09:07:56 UTC, Ilya Yaroshenko wrote:
On Friday, 30 October 2015 at 10:35:03 UTC, Laeeth Isharc wrote:
Any other thoughts?
Floating point operations can be extended automatically
(without some kind of 'fastmath' flag) up to 80bit fp on 32 bit
intel processors.
On Sunday, 1 November 2015 at 20:38:44 UTC, Freddy wrote:
On Friday, 30 October 2015 at 10:35:03 UTC, Laeeth Isharc wrote:
I'm writing a talk for codemesh on the use of D in finance.
I want to start by addressing the good reasons not to use D.
(We all know what the bad ones are). I don't
On Saturday, 31 October 2015 at 05:25:06 UTC, ref2401 wrote:
On Friday, 30 October 2015 at 10:35:03 UTC, Laeeth Isharc wrote:
I'm writing a talk for codemesh on the use of D in finance.
I want to start by addressing the good reasons not to use D.
(We all know what the bad ones are). I don't
On Monday, 2 November 2015 at 15:33:34 UTC, Laeeth Isharc wrote:
Hi Jay.
That may have been me. I have implemented something very
basic, but you can read and write my proto dataframe to/from
CSV and HDF5. The code is up here:
https://github.com/Laeeth/d_dataframes
yes, thanks. I
On Monday, 2 November 2015 at 09:02:28 UTC, Gary Willoughby wrote:
On Monday, 2 November 2015 at 08:23:16 UTC, Nordlöw wrote:
I need `T` to be an alias in order for .stringof to work.
typeof(T).stringof
No, I want the variable name from the calling scope.
This works for a single argument.
On Monday, 2 November 2015 at 09:16:09 UTC, Nordlöw wrote:
On Monday, 2 November 2015 at 09:02:28 UTC, Gary Willoughby
wrote:
On Monday, 2 November 2015 at 08:23:16 UTC, Nordlöw wrote:
I need `T` to be an alias in order for .stringof to work.
typeof(T).stringof
No, I want the variable name
Well, I use Ubuntu 14.04 and I have managed to get qt5.5 at my
/opt/qt55 since the default(usr/lib) directory is occupied by
qt4. Since DOtherSide looks for qt5 from usr/lib, how do I change
it to now point to /opt/qt55?
This is the setup in /opt/qt55
karabuta@mx:/opt/qt55$ ls
bin
On Monday, 2 November 2015 at 09:54:50 UTC, John Colvin wrote:
Why can't I make Args a sequence of aliases?
Works for me on multiple compilers. To be precise, this worked:
Except it prints Arg instead of x, try:
debug write(Args[i].stringof, " is ", Arg);
On Monday, 2 November 2015 at 08:23:16 UTC, Nordlöw wrote:
I need `T` to be an alias in order for .stringof to work.
typeof(T).stringof
On 11/02/2015 03:56 PM, Freddy wrote:
Is there a version of http://dlang.org/phobos/std_range.html#.generate
with state.
generate() already allows "callables", which can be a delegate:
import std.stdio;
import std.range;
struct S {
int i;
int fun() {
return i++;
}
}
Is there a version of
http://dlang.org/phobos/std_range.html#.generate with state.
On Monday, 2 November 2015 at 09:54:50 UTC, John Colvin wrote:
Works for me on multiple compilers. To be precise, this worked:
template show(Args...)
{
void show(string file = __FILE__, uint line = __LINE__,
string fun = __FUNCTION__)()
{
import std.stdio: write, writeln;
On Monday, 2 November 2015 at 11:44:45 UTC, Daniel N wrote:
On Monday, 2 November 2015 at 11:36:27 UTC, Nordlöw wrote:
I want it to print the name of Arg in the closing as
x is 11
See my previous comment:
Arg -> Args[i].stringof
Ahh! Great! Thx!
On Monday, 2 November 2015 at 11:36:27 UTC, Nordlöw wrote:
I want it to print the name of Arg in the closing as
x is 11
See my previous comment:
Arg -> Args[i].stringof
On Tuesday, 3 November 2015 at 00:08:54 UTC, Ali Çehreli wrote:
generate() already allows "callables", which can be a delegate:
import std.stdio;
import std.range;
struct S {
int i;
int fun() {
return i++;
}
}
void main() {
auto s = S(42);
writefln("%(%s %)",
Okay, I finally got it working. The problem was that mrb_value
needed to be fully defined in order for my code to work, because
it was being passed on the stack directly instead of by a pointer:
struct mrb_value
{
union
{
mrb_float f;
void* p;
On Tuesday, 3 November 2015 at 03:16:07 UTC, Andrew wrote:
I've written a short D program that involves many lookups into
a static array. When I make the array immutable the program
runs faster. This must mean that immutable is more than a
restriction on access, it must affect the compiler
On 11/02/2015 04:51 PM, Freddy wrote:
> On Tuesday, 3 November 2015 at 00:08:54 UTC, Ali Çehreli wrote:
>> generate() already allows "callables", which can be a delegate:
>>
>> import std.stdio;
>> import std.range;
>>
>> struct S {
>> int i;
>>
>> int fun() {
>> return i++;
>>
On Tuesday, 3 November 2015 at 01:55:27 UTC, Freddy wrote:
Is there any way I can Unionize range Types?
---
auto primeFactors(T)(T t, T div = 2)
{
if (t % div == 0)
{
return t.only.chain(primeFactors(t / div, div));
}
if (div > t)
{
return [];
}
else
import std.stdio, std.algorithm, std.array, std.traits,std.range,
std.typecons,std.complex;
enum AreSortableArrayItems(T) = isMutable!T &&
__traits(compiles, T.init <
T.init) &&
!isNarrowString!(T[]);
void selectionSort(T)(T[]
On Sunday, 1 November 2015 at 14:26:21 UTC, Nordlöw wrote:
Is there a reason why Phobos doesn't contain a lazy range
variant of std.string.replace?
Ping.
Is there any way I can Unionize range Types?
---
auto primeFactors(T)(T t, T div = 2)
{
if (t % div == 0)
{
return t.only.chain(primeFactors(t / div, div));
}
if (div > t)
{
return [];
}
else
{
return primeFactors(t, div + 1);
}
}
---
I've written a short D program that involves many lookups into a
static array. When I make the array immutable the program runs
faster. This must mean that immutable is more than a restriction
on access, it must affect the compiler output. But why and how?
Thanks
Andrew
41 matches
Mail list logo