-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WIP: Add stub of JavaScript target #109
Conversation
9c6e975
to
8ab0f6b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Though I'm aware that it's working in progress, I left some comments.
@@ -135,6 +144,7 @@ test-suite spec | |||
, nirum | |||
, parsec | |||
-- only for dealing with htoml's ParserError | |||
, pretty >=1.1.3 && <2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As aeson
,aeson-pretty
and pretty
are common dependencies to library
and test-suite spec
, it'd better omit version specifies here.
@@ -0,0 +1,84 @@ | |||
{-# LANGUAGE FlexibleInstances, GeneralizedNewtypeDeriving, MultiParamTypeClasses, TypeOperators #-} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please keep shorter than 80 columns for each line.
toJavaScriptFilename :: ModulePath -> [FilePath] | ||
toJavaScriptFilename mp = | ||
case mp of | ||
ModulePath { .. } -> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can simply match this by ModulePath {} ->
.
| i <- toList path | ||
] | ||
++ [ f moduleName ] | ||
ModuleName { .. } -> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
|
||
|
||
compileModule :: Module -> CodeBuilder () | ||
compileModule Module {..} = do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
야 신 난 다