This file contains hidden or 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
| package org.example; | |
| import static java.lang.reflect.AccessFlag.PUBLIC; | |
| import static java.lang.reflect.AccessFlag.STATIC; | |
| import static java.util.Objects.requireNonNull; | |
| import static java.util.function.Function.identity; | |
| import static org.example.Functions.curry; | |
| import static org.example.Functions.flip; | |
| import static org.example.TyEq.refl; | |
| import static org.example.TypeClass.Witness.Overlap.OVERLAPPABLE; |
This file contains hidden or 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
| _hashCode java/lang/Object.hashCode()I | |
| _getClass java/lang/Object.getClass()Ljava/lang/Class; | |
| _clone java/lang/Object.clone()Ljava/lang/Object; | |
| _dabs java/lang/Math.abs(D)D | |
| _dsin java/lang/Math.sin(D)D | |
| _dcos java/lang/Math.cos(D)D | |
| _dtan java/lang/Math.tan(D)D | |
| _datan2 java/lang/Math.atan2(DD)D | |
| _dsqrt java/lang/Math.sqrt(D)D | |
| _dlog java/lang/Math.log(D)D |
This file contains hidden or 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
| Welcome to Scala version 2.10.2 (Java HotSpot(TM) 64-Bit Server VM, Java 1.7.0_21). | |
| Type in expressions to have them evaluated. | |
| Type :help for more information. | |
| scala> import shapeless._ ; import SingletonTypes._ ; import Record._ | |
| import shapeless._ | |
| import SingletonTypes._ | |
| import Record._ | |
| scala> :paste |
This file contains hidden or 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
| // a.scala | |
| // Fri Jun 29 16:15:08 PDT 2012 | |
| import scala.reflect.makro.Context | |
| import collection.mutable.ListBuffer | |
| import collection.mutable.Stack | |
| import language.experimental.macros | |
| object Macros { | |
| val conversionChars = "%BbCcdEefGgHhinosuXx" |
This file contains hidden or 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
| {-# LANGUAGE GADTs #-} | |
| {-# LANGUAGE RankNTypes #-} | |
| {-# LANGUAGE StandaloneDeriving #-} | |
| module RedBlackTree where | |
| data Zero | |
| data Succ n | |
| type One = Succ Zero | |
| data Black |