From 79e955d048a72fecd88bbc9422cf1827ea63bfe3 Mon Sep 17 00:00:00 2001 From: Jack Stouffer Date: Wed, 25 Nov 2015 11:09:55 -0500 Subject: [PATCH] converted tabs to four spaces --- css/style.css | 1342 +++++++++++++++++++++++----------------------- js/dlang.js | 182 +++---- spec/function.dd | 350 ++++++------ 3 files changed, 937 insertions(+), 937 deletions(-) diff --git a/css/style.css b/css/style.css index 6c3bb0f8ce..2aafc8e852 100644 --- a/css/style.css +++ b/css/style.css @@ -1,20 +1,20 @@ html { - height: 100%; /* of the viewport */ + height: 100%; /* of the viewport */ } body { - padding: 0; - border: 0; - color: black; - background-color: #1f252b; - background-repeat: no-repeat; - font-size: 100%; - font-family: Verdana, "Deja Vu", "Bitstream Vera Sans", sans-serif; - margin: 0px auto; - position: relative; /* So that absolute/fixed positions cling to this. */ - min-height: 100%; + padding: 0; + border: 0; + color: black; + background-color: #1f252b; + background-repeat: no-repeat; + font-size: 100%; + font-family: Verdana, "Deja Vu", "Bitstream Vera Sans", sans-serif; + margin: 0px auto; + position: relative; /* So that absolute/fixed positions cling to this. */ + min-height: 100%; } /* Pseudo-padding. Can't use padding-top, because that's added to height. @@ -22,9 +22,9 @@ Can't use margin-top on children, because it collapses with body's, and consequently is added to height. */ body::before { - content: ""; - display: block; - height: 1em; + content: ""; + display: block; + height: 1em; } /* show signature download on hover */ @@ -81,185 +81,185 @@ em.u table.params { - border: 1px dotted black; + border: 1px dotted black; } tr.param { - border: none; - border-bottom: 1px dotted gray; + border: none; + border-bottom: 1px dotted gray; } tr:last-child { - border-bottom: none; + border-bottom: none; } td.param_id { - border: inherit; - font-family: monospace; - font-weight: bold; - font-size: 120%; - padding-right: 1em; - white-space: nowrap; - vertical-align: top; + border: inherit; + font-family: monospace; + font-weight: bold; + font-size: 120%; + padding-right: 1em; + white-space: nowrap; + vertical-align: top; } td.param_desc { - border: inherit; - font-style: italic; + border: inherit; + font-style: italic; } table.download-compilers { - width: 100%; - max-width: 50em; - table-layout: fixed; + width: 100%; + max-width: 50em; + table-layout: fixed; } table.download-compilers td { - border: none; + border: none; } table.download-compilers h2 { - margin: 0; + margin: 0; } table.download-compilers > tbody > tr:first-child > td { - text-align: center; - vertical-align: middle; + text-align: center; + vertical-align: middle; } table.download-compilers > tbody > tr:nth-child(2) > td { - text-align: left; + text-align: left; } table.download-compilers > tbody > tr:nth-child(2) > td > ul { - margin-bottom: 0; - padding-left: 1em; + margin-bottom: 0; + padding-left: 1em; } table.download-compilers div.download-link { - text-align: center; - margin-bottom: 1em; + text-align: center; + margin-bottom: 1em; } /* table.download-compilers div.download-link a { - background-color: #FF2222; - border: 0.3em solid #AA0000; - border-radius: 1em; - color: white; - padding: 0.5em; - text-decoration: none; + background-color: #FF2222; + border: 0.3em solid #AA0000; + border-radius: 1em; + color: white; + padding: 0.5em; + text-decoration: none; } table.download-compilers div.download-link a:after { - content: '\2b07'; - font-weight: 900; - text-decoration: underline; - margin-left: 0.6em; - font-size: 120%; + content: '\2b07'; + font-weight: 900; + text-decoration: underline; + margin-left: 0.6em; + font-size: 120%; } */ table.download-compilers img { - width: 100%; + width: 100%; } table.download-compilers h3 { - margin-top: 0; - text-align: center; + margin-top: 0; + text-align: center; } div#download-choose { - float: right; + float: right; } .download_image { - display: inline-block; - width: 100px; - vertical-align: top; + display: inline-block; + width: 100px; + vertical-align: top; } h3.download { - display: inline-block; + display: inline-block; } .download_paragraph { - display: inline-block; + display: inline-block; } .download_paragraph > h3 { - margin: 0; + margin: 0; } /* release | beta | nightly */ .download_channels { - word-spacing: 2em; + word-spacing: 2em; } .download_channel { - display: inline-block; - word-spacing: initial; + display: inline-block; + word-spacing: initial; } .footnote { - font-style: italic; + font-style: italic; } .footnote::before { content: " ("; } .footnote::after { content: ")"; } .gname { - font-style: italic; + font-style: italic; } .metacode { - font-style: italic; + font-style: italic; } .key { - font-weight: bold; - display: block; + font-weight: bold; + display: block; } .hyphenate { - -webkit-hyphens: auto; - -moz-hyphens: auto; - -ms-hyphens: auto; - hyphens: auto; + -webkit-hyphens: auto; + -moz-hyphens: auto; + -ms-hyphens: auto; + hyphens: auto; } .donthyphenate { - -webkit-hyphens: manual; - -moz-hyphens: manual; - -ms-hyphens: manual; - hyphens: manual; + -webkit-hyphens: manual; + -moz-hyphens: manual; + -ms-hyphens: manual; + hyphens: manual; } .black { color: black; } @@ -271,116 +271,116 @@ h3.download .bigoh { - font-weight: bold; + font-weight: bold; } div.summary, div.description, div.keyval { - margin: 1.12em 0; + margin: 1.12em 0; } h1, h2, h3, h4, h5, h6 { - font-family: Georgia, "Times New Roman", Times, serif; - font-weight: normal; - color: #633; - line-height: normal; - text-align: left; - margin: 2em 0 1em; + font-family: Georgia, "Times New Roman", Times, serif; + font-weight: normal; + color: #633; + line-height: normal; + text-align: left; + margin: 2em 0 1em; } h1 { - font-size: 2.0em; - margin-top: 0; + font-size: 2.0em; + margin-top: 0; } body#Home h1 span.slogan { - font-size: 0.75em; + font-size: 0.75em; } h2 { - font-size: 1.5em; - margin-top: 1em; - margin-bottom: 0.5em; + font-size: 1.5em; + margin-top: 1em; + margin-bottom: 0.5em; } h3 { - font-size: 1.35em; - margin-bottom: 0.5em; + font-size: 1.35em; + margin-bottom: 0.5em; } h4 { - font-size: 1.15em; - font-style: italic; - margin-bottom: 0; + font-size: 1.15em; + font-style: italic; + margin-bottom: 0; } form { - margin: 0; + margin: 0; } blockquote { - font-family: Georgia, "Times New Roman", Times, serif; - background-color: #e5e5e5; - display: block; - padding: 0.25em 1em; - margin: 1em 2em; + font-family: Georgia, "Times New Roman", Times, serif; + background-color: #e5e5e5; + display: block; + padding: 0.25em 1em; + margin: 1em 2em; } blockquote p:before { - content: "\201C"; - font-family: Georgia, "Times New Roman", Times, serif; - color: #bacaca; - display: block; - font-size: 700%; - width: 50px; - height: 0; - margin-left: -0.5em; - line-height: 0.8em; + content: "\201C"; + font-family: Georgia, "Times New Roman", Times, serif; + color: #bacaca; + display: block; + font-size: 700%; + width: 50px; + height: 0; + margin-left: -0.5em; + line-height: 0.8em; } blockquote p { - margin: 0; - font-style: italic; + margin: 0; + font-style: italic; } blockquote cite { - display: block; - text-align: right; + display: block; + text-align: right; } pre { - background: white; - padding: 1ex; - margin: 1em 0 1em 0em; - font-family: monospace; - font-size: 1.2em; - line-height: normal; - border: 1px solid #ccc; - width: auto; - white-space: pre-wrap; /* css-3 */ - white-space: -moz-pre-wrap; /* Mozilla, since 1999 */ - white-space: -pre-wrap; /* Opera 4-6 */ - white-space: -o-pre-wrap; /* Opera 7 */ - word-wrap: break-word; /* Internet Explorer 5.5+ */ + background: white; + padding: 1ex; + margin: 1em 0 1em 0em; + font-family: monospace; + font-size: 1.2em; + line-height: normal; + border: 1px solid #ccc; + width: auto; + white-space: pre-wrap; /* css-3 */ + white-space: -moz-pre-wrap; /* Mozilla, since 1999 */ + white-space: -pre-wrap; /* Opera 4-6 */ + white-space: -o-pre-wrap; /* Opera 7 */ + word-wrap: break-word; /* Internet Explorer 5.5+ */ } dd, .d_decl_dd { - padding: 1ex; - margin-left: 3em; - margin-bottom: 1em; + padding: 1ex; + margin-left: 3em; + margin-bottom: 1em; } table @@ -392,7 +392,7 @@ table table tr { - border: none; + border: none; } table td, table th, table caption @@ -406,7 +406,7 @@ table td { border: none; border-bottom: 1px solid #E4E9EF; - text-align: justify; + text-align: justify; } table th @@ -422,17 +422,17 @@ table td:not(:last-child), table th:not(:last-child) hr { - margin: 2em 0; + margin: 2em 0; } a { - color: #006; + color: #006; } a:visited { - color: #606; + color: #606; } /* @@ -443,168 +443,168 @@ they are underlined and display a pilcrow after them. */ a.anchor { - color: #633; /* Use the regular header text color */ - text-decoration: none; /* Don't underline unless hovered */ + color: #633; /* Use the regular header text color */ + text-decoration: none; /* Don't underline unless hovered */ } a.anchor:hover { - text-decoration: underline; /* See above */ + text-decoration: underline; /* See above */ } a.anchor:hover:after { - content: " \00B6"; /* Unicode pilcrow symbol */ - color: black; /* Pilcrow should not use the regular header text color */ - font-style: normal; /* ... and should not be italic */ + content: " \00B6"; /* Unicode pilcrow symbol */ + color: black; /* Pilcrow should not use the regular header text color */ + font-style: normal; /* ... and should not be italic */ } /* Avoid inserting the pilcrow in the middle of the line on the compiler pages */ body.dcompiler dt a.anchor:hover:after { - display: none; + display: none; } body.dcompiler dt a.anchor:hover { - position: relative; + position: relative; } body.dcompiler dt a.anchor:hover:before { - content: " \00B6"; - color: black; - font-style: normal; - position: absolute; - left: -1em; + content: " \00B6"; + color: black; + font-style: normal; + position: absolute; + left: -1em; } .notice { - margin-bottom: 0.5em; + margin-bottom: 0.5em; } a.notice:hover { - background: inherit; /* $(menu_bg_hover) */ + background: inherit; /* $(menu_bg_hover) */ } .notice, table.notice-table td { - background-color: white; - box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.16), 0 2px 10px 0 rgba(0, 0, 0, 0.12); - border: 1px dotted #633; - text-align: center; - padding: 0.5em; + background-color: white; + box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.16), 0 2px 10px 0 rgba(0, 0, 0, 0.12); + border: 1px dotted #633; + text-align: center; + padding: 0.5em; } .notice, table.notice-table td a { - text-decoration: none; - font-weight: bold; - display: block; + text-decoration: none; + font-weight: bold; + display: block; } table.notice-table { - border: none; - width: 100%; - border-collapse: separate; - border-spacing: 0 0; + border: none; + width: 100%; + border-collapse: separate; + border-spacing: 0 0; } table.notice-table td { - vertical-align: middle; + vertical-align: middle; } /* padding between left and right cell */ table.notice-table td:nth-child(2) { - visibility: hidden; - border: 0; - padding: 0.25em; + visibility: hidden; + border: 0; + padding: 0.25em; } /* These are different kinds of
 sections */
 .bnf /* grammar */
 {
-	background-color: white;
-	color: #000066;
+    background-color: white;
+    color: #000066;
 }
 
 .ddoccode
 {
-	background-color: #f3eeee;
-	color: #000066;
+    background-color: #f3eeee;
+    color: #000066;
 }
 
 .console /* command line console */
 {
-	background-color: #f7f7f7;
-	color: #181818;
+    background-color: #f7f7f7;
+    color: #181818;
 }
 
 .moddeffile /* module definition file */
 {
-	background-color: #efeffe;
-	color: #010199;
+    background-color: #efeffe;
+    color: #010199;
 }
 
 .scini /* sc.ini configuration file */
 {
-	background-color: #fef6fe;
-	color: #111199;
+    background-color: #fef6fe;
+    color: #111199;
 }
 
 .d_code /* D code */
 {
-	background-color: #fcfcfc;
-	color: #000066;
+    background-color: #fcfcfc;
+    color: #000066;
 }
 
 .d_code2 /* D code */
 {
-	background-color: #fcfcfc;
-	color: #000066;
+    background-color: #fcfcfc;
+    color: #000066;
 }
 
 .asmcode /* Asm code */
 {
-	background-color: #afcbde;
-	color: #000066;
+    background-color: #afcbde;
+    color: #000066;
 }
 
 .ccode /* C code */
 {
-	background-color: #f6ecf0;
-	color: #000066;
+    background-color: #f6ecf0;
+    color: #000066;
 }
 
 .cppcode /* C++ code */
 {
-	background-color: #f6ecf0;
-	color: #000066;
+    background-color: #f6ecf0;
+    color: #000066;
 }
 
 .cppcode2 /* C++ code */
 {
-	background-color: #f6ecf0;
-	color: #000066;
+    background-color: #f6ecf0;
+    color: #000066;
 }
 
 td .d_code2, td .cppcode2, td .cppcode
 {
-	min-width: 20em;
-	margin: 1em 0em;
+    min-width: 20em;
+    margin: 1em 0em;
 }
 
 .d_inlinecode
 {
-	font-family: monospace;
-	/* font-size: 1.2em; */
-	font-weight: bold;
+    font-family: monospace;
+    /* font-size: 1.2em; */
+    font-weight: bold;
 }
 
 /* Elements of D source code text */
@@ -619,51 +619,51 @@ td .d_code2, td .cppcode2, td .cppcode
 
 div#top, div#navigation
 {
-	width: 16em;
-	background: #333 /*hsl(0, 0%, 20%)*/;
-	border: 0.25em none #191919 /*hsl(0, 0%, 10%)*/;
-	border-right-style: solid;
+    width: 16em;
+    background: #333 /*hsl(0, 0%, 20%)*/;
+    border: 0.25em none #191919 /*hsl(0, 0%, 10%)*/;
+    border-right-style: solid;
 }
 div#top
 {
-	position: absolute;
-	top: 0;
-	left: 0;
-	font-size: 0.875em;
-	min-height: 100%;
+    position: absolute;
+    top: 0;
+    left: 0;
+    font-size: 0.875em;
+    min-height: 100%;
 }
 
 div#header
 {
-	position: relative;
-	z-index: 1; /* i.e. higher than #navigation's */
+    position: relative;
+    z-index: 1; /* i.e. higher than #navigation's */
 }
 
 img
 {
-	border: 0;
+    border: 0;
 }
 
 div#header a.logo
 {
-	display: block;
-	text-align: center;
-	padding: 1em 0;
+    display: block;
+    text-align: center;
+    padding: 1em 0;
 }
 
 img#logo
 {
-	vertical-align: text-bottom;
+    vertical-align: text-bottom;
 }
 
 div#header a#d-language
 {
-	display: block;
-	font-variant: small-caps;
-	text-align: center;
-	color: white;
-	text-decoration: none;
-	line-height: 1.4em;
+    display: block;
+    font-variant: small-caps;
+    text-align: center;
+    color: white;
+    text-decoration: none;
+    line-height: 1.4em;
 }
 
 img#github-ribbon
@@ -677,475 +677,475 @@ img#github-ribbon
 
 div#search-box, span#search-query, span#search-dropdown, span#search-submit
 {
-	border: 0.1em none #aaa;
+    border: 0.1em none #aaa;
 }
 
 div#search-box
 {
-	white-space: nowrap;
-	margin: 3em 1em;
-	-webkit-border-radius: 0.3em 0.3em 0.3em 0.3em;
-	-moz-border-radius: 0.3em 0.3em 0.3em 0.3em;
-	border-radius: 0.3em 0.3em 0.3em 0.3em;
-	background: #F6F6F6;
-	border-style: solid;
+    white-space: nowrap;
+    margin: 3em 1em;
+    -webkit-border-radius: 0.3em 0.3em 0.3em 0.3em;
+    -moz-border-radius: 0.3em 0.3em 0.3em 0.3em;
+    border-radius: 0.3em 0.3em 0.3em 0.3em;
+    background: #F6F6F6;
+    border-style: solid;
 }
 
 span#search-query, span#search-dropdown, span#search-submit
 {
-	vertical-align: top;
-	line-height: 1.3em;
-	height: 1.8em;
+    vertical-align: top;
+    line-height: 1.3em;
+    height: 1.8em;
 }
 span#search-dropdown, span#search-submit
 {
-	display: inline-block;
+    display: inline-block;
 }
 
 span#search-query input, span#search-dropdown select, span#search-submit button
 {
-	background: transparent;
-	color: black;
-	border: none;
-	margin: 0;
-	padding: 0 0.5em;
-	width: 100%;
-	height: 100%;
-	outline: none;
+    background: transparent;
+    color: black;
+    border: none;
+    margin: 0;
+    padding: 0 0.5em;
+    width: 100%;
+    height: 100%;
+    outline: none;
 }
 
 span#search-query
 {
-	display: block;
-	border-bottom-style: solid;
+    display: block;
+    border-bottom-style: solid;
 }
 
 span#search-dropdown
 {
-	position: relative;
-	border-right: none;
-	overflow: hidden;
-	width: 11em;
-	/*
-		= 16em [#navigation's width]
-		- 2 * 1em [#search-box's margin-{left,right}]
-		- 3em [#search-submit's width]
-	*/
+    position: relative;
+    border-right: none;
+    overflow: hidden;
+    width: 11em;
+    /*
+        = 16em [#navigation's width]
+        - 2 * 1em [#search-box's margin-{left,right}]
+        - 3em [#search-submit's width]
+    */
 }
 
 span#search-dropdown select
 {
-	position: relative;
-	width: 14em; /* Pushing the native dropdown arrow into invisibility. */
-	z-index: 1;
+    position: relative;
+    width: 14em; /* Pushing the native dropdown arrow into invisibility. */
+    z-index: 1;
 }
 
 span#search-dropdown:after
 {
-	content: "\f107"; /* angle down */
-	font-family: FontAwesome;
-	position: absolute;
-	height: 10px;
-	width: 1em;
-	top: 50%;
-	margin-top: -0.5em;
-	right: 0.2em;
+    content: "\f107"; /* angle down */
+    font-family: FontAwesome;
+    position: absolute;
+    height: 10px;
+    width: 1em;
+    top: 50%;
+    margin-top: -0.5em;
+    right: 0.2em;
 }
 
 span#search-submit
 {
-	line-height: 1.2em;
-	width: 3em;
-	/*
-		= 16em [#navigation's width]
-		- 2 * 1em [#search-box's margin-{left,right}]
-		- 11em [#search-submit's width]
-	*/
-	border-left-style: solid;
-	margin-left: -0.1em; /* = border-width */
+    line-height: 1.2em;
+    width: 3em;
+    /*
+        = 16em [#navigation's width]
+        - 2 * 1em [#search-box's margin-{left,right}]
+        - 11em [#search-submit's width]
+    */
+    border-left-style: solid;
+    margin-left: -0.1em; /* = border-width */
 }
 
 span#search-submit span /* hide 'go' */
 {
-	display: none;
+    display: none;
 }
 
 
 div#navigation
 {
-	position: relative;
-	font-size: 0.875em;
-	float: left;
-	margin-top: 2.4em;
-	/*
-		= - 1em [body::before pseudo-padding]
-		+ 2 * 1em [div#header a.logo's padding-{top,bottom}]
-		+ 1.4em [#d-language's line-height]
-	*/
-	padding-top: 95px; /* = #logo's height */
+    position: relative;
+    font-size: 0.875em;
+    float: left;
+    margin-top: 2.4em;
+    /*
+        = - 1em [body::before pseudo-padding]
+        + 2 * 1em [div#header a.logo's padding-{top,bottom}]
+        + 1.4em [#d-language's line-height]
+    */
+    padding-top: 95px; /* = #logo's height */
 }
 
 div#content
 {
-	text-align: justify;
-	min-height: 440px;
-	margin-left: 18em;
-	/*
-		= 16em [#navigation's width]
-		+ 2em [inter-column space]
-	*/
-	margin-right: 1em;
-	padding: 1.6em;
-	padding-top: 1.3em;
-	padding-bottom: 1em;
-	background-color: #f6f6f6;
-	font-size: 0.875em;
-	line-height: 1.4em;
-	text-align: justify;
-	border: 0.25em solid #ccd5d5;
+    text-align: justify;
+    min-height: 440px;
+    margin-left: 18em;
+    /*
+        = 16em [#navigation's width]
+        + 2em [inter-column space]
+    */
+    margin-right: 1em;
+    padding: 1.6em;
+    padding-top: 1.3em;
+    padding-bottom: 1em;
+    background-color: #f6f6f6;
+    font-size: 0.875em;
+    line-height: 1.4em;
+    text-align: justify;
+    border: 0.25em solid #ccd5d5;
 }
 
 body#Home div#content
 {
-	margin-right: 21em;
-	/*
-		= 1em [#news's margin-right]
-		+ 18em [#news's width]
-		+ 2em [inter-column space]
-	*/
+    margin-right: 21em;
+    /*
+        = 1em [#news's margin-right]
+        + 18em [#news's width]
+        + 2em [inter-column space]
+    */
 }
 
 body.chm div#news,
 body.chm div#navigation,
 body.chm div#top
 {
-	display: none;
+    display: none;
 }
 
 body.chm
 {
-	min-width: 0 !important;
+    min-width: 0 !important;
 }
 
 body.chm div#content
 {
-	padding: 20px;
-	border: none;
-	margin: 0 !important;
-	border-radius: 0;
+    padding: 20px;
+    border: none;
+    margin: 0 !important;
+    border-radius: 0;
 }
 
 body.chm div#tools
 {
-	margin-right: 0;
+    margin-right: 0;
 }
 
 body.chm dt.d_decl
 {
-	width: 100%;
+    width: 100%;
 }
 
 span#wiki
 {
-	position: relative;
-	right: 0;
-	z-index: 2;
+    position: relative;
+    right: 0;
+    z-index: 2;
 }
 
 body#Home #content {
-	margin-right:20em;
+    margin-right:20em;
 }
 
 div#news
 {
-	font-size: 0.875em;
-	float: right;
-	width: 18em;
-	margin-right: 1em;
+    font-size: 0.875em;
+    float: right;
+    width: 18em;
+    margin-right: 1em;
 }
 
 div#twitter
 {
-	color: white;
+    color: white;
 }
 
 div#forum-summary
 {
-	color: white;
-	width: 100%;
-	margin-right: 1em;
+    color: white;
+    width: 100%;
+    margin-right: 1em;
 }
 
 div#forum-summary > iframe
 {
-	border: 0;
-	width: 100%;
-	height: 210px;
+    border: 0;
+    width: 100%;
+    height: 210px;
 }
 
 div.navblock
 {
-	margin-top: 0;
-	margin-bottom: 1em;
+    margin-top: 0;
+    margin-bottom: 1em;
 }
 
 div#navigation .navblock h2
 {
-	font-family: Verdana, "Deja Vu", "Bitstream Vera Sans", sans-serif;
-	font-size: 1.35em;
-	color: #ccc;
-	margin: 0;
+    font-family: Verdana, "Deja Vu", "Bitstream Vera Sans", sans-serif;
+    font-size: 1.35em;
+    color: #ccc;
+    margin: 0;
 }
 
 div#navigation .navblock ul
 {
-	list-style-type: none;
-	margin: 0;
-	padding: 0;
+    list-style-type: none;
+    margin: 0;
+    padding: 0;
 }
 
 div#navigation .navblock li
 {
-	margin: 0 0 0 0.8em;
-	padding: 0;
+    margin: 0 0 0 0.8em;
+    padding: 0;
 }
 
 #navigation .navblock a
 {
-	display: block;
-	color: #ccc;
-	text-decoration: none;
-	padding: 0.1em 0;
-	border-bottom: 1px dotted #494949;
+    display: block;
+    color: #ccc;
+    text-decoration: none;
+    padding: 0.1em 0;
+    border-bottom: 1px dotted #494949;
 }
 
 #navigation .navblock a:hover
 {
-	color: #eee;
+    color: #eee;
 }
 
 #navigation .navblock a.active
 {
-	color: white;
-	border-color: white;
+    color: white;
+    border-color: white;
 }
 
 
 div#translate
 {
-	margin-top: 3em;
-	margin-left: 0;
-	color: #ccc;
+    margin-top: 3em;
+    margin-left: 0;
+    color: #ccc;
 }
 
 
 div#tools
 {
-	display: inline;
-	float: right;
-	margin:
-		-1.1em /* = -(1.3em [#content's padding-top] - 0.2em) */
-		-1.4em /* = -(1.6em [#content's padding-right] - 0.2em) */
-		1em 1em;
-	text-align: right;
+    display: inline;
+    float: right;
+    margin:
+        -1.1em /* = -(1.3em [#content's padding-top] - 0.2em) */
+        -1.4em /* = -(1.6em [#content's padding-right] - 0.2em) */
+        1em 1em;
+    text-align: right;
 }
 
 body#Downloads div#tools
 {
-	padding-right: 149px; /* = width of github-ribbon.png */
+    padding-right: 149px; /* = width of github-ribbon.png */
 }
 
 div#tools a.button
 {
-	-moz-box-shadow:inset 0px 1px 0px 0px #ffffff;
-	-webkit-box-shadow:inset 0px 1px 0px 0px #ffffff;
-	box-shadow:inset 0px 1px 0px 0px #ffffff;
-	background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #ededed), color-stop(1, #dfdfdf) );
-	background:-moz-linear-gradient( center top, #ededed 5%, #dfdfdf 100% );
-	background:-o-linear-gradient(top, #ededed, #dfdfdf);
-	filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ededed', endColorstr='#dfdfdf');
-	background-color:#ededed;
-	border:1px solid #aaa;
-	display:inline-block;
-	color:#555;
-	font-family:arial;
-	font-size:72%;
-	font-weight:bold;
-	padding:0px 6px;
-	text-decoration:none;
-	text-shadow:1px 1px 0px #ffffff;
+    -moz-box-shadow:inset 0px 1px 0px 0px #ffffff;
+    -webkit-box-shadow:inset 0px 1px 0px 0px #ffffff;
+    box-shadow:inset 0px 1px 0px 0px #ffffff;
+    background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #ededed), color-stop(1, #dfdfdf) );
+    background:-moz-linear-gradient( center top, #ededed 5%, #dfdfdf 100% );
+    background:-o-linear-gradient(top, #ededed, #dfdfdf);
+    filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ededed', endColorstr='#dfdfdf');
+    background-color:#ededed;
+    border:1px solid #aaa;
+    display:inline-block;
+    color:#555;
+    font-family:arial;
+    font-size:72%;
+    font-weight:bold;
+    padding:0px 6px;
+    text-decoration:none;
+    text-shadow:1px 1px 0px #ffffff;
 }
 
 div#tools a.button:hover
 {
-	background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #dfdfdf), color-stop(1, #ededed) );
-	background:-moz-linear-gradient( center top, #dfdfdf 5%, #ededed 100% );
-	background:-o-linear-gradient(top, #dfdfdf, #ededed);
-	filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#dfdfdf', endColorstr='#ededed');
-	background-color:#dfdfdf;
+    background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #dfdfdf), color-stop(1, #ededed) );
+    background:-moz-linear-gradient( center top, #dfdfdf 5%, #ededed 100% );
+    background:-o-linear-gradient(top, #dfdfdf, #ededed);
+    filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#dfdfdf', endColorstr='#ededed');
+    background-color:#dfdfdf;
 }
 
 div#tools a.button:active
 {
-	position: relative;
-	top: 1px;
+    position: relative;
+    top: 1px;
 }
 
 div#tools img
 {
-	vertical-align: middle;
+    vertical-align: middle;
 }
 
 .tip {
-	position: relative;
+    position: relative;
 }
 
 .tip span {
-	display: none;
-	position: absolute;
-	top: 25px;
-	left: auto;
-	right: 0;
-	width: 200px;
-	padding: 8px !important;
-	z-index: 100;
-	background: #000;
-	color: #eee !important;
-	font-style: normal !important;
-	font-size: 72%;
-	text-align: left;
-	-moz-border-radius: 5px;
-	-webkit-border-radius: 5px;
-	border-radius: 5px;
-
-	/* undo inherited attributes */
-	text-shadow: none;
+    display: none;
+    position: absolute;
+    top: 25px;
+    left: auto;
+    right: 0;
+    width: 200px;
+    padding: 8px !important;
+    z-index: 100;
+    background: #000;
+    color: #eee !important;
+    font-style: normal !important;
+    font-size: 72%;
+    text-align: left;
+    -moz-border-radius: 5px;
+    -webkit-border-radius: 5px;
+    border-radius: 5px;
+
+    /* undo inherited attributes */
+    text-shadow: none;
 }
 
 .tip:hover span {
-	display: block;
+    display: block;
 }
 
 
 div#content li
 {
-	padding-bottom: .7ex;
+    padding-bottom: .7ex;
 }
 
 
 div#footernav
 {
     clear: both;
-/* 	margin-top: 2em; */
-	padding: 1em 2em 0 2em;
-/* 	background-color: #303333; */
-	color: #666;
-	text-align: center;
-	font-size: 80%;
+/*  margin-top: 2em; */
+    padding: 1em 2em 0 2em;
+/*  background-color: #303333; */
+    color: #666;
+    text-align: center;
+    font-size: 80%;
 }
 
 div#footernav a
 {
-	color: #ccc;
+    color: #ccc;
 }
 
 div#footernav a:hover
 {
-	color: white;
+    color: white;
 }
 
 
 div#copyright
 {
-	padding: 1em 2em;
-/* 	background-color: #303333; */
-	color: #ccc;
-	font-size: 50%;
-	text-align: center;
+    padding: 1em 2em;
+/*  background-color: #303333; */
+    color: #ccc;
+    font-size: 50%;
+    text-align: center;
 }
 
 div#copyright a
 {
-	color: #ccc;
+    color: #ccc;
 }
 
 
 /* These are for the newsgroup archives */
 div#newsnav
 {
-	margin-top: -1.5em;
-	margin-bottom: -1em;
+    margin-top: -1.5em;
+    margin-bottom: -1em;
 }
 div#Posting
 {
-	border: 1px solid #cccccc;
-	margin-bottom: 1em;
+    border: 1px solid #cccccc;
+    margin-bottom: 1em;
 }
 div#PostingHeading
 {
-	font-family: Georgia, "Times New Roman", Times, serif;
-	font-size: larger;
-	color: #633;
-	background-color: #eeeeee;
+    font-family: Georgia, "Times New Roman", Times, serif;
+    font-size: larger;
+    color: #633;
+    background-color: #eeeeee;
 }
 div#PostingHeading img
 {
-	vertical-align: middle;
+    vertical-align: middle;
 }
 div#PostingHeading a
 {
-	text-decoration: none;
+    text-decoration: none;
 }
 div#PostingFooting
 {
-	font-size: smaller;
-	background-color: #eeeeee;
+    font-size: smaller;
+    background-color: #eeeeee;
 }
 div#PostingTOC
 {
-	font-size: smaller;
+    font-size: smaller;
 }
 div#PostingTOC li
 {
-	margin-left: 0;
+    margin-left: 0;
 }
 div#PostingTOC a
 {
-	font-family: Georgia, "Times New Roman", Times, serif;
+    font-family: Georgia, "Times New Roman", Times, serif;
 }
 .PostingBody /* newsgroup posting */
 {
-	border: 0;
-	margin: 0;
-	background-color: #fcfcfc;
-	color: #000066;
-	margin-left: 0em;
-	min-width: 15em;
-	padding-bottom: 0.5em;
+    border: 0;
+    margin: 0;
+    background-color: #fcfcfc;
+    color: #000066;
+    margin-left: 0em;
+    min-width: 15em;
+    padding-bottom: 0.5em;
 }
 .PostingQuote /* quote inside newsgroup posting */
 {
-	border: 1px solid #666666;
-	font-size: 90%;
-	background-color: inherit;
-	color: #666666;
-	margin-left: 0em;
-	min-width: 15em;
+    border: 1px solid #666666;
+    font-size: 90%;
+    background-color: inherit;
+    color: #666666;
+    margin-left: 0em;
+    min-width: 15em;
 }
 
 /* These are for the changelogs */
 div.version
 {
-	font-size: 0.9em;
+    font-size: 0.9em;
 }
 div.version font
 {
-	font-family: Georgia, "Times New Roman", Times, serif;
-	color: #633;
+    font-family: Georgia, "Times New Roman", Times, serif;
+    color: #633;
 }
 div.version li
 {
-	padding-bottom: 0.3ex;
+    padding-bottom: 0.3ex;
 }
 div.bugsfixed
 {
@@ -1155,30 +1155,30 @@ div.whatsnew
 }
 div.changelog-nav
 {
-	font-size: small;
-	margin: 2em 0;
-	text-align: center;
+    font-size: small;
+    margin: 2em 0;
+    text-align: center;
 }
 
 
 /* These are for comparison.html */
 table.comp /* "comparison with D": table */
 {
-	background-color:#e9e6dd;
+    background-color:#e9e6dd;
 }
 table.comp a
 {
-	color: black;
+    color: black;
 }
 td.compNo  /* comparison with D: "NO" */
 {
-	background-color:red;
-	text-align:center;
+    background-color:red;
+    text-align:center;
 }
 td.compYes  /* comparison with D: "YES" */
 {
-	background-color:#00FF00;
-	text-align:center;
+    background-color:#00FF00;
+    text-align:center;
 }
 
 
@@ -1205,33 +1205,33 @@ td.compYes  /* comparison with D: "YES" */
 }
 
 .quickindex {
-	font-weight: normal;
-	background-color: #E4E9EF;
+    font-weight: normal;
+    background-color: #E4E9EF;
 }
 
 .quickindex a {
-	text-decoration: none;
+    text-decoration: none;
 }
 
 .quickindex a:hover {
-	text-decoration: underline;
+    text-decoration: underline;
 }
 
 .question
 {
     display: inline;
-	/* font-weight:bold;	/* Bold font */
-	color: #006;
+    /* font-weight:bold;    /* Bold font */
+    color: #006;
     text-decoration: underline;
-	cursor:pointer;		/* Cursor is like a hand when someone rolls the mouse over the question */
+    cursor:pointer;     /* Cursor is like a hand when someone rolls the mouse over the question */
 }
 
 .answer {
-	display:none;
+    display:none;
 }
 
 .answer-nojs {
-	display:block;
+    display:block;
 }
 
 .nobr {
@@ -1242,29 +1242,29 @@ td.compYes  /* comparison with D: "YES" */
 textarea.d_code {display: none;}
 textarea.d_code_output, textarea.d_code_stdin, textarea.d_code_args
 {
-	text-align: left;
-	border: none;
-	width: 98%;
-	font-size: 1.09em;
-	font-family: monospace;
-	padding: 5px;
-	margin: 1px;
-	word-wrap: break-word;
-	height: auto;
-	background: white;
-	margin-left: 2px;
-	outline: none;
-}
-
-div.d_code {margin: 0; padding: 0; font-size: 100%;	margin-bottom: -14px; background: #F6F6F6;}
+    text-align: left;
+    border: none;
+    width: 98%;
+    font-size: 1.09em;
+    font-family: monospace;
+    padding: 5px;
+    margin: 1px;
+    word-wrap: break-word;
+    height: auto;
+    background: white;
+    margin-left: 2px;
+    outline: none;
+}
+
+div.d_code {margin: 0; padding: 0; font-size: 100%; margin-bottom: -14px; background: #F6F6F6;}
 div.d_run_code {display: none; margin: 1em 0 1em 3.1em;}
 div.d_code_output, div.d_code_stdin, div.d_code_args, div.d_code_unittest
 {
-	border: 1px solid #CCC;
-	background: white;
-	display: none;
-	height: auto;
-	width: 100%;
+    border: 1px solid #CCC;
+    background: white;
+    display: none;
+    height: auto;
+    width: 100%;
 }
 
 .d_code_title {font-weight: bold;font-size: 100%;padding: 5px;}
@@ -1296,34 +1296,34 @@ div.d_code_output, div.d_code_stdin, div.d_code_args, div.d_code_unittest
 
 input.runButton, input.resetButton, input.argsButton, input.inputButton, input.editButton
 {
-	-moz-box-shadow:inset 0px 1px 0px 0px #ffffff;
-	-webkit-box-shadow:inset 0px 1px 0px 0px #ffffff;
-	box-shadow:inset 0px 1px 0px 0px #ffffff;
-	background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #ededed), color-stop(1, #dfdfdf) );
-	background:-moz-linear-gradient( center top, #ededed 5%, #dfdfdf 100% );
-	filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ededed', endColorstr='#dfdfdf');
-	background-color:#ededed;
-	border:1px solid #dcdcdc;
-	display:inline-block;
-	color:#777777;
-	font-family:arial;
-	font-size:72%;
-	font-weight:bold;
-	padding:3px 6px;
-	text-decoration:none;
-	text-shadow:1px 1px 0px #ffffff;
-	width: 50px;
-	margin: 2px;
-	position: relative;
-	z-index: 2;
-	cursor: pointer;
+    -moz-box-shadow:inset 0px 1px 0px 0px #ffffff;
+    -webkit-box-shadow:inset 0px 1px 0px 0px #ffffff;
+    box-shadow:inset 0px 1px 0px 0px #ffffff;
+    background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #ededed), color-stop(1, #dfdfdf) );
+    background:-moz-linear-gradient( center top, #ededed 5%, #dfdfdf 100% );
+    filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ededed', endColorstr='#dfdfdf');
+    background-color:#ededed;
+    border:1px solid #dcdcdc;
+    display:inline-block;
+    color:#777777;
+    font-family:arial;
+    font-size:72%;
+    font-weight:bold;
+    padding:3px 6px;
+    text-decoration:none;
+    text-shadow:1px 1px 0px #ffffff;
+    width: 50px;
+    margin: 2px;
+    position: relative;
+    z-index: 2;
+    cursor: pointer;
 }
 input.runButton:hover, input.resetButton:hover, input.argsButton:hover, input.inputButton:hover, input.editButton:hover,input.runButton[disabled]
 {
-	background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #dfdfdf), color-stop(1, #ededed) );
-	background:-moz-linear-gradient( center top, #dfdfdf 5%, #ededed 100% );
-	filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#dfdfdf', endColorstr='#ededed');
-	background-color:#dfdfdf;
+    background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #dfdfdf), color-stop(1, #ededed) );
+    background:-moz-linear-gradient( center top, #dfdfdf 5%, #ededed 100% );
+    filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#dfdfdf', endColorstr='#ededed');
+    background-color:#dfdfdf;
 }
 input.runButton:active, input.resetButton:active, input.argsButton:active, input.inputButton:active, input.editButton:active
 { position: relative; top: 1px; }
@@ -1332,7 +1332,7 @@ input.resetButton{display: none}
 
 div#mobile-top, div#mobile-search, img#mobile-hamburger
 {
-	display: none;
+    display: none;
 }
 
 .page-contents
@@ -1348,187 +1348,187 @@ div#mobile-top, div#mobile-search, img#mobile-hamburger
 
 .page-contents-header
 {
-	text-align: center;
+    text-align: center;
 }
 
 .page-contents-header h3
 {
-	display: inline;
-	color: #444;
-	font-weight: bold;
-	margin-top: 0;
+    display: inline;
+    color: #444;
+    font-weight: bold;
+    margin-top: 0;
 }
 
 div#content .page-contents li
 {
-	line-height: 1.3;
-	padding-bottom: 0;
+    line-height: 1.3;
+    padding-bottom: 0;
 }
 
 @media only screen and (min-width: 64em) { /* 1024px for default font-size 16 */
-	pre
-	{
-		overflow: auto;
-	}
+    pre
+    {
+        overflow: auto;
+    }
 
-	.page-contents
-	{
+    .page-contents
+    {
         float: right;
-	}
+    }
 }
 
 @media only screen and (max-width: 64em) { /* 1024px for default font-size 16 */
-	div#news{
-		display: none;
-	}
+    div#news{
+        display: none;
+    }
 
-	div#content{
-		margin-right: 1em !important;
-	}
+    div#content{
+        margin-right: 1em !important;
+    }
 }
 
 @media only screen and (max-width: 50em) { /* 800px for default font-size 16 */
 
-	/* Disable desktop-size UI elements */
-
-	div#news {
-		display: none;
-	}
-
-	/* Header */
-
-	div#top {
-		position: relative;
-		width: auto;
-		display: block;
-		border-right-style: none;
-		border-bottom-style: solid;
-		overflow: hidden;
-		text-align: center;
-		font-size: 1em;
-	}
-
-	img#mobile-hamburger {
-		position: absolute;
-		left: 0;
-		top: 0;
-		width: 3.2em;
-		height: 3.2em;
-		line-height: 3.3em;
-		text-align: center;
-		display: block;
-		cursor: pointer;
-	}
-
-	img#mobile-hamburger:hover {
-		background: #444; /* menu_active_bg */
-	}
-
-	div#header {
-		position: static;
-		margin: 0 3.2em; /* = #mobile-hamburger's width */
-	}
-
-	div#header a.logo {
-		display: none;
-	}
-
-	span#d-language-mobilehelper {
-		display: inline-block;
-		vertical-align: middle;
-		line-height: 1.0;
-	}
-
-	div#header a#d-language {
-		position: static;
-		display: table-cell;
-		vertical-align: middle;
-		color: white;
-		text-align: center;
-		height: 3.2em;
-		padding: 0;
-		background: transparent;
-		line-height: 1.2em;
-		background: url(../images/dlogo.png) left no-repeat;
-		background-size: 50px auto;
-		padding-left: 60px;
-		/*
-			= 50px [background image width]
-			+ 10px [some space between image and text]
-		*/
-	}
-
-	/* Search */
-
-	div#search-box
-	{
-		position: static;
-		text-align: center;
-		overflow: hidden;
-		margin-top: 1em;
-
-		-moz-transition: height 0.5s;
-		-webkit-transition: height 0.5s;
-		transition: height 0.5s;
-	}
-
-	div#search-query {
-		width: 40%;
-	}
-
-	/* Navigation */
-
-	div#navigation {
-		display: block;
-		position: absolute;
-		top: 0;
-		left: -20em;
-		min-height: 100%;
-		padding: 0;
-		margin: 0;
-		-moz-box-shadow: 10px 0px 20px black;
-		-webkit-box-shadow: 10px 0px 20px black;
-		box-shadow: 10px 0px 20px black;
-		z-index: 10001;
-		-moz-transition: left 0.5s;
-		-webkit-transition: left 0.5s;
-		transition: left 0.5s;
-	}
-
-	div#navigation.open{
-		left: 0;
-	}
-
-	div#navigation-cancel {
-		position: fixed;
-		left: 0; top: 0; right: 0; bottom: 0;
-		background-color: rgba(255,255,255,0.5);
-		z-index: 10000;
-	}
-
-	/* Content */
-
-	div#content {
-		-moz-border-radius: 0;
-		-webkit-border-radius: 0;
-		border-radius: 0;
-		margin-left: 0;
-		margin-right: 0 !important /* override inline style! */;
-	}
-
-	body::before { /* Disable pseudo-padding. */
-		display: none;
-	}
-
-	pre {
-		font-size: 1em;
-	}
-
-	img#github-ribbon {
-		display: none;
-	}
-
-	body#Downloads div#tools {
-		padding-right: 0;
-	}
+    /* Disable desktop-size UI elements */
+
+    div#news {
+        display: none;
+    }
+
+    /* Header */
+
+    div#top {
+        position: relative;
+        width: auto;
+        display: block;
+        border-right-style: none;
+        border-bottom-style: solid;
+        overflow: hidden;
+        text-align: center;
+        font-size: 1em;
+    }
+
+    img#mobile-hamburger {
+        position: absolute;
+        left: 0;
+        top: 0;
+        width: 3.2em;
+        height: 3.2em;
+        line-height: 3.3em;
+        text-align: center;
+        display: block;
+        cursor: pointer;
+    }
+
+    img#mobile-hamburger:hover {
+        background: #444; /* menu_active_bg */
+    }
+
+    div#header {
+        position: static;
+        margin: 0 3.2em; /* = #mobile-hamburger's width */
+    }
+
+    div#header a.logo {
+        display: none;
+    }
+
+    span#d-language-mobilehelper {
+        display: inline-block;
+        vertical-align: middle;
+        line-height: 1.0;
+    }
+
+    div#header a#d-language {
+        position: static;
+        display: table-cell;
+        vertical-align: middle;
+        color: white;
+        text-align: center;
+        height: 3.2em;
+        padding: 0;
+        background: transparent;
+        line-height: 1.2em;
+        background: url(../images/dlogo.png) left no-repeat;
+        background-size: 50px auto;
+        padding-left: 60px;
+        /*
+            = 50px [background image width]
+            + 10px [some space between image and text]
+        */
+    }
+
+    /* Search */
+
+    div#search-box
+    {
+        position: static;
+        text-align: center;
+        overflow: hidden;
+        margin-top: 1em;
+
+        -moz-transition: height 0.5s;
+        -webkit-transition: height 0.5s;
+        transition: height 0.5s;
+    }
+
+    div#search-query {
+        width: 40%;
+    }
+
+    /* Navigation */
+
+    div#navigation {
+        display: block;
+        position: absolute;
+        top: 0;
+        left: -20em;
+        min-height: 100%;
+        padding: 0;
+        margin: 0;
+        -moz-box-shadow: 10px 0px 20px black;
+        -webkit-box-shadow: 10px 0px 20px black;
+        box-shadow: 10px 0px 20px black;
+        z-index: 10001;
+        -moz-transition: left 0.5s;
+        -webkit-transition: left 0.5s;
+        transition: left 0.5s;
+    }
+
+    div#navigation.open{
+        left: 0;
+    }
+
+    div#navigation-cancel {
+        position: fixed;
+        left: 0; top: 0; right: 0; bottom: 0;
+        background-color: rgba(255,255,255,0.5);
+        z-index: 10000;
+    }
+
+    /* Content */
+
+    div#content {
+        -moz-border-radius: 0;
+        -webkit-border-radius: 0;
+        border-radius: 0;
+        margin-left: 0;
+        margin-right: 0 !important /* override inline style! */;
+    }
+
+    body::before { /* Disable pseudo-padding. */
+        display: none;
+    }
+
+    pre {
+        font-size: 1em;
+    }
+
+    img#github-ribbon {
+        display: none;
+    }
+
+    body#Downloads div#tools {
+        padding-right: 0;
+    }
 }
diff --git a/js/dlang.js b/js/dlang.js
index eb38438fd9..a5c7949810 100644
--- a/js/dlang.js
+++ b/js/dlang.js
@@ -1,108 +1,108 @@
 (function($) {
-	$(function() {
-		if (typeof cssmenu_no_js === 'undefined') {
-			var menu_ul = $('#cssmenu > ul > li > ul');
-			menu_ul.hide();
+    $(function() {
+        if (typeof cssmenu_no_js === 'undefined') {
+            var menu_ul = $('#cssmenu > ul > li > ul');
+            menu_ul.hide();
 
-			function baseName(str) {
-				return str.split('/').pop();
-			}
+            function baseName(str) {
+                return str.split('/').pop();
+            }
 
-			// highlight menu entry of the current page
-			var href = window.location.href.split('#')[0];
-			var current;
-			var res = $('#cssmenu a').each(function (_, a) {
-				if (a.href == href) {
-					current = a;
-					return false;
-				}
-			});
-			current = $(current);
-			// direct li parent containing the link
-			current.parent('li').addClass('active');
-			// topmost li parent, e.g. 'std'
-			current.parents('#cssmenu li.has-sub').addClass('active')
-			// show menu tree
-				.children('ul').show();
+            // highlight menu entry of the current page
+            var href = window.location.href.split('#')[0];
+            var current;
+            var res = $('#cssmenu a').each(function (_, a) {
+                if (a.href == href) {
+                    current = a;
+                    return false;
+                }
+            });
+            current = $(current);
+            // direct li parent containing the link
+            current.parent('li').addClass('active');
+            // topmost li parent, e.g. 'std'
+            current.parents('#cssmenu li.has-sub').addClass('active')
+            // show menu tree
+                .children('ul').show();
 
 
-			$('#cssmenu > ul > li > a').click(function() {
-				$li = $(this).closest('li');
-				if (!$li.hasClass('has-sub')) {
-					$('#cssmenu li').removeClass('active');
-				}
-				$li.addClass('active');
-				var checkElement = $(this).next();
-				if((checkElement.is('ul')) && (checkElement.is(':visible'))) {
-					$(this).closest('li').removeClass('active');
-					checkElement.slideUp('normal');
-				}
-				if((checkElement.is('ul')) && (!checkElement.is(':visible'))) {
-					/* $('#cssmenu ul ul:visible').slideUp('normal'); */
-					checkElement.slideDown('normal');
-				}
-				if($(this).closest('li').find('ul').children().length == 0) {
-					return true;
-				} else {
-					return false;
-				}
-			});
-		}
+            $('#cssmenu > ul > li > a').click(function() {
+                $li = $(this).closest('li');
+                if (!$li.hasClass('has-sub')) {
+                    $('#cssmenu li').removeClass('active');
+                }
+                $li.addClass('active');
+                var checkElement = $(this).next();
+                if((checkElement.is('ul')) && (checkElement.is(':visible'))) {
+                    $(this).closest('li').removeClass('active');
+                    checkElement.slideUp('normal');
+                }
+                if((checkElement.is('ul')) && (!checkElement.is(':visible'))) {
+                    /* $('#cssmenu ul ul:visible').slideUp('normal'); */
+                    checkElement.slideDown('normal');
+                }
+                if($(this).closest('li').find('ul').children().length == 0) {
+                    return true;
+                } else {
+                    return false;
+                }
+            });
+        }
 
-		$('#mobile-hamburger').click(function() {
-			var duration = 500;
-			$("#navigation").addClass('open');
-			var $cancel = $('
') - .attr('id', 'navigation-cancel') - .click(function() { - $("#navigation").removeClass('open'); - $cancel.fadeOut(duration, function() { - $cancel.remove(); - }); - $cancel.off(); - }) - .hide() - .appendTo('body') - .fadeIn(500) - ; - }); + $('#mobile-hamburger').click(function() { + var duration = 500; + $("#navigation").addClass('open'); + var $cancel = $('
') + .attr('id', 'navigation-cancel') + .click(function() { + $("#navigation").removeClass('open'); + $cancel.fadeOut(duration, function() { + $cancel.remove(); + }); + $cancel.off(); + }) + .hide() + .appendTo('body') + .fadeIn(500) + ; + }); - // [your code here] rotation for index.html - var $examples = $('.your-code-here-extra > pre'); - if ($examples.length) { - var n = Math.floor(Math.random() * ($examples.length+1)); - if (n) - $('#your-code-here-default > pre').replaceWith($examples[n-1]); - } + // [your code here] rotation for index.html + var $examples = $('.your-code-here-extra > pre'); + if ($examples.length) { + var n = Math.floor(Math.random() * ($examples.length+1)); + if (n) + $('#your-code-here-default > pre').replaceWith($examples[n-1]); + } - // Insert the show/hide button if the contents section exists - $('.page-contents-header').append('[hide]'); + // Insert the show/hide button if the contents section exists + $('.page-contents-header').append('[hide]'); - // Event to hide or show the "contents" section when the hide button - // is clicked - $(".page-contents-header a").click(function () { - var elem = $('.page-contents > ol'); + // Event to hide or show the "contents" section when the hide button + // is clicked + $(".page-contents-header a").click(function () { + var elem = $('.page-contents > ol'); - if (elem.is(':visible')) { - $(this).text("[show]"); - elem.hide(); - } else { - $(this).text("[hide]"); - elem.show(); - } - }); - }); + if (elem.is(':visible')) { + $(this).text("[show]"); + elem.hide(); + } else { + $(this).text("[hide]"); + elem.show(); + } + }); + }); })(jQuery); // "This Week in D" integration // setTwid is called from http://arsdnet.net/this-week-in-d/twid-latest.js // which is included in index.html function setTwid(url, title, description) { - $('table.notice-table td:first-child').html( - $('') - .attr('href', url) - .append($('').text(title + ':')) - .append($('
')) - .append($('').text(description)) - ); + $('table.notice-table td:first-child').html( + $('
') + .attr('href', url) + .append($('').text(title + ':')) + .append($('
')) + .append($('').text(description)) + ); } diff --git a/spec/function.dd b/spec/function.dd index 3a9da02800..fbe64e7e1f 100644 --- a/spec/function.dd +++ b/spec/function.dd @@ -142,13 +142,13 @@ $(GNAME BodyStatement): $(H4 $(LNAME2 contracts, Contracts)) - $(P The $(D in) and $(D out) blocks of a function declaration specify - the pre- and post-conditions of the function. They are used in - $(LINK2 contracts.html, Contract Programming). - The code inside these blocks should - not have any side-effects, including modifying function parameters - and/or return values. - ) + $(P The $(D in) and $(D out) blocks of a function declaration specify + the pre- and post-conditions of the function. They are used in + $(LINK2 contracts.html, Contract Programming). + The code inside these blocks should + not have any side-effects, including modifying function parameters + and/or return values. + ) $(H4 $(LNAME2 function-return-values, Function Return Values)) @@ -158,24 +158,24 @@ $(H4 $(LNAME2 function-return-values, Function Return Values)) $(H4 $(LNAME2 function-declarations, Functions Without Bodies)) - $(P Functions without bodies:) + $(P Functions without bodies:) --- int foo(); --- - $(P that are not declared as $(D abstract) are expected to have their implementations - elsewhere, and that implementation will be provided at the link step. - This enables an implementation of a function to be completely hidden from the user - of it, and the implementation may be in another language such as C, assembler, etc. - ) + $(P that are not declared as $(D abstract) are expected to have their implementations + elsewhere, and that implementation will be provided at the link step. + This enables an implementation of a function to be completely hidden from the user + of it, and the implementation may be in another language such as C, assembler, etc. + ) $(H4 $(LNAME2 pure-functions, Pure Functions)) $(P Pure functions are functions which cannot access global or static, mutable state save through their arguments. - This enables optimizations based on the fact that a pure function may at most mutate state - reachable through its parameters. + This enables optimizations based on the fact that a pure function may at most mutate state + reachable through its parameters. To that end, a pure function: ) @@ -418,21 +418,21 @@ $(H4 $(LNAME2 inout-functions, Inout Functions)) $(H4 $(LNAME2 optional-parenthesis, Optional Parentheses)) - $(P If a function call passes no explicit argument, i.e. it would syntactically use $(D ()), then these parentheses - may be omitted, similar to a getter invocation of a + $(P If a function call passes no explicit argument, i.e. it would syntactically use $(D ()), then these parentheses + may be omitted, similar to a getter invocation of a $(RELATIVE_LINK2 property-functions, property function). ) --- void foo() {} // no arguments - void fun(int x = 10) { } + void fun(int x = 10) { } void bar(int[] arr) {} // for UFCS void main() { foo(); // OK foo; // also OK - fun; // OK + fun; // OK int[] arr; arr.bar(); // OK @@ -440,129 +440,129 @@ $(H4 $(LNAME2 optional-parenthesis, Optional Parentheses)) } --- - $(P Optional parentheses are not applied to delegates or function pointers.) + $(P Optional parentheses are not applied to delegates or function pointers.) - --- - void main() - { - int function() fp; + --- + void main() + { + int function() fp; - assert(fp == 6); // Error, incompatible types int function() and int - assert(*fp == 6); // Error, incompatible types int() and int + assert(fp == 6); // Error, incompatible types int function() and int + assert(*fp == 6); // Error, incompatible types int() and int - int delegate() dg; - assert(dg == 6); // Error, incompatible types int delegate() and int - } - --- + int delegate() dg; + assert(dg == 6); // Error, incompatible types int delegate() and int + } + --- - $(P If a function returns a delegate or function pointer, the parantheses are required if the - returned value is to be called. - ) + $(P If a function returns a delegate or function pointer, the parantheses are required if the + returned value is to be called. + ) - --- - struct S { - int function() callfp() { return &numfp; } - int delegate() calldg() { return &numdg; } - int numdg() { return 6; } - } + --- + struct S { + int function() callfp() { return &numfp; } + int delegate() calldg() { return &numdg; } + int numdg() { return 6; } + } - int numfp() { return 6; } + int numfp() { return 6; } - void main() - { - S s; - int function() fp; + void main() + { + S s; + int function() fp; - fp = s.callfp; - assert(fp() == 6); + fp = s.callfp; + assert(fp() == 6); - fp = s.callfp(); - assert(fp() == 6); + fp = s.callfp(); + assert(fp() == 6); - int x = s.callfp()(); - assert(x == 6); + int x = s.callfp()(); + assert(x == 6); - int delegate() dg; + int delegate() dg; - dg = s.calldg; - assert(dg() == 6); + dg = s.calldg; + assert(dg() == 6); - dg = s.calldg(); - assert(dg() == 6); + dg = s.calldg(); + assert(dg() == 6); - int y = s.calldg()(); - assert(y == 6); - } - --- + int y = s.calldg()(); + assert(y == 6); + } + --- $(H4 $(LNAME2 property-functions, Property Functions)) - $(P Properties are functions that can be syntactically treated - as if they were fields or variables. Properties can be read from or written to. - A property is read by calling a method or function with no arguments; - a property is written by calling a method or function with its argument - being the value it is set to. - ) - - $(P Simple getter and setter properties can be written using $(LINK2 pseudo-member, UFCS). - These can be enhanced with the additon of the $(D @property) attribute to the function, which - adds the following behaviors: - ) - - $(UL - $(LI $(D @property) functions cannot be overloaded with non-$(D @property) functions with the same name.) - $(LI $(D @property) functions can only have zero, one or two parameters.) - $(LI $(D @property) functions cannot have variadic parameters.) - $(LI For the expression $(D typeof(exp)) where $(D exp) is an $(D @property) function, - the type is the return type of the function, rather than the type of the function.) - $(LI For the expression $(D __traits(compiles, exp)) where $(D exp) is an $(D @property) function, - a further check is made to see if the function can be called.) - $(LI $(D @property) are mangled differently, meaning that $(D @property) must be consistently - used across different compilation units.) - $(LI The ObjectiveC interface recognizes $(D @property) setter functions as special and modifies - them accordingly.) - ) - - $(P A simple property would be:) - - - --- - struct Foo - { - @property int data() { return m_data; } // read property - - @property int data(int value) { return m_data = value; } // write property - - private: - int m_data; - } - --- - - $(P To use it:) - - --- - int test() - { - Foo f; - - f.data = 3; // same as f.data(3); - return f.data + 3; // same as return f.data() + 3; - } - --- - - $(P The absence of a read method means that the property is write-only. - The absence of a write method means that the property is read-only. - Multiple write methods can exist; the correct one is selected using - the usual function overloading rules. - ) - - $(P In all the other respects, these methods are like any other methods. - They can be static, have different linkages, have their address taken, etc. - ) - - $(P The built in properties $(D .sizeof), $(D .alignof), and $(D .mangleof) - may not be declared as fields or methods in structs, unions, classes or enums. - ) + $(P Properties are functions that can be syntactically treated + as if they were fields or variables. Properties can be read from or written to. + A property is read by calling a method or function with no arguments; + a property is written by calling a method or function with its argument + being the value it is set to. + ) + + $(P Simple getter and setter properties can be written using $(LINK2 pseudo-member, UFCS). + These can be enhanced with the additon of the $(D @property) attribute to the function, which + adds the following behaviors: + ) + + $(UL + $(LI $(D @property) functions cannot be overloaded with non-$(D @property) functions with the same name.) + $(LI $(D @property) functions can only have zero, one or two parameters.) + $(LI $(D @property) functions cannot have variadic parameters.) + $(LI For the expression $(D typeof(exp)) where $(D exp) is an $(D @property) function, + the type is the return type of the function, rather than the type of the function.) + $(LI For the expression $(D __traits(compiles, exp)) where $(D exp) is an $(D @property) function, + a further check is made to see if the function can be called.) + $(LI $(D @property) are mangled differently, meaning that $(D @property) must be consistently + used across different compilation units.) + $(LI The ObjectiveC interface recognizes $(D @property) setter functions as special and modifies + them accordingly.) + ) + + $(P A simple property would be:) + + + --- + struct Foo + { + @property int data() { return m_data; } // read property + + @property int data(int value) { return m_data = value; } // write property + + private: + int m_data; + } + --- + + $(P To use it:) + + --- + int test() + { + Foo f; + + f.data = 3; // same as f.data(3); + return f.data + 3; // same as return f.data() + 3; + } + --- + + $(P The absence of a read method means that the property is write-only. + The absence of a write method means that the property is read-only. + Multiple write methods can exist; the correct one is selected using + the usual function overloading rules. + ) + + $(P In all the other respects, these methods are like any other methods. + They can be static, have different linkages, have their address taken, etc. + ) + + $(P The built in properties $(D .sizeof), $(D .alignof), and $(D .mangleof) + may not be declared as fields or methods in structs, unions, classes or enums. + ) $(P If a property function has no parameters, it works as a getter. If has exactly one parameter, it works as a setter. @@ -1043,23 +1043,23 @@ int foo(in int x, out int y, ref int z, int q); possibly better code generation.) ) - $(TABLE_2COLS Parameter Storage Classes, - $(THEAD Storage Class, Description) - $(TROW $(I none), parameter becomes a mutable copy of its argument) + $(TABLE_2COLS Parameter Storage Classes, + $(THEAD Storage Class, Description) + $(TROW $(I none), parameter becomes a mutable copy of its argument) - $(TROW $(D in), equivalent to $(D const scope)) - $(TROW $(D out), parameter is initialized upon function entry with the default value - for its type) + $(TROW $(D in), equivalent to $(D const scope)) + $(TROW $(D out), parameter is initialized upon function entry with the default value + for its type) - $(TROW $(D ref), parameter is passed by reference) - $(TROW $(D scope), references in the parameter - cannot be escaped (e.g. assigned to a global variable)) - $(TROW $(D lazy), argument is evaluated by the called function and not by the caller) - $(TROW $(D const), argument is implicitly converted to a const type) - $(TROW $(D immutable), argument is implicitly converted to an immutable type) - $(TROW $(D shared), argument is implicitly converted to a shared type) - $(TROW $(D inout), argument is implicitly converted to an inout type) - ) + $(TROW $(D ref), parameter is passed by reference) + $(TROW $(D scope), references in the parameter + cannot be escaped (e.g. assigned to a global variable)) + $(TROW $(D lazy), argument is evaluated by the called function and not by the caller) + $(TROW $(D const), argument is implicitly converted to a const type) + $(TROW $(D immutable), argument is implicitly converted to an immutable type) + $(TROW $(D shared), argument is implicitly converted to a shared type) + $(TROW $(D inout), argument is implicitly converted to an inout type) + ) ------ void foo(out int x) @@ -1182,11 +1182,11 @@ extern (C) int def(...); // error, must have at least one parameter C-style variadic functions match the C calling convention for variadic functions, and is most useful for calling C library functions like $(D printf). - ) + ) - $(P Access to variadic arguments is done using the standard library - module $(D core.stdc.stdarg). - ) + $(P Access to variadic arguments is done using the standard library + module $(D core.stdc.stdarg). + ) ------ import core.stdc.stdarg; @@ -1229,7 +1229,7 @@ int abc(char c, ...); // one required parameter: c int def(...); // ok ------ - To access them, the following import is required: + To access them, the following import is required: ------ import core.vararg; @@ -1238,9 +1238,9 @@ import core.vararg; These variadic functions have a special local variable declared for them, $(D _argptr), which is a $(D core.vararg) - reference to the first of the variadic + reference to the first of the variadic arguments. To access the arguments, $(D _argptr) must be used - in conjuction with $(D va_arg): + in conjuction with $(D va_arg): ------ import core.vararg; @@ -1522,11 +1522,11 @@ void func(int x) $(H3 $(LEGACY_LNAME2 Local Static Variables, local-static-variables, Local Static Variables)) - $(P Local variables in functions can be declared as static - or $(D __gshared) in which case they are statically allocated - rather than being allocated on the stack. - As such, their value persists beyond the exit of the function. - ) + $(P Local variables in functions can be declared as static + or $(D __gshared) in which case they are statically allocated + rather than being allocated on the stack. + As such, their value persists beyond the exit of the function. + ) --- void foo() @@ -1537,16 +1537,16 @@ void foo() } --- - $(P The initializer for a static variable must be evaluatable at - compile time, and they are initialized upon the start of the thread - (or the start of the program for $(D __gshared)). - There are no static constructors or static destructors - for static local variables. - ) + $(P The initializer for a static variable must be evaluatable at + compile time, and they are initialized upon the start of the thread + (or the start of the program for $(D __gshared)). + There are no static constructors or static destructors + for static local variables. + ) - $(P Although static variable name visibility follows the usual scoping - rules, the names of them must be unique within a particular function. - ) + $(P Although static variable name visibility follows the usual scoping + rules, the names of them must be unique within a particular function. + ) --- void main() @@ -1789,7 +1789,7 @@ void test() ) - $(P Nested functions cannot be overloaded.) + $(P Nested functions cannot be overloaded.) $(H4 $(LNAME2 closures, Delegates, Function Pointers, and Closures)) @@ -2070,15 +2070,15 @@ static assert(countTen(12) == 12); // invalid, modifies y. ) - $(P In order to be executed at compile time, the function - must appear in a context where it must be so executed, for - example:) + $(P In order to be executed at compile time, the function + must appear in a context where it must be so executed, for + example:) - $(UL - $(LI initialization of a static variable) - $(LI dimension of a static array) - $(LI argument for a template value parameter) - ) + $(UL + $(LI initialization of a static variable) + $(LI dimension of a static array) + $(LI argument for a template value parameter) + ) --- template eval( A... ) @@ -2263,11 +2263,11 @@ $(H3 $(LNAME2 pseudo-member, Uniform Function Call Syntax (UFCS))) // it's automatically rewritten to 'func(obj)' --- - $(P This provides a way to add functions to a class externally as if they were - public final member functions, which enables - $(WEB www.drdobbs.com/architecture-and-design/component-programming-in-d/240008321, - function chaining and component programming). - ) + $(P This provides a way to add functions to a class externally as if they were + public final member functions, which enables + $(WEB www.drdobbs.com/architecture-and-design/component-programming-in-d/240008321, + function chaining and component programming). + ) --- stdin.byLine(KeepTerminator.yes)