Skip to content

Instantly share code, notes, and snippets.

View ikhoon's full-sized avatar
🐱
Working from home

Ikhun Um ikhoon

🐱
Working from home
View GitHub Profile
@ikhoon
ikhoon / learning-shapeless.md
Last active October 18, 2018 08:51
Learning Materials for generic & dependent programming using shapeless
@ikhoon
ikhoon / Contravariant.scala
Last active June 10, 2022 05:59
왜 함수의 input은 반공변성인가?
// https://twitter.github.io/scala_school/type-basics.html
// 트위터 스칼라 스쿨에 나오는 자료구조를 활용해보겠다.
class Animal { val sound = "rustle" }
class Bird extends Animal { override val sound = "call" }
class Chicken extends Bird { override val sound = "cluck" }
class Duck extends Bird { override val sound = "duck" }
def foo(tweet: Bird => String) = {
tweet(new Bird)
object TwiiterScalaFutureOps {
import TwitterScalaFutureConverters._
implicit class ScalaToTwitterFuture[T](f: Future[T]) {
def toTwitterFuture: twitter.Future[T] = scalaToTwitterFuture(f)
}
implicit class TwitterToScalaFuture[T](f: twitter.Future[T]) {
def toScalaFuture: Future[T] = twitterToScalaFuture(f)
}
@ikhoon
ikhoon / scaladays2017_cph.md
Created February 12, 2017 12:19
스칼라데이즈 2017 코펜하겐
@ikhoon
ikhoon / must-watch-talks.md
Last active April 14, 2020 10:46
Must watch talks - reddit /r/scala
@ikhoon
ikhoon / Java8TimeTest.java
Created August 31, 2016 06:25
Java8 Time API 기능 비교
import org.junit.Test;
import java.time.Instant;
import java.time.OffsetDateTime;
import java.time.ZonedDateTime;
import java.time.format.DateTimeParseException;
public class Java8TimeTest {
private String instantFormat = "2007-12-03T10:14:30.000Z";