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

Remove old & invalid msie < 9 support code #2364

Merged
merged 2 commits into from
May 8, 2018

Conversation

wilzbach
Copy link
Member

@wilzbach wilzbach commented May 8, 2018

Turns out that DDox's macro processor doesn't insert a newline when newlines occur in macros.
The workaround is to use good, old HTML.

The old MSIE < 9 support code lead to the final "}" being removed.

See also: dlang/ddox#204

@dlang-bot
Copy link
Contributor

dlang-bot commented May 8, 2018

Thanks for your pull request, @wilzbach!

Bugzilla references

Auto-close Bugzilla Severity Description
18761 major Page for assumeUnique documentation displays incorrectly

@wilzbach
Copy link
Member Author

wilzbach commented May 8, 2018

Before:

 $(RUNNABLE_EXAMPLE
 ----
 string letters()
 {
   char[] result = new char['z' - 'a' + 1];
   foreach (i, ref e; result)
   {
     e = cast(char)('a' + i);
   }
   return assumeUnique(result);
 }
 ----
 )

And after rendering the macros:

<div class="runnable-examples"> ----
 string letters()
 {
   char[] result = new char['z' - 'a' + 1];
   foreach (i, ref e; result)
   {
     e = cast(char)('a' + i);
   }
   return assumeUnique(result);
 }
 ----
 </div>

After:

$(RUNNABLE_EXAMPLE
 ----
 string letters()
 {
   char[] result = new char['z' - 'a' + 1];
   foreach (i, ref e; result)
   {
     e = cast(char)('a' + i);
   }
   return assumeUnique(result);
 }
 ----
 )

And after rendering the macros:

<div class="runnable-examples">
 ----
 string letters()
 {
   char[] result = new char['z' - 'a' + 1];
   foreach (i, ref e; result)
   {
     e = cast(char)('a' + i);
   }
   return assumeUnique(result);
 }
 ----

</div>

@dlang-bot dlang-bot merged commit 6afeb37 into dlang:master May 8, 2018
@wilzbach wilzbach deleted the runnable-example branch July 18, 2018 11:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants