# Heading 1 标题一

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. 这是一段测试文字。这是一段测试文字。

# Heading 2 标题二

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. 这是一段测试文字。这是一段测试文字。

# Heading 3 标题三

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. 这是一段测试文字。这是一段测试文字。

# Heading 4 标题四

data HinaError
  = HEParse (Report T.Text [Token])
  | HEResolve ResolveError
  | HETyck TyckError
  deriving (Show)

type HinaEff m = (Members '[Error HinaError, State CoreMapping] m, FreshEff m)

hina :: HinaEff m => T.Text -> Eff m [Core.Def]
hina txt = do
  let tokens = tokenize (T.unpack txt)
  ast <- case fullParses (parser prog) tokens of
    ([x], _) -> pure x
    (_, r)   -> throwError $ HEParse r
  resolved <- runError $ evalState (ResolveContext Map.empty Map.empty) $ resolveAll ast
  resolved' <- case resolved of
    Left e  -> throwError (HEResolve e)
    Right x -> pure x
  headChecked <- runError $ evalState (LocalCtx IntMap.empty) $ traverse checkHead resolved'
  case headChecked of
    Left e  -> throwError (HETyck e)
    Right _ -> pure ()
  bodyChecked <- runError $ evalState (LocalCtx IntMap.empty) $ traverse checkBody resolved'
  case bodyChecked of
    Left e  -> throwError (HETyck e)
    Right x -> pure x

runHina :: T.Text -> Either HinaError [Core.Def]
runHina = run . runError . evalState (CoreMapping IntMap.empty) . evalFresh 0 . hina
# Heading 5 标题五
This Is A Table
Row1 - - -
Row2 2 - -
Row3 3 3 -
Row4 4 4 4
# Heading 6 标题六

BERRYMAN-LANGFORD

copy: Feather fractal, Kevin Dooley, CC-BY 2.0, src.