Build your own Trie entry table

2016-12-26 Thread Remi Thebault via Digitalmars-d-learn
Hello I want to map a dchar to its Bidi_Class. I've built an utility that reads UnicodeData.txt into an AA and builds a trie with std.uni.codepointTrie from it. I use Trie.store() to export the trie entry table into a D module. (I believe in a similar manner than phobos' unicode_tables.d) N

[question] Access from UDA constructor to parent symbol

2016-12-26 Thread crimaniak via Digitalmars-d-learn
``` class uda { this() { // I want to see Foo here and use it's reflection to iterate fields and methods. } } @uda struct Foo { } ``` Is there a way to do it?

Re: [question] Access from UDA constructor to parent symbol

2016-12-26 Thread Adam D. Ruppe via Digitalmars-d-learn
On Monday, 26 December 2016 at 20:07:56 UTC, crimaniak wrote: // I want to see Foo here and use it's reflection to iterate fields and methods. then pass foo to it What do you mean parent symbol? I assumed you mean subclass but your example shows one class and one struct. So is it

Re: Is there anything other than nullable to work with optional types?

2016-12-26 Thread aliak via Digitalmars-d-learn
On Monday, 26 December 2016 at 04:55:30 UTC, Seb wrote: Then help to push it forward!! There are many ways: - review the PR and point out anything problematic you see (lack of reviews/interest is a main reason why PRs get stalled) - post reasons and arguments for merging this PR (seems like yo

Re: [question] Access from UDA constructor to parent symbol

2016-12-26 Thread crimaniak via Digitalmars-d-learn
On Monday, 26 December 2016 at 21:15:03 UTC, Adam D. Ruppe wrote: On Monday, 26 December 2016 at 20:07:56 UTC, crimaniak wrote: // I want to see Foo here and use it's reflection to iterate fields and methods. then pass foo to it What do you mean parent symbol? I assumed you mean

Re: [question] Access from UDA constructor to parent symbol

2016-12-26 Thread Ali Çehreli via Digitalmars-d-learn
On 12/26/2016 02:04 PM, crimaniak wrote: So my main question: how it is possible to do such thing? Just to make sure we're on the same page: :) * There is 'interface' in addition to 'class' * If all you want is to check, then you can write template constraints by following the example of st