Skip to content

Instantly share code, notes, and snippets.

View keizo042's full-sized avatar

Koichi Nakanishi keizo042

  • japanese company
  • Japan
View GitHub Profile
// when depoyment
//
// $ gcc sample.c main.c -o sample
// when testing
//
// $ gcc -DDEBUG sample.c test/test_main.c -o test/test
#include <stdio.h>
#define FAIL 1
Theorem plus_comm : forall n m : nat,
n + m = m + n.
Proof.
intros.
induction n.
induction m.
reflexivity.
We couldn’t find that file to show.
We couldn’t find that file to show.

quic frame degin idea

class Greeding
@@hello =nil
def self.hello=(word)
@@hello = word
end
def hello
@@hello
end
end
/usr/local/Cellar/ruby/2.4.1_1/lib/ruby/2.4.0/openssl/buffering.rb:125:in `sysread': end of file reached (EOFError)
	from /usr/local/Cellar/ruby/2.4.1_1/lib/ruby/2.4.0/openssl/buffering.rb:125:in `readpartial'
	from /usr/local/lib/ruby/gems/2.4.0/gems/twitter-6.1.0/lib/twitter/streaming/connection.rb:21:in `stream'
	from /usr/local/lib/ruby/gems/2.4.0/gems/twitter-6.1.0/lib/twitter/streaming/client.rb:119:in `request'
	from /usr/local/lib/ruby/gems/2.4.0/gems/twitter-6.1.0/lib/twitter/streaming/client.rb:92:in `user'
	from /usr/local/lib/ruby/gems/2.4.0/gems/t-3.1.0/lib/t/stream.rb:146:in `timeline'
	from /usr/local/lib/ruby/gems/2.4.0/gems/thor-0.19.4/lib/thor/command.rb:27:in `run'
	from /usr/local/lib/ruby/gems/2.4.0/gems/thor-0.19.4/lib/thor/invocation.rb:126:in `invoke_command'
	from /usr/local/lib/ruby/gems/2.4.0/gems/thor-0.19.4/lib/thor.rb:369:in `dispatch'
@keizo042
keizo042 / client.hs
Created August 10, 2017 15:57
Dummy Code to ideal sample for "quic" package
module Main where
import Network.QUIC
-- Dummy Code : Simple QUIC Client to Echo Server
main = do
manager <- newManager defaultManagerSettings
ctx <- handshake manager "loclahost" 8080
send ctx "1st hello"
newManager :: ManagerSetting -> IO Manager
newManager = undefined
open :: Manager -> String -> Int -> IO Context
open = undefined
connect :: Context -> IO ()
connect = undefined