pが十分小さい場合の近似として、次の式がよく用いられる:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/discouraged.rs b/src/discouraged.rs | |
index fb98d633..059b7351 100644 | |
--- a/src/discouraged.rs | |
+++ b/src/discouraged.rs | |
@@ -170,7 +170,7 @@ impl<'a> Speculative for ParseBuffer<'a> { | |
match (fork_sp, self_sp) { | |
// Unexpected set on the fork, but not on `self`, copy it over. | |
(Some(span), None) => { | |
- self_unexp.set(Unexpected::Some(span)); | |
+ self_unexp.set(Unexpected::Some(span.0, span.1)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with import <nixpkgs> {}; | |
with lib; | |
let | |
antoyoGccRev = "72cb89f82a6c9c5471f0b2c122b21dbe387c7904"; | |
gccjit = (gcc11.cc.overrideAttrs (oldAttrs: oldAttrs // { | |
src = fetchFromGitHub { | |
owner = "antoyo"; | |
repo = "gcc"; | |
rev = antoyoGccRev; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ FARCRI_TARGET=nucleo_f401re cargo criterion --plotting-backend gnuplot --bench binsearch | |
... | |
Binary Search Increasing/std/L1 | |
time: [114.01 cycles 114.01 cycles 114.01 cycles] | |
Binary Search Increasing/custom_1/L1 | |
time: [108.01 cycles 108.01 cycles 108.01 cycles] | |
Binary Search Increasing/std/L2 | |
time: [150.01 cycles 150.01 cycles 150.01 cycles] | |
Binary Search Increasing/custom_1/L2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<snippet> | |
<content><![CDATA[ | |
“${1:lorem ipsum}” | |
]]></content> | |
<!-- Optional: Set a tabTrigger to define how to trigger the snippet --> | |
<tabTrigger>""</tabTrigger> | |
<!-- Optional: Set a scope to limit where the snippet will trigger --> | |
<!-- <scope>text.foremark</scope> --> | |
</snippet> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
function genquery { | |
# Login to VLC's telnet interface | |
echo Password | |
# Submit the command | |
echo "$@" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#version 310 es | |
precision mediump float; | |
const uint local_size = 64u; | |
const uint kernel_size = 4u; | |
layout(local_size_x = 64 /* local_size */) in; | |
shared uint in_values[local_size + kernel_size - 1u]; | |
shared uint kernel_values[kernel_size]; |
TypeScriptをブラウザで直接実行できるようにするの、全くもって利点が無いんだよね。理由は数え切れないほどあって、その一つが実行効率。TypeScriptは静的型付け言語の一つではあるけど、他の同種の言語と大きく異なるのは、実行効率ではなく動的型付けの世界で書かれたものをうまくキャプチャするように設計されているから、一般的な静的型付け言語と同様の方法でコンパイルすると一部の特別なケースでしか効率良く実行できない (実際、HaxeのC++バックエンドもインタフェース呼び出しが低速だよね)。
もう一つは読み込み速度。まずそもそも何故静的型付け言語が(一般に)高速に実行できるかと考えると、事前に型に関する情報があるからそれに基づいて最適化が行えるから。例えば a + b
のオペランドが両方とも int
だと分かっていれば +
に関して動的ディスパッチを行う必要はない。他の例を挙げると、ジェネリック関数は型引数ごとに特殊化 (Rustのコンテクストではmonomorphizationと呼ばれる) すればそこから新たな最適化の可能性が導き出せる。こうした最適化を行うことを前提とした場合、誤った型のデータが入力された場合に備え、型チェックを行うことは必須になる。
(todo)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sun Feb 26 01:32:08 2017 flutershy : best frags best ratio best skill best IQ best pony ever | |
Sun Feb 26 02:36:27 2017 flutterholly has a kill-death ratio of 3.10, headshot-death ratio of 2.90 (31 kills, 10 | |
Sun Feb 26 02:36:27 2017 deaths, 29 headshot, 0 melee, 0 grenade). | |
Sun Feb 26 02:36:27 2017 flutterholly removed 763 blocks in the last 2 minutes. Some of them were placed by | |
Sun Feb 26 02:36:27 2017 francisco, yeetypete. Last one was destroyed 3 seconds ago, and belonged to yeetypete. | |
Sun Feb 26 02:36:27 2017 flutershy started a VOTEKICK against flutterholly. Say /Y to agree | |
Sun Feb 26 02:36:27 2017 Reason: brasilian homohax | |
Sun Feb 26 02:36:35 2017 catnip voted YES |
http://affinelayer.com/pixsrv/index.html
var x=getEventListeners(document)['mousemove'][0].listener,y=getEventListeners(document)['mousedown'][0].listener;
document.removeEventListener('mousedown',y);
document.addEventListener('mousedown',function(e){x(e);window.requestAnimationFrame(function(){y(e)});});
NewerOlder