New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

REST enhancement #1: Allow one to get parameters from headers #908

Merged
merged 12 commits into from Dec 11, 2014

Conversation

Projects
None yet
4 participants
@Geod24
Contributor

Geod24 commented Dec 1, 2014

As the title say, I reopen #867 here.
I accidentally deleted my (remote) branch, and Github won't let me re-open the P.R.

I re-pushed original code to #867 . This one is rebased (because of #871 ).

The only change from #867 is that I renamed @fromHeader to @headerParam.
I can revert that if needed, but I think we have 2 advantages here:

Pinging @Dicebot .

Handle @headerParam client-side
- Add a string[string] headers__ local variable to the generated function;
- If there's one and only one WebParamAttribute with the name of the parameter we're currently processing (as parameter gets processed in order), we add it to the AA, the key being the 'field' in WebParamAttribute;
- headers__ gets later passed to request() which will add all it's field to the headers;
@Geod24

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 2, 2014

Contributor

For the record, my unittests are here:
https://github.com/Geod24/vibe.d/tree/rest-unittests

(under tests/rest/parameter/)

Not complete yet though. And I got a cryptic linker failure when running dub test (DMD 2.066, SEGV with GDC 4.9...).

/usr/include/dlang/dmd/std/array.d:62: error: undefined reference to '_D3std9algorithm463__T12FilterResultS4364vibe3web4rest109__T21registerRestInterfaceTC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigZ21registerRestInterfaceFC4vibe4http6router9URLRouterC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigC4vibe3web4rest21RestInterfaceSettingsZ8addRouteMFE4vibe4http6common10HTTPMethodAyaDFC4vibe4http6server17HTTPServerRequestC4vibe4http6server18HTTPServerResponseZvAAyaZ9__lambda5TAAyaZ12FilterResult7opSliceMFNaNbNiNfZS3std9algorithm463__T12FilterResultS4364vibe3web4rest109__T21registerRestInterfaceTC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigZ21registerRestInterfaceFC4vibe4http6router9URLRouterC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigC4vibe3web4rest21RestInterfaceSettingsZ8addRouteMFE4vibe4http6common10HTTPMethodAyaDFC4vibe4http6server17HTTPServerRequestC4vibe4http6server18HTTPServerResponseZvAAyaZ9__lambda5TAAyaZ12FilterResult'
/usr/include/dlang/dmd/std/array.d:62: error: undefined reference to '_D3std9algorithm463__T12FilterResultS4364vibe3web4rest109__T21registerRestInterfaceTC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigZ21registerRestInterfaceFC4vibe4http6router9URLRouterC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigC4vibe3web4rest21RestInterfaceSettingsZ8addRouteMFE4vibe4http6common10HTTPMethodAyaDFC4vibe4http6server17HTTPServerRequestC4vibe4http6server18HTTPServerResponseZvAAyaZ9__lambda5TAAyaZ12FilterResult5emptyMFNaNbNdNiNfZb'
/usr/include/dlang/dmd/std/array.d:62: error: undefined reference to '_D3std9algorithm463__T12FilterResultS4364vibe3web4rest109__T21registerRestInterfaceTC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigZ21registerRestInterfaceFC4vibe4http6router9URLRouterC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigC4vibe3web4rest21RestInterfaceSettingsZ8addRouteMFE4vibe4http6common10HTTPMethodAyaDFC4vibe4http6server17HTTPServerRequestC4vibe4http6server18HTTPServerResponseZvAAyaZ9__lambda5TAAyaZ12FilterResult5frontMFNaNbNcNdNiNfZAya'
/usr/include/dlang/dmd/std/array.d:62: error: undefined reference to '_D3std9algorithm463__T12FilterResultS4364vibe3web4rest109__T21registerRestInterfaceTC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigZ21registerRestInterfaceFC4vibe4http6router9URLRouterC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigC4vibe3web4rest21RestInterfaceSettingsZ8addRouteMFE4vibe4http6common10HTTPMethodAyaDFC4vibe4http6server17HTTPServerRequestC4vibe4http6server18HTTPServerResponseZvAAyaZ9__lambda5TAAyaZ12FilterResult8popFrontMFNaNbNiNfZv'
collect2: error: ld returned 1 exit status

Will check what's going on.

EDIT 437: Sooooooo, Vibe.d doesn't compile with DMD master. Will work on it.

Contributor

Geod24 commented Dec 2, 2014

For the record, my unittests are here:
https://github.com/Geod24/vibe.d/tree/rest-unittests

(under tests/rest/parameter/)

Not complete yet though. And I got a cryptic linker failure when running dub test (DMD 2.066, SEGV with GDC 4.9...).

/usr/include/dlang/dmd/std/array.d:62: error: undefined reference to '_D3std9algorithm463__T12FilterResultS4364vibe3web4rest109__T21registerRestInterfaceTC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigZ21registerRestInterfaceFC4vibe4http6router9URLRouterC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigC4vibe3web4rest21RestInterfaceSettingsZ8addRouteMFE4vibe4http6common10HTTPMethodAyaDFC4vibe4http6server17HTTPServerRequestC4vibe4http6server18HTTPServerResponseZvAAyaZ9__lambda5TAAyaZ12FilterResult7opSliceMFNaNbNiNfZS3std9algorithm463__T12FilterResultS4364vibe3web4rest109__T21registerRestInterfaceTC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigZ21registerRestInterfaceFC4vibe4http6router9URLRouterC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigC4vibe3web4rest21RestInterfaceSettingsZ8addRouteMFE4vibe4http6common10HTTPMethodAyaDFC4vibe4http6server17HTTPServerRequestC4vibe4http6server18HTTPServerResponseZvAAyaZ9__lambda5TAAyaZ12FilterResult'
/usr/include/dlang/dmd/std/array.d:62: error: undefined reference to '_D3std9algorithm463__T12FilterResultS4364vibe3web4rest109__T21registerRestInterfaceTC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigZ21registerRestInterfaceFC4vibe4http6router9URLRouterC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigC4vibe3web4rest21RestInterfaceSettingsZ8addRouteMFE4vibe4http6common10HTTPMethodAyaDFC4vibe4http6server17HTTPServerRequestC4vibe4http6server18HTTPServerResponseZvAAyaZ9__lambda5TAAyaZ12FilterResult5emptyMFNaNbNdNiNfZb'
/usr/include/dlang/dmd/std/array.d:62: error: undefined reference to '_D3std9algorithm463__T12FilterResultS4364vibe3web4rest109__T21registerRestInterfaceTC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigZ21registerRestInterfaceFC4vibe4http6router9URLRouterC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigC4vibe3web4rest21RestInterfaceSettingsZ8addRouteMFE4vibe4http6common10HTTPMethodAyaDFC4vibe4http6server17HTTPServerRequestC4vibe4http6server18HTTPServerResponseZvAAyaZ9__lambda5TAAyaZ12FilterResult5frontMFNaNbNcNdNiNfZAya'
/usr/include/dlang/dmd/std/array.d:62: error: undefined reference to '_D3std9algorithm463__T12FilterResultS4364vibe3web4rest109__T21registerRestInterfaceTC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigZ21registerRestInterfaceFC4vibe4http6router9URLRouterC5tests4rest10parameters6source3app16__unittestL167_2FZ24TestHeaderParamMisconfigC4vibe3web4rest21RestInterfaceSettingsZ8addRouteMFE4vibe4http6common10HTTPMethodAyaDFC4vibe4http6server17HTTPServerRequestC4vibe4http6server18HTTPServerResponseZvAAyaZ9__lambda5TAAyaZ12FilterResult8popFrontMFNaNbNiNfZv'
collect2: error: ld returned 1 exit status

Will check what's going on.

EDIT 437: Sooooooo, Vibe.d doesn't compile with DMD master. Will work on it.

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 2, 2014

Contributor

Re-reading (because I have forgotten everything, doh)

Contributor

mihails-strasuns commented Dec 2, 2014

Re-reading (because I have forgotten everything, doh)

@Geod24

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 5, 2014

Contributor

@Dicebot : Was the code that bad ? ;-)

Contributor

Geod24 commented Dec 5, 2014

@Dicebot : Was the code that bad ? ;-)

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 5, 2014

Contributor

No, sorry, I have read it through once to actually remember what we are speaking about and now I need time to actually do line-by-line implementation review. Hopefully this weekend.

Contributor

mihails-strasuns commented Dec 5, 2014

No, sorry, I have read it through once to actually remember what we are speaking about and now I need time to actually do line-by-line implementation review. Hopefully this weekend.

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

wrong indentation

wrong indentation

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

What global import is needed for?

What global import is needed for?

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 6, 2014

Owner

Because everything in this module needs it (Both version of findNextUDA and UDATuple as well).

Owner

Geod24 replied Dec 6, 2014

Because everything in this module needs it (Both version of findNextUDA and UDATuple as well).

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

General rule is to try move imports as locally as possible unless those are needed in stuff like template constraints. Especially important for templates as makes imports effectively lazy.

mihails-strasuns replied Dec 6, 2014

General rule is to try move imports as locally as possible unless those are needed in stuff like template constraints. Especially important for templates as makes imports effectively lazy.

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

(and at least UDATuple does import it locally alread)

mihails-strasuns replied Dec 6, 2014

(and at least UDATuple does import it locally alread)

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

What was the reason for moving this out of utility that generates it?

What was the reason for moving this out of utility that generates it?

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

(I also now see that it could have used outer scope alias argument instead of defining own in that case)

mihails-strasuns replied Dec 6, 2014

(I also now see that it could have used outer scope alias argument instead of defining own in that case)

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 6, 2014

Owner

Reduce template instantiation.

Owner

Geod24 replied Dec 6, 2014

Reduce template instantiation.

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 7, 2014

I had a quick look at how many different symbols have identical UDA values and looks like it is a valid concern. Nevermind.

mihails-strasuns replied Dec 7, 2014

I had a quick look at how many different symbols have identical UDA values and looks like it is a valid concern. Nevermind.

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

while this works too I prefer to always use alias with TypeTuple as it isn't actually a value

while this works too I prefer to always use alias with TypeTuple as it isn't actually a value

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

I wonder if removing idx / Symbol argument and accepting UDA tuple slice instead would be more idiomatic - is this ever supposed to be used directly outside of vibe.internal.meta package?

I wonder if removing idx / Symbol argument and accepting UDA tuple slice instead would be more idiomatic - is this ever supposed to be used directly outside of vibe.internal.meta package?

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 6, 2014

Owner

It could and I originally intended to do so. I just couldn't find any code that was using multiple UDA of the same type.

Owner

Geod24 replied Dec 6, 2014

It could and I originally intended to do so. I just couldn't find any code that was using multiple UDA of the same type.

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 7, 2014

I am not sure I understand.

couldn't find any code that was using multiple UDA of the same type

This was a reason why findNextUDA was not present at all originally. How does it impact specific API used once it actually got introduced?

mihails-strasuns replied Dec 7, 2014

I am not sure I understand.

couldn't find any code that was using multiple UDA of the same type

This was a reason why findNextUDA was not present at all originally. How does it impact specific API used once it actually got introduced?

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 7, 2014

Owner

Oops, my response refered to the later part of your comment: it could be used outside of vibe.d, but I think most people would be looking for findNextUDA. I would prefer to wait how we can use UDATuple internally before redefining findNextUDA in term of it.

Owner

Geod24 replied Dec 7, 2014

Oops, my response refered to the later part of your comment: it could be used outside of vibe.d, but I think most people would be looking for findNextUDA. I would prefer to wait how we can use UDATuple internally before redefining findNextUDA in term of it.

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 7, 2014

kk, fine by me

mihails-strasuns replied Dec 7, 2014

kk, fine by me

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

better to protect such symbol with version(none), lack of documentation is not reliable enough

mihails-strasuns commented on source/vibe/web/common.d in 797afca Dec 6, 2014

better to protect such symbol with version(none), lack of documentation is not reliable enough

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 6, 2014

Owner

Old comment, I made them private afterwards, but version(none) is even better.

Owner

Geod24 replied Dec 6, 2014

Old comment, I made them private afterwards, but version(none) is even better.

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

please link the bugzilla issue from here too

mihails-strasuns commented on source/vibe/web/rest.d in d0d42c0 Dec 6, 2014

please link the bugzilla issue from here too

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

same here, enum -> alias

mihails-strasuns commented on source/vibe/web/rest.d in d0d42c0 Dec 6, 2014

same here, enum -> alias

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

also I don't recall all caps naming scheme in vibe.d style guide :p

mihails-strasuns replied Dec 6, 2014

also I don't recall all caps naming scheme in vibe.d style guide :p

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

If original definitions for non-implemented parameters are protected as suggested there will be no need in dead code in actual implementation

mihails-strasuns commented on source/vibe/web/rest.d in d0d42c0 Dec 6, 2014

If original definitions for non-implemented parameters are protected as suggested there will be no need in dead code in actual implementation

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 6, 2014

Owner

It's more like a placeholder "that should go there". It's also here for the same reason the attributes are here but versioned out: it makes it explicit what the overall goal of this first commit is. As it will never be evaluated, does it hurt ? Also, real implementation will follow before next Vibe.d's release.

Owner

Geod24 replied Dec 6, 2014

It's more like a placeholder "that should go there". It's also here for the same reason the attributes are here but versioned out: it makes it explicit what the overall goal of this first commit is. As it will never be evaluated, does it hurt ? Also, real implementation will follow before next Vibe.d's release.

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 7, 2014

I simply have a bad experience with any kind of "TODO" code submitted into master :)
Not really important, if you are going to implement that soon, let's keep it that way.

mihails-strasuns replied Dec 7, 2014

I simply have a bad experience with any kind of "TODO" code submitted into master :)
Not really important, if you are going to implement that soon, let's keep it that way.

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

Makes me miss static switch :(

mihails-strasuns commented on source/vibe/web/rest.d in d0d42c0 Dec 6, 2014

Makes me miss static switch :(

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns commented on source/vibe/web/rest.d in ca950a3 Dec 6, 2014

enum -> alias

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

something wrong with indentation here (and looks it was already broken before)

mihails-strasuns commented on source/vibe/web/rest.d in ca950a3 Dec 6, 2014

something wrong with indentation here (and looks it was already broken before)

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 6, 2014

Contributor

Good. There are plenty of comments but those are mostly matter of style and naming - actual feature looks useful and solid.

Contributor

mihails-strasuns commented Dec 6, 2014

Good. There are plenty of comments but those are mostly matter of style and naming - actual feature looks useful and solid.

@Geod24

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 6, 2014

Contributor

Thanks for the review ! I fixed the style issues.

What's left is:

Contributor

Geod24 commented Dec 6, 2014

Thanks for the review ! I fixed the style issues.

What's left is:

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 7, 2014

Contributor

LGTM @s-ludwig

btw, @Geod24 I am thinking that after majority of your enhancements are merged we should go for separating/rewriting http://vibed.org/docs#rest-interface-generator into detailed guide. Something that will help answer the question "how am I supposed to use all that stuff?". Willing to join? :)

Contributor

mihails-strasuns commented Dec 7, 2014

LGTM @s-ludwig

btw, @Geod24 I am thinking that after majority of your enhancements are merged we should go for separating/rewriting http://vibed.org/docs#rest-interface-generator into detailed guide. Something that will help answer the question "how am I supposed to use all that stuff?". Willing to join? :)

@Geod24

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 7, 2014

Contributor

Sure ! :-)
Any specific milestone in mind ?

Contributor

Geod24 commented Dec 7, 2014

Sure ! :-)
Any specific milestone in mind ?

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 7, 2014

Contributor

As soon as your planned enhancements are complete so that next vibe.d release comes with both features and explanation for them.

Contributor

mihails-strasuns commented Dec 7, 2014

As soon as your planned enhancements are complete so that next vibe.d release comes with both features and explanation for them.

@mihails-strasuns

This comment has been minimized.

Show comment
Hide comment
@mihails-strasuns

mihails-strasuns Dec 7, 2014

Contributor

I'll probably start writing something based on existing stuff I know and let you eventually take it over

Contributor

mihails-strasuns commented Dec 7, 2014

I'll probably start writing something based on existing stuff I know and let you eventually take it over

@Geod24

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 7, 2014

Contributor

I have something on my mind about REST paths. I'll try to formalize that and e-mail you next week. That would be one of the 2 breaking change I plan for this module (The other one being the serialization).

Contributor

Geod24 commented Dec 7, 2014

I have something on my mind about REST paths. I'll try to formalize that and e-mail you next week. That would be one of the 2 breaking change I plan for this module (The other one being the serialization).

Show outdated Hide outdated source/vibe/web/rest.d Outdated
@s-ludwig

This comment has been minimized.

Show comment
Hide comment
@s-ludwig

s-ludwig Dec 10, 2014

Member

Generally looks good AFAICS.

Member

s-ludwig commented Dec 10, 2014

Generally looks good AFAICS.

@Geod24

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 11, 2014

Contributor

@s-ludwig : Thanks for the suggestion, I switched to InetHeaderMap.

Contributor

Geod24 commented Dec 11, 2014

@s-ludwig : Thanks for the suggestion, I switched to InetHeaderMap.

@s-ludwig

This comment has been minimized.

Show comment
Hide comment
@s-ludwig

s-ludwig Dec 11, 2014

Member

Okay thanks, merging (finally)!

Member

s-ludwig commented Dec 11, 2014

Okay thanks, merging (finally)!

s-ludwig added a commit that referenced this pull request Dec 11, 2014

Merge pull request #908 from Geod24/rest-enh-unsplit-2
REST enhancement #1: Allow one to get parameters from headers

@s-ludwig s-ludwig merged commit 643cf77 into vibe-d:master Dec 11, 2014

1 check passed

continuous-integration/travis-ci The Travis CI build passed
Details
@Geod24

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 11, 2014

Contributor

Yay, thanks !

Contributor

Geod24 commented Dec 11, 2014

Yay, thanks !

@Geod24 Geod24 deleted the Geod24:rest-enh-unsplit-2 branch Dec 11, 2014

@MartinNowak

This comment has been minimized.

Show comment
Hide comment
@MartinNowak

MartinNowak Dec 15, 2014

Contributor

This broke compilation on anything but dmd-2.066.1, see https://travis-ci.org/rejectedsoftware/vibe.d/builds/44058739.

Contributor

MartinNowak commented Dec 15, 2014

This broke compilation on anything but dmd-2.066.1, see https://travis-ci.org/rejectedsoftware/vibe.d/builds/44058739.

@Geod24

This comment has been minimized.

Show comment
Hide comment
@Geod24

Geod24 Dec 15, 2014

Contributor

Did it ?

From the error:

source/vibe/internal/meta/uda.d(30): Error: template vibe.internal.meta.uda.findNextUDA matches more than one template declaration:
    source/vibe/internal/meta/uda.d(61):findNextUDA(alias UDA, alias Symbol, long idx, bool allow_types = false)
and
    source/vibe/internal/meta/uda.d(95):findNextUDA(UDA, alias Symbol, long idx, bool allow_types = false)

It looks like it was already broken (but not noticed) before:
https://github.com/rejectedsoftware/vibe.d/blob/2dfacf9863a79ed5a749bdb647b08686ca08b110/source/vibe/internal/meta/uda.d#L28
https://github.com/rejectedsoftware/vibe.d/blob/2dfacf9863a79ed5a749bdb647b08686ca08b110/source/vibe/internal/meta/uda.d#L66

From a quick look, the fix seems trivial, will submit P.R. today. Thanks for your work on this !

Contributor

Geod24 commented Dec 15, 2014

Did it ?

From the error:

source/vibe/internal/meta/uda.d(30): Error: template vibe.internal.meta.uda.findNextUDA matches more than one template declaration:
    source/vibe/internal/meta/uda.d(61):findNextUDA(alias UDA, alias Symbol, long idx, bool allow_types = false)
and
    source/vibe/internal/meta/uda.d(95):findNextUDA(UDA, alias Symbol, long idx, bool allow_types = false)

It looks like it was already broken (but not noticed) before:
https://github.com/rejectedsoftware/vibe.d/blob/2dfacf9863a79ed5a749bdb647b08686ca08b110/source/vibe/internal/meta/uda.d#L28
https://github.com/rejectedsoftware/vibe.d/blob/2dfacf9863a79ed5a749bdb647b08686ca08b110/source/vibe/internal/meta/uda.d#L66

From a quick look, the fix seems trivial, will submit P.R. today. Thanks for your work on this !

@MartinNowak

This comment has been minimized.

Show comment
Hide comment
@MartinNowak

MartinNowak Dec 15, 2014

Contributor

see #927

Contributor

MartinNowak commented Dec 15, 2014

see #927

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment