Skip to content
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

「is default」 for subs is not searchable #1040

Closed
AlexDaniel opened this issue Dec 8, 2016 · 8 comments · Fixed by #1052
Closed

「is default」 for subs is not searchable #1040

AlexDaniel opened this issue Dec 8, 2016 · 8 comments · Fixed by #1052

Comments

@AlexDaniel
Copy link
Member

AlexDaniel commented Dec 8, 2016

<babydrop> m: multi foo (Int) is default {say "here"}; multi foo (Int) {say "there"}; foo 42
<camelia> rakudo-moar a98724: OUTPUT«here␤»
<babydrop> m: multi foo (Int) {say "here"}; multi foo (Int) is default {say "there"}; foo 42
<camelia> rakudo-moar a98724: OUTPUT«there␤»
<babydrop> Neat.
<babydrop> TIL
<AlexDaniel> hmmm
<AlexDaniel> so what does it do exactly?
<moritz> it disambiguates ambiguous dispatches

(IRC log: https://irclog.perlgeek.de/perl6/2016-12-08#i_13703911)

@coke coke added the docs Documentation issue (primary issue type) label Dec 11, 2016
@nicqrocks
Copy link
Contributor

Wrote a small thing to try and fix this. See pull #1052.

@AlexDaniel AlexDaniel added search and removed docs Documentation issue (primary issue type) labels Dec 31, 2016
@AlexDaniel
Copy link
Member Author

Make it searchable

@AlexDaniel AlexDaniel reopened this Dec 31, 2016
@AlexDaniel AlexDaniel changed the title 「is default」 for subs is not documented 「is default」 for subs is not searchable Dec 31, 2016
@Altai-man
Copy link
Member

You can add a subsection header like =head2 is_default (sub trait)(or something along the lines) and it will be added to the index automatically. And, I suspect, it will be more readable with such distinction. I assume that header on Variable page should be changed too, for some consistency between these two.

@nicqrocks
Copy link
Contributor

Added headers and changed the one for variables a bit. See pull request #1100.

@Altai-man
Copy link
Member

Closed with a merged pull request. Feel free to reopen or just patch as needed.

@AlexDaniel
Copy link
Member Author

AlexDaniel commented Jan 2, 2017

Still not searchable.

screenshot

@AlexDaniel AlexDaniel reopened this Jan 2, 2017
@Altai-man
Copy link
Member

Altai-man commented Jan 2, 2017

Hmm, it seems that trait of is also not searchable, but trait is dynamic is.

Judging by grep,

➜  doc git:(master) ✗ grep -I -r 'is dynamic' doc/
doc/Type/Variable.pod6:=head2 trait is dynamic
doc/Type/Variable.pod6:    my $x B<is dynamic> = 23;

it should be done. And is dynamic search anchor doesn't look like injected as some exception.

As for me, it is more strange that is dynamic is indexed now.

@AlexDaniel
Copy link
Member Author

It's now indexed… twice.

image

I'll close this issue and create a new one so that it looks less scary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants